2 * ***** BEGIN GPL LICENSE BLOCK *****
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version 2
7 * of the License, or (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software Foundation,
16 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
19 * All rights reserved.
21 * The Original Code is: all of this file.
23 * Contributor(s): none yet.
25 * ***** END GPL LICENSE BLOCK *****
28 /** \file DNA_scene_types.h
32 #ifndef __DNA_SCENE_TYPES_H__
33 #define __DNA_SCENE_TYPES_H__
37 /* XXX, temp feature - campbell */
38 #define DURIAN_CAMERA_SWITCH
44 #include "DNA_color_types.h" /* color management */
45 #include "DNA_vec_types.h"
46 #include "DNA_listBase.h"
63 /* ************************************************************* */
66 /* Base - Wrapper for referencing Objects in a Scene */
68 struct Base *next, *prev;
69 unsigned int lay, selcol;
72 struct Object *object;
75 /* ************************************************************* */
76 /* Output Format Data */
78 typedef struct AviCodecData {
79 void *lpFormat; /* save format */
80 void *lpParms; /* compressor options */
81 unsigned int cbFormat; /* size of lpFormat buffer */
82 unsigned int cbParms; /* size of lpParms buffer */
84 unsigned int fccType; /* stream type, for consistency */
85 unsigned int fccHandler; /* compressor */
86 unsigned int dwKeyFrameEvery; /* keyframe rate */
87 unsigned int dwQuality; /* compress quality 0-10,000 */
88 unsigned int dwBytesPerSecond; /* bytes per second */
89 unsigned int dwFlags; /* flags... see below */
90 unsigned int dwInterleaveEvery; /* for non-video streams only */
93 char avicodecname[128];
96 typedef struct QuicktimeCodecData {
97 /*Old quicktime implementation compatibility fields, read only in 2.5 - deprecated*/
98 void *cdParms; /* codec/compressor options */
99 void *pad; /* padding */
101 unsigned int cdSize; /* size of cdParms buffer */
102 unsigned int pad2; /* padding */
104 char qtcodecname[128];
105 } QuicktimeCodecData;
107 typedef struct QuicktimeCodecSettings {
108 /* Codec settings detailed for 2.5 implementation*/
109 int codecType; /* Types defined in quicktime_export.h */
110 int codecSpatialQuality; /* in 0-100 scale, to be translated in 0-1024 for qt use */
112 /* Settings not available in current QTKit API */
116 int codecTemporalQuality; /* in 0-100 scale, to be translated in 0-1024 for qt use */
117 int minSpatialQuality; /* in 0-100 scale, to be translated in 0-1024 for qt use */
118 int minTemporalQuality; /* in 0-100 scale, to be translated in 0-1024 for qt use */
120 int bitRate; /* bitrate in bps */
122 /* Audio Codec settings */
130 } QuicktimeCodecSettings;
132 typedef struct FFMpegCodecData {
150 IDProperty *properties;
153 /* ************************************************************* */
156 typedef struct AudioData {
157 int mixrate; // 2.5: now in FFMpegCodecData: audio_mixrate
158 float main; // 2.5: now in FFMpegCodecData: audio_volume
159 float speed_of_sound;
160 float doppler_factor;
168 /* *************************************************************** */
172 typedef struct SceneRenderLayer {
173 struct SceneRenderLayer *next, *prev;
175 char name[64]; /* MAX_NAME */
177 struct Material *mat_override;
178 struct Group *light_override;
180 unsigned int lay; /* scene->lay itself has priority over this */
181 unsigned int lay_zmask; /* has to be after lay, this is for Z-masking */
182 unsigned int lay_exclude; /* not used by internal, exclude */
185 int passflag; /* pass_xor has to be after passflag */
193 #define SCE_LAY_SOLID 1
194 #define SCE_LAY_ZTRA 2
195 #define SCE_LAY_HALO 4
196 #define SCE_LAY_EDGE 8
197 #define SCE_LAY_SKY 16
198 #define SCE_LAY_STRAND 32
199 /* flags between 32 and 0x8000 are set to 1 already, for future options */
201 #define SCE_LAY_ALL_Z 0x8000
202 #define SCE_LAY_XOR 0x10000
203 #define SCE_LAY_DISABLE 0x20000
204 #define SCE_LAY_ZMASK 0x40000
205 #define SCE_LAY_NEG_ZMASK 0x80000
208 #define SCE_PASS_COMBINED (1<<0)
209 #define SCE_PASS_Z (1<<1)
210 #define SCE_PASS_RGBA (1<<2)
211 #define SCE_PASS_DIFFUSE (1<<3)
212 #define SCE_PASS_SPEC (1<<4)
213 #define SCE_PASS_SHADOW (1<<5)
214 #define SCE_PASS_AO (1<<6)
215 #define SCE_PASS_REFLECT (1<<7)
216 #define SCE_PASS_NORMAL (1<<8)
217 #define SCE_PASS_VECTOR (1<<9)
218 #define SCE_PASS_REFRACT (1<<10)
219 #define SCE_PASS_INDEXOB (1<<11)
220 #define SCE_PASS_UV (1<<12)
221 #define SCE_PASS_INDIRECT (1<<13)
222 #define SCE_PASS_MIST (1<<14)
223 #define SCE_PASS_RAYHITS (1<<15)
224 #define SCE_PASS_EMIT (1<<16)
225 #define SCE_PASS_ENVIRONMENT (1<<17)
226 #define SCE_PASS_INDEXMA (1<<18)
227 #define SCE_PASS_DIFFUSE_DIRECT (1<<19)
228 #define SCE_PASS_DIFFUSE_INDIRECT (1<<20)
229 #define SCE_PASS_DIFFUSE_COLOR (1<<21)
230 #define SCE_PASS_GLOSSY_DIRECT (1<<22)
231 #define SCE_PASS_GLOSSY_INDIRECT (1<<23)
232 #define SCE_PASS_GLOSSY_COLOR (1<<24)
233 #define SCE_PASS_TRANSM_DIRECT (1<<25)
234 #define SCE_PASS_TRANSM_INDIRECT (1<<26)
235 #define SCE_PASS_TRANSM_COLOR (1<<27)
237 /* note, srl->passflag is treestore element 'nr' in outliner, short still... */
239 /* *************************************************************** */
241 /* Generic image format settings,
242 * this is used for NodeImageFile and IMAGE_OT_save_as operator too.
244 * note: its a bit strange that even though this is an image format struct
245 * the imtype can still be used to select video formats.
246 * RNA ensures these enum's are only selectable for render output.
248 typedef struct ImageFormatData {
249 char imtype; /* R_IMF_IMTYPE_PNG, R_... */
250 /* note, video types should only ever be set from this
251 * structure when used from RenderData */
252 char depth; /* bits per channel, R_IMF_CHAN_DEPTH_8 -> 32,
253 * not a flag, only set 1 at a time */
255 char planes; /* - R_IMF_PLANES_BW, R_IMF_PLANES_RGB, R_IMF_PLANES_RGBA */
256 char flag; /* generic options for all image types, alpha zbuffer */
258 char quality; /* (0 - 100), eg: jpeg quality */
259 char compress; /* (0 - 100), eg: png compression */
262 /* --- format specific --- */
269 short cineon_white, cineon_black;
277 /* color management */
278 ColorManagedViewSettings view_settings;
279 ColorManagedDisplaySettings display_settings;
283 /* ImageFormatData.imtype */
284 #define R_IMF_IMTYPE_TARGA 0
285 #define R_IMF_IMTYPE_IRIS 1
286 /* #define R_HAMX 2 */ /* hamx is nomore */
287 /* #define R_FTYPE 3 */ /* ftype is nomore */
288 #define R_IMF_IMTYPE_JPEG90 4
289 /* #define R_MOVIE 5 */ /* movie is nomore */
290 #define R_IMF_IMTYPE_IRIZ 7
291 #define R_IMF_IMTYPE_RAWTGA 14
292 #define R_IMF_IMTYPE_AVIRAW 15
293 #define R_IMF_IMTYPE_AVIJPEG 16
294 #define R_IMF_IMTYPE_PNG 17
295 /* #define R_IMF_IMTYPE_AVICODEC 18 */ /* avicodec is nomore */
296 #define R_IMF_IMTYPE_QUICKTIME 19
297 #define R_IMF_IMTYPE_BMP 20
298 #define R_IMF_IMTYPE_RADHDR 21
299 #define R_IMF_IMTYPE_TIFF 22
300 #define R_IMF_IMTYPE_OPENEXR 23
301 #define R_IMF_IMTYPE_FFMPEG 24
302 #define R_IMF_IMTYPE_FRAMESERVER 25
303 #define R_IMF_IMTYPE_CINEON 26
304 #define R_IMF_IMTYPE_DPX 27
305 #define R_IMF_IMTYPE_MULTILAYER 28
306 #define R_IMF_IMTYPE_DDS 29
307 #define R_IMF_IMTYPE_JP2 30
308 #define R_IMF_IMTYPE_H264 31
309 #define R_IMF_IMTYPE_XVID 32
310 #define R_IMF_IMTYPE_THEORA 33
312 #define R_IMF_IMTYPE_INVALID 255
314 /* ImageFormatData.flag */
315 #define R_IMF_FLAG_ZBUF (1<<0) /* was R_OPENEXR_ZBUF */
316 #define R_IMF_FLAG_PREVIEW_JPG (1<<1) /* was R_PREVIEW_JPG */
318 /* return values from BKE_imtype_valid_depths, note this is depts per channel */
319 #define R_IMF_CHAN_DEPTH_1 (1<<0) /* 1bits (unused) */
320 #define R_IMF_CHAN_DEPTH_8 (1<<1) /* 8bits (default) */
321 #define R_IMF_CHAN_DEPTH_10 (1<<2) /* 10bits (uncommon, Cineon/DPX support) */
322 #define R_IMF_CHAN_DEPTH_12 (1<<3) /* 12bits (uncommon, jp2/DPX support) */
323 #define R_IMF_CHAN_DEPTH_16 (1<<4) /* 16bits (tiff, halff float exr) */
324 #define R_IMF_CHAN_DEPTH_24 (1<<5) /* 24bits (unused) */
325 #define R_IMF_CHAN_DEPTH_32 (1<<6) /* 32bits (full float exr) */
327 /* ImageFormatData.planes */
328 #define R_IMF_PLANES_RGB 24
329 #define R_IMF_PLANES_RGBA 32
330 #define R_IMF_PLANES_BW 8
332 /* ImageFormatData.exr_codec */
333 #define R_IMF_EXR_CODEC_NONE 0
334 #define R_IMF_EXR_CODEC_PXR24 1
335 #define R_IMF_EXR_CODEC_ZIP 2
336 #define R_IMF_EXR_CODEC_PIZ 3
337 #define R_IMF_EXR_CODEC_RLE 4
339 /* ImageFormatData.jp2_flag */
340 #define R_IMF_JP2_FLAG_YCC (1<<0) /* when disabled use RGB */ /* was R_JPEG2K_YCC */
341 #define R_IMF_JP2_FLAG_CINE_PRESET (1<<1) /* was R_JPEG2K_CINE_PRESET */
342 #define R_IMF_JP2_FLAG_CINE_48 (1<<2) /* was R_JPEG2K_CINE_48FPS */
344 /* ImageFormatData.cineon_flag */
345 #define R_IMF_CINEON_FLAG_LOG (1<<0) /* was R_CINEON_LOG */
347 /* *************************************************************** */
350 typedef struct RenderData {
351 struct ImageFormatData im_format;
353 struct AviCodecData *avicodecdata;
354 struct QuicktimeCodecData *qtcodecdata;
355 struct QuicktimeCodecSettings qtcodecsettings;
356 struct FFMpegCodecData ffcodecdata;
358 int cfra, sfra, efra; /* frames as in 'images' */
359 float subframe; /* subframe offset from cfra, in 0.0-1.0 */
360 int psfra, pefra; /* start+end frames of preview range */
362 int images, framapto;
365 float framelen, blurfac;
367 /** For UR edge rendering: give the edges this color */
368 float edgeR, edgeG, edgeB;
371 /* standalone player */ // XXX deprecated since 2.5
372 short fullscreen DNA_DEPRECATED, xplay DNA_DEPRECATED, yplay DNA_DEPRECATED;
373 short freqplay DNA_DEPRECATED;
374 /* standalone player */ // XXX deprecated since 2.5
375 short depth DNA_DEPRECATED, attrib DNA_DEPRECATED;
378 int frame_step; /* frames to jump during render/playback */
380 short stereomode DNA_DEPRECATED; /* standalone player stereo settings */ // XXX deprecated since 2.5
382 short dimensionspreset; /* for the dimensions presets menu */
384 short filtertype; /* filter is box, tent, gauss, mitch, etc */
386 short size, maximsize; /* size in %, max in Kb */
389 * The desired number of pixels in the x direction
393 * The desired number of pixels in the y direction
397 * The number of part to use in the x direction
399 short xparts DNA_DEPRECATED;
401 * The number of part to use in the y direction
403 short yparts DNA_DEPRECATED;
406 * render tile dimensions
410 short planes DNA_DEPRECATED, imtype DNA_DEPRECATED, subimtype DNA_DEPRECATED, quality DNA_DEPRECATED; /*deprecated!*/
413 * Render to image editor, fullscreen or to new window.
418 * Flags for render settings. Use bit-masking to access the settings.
423 * Flags for render settings. Use bit-masking to access the settings.
428 * Flags for raytrace settings. Use bit-masking to access the settings.
430 int raytrace_options;
433 * Raytrace acceleration structure
435 short raytrace_structure;
439 /* octree resolution */
444 * What to do with the sky/background. Picks sky/premul/key
445 * blending for the background
450 * The number of samples to use per pixel.
454 short frs_sec, edgeint;
459 /* safety, border and display rect */
463 /* information on different layers to be rendered */
467 /* number of mblur samples */
471 * Adjustment factors for the aspect ratio in the x direction, was a short in 2.45
478 * Value used to define filter size for all filter options */
482 /* color management settings - color profiles, gamma correction, etc */
485 /** post-production settings. deprecated, but here for upwards compat (initialized to 1) */
486 float postgamma, posthue, postsat;
488 /* Dither noise intensity */
489 float dither_intensity;
491 /* Bake Render options */
492 short bake_osa, bake_filter, bake_mode, bake_flag;
493 short bake_normal_space, bake_quad_split;
494 float bake_maxdist, bake_biasdist;
495 int bake_rays_number;
497 /* path to render output */
498 char pic[1024]; /* 1024 = FILE_MAX */
502 short stamp_font_id, pad3; /* select one of blenders bitmap fonts */
504 /* stamp info user data. */
505 char stamp_udata[768];
507 /* foreground/background color. */
511 /* sequencer options */
514 char seq_flag; /* flag use for sequence render/draw */
517 /* render simplify */
519 short simplify_subsurf;
520 short simplify_shadowsamples;
521 float simplify_particles;
522 float simplify_aosss;
525 short cineonwhite DNA_DEPRECATED, cineonblack DNA_DEPRECATED; /*deprecated*/
526 float cineongamma DNA_DEPRECATED; /*deprecated*/
529 short jp2_preset DNA_DEPRECATED, jp2_depth DNA_DEPRECATED; /*deprecated*/
532 /* Dome variables */ // XXX deprecated since 2.5
533 short domeres DNA_DEPRECATED, domemode DNA_DEPRECATED; // XXX deprecated since 2.5
534 short domeangle DNA_DEPRECATED, dometilt DNA_DEPRECATED; // XXX deprecated since 2.5
535 float domeresbuf DNA_DEPRECATED; // XXX deprecated since 2.5
537 struct Text *dometext DNA_DEPRECATED; // XXX deprecated since 2.5
543 /* *************************************************************** */
544 /* Render Conversion/Simplfication Settings */
546 /* control render convert and shading engine */
547 typedef struct RenderProfile {
548 struct RenderProfile *next, *prev;
553 short shadbufsample_max;
556 float ao_error, pad2;
560 /* *************************************************************** */
561 /* Game Engine - Dome */
563 typedef struct GameDome {
567 struct Text *warptext;
570 #define DOME_FISHEYE 1
571 #define DOME_TRUNCATED_FRONT 2
572 #define DOME_TRUNCATED_REAR 3
573 #define DOME_ENVMAP 4
574 #define DOME_PANORAM_SPH 5
575 #define DOME_NUM_MODES 6
577 /* *************************************************************** */
580 typedef struct GameFraming {
582 char type, pad1, pad2, pad3;
585 #define SCE_GAMEFRAMING_BARS 0
586 #define SCE_GAMEFRAMING_EXTEND 1
587 #define SCE_GAMEFRAMING_SCALE 2
589 typedef struct RecastData {
599 float regionmergesize;
601 float detailsampledist;
602 float detailsamplemaxerror;
606 typedef struct GameData {
608 /* standalone player */
609 struct GameFraming framing;
610 short playerflag, xplay, yplay, freqplay;
611 short depth, attrib, rt1, rt2;
612 short aasamples, pad4[3];
614 /* stereo/dome mode */
615 struct GameDome dome;
616 short stereoflag, stereomode;
618 RecastData recastData;
621 /* physics (it was in world)*/
622 float gravity; /*Gravitation constant for the game world*/
625 * Radius of the activity bubble, in Manhattan length. Objects
626 * outside the box are activity-culled. */
627 float activityBoxRadius;
630 * bit 3: (gameengine): Activity culling is enabled.
631 * bit 5: (gameengine) : enable Bullet DBVT tree for view frustrum culling
635 short occlusionRes; /* resolution of occlusion Z buffer in pixel */
638 short ticrate, maxlogicstep, physubstep, maxphystep;
639 short obstacleSimulation, pad1;
641 float deactivationtime, lineardeactthreshold, angulardeactthreshold, pad2;
644 #define STEREO_NOSTEREO 1
645 #define STEREO_ENABLED 2
646 #define STEREO_DOME 3
648 //#define STEREO_NOSTEREO 1
649 #define STEREO_QUADBUFFERED 2
650 #define STEREO_ABOVEBELOW 3
651 #define STEREO_INTERLACED 4
652 #define STEREO_ANAGLYPH 5
653 #define STEREO_SIDEBYSIDE 6
654 #define STEREO_VINTERLACE 7
655 //#define STEREO_DOME 8
659 #define WOPHY_BULLET 5
661 /* obstacleSimulation */
662 #define OBSTSIMULATION_NONE 0
663 #define OBSTSIMULATION_TOI_rays 1
664 #define OBSTSIMULATION_TOI_cells 2
667 #define GAME_RESTRICT_ANIM_UPDATES (1 << 0)
668 #define GAME_ENABLE_ALL_FRAMES (1 << 1)
669 #define GAME_SHOW_DEBUG_PROPS (1 << 2)
670 #define GAME_SHOW_FRAMERATE (1 << 3)
671 #define GAME_SHOW_PHYSICS (1 << 4)
672 #define GAME_DISPLAY_LISTS (1 << 5)
673 #define GAME_GLSL_NO_LIGHTS (1 << 6)
674 #define GAME_GLSL_NO_SHADERS (1 << 7)
675 #define GAME_GLSL_NO_SHADOWS (1 << 8)
676 #define GAME_GLSL_NO_RAMPS (1 << 9)
677 #define GAME_GLSL_NO_NODES (1 << 10)
678 #define GAME_GLSL_NO_EXTRA_TEX (1 << 11)
679 #define GAME_IGNORE_DEPRECATION_WARNINGS (1 << 12)
680 #define GAME_ENABLE_ANIMATION_RECORD (1 << 13)
681 #define GAME_SHOW_MOUSE (1 << 14)
682 #define GAME_GLSL_NO_COLOR_MANAGEMENT (1 << 15)
683 #define GAME_SHOW_OBSTACLE_SIMULATION (1 << 16)
684 /* Note: GameData.flag is now an int (max 32 flags). A short could only take 16 flags */
686 /* GameData.playerflag */
687 #define GAME_PLAYER_FULLSCREEN (1 << 0)
688 #define GAME_PLAYER_DESKTOP_RESOLUTION (1 << 1)
690 /* GameData.matmode */
691 #define GAME_MAT_TEXFACE 0
692 #define GAME_MAT_MULTITEX 1
693 #define GAME_MAT_GLSL 2
696 #define UV_SCULPT_LOCK_BORDERS 1
697 #define UV_SCULPT_ALL_ISLANDS 2
699 #define UV_SCULPT_TOOL_PINCH 1
700 #define UV_SCULPT_TOOL_RELAX 2
701 #define UV_SCULPT_TOOL_GRAB 3
703 #define UV_SCULPT_TOOL_RELAX_LAPLACIAN 1
704 #define UV_SCULPT_TOOL_RELAX_HC 2
708 typedef struct TimeMarker {
709 struct TimeMarker *next, *prev;
713 struct Object *camera;
716 /* *************************************************************** */
717 /* Paint Mode/Tool Data */
719 #define PAINT_MAX_INPUT_SAMPLES 64
721 /* Paint Tool Base */
722 typedef struct Paint {
725 /* WM Paint cursor */
727 unsigned char paint_cursor_col[4];
729 /* enum PaintFlags */
732 /* Paint stroke can use up to PAINT_MAX_INPUT_SAMPLES inputs to
733 * smooth the stroke */
734 int num_input_samples;
739 /* ------------------------------------------- */
742 /* Texture/Image Editor */
743 typedef struct ImagePaintSettings {
748 /* for projection painting only */
749 short seam_bleed, normal_angle;
750 short screen_grab_size[2]; /* capture size for re-projection */
754 void *paintcursor; /* wm handle */
755 } ImagePaintSettings;
757 /* ------------------------------------------- */
760 /* Settings for a Particle Editing Brush */
761 typedef struct ParticleBrushData {
762 short size; /* common setting */
763 short step, invert, count; /* for specific brushes only */
768 /* Particle Edit Mode Settings */
769 typedef struct ParticleEditSettings {
775 ParticleBrushData brush[7]; /* 7 = PE_TOT_BRUSH */
776 void *paintcursor; /* runtime */
778 float emitterdist, rt;
783 int draw_step, fade_frames;
786 struct Object *object;
787 } ParticleEditSettings;
789 /* ------------------------------------------- */
793 typedef struct Sculpt {
796 /* For rotating around a pivot point */
797 //float pivot[3]; XXX not used?
800 /* Control tablet input */
801 //char tablet_size, tablet_strength; XXX not used?
804 // all this below is used to communicate with the cursor drawing routine
806 /* record movement of mouse so that rake can start at an intuitive angle */
807 float last_x, last_y;
812 float anchored_location[3];
813 float anchored_initial_mouse[2];
816 float pressure_value;
818 float special_rotation;
823 typedef struct UvSculpt {
826 /* ------------------------------------------- */
830 typedef struct VPaint {
834 int tot; /* allocation size of prev buffers */
835 unsigned int *vpaint_prev; /* previous mesh colors */
836 struct MDeformVert *wpaint_prev; /* previous vertex weights */
838 void *paintcursor; /* wm handle */
843 // VP_COLINDEX = (1 << 0), /* only paint onto active material*/ /* deprecated since before 2.49 */
845 VP_NORMALS = (1 << 3),
847 // VP_MIRROR_X = (1 << 5), /* deprecated in 2.5x use (me->editflag & ME_EDIT_MIRROR_X) */
848 VP_ONLYVGROUP = (1 << 7) /* weight paint only */
851 /* *************************************************************** */
852 /* Transform Orientations */
854 typedef struct TransformOrientation {
855 struct TransformOrientation *next, *prev;
856 char name[64]; /* MAX_NAME */
859 } TransformOrientation;
861 /* *************************************************************** */
862 /* Unified Paint Settings
865 /* These settings can override the equivalent fields in the active
866 * Brush for any paint mode; the flag field controls whether these
868 typedef struct UnifiedPaintSettings {
869 /* unified radius of brush in pixels */
872 /* unified radius of brush in Blender units */
873 float unprojected_radius;
875 /* unified strength of brush */
878 /* unified brush weight, [0, 1] */
881 /* user preferences for sculpt and paint */
884 } UnifiedPaintSettings;
887 UNIFIED_PAINT_SIZE = (1<<0),
888 UNIFIED_PAINT_ALPHA = (1<<1),
889 UNIFIED_PAINT_WEIGHT = (1<<5),
891 /* only used if unified size is enabled, mirros the brush flags
892 * BRUSH_LOCK_SIZE and BRUSH_SIZE_PRESSURE */
893 UNIFIED_PAINT_BRUSH_LOCK_SIZE = (1<<2),
894 UNIFIED_PAINT_BRUSH_SIZE_PRESSURE = (1<<3),
896 /* only used if unified alpha is enabled, mirrors the brush flag
897 * BRUSH_ALPHA_PRESSURE */
898 UNIFIED_PAINT_BRUSH_ALPHA_PRESSURE = (1<<4)
899 } UnifiedPaintSettingsFlags;
901 /* *************************************************************** */
904 typedef struct ToolSettings {
905 VPaint *vpaint; /* vertex paint */
906 VPaint *wpaint; /* weight paint */
908 UvSculpt *uvsculpt; /* uv smooth */
910 /* Vertex group weight - used only for editmode, not weight
914 /* Subdivide Settings */
917 /*Triangle to Quad conversion threshold*/
924 float extr_offs; /* extrude offset */
925 float doublimit; /* remove doubles limit */
926 float normalsize; /* size of normals */
929 /* Selection Mode for Mesh */
932 /* Primitive Settings */
937 /* Cylinder - Tube - Circle */
943 float uvcalc_cubesize;
946 short uvcalc_mapalign;
948 short uv_flag, uv_selectmode;
955 short autoik_chainlen;
957 /* Image Paint (8 byttse aligned please!) */
958 struct ImagePaintSettings imapaint;
960 /* Particle Editing */
961 struct ParticleEditSettings particle;
963 /* Transform Proportional Area of Effect */
964 float proportional_size;
966 /* Select Group Threshold */
972 /* Auto-Keying Mode */
973 short autokey_mode, autokey_flag; /* defines in DNA_userdef_types.h */
976 char multires_subdiv_type;
979 /* Skeleton generation */
980 short skgen_resolution;
981 float skgen_threshold_internal;
982 float skgen_threshold_external;
983 float skgen_length_ratio;
984 float skgen_length_limit;
985 float skgen_angle_limit;
986 float skgen_correlation_limit;
987 float skgen_symmetry_limit;
988 float skgen_retarget_angle_weight;
989 float skgen_retarget_length_weight;
990 float skgen_retarget_distance_weight;
993 char skgen_postpro_passes;
994 char skgen_subdivisions[3];
995 char skgen_multi_level;
997 /* Skeleton Sketching */
998 struct Object *skgen_template;
1000 char bone_sketching_convert;
1001 char skgen_subdivision_number;
1002 char skgen_retarget_options;
1003 char skgen_retarget_roll;
1004 char skgen_side_string[8];
1005 char skgen_num_string[8];
1007 /* Alt+RMB option */
1009 char edge_mode_live_unwrap;
1012 char snap_mode, snap_node_mode;
1014 short snap_flag, snap_target;
1015 short proportional, prop_mode;
1016 char proportional_objects; /* proportional edit, object mode */
1017 char proportional_mask; /* proportional edit, object mode */
1020 char auto_normalize; /*auto normalizing mode in wpaint*/
1021 char multipaint; /* paint multiple bones in wpaint */
1025 int uv_sculpt_settings;
1027 int uv_relax_method;
1028 /* XXX: these sculpt_paint_* fields are deprecated, use the
1029 * unified_paint_settings field instead! */
1030 short sculpt_paint_settings DNA_DEPRECATED; short pad5;
1031 int sculpt_paint_unified_size DNA_DEPRECATED;
1032 float sculpt_paint_unified_unprojected_radius DNA_DEPRECATED;
1033 float sculpt_paint_unified_alpha DNA_DEPRECATED;
1035 /* Unified Paint Settings */
1036 struct UnifiedPaintSettings unified_paint_settings;
1039 /* *************************************************************** */
1040 /* Assorted Scene Data */
1042 /* ------------------------------------------- */
1043 /* Stats (show in Info header) */
1045 typedef struct bStats {
1046 /* scene totals for visible layers */
1047 int totobj, totlamp, totobjsel, totcurve, totmesh, totarmature;
1048 int totvert, totface;
1051 /* ------------------------------------------- */
1054 typedef struct UnitSettings {
1055 /* Display/Editing unit options for each scene */
1056 float scale_length; /* maybe have other unit conversions? */
1057 char system; /* imperial, metric etc */
1058 char system_rotation; /* not implemented as a proper unit system yet */
1062 /* ------------------------------------------- */
1063 /* Global/Common Physics Settings */
1065 typedef struct PhysicsSettings {
1067 int flag, quick_cache_step, rt;
1070 /* *************************************************************** */
1071 /* Scene ID-Block */
1073 typedef struct Scene {
1075 struct AnimData *adt; /* animation data (must be immediately after id for utilities to use it) */
1077 struct Object *camera;
1078 struct World *world;
1083 struct Base *basact; /* active base */
1084 struct Object *obedit; /* name replaces old G.obedit */
1086 float cursor[3]; /* 3d cursor location */
1087 float twcent[3]; /* center for transform widget */
1088 float twmin[3], twmax[3]; /* boundbox of selection for transform widget */
1090 unsigned int lay; /* bitflags for layer visibility */
1091 int layact; /* active layer */
1092 unsigned int lay_updated; /* runtime flag, has layer ever been updated since load? */
1094 short flag; /* various settings */
1098 struct bNodeTree *nodetree;
1100 struct Editing *ed; /* sequence editor data is allocated here */
1102 struct ToolSettings *toolsettings; /* default allocated now */
1103 struct SceneStats *stats; /* default allocated now */
1105 /* migrate or replace? depends on some internal things... */
1106 /* no, is on the right place (ton) */
1107 struct RenderData r;
1108 struct AudioData audio;
1111 ListBase transform_spaces;
1114 void *sound_scene_handle;
1115 void *sound_scrub_handle;
1116 void *speaker_handles;
1118 void *fps_info; /* (runtime) info/cache used for presenting playback framerate info to the user */
1120 /* none of the dependency graph vars is mean to be saved */
1121 struct DagForest *theDag;
1122 short dagisvalid, dagflags;
1123 short recalc; /* recalc = counterpart of ob->recalc */
1128 /* User-Defined KeyingSets */
1129 int active_keyingset; /* index of the active KeyingSet. first KeyingSet has index 1, 'none' active is 0, 'add new' is -1 */
1130 ListBase keyingsets; /* KeyingSets for this scene */
1133 struct GameFraming framing DNA_DEPRECATED; // XXX deprecated since 2.5
1137 struct UnitSettings unit;
1140 struct bGPdata *gpd;
1142 /* Physics simulation settings */
1143 struct PhysicsSettings physics_settings;
1145 /* Movie Tracking */
1146 struct MovieClip *clip; /* active movie clip */
1148 uint64_t customdata_mask; /* XXX. runtime flag for drawing, actually belongs in the window, only used by BKE_object_handle_update() */
1149 uint64_t customdata_mask_modal; /* XXX. same as above but for temp operator use (gl renders) */
1151 /* Color Management */
1152 ColorManagedViewSettings view_settings;
1153 ColorManagedDisplaySettings display_settings;
1154 ColorManagedColorspaceSettings sequencer_colorspace_settings;
1158 /* **************** RENDERDATA ********************* */
1161 /* use preview range */
1162 #define SCER_PRV_RANGE (1<<0)
1164 /* mode (int now) */
1165 #define R_OSA 0x0001
1166 #define R_SHADOW 0x0002
1167 #define R_GAMMA 0x0004
1168 #define R_ORTHO 0x0008
1169 #define R_ENVMAP 0x0010
1170 #define R_EDGE 0x0020
1171 #define R_FIELDS 0x0040
1172 #define R_FIELDSTILL 0x0080
1173 /*#define R_RADIO 0x0100 */ /* deprecated */
1174 #define R_BORDER 0x0200
1175 #define R_PANORAMA 0x0400 /* deprecated as scene option, still used in renderer */
1176 #define R_CROP 0x0800
1177 /*#define R_COSMO 0x1000 deprecated */
1178 #define R_ODDFIELD 0x2000
1179 #define R_MBLUR 0x4000
1180 /* unified was here */
1181 #define R_RAYTRACE 0x10000
1182 /* R_GAUSS is obsolete, but used to retrieve setting from old files */
1183 #define R_GAUSS 0x20000
1184 /* fbuf obsolete... */
1185 /*#define R_FBUF 0x40000*/
1186 /* threads obsolete... is there for old files, now use for autodetect threads */
1187 #define R_THREADS 0x80000
1188 /* Use the same flag for autothreads */
1189 #define R_FIXED_THREADS 0x80000
1191 #define R_SPEED 0x100000
1192 #define R_SSS 0x200000
1193 #define R_NO_OVERWRITE 0x400000 /* skip existing files */
1194 #define R_TOUCH 0x800000 /* touch files before rendering */
1195 #define R_SIMPLIFY 0x1000000
1196 #define R_EDGE_FRS 0x2000000 /* R_EDGE reserved for Freestyle */
1197 #define R_PERSISTENT_DATA 0x4000000 /* keep data around for re-render */
1200 #define R_SEQ_GL_PREV 1
1201 // #define R_SEQ_GL_REND 2 // UNUSED, opengl render has its own operator now.
1202 #define R_SEQ_SOLID_TEX 4
1206 #define R_OUTPUT_SCREEN 0
1207 #define R_OUTPUT_AREA 1
1208 #define R_OUTPUT_WINDOW 2
1209 #define R_OUTPUT_NONE 3
1210 /*#define R_OUTPUT_FORKED 4*/
1213 #define R_FILTER_BOX 0
1214 #define R_FILTER_TENT 1
1215 #define R_FILTER_QUAD 2
1216 #define R_FILTER_CUBIC 3
1217 #define R_FILTER_CATROM 4
1218 #define R_FILTER_GAUSS 5
1219 #define R_FILTER_MITCH 6
1220 #define R_FILTER_FAST_GAUSS 7 /* note, this is only used for nodes at the moment */
1222 /* raytrace structure */
1223 #define R_RAYSTRUCTURE_AUTO 0
1224 #define R_RAYSTRUCTURE_OCTREE 1
1225 #define R_RAYSTRUCTURE_BLIBVH 2
1226 #define R_RAYSTRUCTURE_VBVH 3
1227 #define R_RAYSTRUCTURE_SIMD_SVBVH 4 /* needs SIMD */
1228 #define R_RAYSTRUCTURE_SIMD_QBVH 5 /* needs SIMD */
1230 /* raytrace_options */
1231 #define R_RAYTRACE_USE_LOCAL_COORDS 0x0001
1232 #define R_RAYTRACE_USE_INSTANCES 0x0002
1234 /* scemode (int now) */
1235 #define R_DOSEQ 0x0001
1236 #define R_BG_RENDER 0x0002
1237 /* passepartout is camera option now, keep this for backward compatibility */
1238 #define R_PASSEPARTOUT 0x0004
1239 #define R_PREVIEWBUTS 0x0008
1240 #define R_EXTENSION 0x0010
1241 #define R_MATNODE_PREVIEW 0x0020
1242 #define R_DOCOMP 0x0040
1243 #define R_COMP_CROP 0x0080
1244 #define R_FREE_IMAGE 0x0100
1245 #define R_SINGLE_LAYER 0x0200
1246 #define R_EXR_TILE_FILE 0x0400
1247 #define R_COMP_FREE 0x0800
1248 #define R_NO_IMAGE_LOAD 0x1000
1249 #define R_NO_TEX 0x2000
1250 #define R_NO_FRAME_UPDATE 0x4000
1251 #define R_FULL_SAMPLE 0x8000
1252 /* #define R_DEPRECATED 0x10000 */
1253 /* #define R_RECURS_PROTECTION 0x20000 */
1254 #define R_TEXNODE_PREVIEW 0x40000
1257 #define R_STAMP_TIME 0x0001
1258 #define R_STAMP_FRAME 0x0002
1259 #define R_STAMP_DATE 0x0004
1260 #define R_STAMP_CAMERA 0x0008
1261 #define R_STAMP_SCENE 0x0010
1262 #define R_STAMP_NOTE 0x0020
1263 #define R_STAMP_DRAW 0x0040 /* draw in the image */
1264 #define R_STAMP_MARKER 0x0080
1265 #define R_STAMP_FILENAME 0x0100
1266 #define R_STAMP_SEQSTRIP 0x0200
1267 #define R_STAMP_RENDERTIME 0x0400
1268 #define R_STAMP_CAMERALENS 0x0800
1269 #define R_STAMP_ALL (R_STAMP_TIME|R_STAMP_FRAME|R_STAMP_DATE|R_STAMP_CAMERA|R_STAMP_SCENE| \
1270 R_STAMP_NOTE|R_STAMP_MARKER|R_STAMP_FILENAME|R_STAMP_SEQSTRIP| \
1271 R_STAMP_RENDERTIME|R_STAMP_CAMERALENS)
1275 #define R_ALPHAPREMUL 1
1276 #define R_ALPHAKEY 2
1278 /* color_mgt_flag */
1279 #define R_COLOR_MANAGEMENT (1 << 0) /* deprecated, should only be used in versioning code only */
1280 #define R_COLOR_MANAGEMENT_PREDIVIDE (1 << 1)
1282 /* subimtype, flag options for imtype */
1283 #define R_OPENEXR_HALF 1 /*deprecated*/
1284 #define R_OPENEXR_ZBUF 2 /*deprecated*/
1285 #define R_PREVIEW_JPG 4 /*deprecated*/
1286 #define R_CINEON_LOG 8 /*deprecated*/
1287 #define R_TIFF_16BIT 16 /*deprecated*/
1289 #define R_JPEG2K_12BIT 32 /* Jpeg2000 */ /*deprecated*/
1290 #define R_JPEG2K_16BIT 64 /*deprecated*/
1291 #define R_JPEG2K_YCC 128 /* when disabled use RGB */ /*deprecated*/
1292 #define R_JPEG2K_CINE_PRESET 256 /*deprecated*/
1293 #define R_JPEG2K_CINE_48FPS 512 /*deprecated*/
1295 /* bake_mode: same as RE_BAKE_xxx defines */
1297 #define R_BAKE_CLEAR 1
1298 #define R_BAKE_OSA 2
1299 #define R_BAKE_TO_ACTIVE 4
1300 #define R_BAKE_NORMALIZE 8
1301 #define R_BAKE_MULTIRES 16
1302 #define R_BAKE_LORES_MESH 32
1304 /* bake_normal_space */
1305 #define R_BAKE_SPACE_CAMERA 0
1306 #define R_BAKE_SPACE_WORLD 1
1307 #define R_BAKE_SPACE_OBJECT 2
1308 #define R_BAKE_SPACE_TANGENT 3
1311 #define R_SIMPLE_NO_TRIANGULATE 1
1313 /* sequencer seq_prev_type seq_rend_type */
1317 /* **************** SCENE ********************* */
1319 /* for general use */
1320 #define MAXFRAME 300000
1321 #define MAXFRAMEF 300000.0f
1324 #define MINFRAMEF 0.0f
1326 /* (minimum frame number for current-frame) */
1327 #define MINAFRAME -300000
1328 #define MINAFRAMEF -300000.0f
1330 /* depricate this! */
1331 #define TESTBASE(v3d, base) ( \
1332 ((base)->flag & SELECT) && \
1333 ((base)->lay & v3d->lay) && \
1334 (((base)->object->restrictflag & OB_RESTRICT_VIEW) == 0))
1335 #define TESTBASELIB(v3d, base) ( \
1336 ((base)->flag & SELECT) && \
1337 ((base)->lay & v3d->lay) && \
1338 ((base)->object->id.lib == NULL) && \
1339 (((base)->object->restrictflag & OB_RESTRICT_VIEW) == 0))
1340 #define TESTBASELIB_BGMODE(v3d, scene, base) ( \
1341 ((base)->flag & SELECT) && \
1342 ((base)->lay & (v3d ? v3d->lay : scene->lay)) && \
1343 ((base)->object->id.lib == NULL) && \
1344 (((base)->object->restrictflag & OB_RESTRICT_VIEW) == 0))
1345 #define BASE_EDITABLE_BGMODE(v3d, scene, base) ( \
1346 ((base)->lay & (v3d ? v3d->lay : scene->lay)) && \
1347 ((base)->object->id.lib == NULL) && \
1348 (((base)->object->restrictflag & OB_RESTRICT_VIEW) == 0))
1349 #define BASE_SELECTABLE(v3d, base) ( \
1350 (base->lay & v3d->lay) && \
1351 (base->object->restrictflag & (OB_RESTRICT_SELECT | OB_RESTRICT_VIEW)) == 0)
1352 #define BASE_VISIBLE(v3d, base) ( \
1353 (base->lay & v3d->lay) && \
1354 (base->object->restrictflag & OB_RESTRICT_VIEW) == 0)
1356 #define FIRSTBASE scene->base.first
1357 #define LASTBASE scene->base.last
1358 #define BASACT (scene->basact)
1359 #define OBACT (BASACT ? BASACT->object: NULL)
1361 #define V3D_CAMERA_LOCAL(v3d) ((!(v3d)->scenelock && (v3d)->camera) ? (v3d)->camera : NULL)
1362 #define V3D_CAMERA_SCENE(scene, v3d) ((!(v3d)->scenelock && (v3d)->camera) ? (v3d)->camera : (scene)->camera)
1364 #define CFRA (scene->r.cfra)
1365 #define SUBFRA (scene->r.subframe)
1366 #define SFRA (scene->r.sfra)
1367 #define EFRA (scene->r.efra)
1368 #define PRVRANGEON (scene->r.flag & SCER_PRV_RANGE)
1369 #define PSFRA ((PRVRANGEON) ? (scene->r.psfra) : (scene->r.sfra))
1370 #define PEFRA ((PRVRANGEON) ? (scene->r.pefra) : (scene->r.efra))
1371 #define FRA2TIME(a) ((((double) scene->r.frs_sec_base) * (double)(a)) / (double)scene->r.frs_sec)
1372 #define TIME2FRA(a) ((((double) scene->r.frs_sec) * (double)(a)) / (double)scene->r.frs_sec_base)
1373 #define FPS (((double) scene->r.frs_sec) / (double)scene->r.frs_sec_base)
1375 /* base->flag is in DNA_object_types.h */
1377 /* toolsettings->snap_flag */
1379 #define SCE_SNAP_ROTATE 2
1380 #define SCE_SNAP_PEEL_OBJECT 4
1381 #define SCE_SNAP_PROJECT 8
1382 #define SCE_SNAP_NO_SELF 16
1383 /* toolsettings->snap_target */
1384 #define SCE_SNAP_TARGET_CLOSEST 0
1385 #define SCE_SNAP_TARGET_CENTER 1
1386 #define SCE_SNAP_TARGET_MEDIAN 2
1387 #define SCE_SNAP_TARGET_ACTIVE 3
1388 /* toolsettings->snap_mode */
1389 #define SCE_SNAP_MODE_INCREMENT 0
1390 #define SCE_SNAP_MODE_VERTEX 1
1391 #define SCE_SNAP_MODE_EDGE 2
1392 #define SCE_SNAP_MODE_FACE 3
1393 #define SCE_SNAP_MODE_VOLUME 4
1394 #define SCE_SNAP_MODE_NODE_X 5
1395 #define SCE_SNAP_MODE_NODE_Y 6
1396 #define SCE_SNAP_MODE_NODE_XY 7
1398 /* toolsettings->selectmode */
1399 #define SCE_SELECT_VERTEX 1 /* for mesh */
1400 #define SCE_SELECT_EDGE 2
1401 #define SCE_SELECT_FACE 4
1403 /* toolsettings->particle.selectmode for particles */
1404 #define SCE_SELECT_PATH 1
1405 #define SCE_SELECT_POINT 2
1406 #define SCE_SELECT_END 4
1408 /* sce->recalc (now in use by previewrender) */
1409 #define SCE_PRV_CHANGED 1
1411 /* toolsettings->prop_mode (proportional falloff) */
1412 #define PROP_SMOOTH 0
1413 #define PROP_SPHERE 1
1415 #define PROP_SHARP 3
1417 #define PROP_CONST 5
1418 #define PROP_RANDOM 6
1419 #define PROP_MODE_MAX 7
1421 /* toolsettings->proportional */
1422 #define PROP_EDIT_OFF 0
1423 #define PROP_EDIT_ON 1
1424 #define PROP_EDIT_CONNECTED 2
1427 #define SCE_DS_SELECTED (1<<0)
1428 #define SCE_DS_COLLAPSED (1<<1)
1429 #define SCE_NLA_EDIT_ON (1<<2)
1430 #define SCE_FRAME_DROP (1<<3)
1433 /* return flag BKE_scene_base_iter_next function */
1440 #define AUDIO_MUTE (1<<0)
1441 #define AUDIO_SYNC (1<<1)
1442 #define AUDIO_SCRUB (1<<2)
1443 #define AUDIO_VOLUME_ANIMATED (1<<3)
1445 #define FFMPEG_MULTIPLEX_AUDIO 1 /* deprecated, you can choose none as audiocodec now */
1446 #define FFMPEG_AUTOSPLIT_OUTPUT 2
1447 #define FFMPEG_LOSSLESS_OUTPUT 4
1451 PAINT_SHOW_BRUSH = (1 << 0),
1452 PAINT_FAST_NAVIGATE = (1 << 1),
1453 PAINT_SHOW_BRUSH_ON_SURFACE = (1 << 2),
1457 /* These can eventually be moved to paint flags? */
1458 typedef enum SculptFlags {
1459 SCULPT_SYMM_X = (1<<0),
1460 SCULPT_SYMM_Y = (1<<1),
1461 SCULPT_SYMM_Z = (1<<2),
1462 SCULPT_LOCK_X = (1<<3),
1463 SCULPT_LOCK_Y = (1<<4),
1464 SCULPT_LOCK_Z = (1<<5),
1465 SCULPT_SYMMETRY_FEATHER = (1<<6),
1466 SCULPT_USE_OPENMP = (1<<7),
1467 SCULPT_ONLY_DEFORM = (1<<8),
1468 SCULPT_SHOW_DIFFUSE = (1<<9),
1471 /* ImagePaintSettings.flag */
1472 #define IMAGEPAINT_DRAWING 1
1473 // #define IMAGEPAINT_DRAW_TOOL 2 // deprecated
1474 // #define IMAGEPAINT_DRAW_TOOL_DRAWING 4 // deprecated
1476 /* projection painting only */
1477 #define IMAGEPAINT_PROJECT_DISABLE 8 /* Non projection 3D painting */
1478 #define IMAGEPAINT_PROJECT_XRAY 16
1479 #define IMAGEPAINT_PROJECT_BACKFACE 32
1480 #define IMAGEPAINT_PROJECT_FLAT 64
1481 #define IMAGEPAINT_PROJECT_LAYER_CLONE 128
1482 #define IMAGEPAINT_PROJECT_LAYER_STENCIL 256
1483 #define IMAGEPAINT_PROJECT_LAYER_STENCIL_INV 512
1485 /* toolsettings->uvcalc_flag */
1486 #define UVCALC_FILLHOLES 1
1487 #define UVCALC_NO_ASPECT_CORRECT 2 /* would call this UVCALC_ASPECT_CORRECT, except it should be default with old file */
1488 #define UVCALC_TRANSFORM_CORRECT 4 /* adjust UV's while transforming to avoid distortion */
1489 #define UVCALC_USESUBSURF 8 /* Use mesh data after subsurf to compute UVs*/
1491 /* toolsettings->uv_flag */
1492 #define UV_SYNC_SELECTION 1
1493 #define UV_SHOW_SAME_IMAGE 2
1495 /* toolsettings->uv_selectmode */
1496 #define UV_SELECT_VERTEX 1
1497 #define UV_SELECT_EDGE 2
1498 #define UV_SELECT_FACE 4
1499 #define UV_SELECT_ISLAND 8
1501 /* toolsettings->edge_mode */
1502 #define EDGE_MODE_SELECT 0
1503 #define EDGE_MODE_TAG_SEAM 1
1504 #define EDGE_MODE_TAG_SHARP 2
1505 #define EDGE_MODE_TAG_CREASE 3
1506 #define EDGE_MODE_TAG_BEVEL 4
1508 /* toolsettings->gpencil_flags */
1509 #define GP_TOOL_FLAG_PAINTSESSIONS_ON (1<<0)
1511 /* toolsettings->particle flag */
1512 #define PE_KEEP_LENGTHS 1
1513 #define PE_LOCK_FIRST 2
1514 #define PE_DEFLECT_EMITTER 4
1515 #define PE_INTERPOLATE_ADDED 8
1516 #define PE_DRAW_PART 16
1517 /* #define PE_X_MIRROR 64 */ /* deprecated */
1518 #define PE_FADE_TIME 128
1519 #define PE_AUTO_VELOCITY 256
1521 /* toolsetting->particle brushtype */
1522 #define PE_BRUSH_NONE -1
1523 #define PE_BRUSH_COMB 0
1524 #define PE_BRUSH_CUT 1
1525 #define PE_BRUSH_LENGTH 2
1526 #define PE_BRUSH_PUFF 3
1527 #define PE_BRUSH_ADD 4
1528 #define PE_BRUSH_SMOOTH 5
1529 #define PE_BRUSH_WEIGHT 6
1531 /* this must equal ParticleEditSettings.brush array size */
1532 #define PE_TOT_BRUSH 6
1534 /* ParticleBrushData->flag */
1535 #define PE_BRUSH_DATA_PUFF_VOLUME 1
1537 /* tooksettings->particle edittype */
1538 #define PE_TYPE_PARTICLES 0
1539 #define PE_TYPE_SOFTBODY 1
1540 #define PE_TYPE_CLOTH 2
1542 /* toolsettings->skgen_options */
1543 #define SKGEN_FILTER_INTERNAL (1 << 0)
1544 #define SKGEN_FILTER_EXTERNAL (1 << 1)
1545 #define SKGEN_SYMMETRY (1 << 2)
1546 #define SKGEN_CUT_LENGTH (1 << 3)
1547 #define SKGEN_CUT_ANGLE (1 << 4)
1548 #define SKGEN_CUT_CORRELATION (1 << 5)
1549 #define SKGEN_HARMONIC (1 << 6)
1550 #define SKGEN_STICK_TO_EMBEDDING (1 << 7)
1551 #define SKGEN_ADAPTIVE_DISTANCE (1 << 8)
1552 #define SKGEN_FILTER_SMART (1 << 9)
1553 #define SKGEN_DISP_LENGTH (1 << 10)
1554 #define SKGEN_DISP_WEIGHT (1 << 11)
1555 #define SKGEN_DISP_ORIG (1 << 12)
1556 #define SKGEN_DISP_EMBED (1 << 13)
1557 #define SKGEN_DISP_INDEX (1 << 14)
1559 #define SKGEN_SUB_LENGTH 0
1560 #define SKGEN_SUB_ANGLE 1
1561 #define SKGEN_SUB_CORRELATION 2
1562 #define SKGEN_SUB_TOTAL 3
1564 /* toolsettings->skgen_postpro */
1565 #define SKGEN_SMOOTH 0
1566 #define SKGEN_AVERAGE 1
1567 #define SKGEN_SHARPEN 2
1569 /* toolsettings->bone_sketching */
1570 #define BONE_SKETCHING 1
1571 #define BONE_SKETCHING_QUICK 2
1572 #define BONE_SKETCHING_ADJUST 4
1574 /* toolsettings->bone_sketching_convert */
1575 #define SK_CONVERT_CUT_FIXED 0
1576 #define SK_CONVERT_CUT_LENGTH 1
1577 #define SK_CONVERT_CUT_ADAPTATIVE 2
1578 #define SK_CONVERT_RETARGET 3
1580 /* toolsettings->skgen_retarget_options */
1581 #define SK_RETARGET_AUTONAME 1
1583 /* toolsettings->skgen_retarget_roll */
1584 #define SK_RETARGET_ROLL_NONE 0
1585 #define SK_RETARGET_ROLL_VIEW 1
1586 #define SK_RETARGET_ROLL_JOINT 2
1588 /* physics_settings->flag */
1589 #define PHYS_GLOBAL_GRAVITY 1
1593 /* UnitSettings->system */
1594 #define USER_UNIT_NONE 0
1595 #define USER_UNIT_METRIC 1
1596 #define USER_UNIT_IMPERIAL 2
1597 /* UnitSettings->flag */
1598 #define USER_UNIT_OPT_SPLIT 1
1599 #define USER_UNIT_ROT_RADIANS 2
1605 #endif /* __DNA_SCENE_TYPES_H__ */