Blender V2.61 - r43446

DNA_space_types.h

Go to the documentation of this file.
00001 /*
00002  * ***** BEGIN GPL LICENSE BLOCK *****
00003  *
00004  * This program is free software; you can redistribute it and/or
00005  * modify it under the terms of the GNU General Public License
00006  * as published by the Free Software Foundation; either version 2
00007  * of the License, or (at your option) any later version.
00008  *
00009  * This program is distributed in the hope that it will be useful,
00010  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012  * GNU General Public License for more details.
00013  *
00014  * You should have received a copy of the GNU General Public License
00015  * along with this program; if not, write to the Free Software Foundation,
00016  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
00017  *
00018  * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
00019  * All rights reserved.
00020  *
00021  * The Original Code is: all of this file.
00022  *
00023  * Contributor(s): none yet.
00024  *
00025  * ***** END GPL LICENSE BLOCK *****
00026  */
00033 #ifndef DNA_SPACE_TYPES_H
00034 #define DNA_SPACE_TYPES_H
00035 
00036 #include "DNA_defs.h"
00037 #include "DNA_listBase.h"
00038 #include "DNA_color_types.h"        /* for Histogram */
00039 #include "DNA_vec_types.h"
00040 #include "DNA_outliner_types.h"     /* for TreeStoreElem */
00041 #include "DNA_image_types.h"    /* ImageUser */
00042 #include "DNA_movieclip_types.h"    /* MovieClipUser */
00043 /* Hum ... Not really nice... but needed for spacebuts. */
00044 #include "DNA_view2d_types.h"
00045 
00046 struct ID;
00047 struct Text;
00048 struct Script;
00049 struct bSound;
00050 struct ImBuf;
00051 struct Image;
00052 struct Scopes;
00053 struct Histogram;
00054 struct SpaceIpo;
00055 struct BlendHandle;
00056 struct RenderInfo;
00057 struct bNodeTree;
00058 struct uiBlock;
00059 struct FileList;
00060 struct bGPdata;
00061 struct bDopeSheet;
00062 struct FileSelectParams;
00063 struct FileLayout;
00064 struct bScreen;
00065 struct Scene;
00066 struct wmOperator;
00067 struct wmTimer;
00068 struct MovieClip;
00069 struct MovieClipScopes;
00070 
00077 typedef struct SpaceLink {
00078     struct SpaceLink *next, *prev;
00079     ListBase regionbase;        /* storage of regions for inactive spaces */
00080     int spacetype;
00081     float blockscale  DNA_DEPRECATED;       /* XXX make deprecated */
00082     short blockhandler[8]  DNA_DEPRECATED;  /* XXX make deprecated */
00083 } SpaceLink;
00084 
00085 typedef struct SpaceInfo {
00086     SpaceLink *next, *prev;
00087     ListBase regionbase;        /* storage of regions for inactive spaces */
00088     int spacetype;
00089     float blockscale  DNA_DEPRECATED;
00090 
00091     short blockhandler[8]  DNA_DEPRECATED;      /* XXX make deprecated */
00092     
00093     char rpt_mask;
00094     char pad[7];
00095     
00096 } SpaceInfo;
00097 
00098 /* SpaceInfo.rpt_mask */
00099 enum {
00100     INFO_RPT_DEBUG  = 1<<0,
00101     INFO_RPT_INFO   = 1<<1,
00102     INFO_RPT_OP     = 1<<2,
00103     INFO_RPT_WARN   = 1<<3,
00104     INFO_RPT_ERR        = 1<<4,
00105 };
00106 
00107 /* 'Graph' Editor (formerly known as the IPO Editor) */
00108 typedef struct SpaceIpo {
00109     SpaceLink *next, *prev;
00110     ListBase regionbase;        /* storage of regions for inactive spaces */
00111     int spacetype;
00112     float blockscale  DNA_DEPRECATED;
00113 
00114     short blockhandler[8]  DNA_DEPRECATED;
00115     View2D v2d  DNA_DEPRECATED; /* deprecated, copied to region */
00116     
00117     struct bDopeSheet *ads; /* settings for filtering animation data (NOTE: we use a pointer due to code-linking issues) */
00118     
00119     ListBase ghostCurves;   /* sampled snapshots of F-Curves used as in-session guides */
00120     
00121     short mode;             /* mode for the Graph editor (eGraphEdit_Mode) */
00122     short autosnap;         /* time-transform autosnapping settings for Graph editor (eAnimEdit_AutoSnap in DNA_action_types.h) */
00123     int flag;               /* settings for Graph editor */
00124     
00125     float cursorVal;        /* cursor value (y-value, x-value is current frame) */
00126     int around;             /* pivot point for transforms */
00127 } SpaceIpo;
00128 
00129 typedef struct SpaceButs {
00130     SpaceLink *next, *prev;
00131     ListBase regionbase;        /* storage of regions for inactive spaces */
00132     int spacetype;
00133     float blockscale  DNA_DEPRECATED;
00134     
00135     short blockhandler[8]  DNA_DEPRECATED;
00136 
00137     View2D v2d  DNA_DEPRECATED;                     /* deprecated, copied to region */
00138     
00139     short mainb, mainbo, mainbuser; /* context tabs */
00140     short re_align, align;          /* align for panels */
00141     short preview;                  /* preview is signal to refresh */
00142     short texture_context;          /* texture context selector (material, world, brush)*/
00143     char flag, pad;
00144     
00145     void *path;                     /* runtime */
00146     int pathflag, dataicon;         /* runtime */
00147     ID *pinid;
00148 
00149     void *texuser;
00150 } SpaceButs;
00151 
00152 typedef struct SpaceSeq {
00153     SpaceLink *next, *prev;
00154     ListBase regionbase;        /* storage of regions for inactive spaces */
00155     int spacetype;
00156     float blockscale  DNA_DEPRECATED;
00157 
00158     short blockhandler[8]  DNA_DEPRECATED;
00159 
00160     View2D v2d  DNA_DEPRECATED; /* deprecated, copied to region */
00161     
00162     float xof  DNA_DEPRECATED, yof  DNA_DEPRECATED; /* deprecated: offset for drawing the image preview */
00163     short mainb;    /* weird name for the sequencer subtype (seq, image, luma... etc) */
00164     short render_size;
00165     short chanshown;
00166     short zebra;
00167     int flag;
00168     float zoom  DNA_DEPRECATED; /* deprecated, handled by View2D now */
00169     int view; /* see SEQ_VIEW_* below */
00170     int pad;
00171 
00172     struct bGPdata *gpd;        /* grease-pencil data */
00173 } SpaceSeq;
00174 
00175 typedef struct FileSelectParams {
00176     char title[32]; /* title, also used for the text of the execute button */
00177     char dir[240]; /* directory */
00178     char file[80]; /* file */
00179     char renamefile[80];
00180     char renameedit[80]; /* annoying but the first is only used for initialization */
00181 
00182     char filter_glob[64]; /* list of filetypes to filter */
00183 
00184     int active_file;
00185     int sel_first;
00186     int sel_last;
00187 
00188     /* short */
00189     short type; /* XXXXX for now store type here, should be moved to the operator */
00190     short flag; /* settings for filter, hiding dots files,...  */
00191     short sort; /* sort order */
00192     short display; /* display mode flag */
00193     short filter; /* filter when (flags & FILE_FILTER) is true */
00194 
00195     /* XXX --- still unused -- */
00196     short f_fp; /* show font preview */
00197     char fp_str[8]; /* string to use for font preview */
00198 
00199     /* XXX --- end unused -- */
00200 } FileSelectParams;
00201 
00202 
00203 typedef struct SpaceFile {
00204     SpaceLink *next, *prev;
00205     ListBase regionbase;        /* storage of regions for inactive spaces */
00206     int spacetype;
00207     int scroll_offset;
00208 
00209     struct FileSelectParams *params; /* config and input for file select */
00210     
00211     struct FileList *files; /* holds the list of files to show */
00212 
00213     ListBase *folders_prev; /* holds the list of previous directories to show */
00214     ListBase *folders_next; /* holds the list of next directories (pushed from previous) to show */
00215 
00216     /* operator that is invoking fileselect 
00217        op->exec() will be called on the 'Load' button.
00218        if operator provides op->cancel(), then this will be invoked
00219        on the cancel button.
00220     */
00221     struct wmOperator *op; 
00222 
00223     struct wmTimer *smoothscroll_timer;
00224 
00225     struct FileLayout *layout;
00226     
00227     short recentnr, bookmarknr;
00228     short systemnr, pad2;
00229 } SpaceFile;
00230 
00231 typedef struct SpaceOops {
00232     SpaceLink *next, *prev;
00233     ListBase regionbase;        /* storage of regions for inactive spaces */
00234     int spacetype;
00235     float blockscale  DNA_DEPRECATED;
00236 
00237     short blockhandler[8]  DNA_DEPRECATED;
00238 
00239     View2D v2d  DNA_DEPRECATED; /* deprecated, copied to region */
00240     
00241     ListBase tree;
00242     struct TreeStore *treestore;
00243     
00244     /* search stuff */
00245     char search_string[32];
00246     struct TreeStoreElem search_tse;
00247 
00248     short flag, outlinevis, storeflag, search_flags;
00249 } SpaceOops;
00250 
00251 typedef struct SpaceImage {
00252     SpaceLink *next, *prev;
00253     ListBase regionbase;        /* storage of regions for inactive spaces */
00254     int spacetype;
00255 
00256     int flag;
00257 
00258     struct Image *image;
00259     struct ImageUser iuser;
00260     struct CurveMapping *cumap;     
00261     
00262     struct Scopes scopes;           /* histogram waveform and vectorscope */
00263     struct Histogram sample_line_hist;  /* sample line histogram */
00264 
00265     struct bGPdata *gpd;            /* grease pencil data */
00266 
00267     float cursor[2];                /* UV editor 2d cursor */
00268     float xof, yof;                 /* user defined offset, image is centered */
00269     float zoom;                     /* user defined zoom level */
00270     float centx, centy;             /* storage for offset while render drawing */
00271 
00272     short curtile; /* the currently active tile of the image when tile is enabled, is kept in sync with the active faces tile */
00273     short pad;
00274     short lock;
00275     short pin;
00276     char dt_uv; /* UV draw type */
00277     char sticky; /* sticky selection type */
00278     char dt_uvstretch;
00279     char around;
00280 } SpaceImage;
00281 
00282 typedef struct SpaceNla {
00283     struct SpaceLink *next, *prev;
00284     ListBase regionbase;        /* storage of regions for inactive spaces */
00285     int spacetype;
00286     float blockscale  DNA_DEPRECATED;
00287 
00288     short blockhandler[8]  DNA_DEPRECATED;
00289 
00290     short autosnap;         /* this uses the same settings as autosnap for Action Editor */
00291     short flag;
00292     int pad;
00293     
00294     struct bDopeSheet *ads;
00295     View2D v2d  DNA_DEPRECATED;  /* deprecated, copied to region */
00296 } SpaceNla;
00297 
00298 typedef struct SpaceText {
00299     SpaceLink *next, *prev;
00300     ListBase regionbase;        /* storage of regions for inactive spaces */
00301     int spacetype;
00302     float blockscale  DNA_DEPRECATED;
00303 
00304     short blockhandler[8]  DNA_DEPRECATED;
00305 
00306     struct Text *text;  
00307 
00308     int top, viewlines;
00309     short flags, menunr;    
00310 
00311     short lheight;      /* user preference */
00312     char cwidth, linenrs_tot;       /* runtime computed, character width and the number of chars to use when showing line numbers */
00313     int left;
00314     int showlinenrs;
00315     int tabnumber;
00316 
00317     short showsyntax;
00318     short line_hlight;
00319     short overwrite;
00320     short live_edit; /* run python while editing, evil */
00321     float pix_per_line;
00322 
00323     struct rcti txtscroll, txtbar;
00324 
00325     int wordwrap, doplugins;
00326 
00327     char findstr[256];      /* ST_MAX_FIND_STR */
00328     char replacestr[256];   /* ST_MAX_FIND_STR */
00329 
00330     short margin_column; /* column number to show right margin at */
00331     char pad[6];
00332 
00333     void *drawcache; /* cache for faster drawing */
00334 } SpaceText;
00335 
00336 typedef struct Script {
00337     ID id;
00338 
00339     void *py_draw;
00340     void *py_event;
00341     void *py_button;
00342     void *py_browsercallback;
00343     void *py_globaldict;
00344 
00345     int flags, lastspace;
00346     char scriptname[256]; /* store the script file here so we can re-run it on loading blender, if "Enable Scripts" is on */
00347     char scriptarg[256];
00348 } Script;
00349 #define SCRIPT_SET_NULL(_script) _script->py_draw = _script->py_event = _script->py_button = _script->py_browsercallback = _script->py_globaldict = NULL; _script->flags = 0;
00350 
00351 typedef struct SpaceScript {
00352     SpaceLink *next, *prev;
00353     ListBase regionbase;        /* storage of regions for inactive spaces */
00354     int spacetype;
00355     float blockscale  DNA_DEPRECATED;
00356     struct Script *script;
00357 
00358     short flags, menunr;
00359     int pad1;
00360     
00361     void *but_refs;
00362 } SpaceScript;
00363 
00364 # /* Only store the data array in the cache to avoid constant reallocation. */
00365 # /* No need to store when saved. */
00366 typedef struct SpaceTimeCache {
00367     struct SpaceTimeCache *next, *prev;
00368     float *array;
00369 } SpaceTimeCache;
00370 
00371 typedef struct SpaceTime {
00372     SpaceLink *next, *prev;
00373     ListBase regionbase;        /* storage of regions for inactive spaces */
00374     int spacetype;
00375     float blockscale  DNA_DEPRECATED;
00376     
00377     View2D v2d  DNA_DEPRECATED; /* deprecated, copied to region */
00378 
00379     ListBase caches;
00380 
00381     int cache_display;
00382     int flag;
00383 } SpaceTime;
00384 
00385 typedef struct SpaceNode {
00386     SpaceLink *next, *prev;
00387     ListBase regionbase;        /* storage of regions for inactive spaces */
00388     int spacetype;
00389     float blockscale  DNA_DEPRECATED;
00390     
00391     short blockhandler[8]  DNA_DEPRECATED;
00392     
00393     View2D v2d  DNA_DEPRECATED; /* deprecated, copied to region */
00394     
00395     struct ID *id, *from;       /* context, no need to save in file? well... pinning... */
00396     short flag, pad1;           /* menunr: browse id block in header */
00397     float aspect;
00398     
00399     float xof, yof;     /* offset for drawing the backdrop */
00400     float zoom, padf;   /* zoom for backdrop */
00401     float mx, my;       /* mousepos for drawing socketless link */
00402     
00403     struct bNodeTree *nodetree, *edittree;
00404     int treetype;       /* treetype: as same nodetree->type */
00405     short texfrom;      /* texfrom object, world or brush */
00406     short shaderfrom;   /* shader from object or world */
00407     short recalc;       /* currently on 0/1, for auto compo */
00408     short pad[3];
00409     ListBase linkdrag;  /* temporary data for modal linking operator */
00410     
00411     struct bGPdata *gpd;        /* grease-pencil data */
00412 } SpaceNode;
00413 
00414 /* snode->flag */
00415 #define SNODE_BACKDRAW      2
00416 #define SNODE_DISPGP        4
00417 #define SNODE_USE_ALPHA     8
00418 #define SNODE_SHOW_ALPHA    16
00419 #define SNODE_AUTO_RENDER   32
00420 
00421 /* snode->texfrom */
00422 #define SNODE_TEX_OBJECT    0
00423 #define SNODE_TEX_WORLD     1
00424 #define SNODE_TEX_BRUSH     2
00425 
00426 /* snode->shaderfrom */
00427 #define SNODE_SHADER_OBJECT 0
00428 #define SNODE_SHADER_WORLD  1
00429 
00430 typedef struct SpaceLogic {
00431     SpaceLink *next, *prev;
00432     ListBase regionbase;        /* storage of regions for inactive spaces */
00433     int spacetype;
00434     float blockscale  DNA_DEPRECATED;
00435     
00436     short blockhandler[8]  DNA_DEPRECATED;
00437     
00438     short flag, scaflag;
00439     int pad;
00440     
00441     struct bGPdata *gpd;        /* grease-pencil data */
00442 } SpaceLogic;
00443 
00444 typedef struct ConsoleLine {
00445     struct ConsoleLine *next, *prev;
00446     
00447     /* keep these 3 vars so as to share free, realloc funcs */
00448     int len_alloc;  /* allocated length */
00449     int len;    /* real len - strlen() */
00450     char *line; 
00451     
00452     int cursor;
00453     int type; /* only for use when in the 'scrollback' listbase */
00454 } ConsoleLine;
00455 
00456 /* ConsoleLine.type */
00457 enum {
00458     CONSOLE_LINE_OUTPUT=0,
00459     CONSOLE_LINE_INPUT,
00460     CONSOLE_LINE_INFO, /* autocomp feedback */
00461     CONSOLE_LINE_ERROR
00462 };
00463 
00464 typedef struct SpaceConsole {
00465     SpaceLink *next, *prev;
00466     ListBase regionbase;        /* storage of regions for inactive spaces */
00467     int spacetype;
00468     float blockscale  DNA_DEPRECATED;           // XXX are these needed?
00469     
00470     short blockhandler[8]  DNA_DEPRECATED;      // XXX are these needed?
00471     
00472     /* space vars */
00473     int lheight, pad;
00474 
00475     ListBase scrollback; /* ConsoleLine; output */
00476     ListBase history; /* ConsoleLine; command history, current edited line is the first */
00477     char prompt[256];
00478     char language[32]; /* multiple consoles are possible, not just python */
00479     
00480     int sel_start;
00481     int sel_end;
00482 } SpaceConsole;
00483 
00484 typedef struct SpaceUserPref {
00485     SpaceLink *next, *prev;
00486     ListBase regionbase;        /* storage of regions for inactive spaces */
00487     int spacetype;
00488 
00489     int pad;
00490     
00491     char filter[64];        /* search term for filtering in the UI */
00492 
00493 } SpaceUserPref;
00494 
00495 typedef struct SpaceClip {
00496     SpaceLink *next, *prev;
00497     ListBase regionbase;        /* storage of regions for inactive spaces */
00498     int spacetype;
00499 
00500     float xof, yof;             /* user defined offset, image is centered */
00501     float xlockof, ylockof;     /* user defined offset from locked position */
00502     float zoom;                 /* user defined zoom level */
00503 
00504     struct MovieClipUser user;      /* user of clip */
00505     struct MovieClip *clip;         /* clip data */
00506     struct MovieClipScopes scopes;  /* different scoped displayed in space panels */
00507 
00508     int flag;                   /* flags */
00509     short mode;                 /* editor mode (editing context being displayed) */
00510     short view;                 /* type of the clip editor view */
00511 
00512     int path_length;            /* length of displaying path, in frames */
00513 
00514     /* current stabilization data */
00515     float loc[2], scale, angle; /* pre-composed stabilization data */
00516     int pad;
00517     float stabmat[4][4], unistabmat[4][4];      /* current stabilization matrix and the same matrix in unified space,
00518                                                    defined when drawing and used for mouse position calculation */
00519 
00520     /* movie postprocessing */
00521     int postproc_flag, pad2;
00522 } SpaceClip;
00523 
00524 /* view3d  Now in DNA_view3d_types.h */
00525 
00526 
00527 
00528 /* **************** SPACE DEFINES ********************* */
00529 
00530 /* button defines (deprecated) */
00531 /* warning: the values of these defines are used in sbuts->tabs[8] */
00532 /* sbuts->mainb new */
00533 #define CONTEXT_SCENE   0
00534 #define CONTEXT_OBJECT  1
00535 #define CONTEXT_TYPES   2
00536 #define CONTEXT_SHADING 3
00537 #define CONTEXT_EDITING 4
00538 #define CONTEXT_SCRIPT  5
00539 #define CONTEXT_LOGIC   6
00540 
00541 /* sbuts->mainb old (deprecated) */
00542 #define BUTS_VIEW           0
00543 #define BUTS_LAMP           1
00544 #define BUTS_MAT            2
00545 #define BUTS_TEX            3
00546 #define BUTS_ANIM           4
00547 #define BUTS_WORLD          5
00548 #define BUTS_RENDER         6
00549 #define BUTS_EDIT           7
00550 #define BUTS_GAME           8
00551 #define BUTS_FPAINT         9
00552 #define BUTS_RADIO          10
00553 #define BUTS_SCRIPT         11
00554 #define BUTS_SOUND          12
00555 #define BUTS_CONSTRAINT     13
00556 #define BUTS_EFFECTS        14
00557 
00558 /* buts->mainb new */
00559 #define BCONTEXT_RENDER             0
00560 #define BCONTEXT_SCENE              1
00561 #define BCONTEXT_WORLD              2
00562 #define BCONTEXT_OBJECT             3
00563 #define BCONTEXT_DATA               4
00564 #define BCONTEXT_MATERIAL           5
00565 #define BCONTEXT_TEXTURE            6
00566 #define BCONTEXT_PARTICLE           7
00567 #define BCONTEXT_PHYSICS            8
00568 #define BCONTEXT_BONE               9
00569 #define BCONTEXT_MODIFIER           10
00570 #define BCONTEXT_CONSTRAINT         12
00571 #define BCONTEXT_BONE_CONSTRAINT    13
00572 #define BCONTEXT_TOT                14
00573 
00574 /* sbuts->flag */
00575 #define SB_PRV_OSA          1
00576 #define SB_PIN_CONTEXT      2
00577 //#define SB_WORLD_TEX      4   //not used anymore
00578 //#define SB_BRUSH_TEX      8   //not used anymore  
00579 #define SB_SHADING_CONTEXT  16
00580 
00581 /* sbuts->texture_context */
00582 #define SB_TEXC_MAT_OR_LAMP 0
00583 #define SB_TEXC_WORLD       1
00584 #define SB_TEXC_BRUSH       2
00585 #define SB_TEXC_PARTICLES   3
00586 
00587 /* sbuts->align */
00588 #define BUT_FREE        0
00589 #define BUT_HORIZONTAL  1
00590 #define BUT_VERTICAL    2
00591 #define BUT_AUTO        3
00592 
00593 /* sbuts->scaflag */        
00594 #define BUTS_SENS_SEL       1
00595 #define BUTS_SENS_ACT       2
00596 #define BUTS_SENS_LINK      4
00597 #define BUTS_CONT_SEL       8
00598 #define BUTS_CONT_ACT       16
00599 #define BUTS_CONT_LINK      32
00600 #define BUTS_ACT_SEL        64
00601 #define BUTS_ACT_ACT        128
00602 #define BUTS_ACT_LINK       256
00603 #define BUTS_SENS_STATE     512
00604 #define BUTS_ACT_STATE      1024
00605 #define BUTS_CONT_INIT_STATE    2048
00606 
00607 /* FileSelectParams.display */
00608 enum FileDisplayTypeE {
00609     FILE_SHORTDISPLAY = 1,
00610     FILE_LONGDISPLAY,
00611     FILE_IMGDISPLAY
00612 };
00613 
00614 /* FileSelectParams.sort */
00615 enum FileSortTypeE {
00616     FILE_SORT_NONE = 0,
00617     FILE_SORT_ALPHA = 1,
00618     FILE_SORT_EXTENSION,
00619     FILE_SORT_TIME,
00620     FILE_SORT_SIZE
00621 };
00622 
00623 /* these values need to be hardcoded in structs, dna does not recognize defines */
00624 /* also defined in BKE */
00625 #define FILE_MAXDIR         160
00626 #define FILE_MAXFILE        80
00627 #define FILE_MAX            240
00628 
00629 /* filesel types */
00630 #define FILE_UNIX           8
00631 #define FILE_BLENDER        8 /* dont display relative paths */
00632 #define FILE_SPECIAL        9
00633 
00634 #define FILE_LOADLIB        1
00635 #define FILE_MAIN           2
00636 #define FILE_LOADFONT       3
00637 /* filesel op property -> action */
00638 #define FILE_OPENFILE       0
00639 #define FILE_SAVE           1
00640 
00641 /* sfile->params->flag and simasel->flag */
00642 #define FILE_SHOWSHORT      (1<<0)
00643 #define FILE_RELPATH        (1<<1) /* was FILE_STRINGCODE */
00644 #define FILE_LINK           (1<<2)
00645 #define FILE_HIDE_DOT       (1<<3)
00646 #define FILE_AUTOSELECT     (1<<4)
00647 #define FILE_ACTIVELAY      (1<<5)
00648 /* #define FILE_ATCURSOR    (1<<6) */ /* deprecated */
00649 #define FILE_DIRSEL_ONLY    (1<<7)
00650 #define FILE_FILTER         (1<<8)
00651 #define FILE_BOOKMARKS      (1<<9)
00652 #define FILE_GROUP_INSTANCE (1<<10)
00653 
00654 
00655 /* files in filesel list: file types */
00656 #define BLENDERFILE         (1<<2)
00657 #define BLENDERFILE_BACKUP  (1<<3)
00658 #define IMAGEFILE           (1<<4)
00659 #define MOVIEFILE           (1<<5)
00660 #define PYSCRIPTFILE        (1<<6)
00661 #define FTFONTFILE          (1<<7)
00662 #define SOUNDFILE           (1<<8)
00663 #define TEXTFILE            (1<<9)
00664 #define MOVIEFILE_ICON      (1<<10) /* movie file that preview can't load */
00665 #define FOLDERFILE          (1<<11) /* represents folders for filtering */
00666 #define BTXFILE             (1<<12)
00667 #define COLLADAFILE         (1<<13)
00668 #define OPERATORFILE        (1<<14) /* from filter_glob operator property */
00669 
00670 
00671 /* Selection Flags in filesel: struct direntry, unsigned char selflag */
00672 /* #define ACTIVE_FILE      (1<<1) */ /* UNUSED */
00673 #define HILITED_FILE        (1<<2)
00674 #define SELECTED_FILE       (1<<3)
00675 #define EDITING_FILE        (1<<4)
00676 
00677 /* SpaceImage->dt_uv */
00678 #define SI_UVDT_OUTLINE 0
00679 #define SI_UVDT_DASH    1
00680 #define SI_UVDT_BLACK   2
00681 #define SI_UVDT_WHITE   3
00682 
00683 /* SpaceImage->dt_uvstretch */
00684 #define SI_UVDT_STRETCH_ANGLE   0
00685 #define SI_UVDT_STRETCH_AREA    1
00686 
00687 /* SpaceImage->sticky
00688  * Note DISABLE should be 0, however would also need to re-arrange icon order,
00689  * also, sticky loc is the default mode so this means we dont need to 'do_versons' */
00690 #define SI_STICKY_LOC       0
00691 #define SI_STICKY_DISABLE   1
00692 #define SI_STICKY_VERTEX    2
00693 
00694 /* SpaceImage->flag */
00695 #define SI_BE_SQUARE    (1<<0)
00696 #define SI_EDITTILE     (1<<1)
00697 #define SI_CLIP_UV      (1<<2)
00698 #define SI_DRAWTOOL     (1<<3)
00699 #define SI_NO_DRAWFACES (1<<4)
00700 #define SI_DRAWSHADOW   (1<<5)
00701 #define SI_SELACTFACE   (1<<6)  /* deprecated */
00702 #define SI_DEPRECATED2  (1<<7)
00703 #define SI_DEPRECATED3  (1<<8)  /* stick UV selection to mesh vertex (UVs wont always be touching) */
00704 #define SI_COORDFLOATS  (1<<9)
00705 #define SI_PIXELSNAP    (1<<10)
00706 #define SI_LIVE_UNWRAP  (1<<11)
00707 #define SI_USE_ALPHA    (1<<12)
00708 #define SI_SHOW_ALPHA   (1<<13)
00709 #define SI_SHOW_ZBUF    (1<<14)
00710         /* next two for render window dislay */
00711 #define SI_PREVSPACE    (1<<15)
00712 #define SI_FULLWINDOW   (1<<16)
00713 #define SI_DEPRECATED4  (1<<17)
00714 #define SI_DEPRECATED5  (1<<18)
00715         /* this means that the image is drawn until it reaches the view edge,
00716          * in the image view, its unrelated to the 'tile' mode for texface */
00717 #define SI_DRAW_TILE    (1<<19)
00718 #define SI_SMOOTH_UV    (1<<20)
00719 #define SI_DRAW_STRETCH (1<<21)
00720 #define SI_DISPGP       (1<<22)
00721 #define SI_DRAW_OTHER   (1<<23)
00722 
00723 #define SI_COLOR_CORRECTION (1<<24)
00724 
00725 /* SpaceIpo->flag (Graph Editor Settings) */
00726     /* OLD DEPRECEATED SETTING */
00727 #define SIPO_LOCK_VIEW          (1<<0)
00728     /* don't merge keyframes on the same frame after a transform */
00729 #define SIPO_NOTRANSKEYCULL     (1<<1)
00730     /* don't show any keyframe handles at all */
00731 #define SIPO_NOHANDLES          (1<<2)
00732     /* don't show current frame number beside indicator line */
00733 #define SIPO_NODRAWCFRANUM      (1<<3)
00734     /* show timing in seconds instead of frames */
00735 #define SIPO_DRAWTIME           (1<<4)
00736     /* only show keyframes for selected F-Curves */
00737 #define SIPO_SELCUVERTSONLY     (1<<5)
00738     /* draw names of F-Curves beside the respective curves */
00739     /* NOTE: currently not used */
00740 #define SIPO_DRAWNAMES          (1<<6)
00741     /* show sliders in channels list */
00742 #define SIPO_SLIDERS            (1<<7)
00743     /* don't show the horizontal component of the cursor */
00744 #define SIPO_NODRAWCURSOR       (1<<8)
00745     /* only show handles of selected keyframes */
00746 #define SIPO_SELVHANDLESONLY    (1<<9)
00747     /* temporary flag to force channel selections to be synced with main */
00748 #define SIPO_TEMP_NEEDCHANSYNC  (1<<10)
00749     /* don't perform realtime updates */
00750 #define SIPO_NOREALTIMEUPDATES  (1<<11)
00751     /* don't draw curves with AA ("beauty-draw") for performance */
00752 #define SIPO_BEAUTYDRAW_OFF     (1<<12)
00753 
00754 /* SpaceIpo->mode (Graph Editor Mode) */
00755 enum {
00756         /* all animation curves (from all over Blender) */
00757     SIPO_MODE_ANIMATION = 0,
00758         /* drivers only */
00759     SIPO_MODE_DRIVERS,
00760 } eGraphEdit_Mode;
00761 
00762 /* SpaceText flags (moved from DNA_text_types.h) */
00763 
00764 #define ST_SCROLL_SELECT        0x0001 // scrollable
00765 #define ST_CLEAR_NAMESPACE      0x0010 // clear namespace after script
00766                                        // execution (see BPY_main.c)
00767 #define ST_FIND_WRAP            0x0020
00768 #define ST_FIND_ALL             0x0040
00769 #define ST_SHOW_MARGIN          0x0080
00770 #define ST_MATCH_CASE           0x0100
00771 
00772 
00773 /* stext->findstr/replacestr */
00774 #define ST_MAX_FIND_STR     256
00775 
00776 /* SpaceOops->flag */
00777 #define SO_TESTBLOCKS   1
00778 #define SO_NEWSELECTED  2
00779 #define SO_HIDE_RESTRICTCOLS        4
00780 #define SO_HIDE_KEYINGSETINFO       8
00781 
00782 /* SpaceOops->outlinevis */
00783 #define SO_ALL_SCENES   0
00784 #define SO_CUR_SCENE    1
00785 #define SO_VISIBLE      2
00786 #define SO_SELECTED     3
00787 #define SO_ACTIVE       4
00788 #define SO_SAME_TYPE    5
00789 #define SO_GROUPS       6
00790 #define SO_LIBRARIES    7
00791 #define SO_VERSE_SESSION    8
00792 #define SO_VERSE_MS     9
00793 #define SO_SEQUENCE     10
00794 #define SO_DATABLOCKS   11
00795 #define SO_USERDEF      12
00796 #define SO_KEYMAP       13
00797 
00798 /* SpaceOops->storeflag */
00799 #define SO_TREESTORE_CLEANUP    1
00800         /* if set, it allows redraws. gets set for some allqueue events */
00801 #define SO_TREESTORE_REDRAW     2
00802 
00803 /* outliner search flags (SpaceOops->search_flags) */
00804 #define SO_FIND_CASE_SENSITIVE      (1<<0)
00805 #define SO_FIND_COMPLETE            (1<<1)
00806 #define SO_SEARCH_RECURSIVE     (1<<2)
00807 
00808 /* headerbuttons: 450-499 */
00809 
00810 #define B_IMASELHOME        451
00811 #define B_IMASELREMOVEBIP   452
00812 
00813 /* nla->flag */
00814 /* flags (1<<0), (1<<1), and (1<<3) are depreceated flags from old blenders */
00815     /* draw timing in seconds instead of frames */
00816 #define SNLA_DRAWTIME       (1<<2)
00817     /* don't draw frame number beside frame indicator */
00818 #define SNLA_NODRAWCFRANUM  (1<<4)
00819     /* don't draw influence curves on strips */
00820 #define SNLA_NOSTRIPCURVES  (1<<5)
00821     /* don't perform realtime updates */
00822 #define SNLA_NOREALTIMEUPDATES  (1<<6)
00823 
00824 /* time->flag */
00825     /* show timing in frames instead of in seconds */
00826 #define TIME_DRAWFRAMES     1
00827     /* show time indicator box beside the frame number */
00828 #define TIME_CFRA_NUM       2
00829     /* only keyframes from active/selected channels get shown */
00830 #define TIME_ONLYACTSEL     4
00831 
00832 /* time->redraws (now screen->redraws_flag) */
00833 #define TIME_REGION             1
00834 #define TIME_ALL_3D_WIN         2
00835 #define TIME_ALL_ANIM_WIN       4
00836 #define TIME_ALL_BUTS_WIN       8
00837 #define TIME_WITH_SEQ_AUDIO     16      // deprecated
00838 #define TIME_SEQ                32
00839 #define TIME_ALL_IMAGE_WIN      64
00840 #define TIME_CONTINUE_PHYSICS   128
00841 #define TIME_NODES              256
00842 #define TIME_CLIPS              512
00843 
00844 /* time->cache */
00845 #define TIME_CACHE_DISPLAY      1
00846 #define TIME_CACHE_SOFTBODY     2
00847 #define TIME_CACHE_PARTICLES    4
00848 #define TIME_CACHE_CLOTH        8
00849 #define TIME_CACHE_SMOKE        16
00850 #define TIME_CACHE_DYNAMICPAINT 32
00851 
00852 /* sseq->mainb */
00853 #define SEQ_DRAW_SEQUENCE         0
00854 #define SEQ_DRAW_IMG_IMBUF        1
00855 #define SEQ_DRAW_IMG_WAVEFORM     2
00856 #define SEQ_DRAW_IMG_VECTORSCOPE  3
00857 #define SEQ_DRAW_IMG_HISTOGRAM    4
00858 
00859 /* sseq->flag */
00860 #define SEQ_DRAWFRAMES   1
00861 #define SEQ_MARKER_TRANS 2
00862 #define SEQ_DRAW_COLOR_SEPERATED     4
00863 #define SEQ_DRAW_SAFE_MARGINS        8
00864 #define SEQ_DRAW_GPENCIL            16
00865 #define SEQ_NO_DRAW_CFRANUM         32
00866 
00867 /* sseq->view */
00868 #define SEQ_VIEW_SEQUENCE           1
00869 #define SEQ_VIEW_PREVIEW            2
00870 #define SEQ_VIEW_SEQUENCE_PREVIEW   3
00871 
00872 /* sseq->render_size */
00873 #define SEQ_PROXY_RENDER_SIZE_NONE      -1
00874 #define SEQ_PROXY_RENDER_SIZE_SCENE     0
00875 #define SEQ_PROXY_RENDER_SIZE_25        25
00876 #define SEQ_PROXY_RENDER_SIZE_50        50
00877 #define SEQ_PROXY_RENDER_SIZE_75        75
00878 #define SEQ_PROXY_RENDER_SIZE_100       99
00879 #define SEQ_PROXY_RENDER_SIZE_FULL      100
00880 
00881 /* SpaceClip->flag */
00882 #define SC_SHOW_MARKER_PATTERN  (1<<0)
00883 #define SC_SHOW_MARKER_SEARCH   (1<<1)
00884 #define SC_LOCK_SELECTION       (1<<2)
00885 #define SC_SHOW_TINY_MARKER     (1<<3)
00886 #define SC_SHOW_TRACK_PATH      (1<<4)
00887 #define SC_SHOW_BUNDLES         (1<<5)
00888 #define SC_MUTE_FOOTAGE         (1<<6)
00889 #define SC_HIDE_DISABLED        (1<<7)
00890 #define SC_SHOW_NAMES           (1<<8)
00891 #define SC_SHOW_GRID            (1<<9)
00892 #define SC_SHOW_STABLE          (1<<10)
00893 #define SC_MANUAL_CALIBRATION   (1<<11)
00894 #define SC_SHOW_GPENCIL         (1<<12)
00895 #define SC_SHOW_FILTERS         (1<<13)
00896 #define SC_SHOW_GRAPH_FRAMES    (1<<14)
00897 #define SC_SHOW_GRAPH_TRACKS    (1<<15)
00898 #define SC_SHOW_PYRAMID_LEVELS      (1<<16)
00899 
00900 /* SpaceClip->mode */
00901 #define SC_MODE_TRACKING        0
00902 #define SC_MODE_RECONSTRUCTION  1
00903 #define SC_MODE_DISTORTION      2
00904 
00905 /* SpaceClip->view */
00906 #define SC_VIEW_CLIP        0
00907 #define SC_VIEW_GRAPH       1
00908 
00909 /* space types, moved from DNA_screen_types.h */
00910 /* Do NOT change order, append on end. types are hardcoded needed */
00911 enum {
00912     SPACE_EMPTY,
00913     SPACE_VIEW3D,
00914     SPACE_IPO,
00915     SPACE_OUTLINER,
00916     SPACE_BUTS,
00917     SPACE_FILE,
00918     SPACE_IMAGE,        
00919     SPACE_INFO,
00920     SPACE_SEQ,
00921     SPACE_TEXT,
00922     SPACE_IMASEL, /* deprecated */
00923     SPACE_SOUND, /* Deprecated */
00924     SPACE_ACTION,
00925     SPACE_NLA,
00926     SPACE_SCRIPT, /* Deprecated */
00927     SPACE_TIME,
00928     SPACE_NODE,
00929     SPACE_LOGIC,
00930     SPACE_CONSOLE,
00931     SPACE_USERPREF,
00932     SPACE_CLIP,
00933     SPACEICONMAX = SPACE_CLIP
00934 };
00935 
00936 #endif