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