Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2011-07-21 13:40:59 +0400
committerNathan Letwory <nathan@letworyinteractive.com>2011-07-21 13:40:59 +0400
commiteea7c358c7d606f9a4df8f11d42ac5b0df28a6d4 (patch)
tree32c72886e2007dad65c71b89c90dee891c08e5c3 /source/blender/makesdna
parentc89379e7e15aeb50a7d7106218821a17e5a7dac9 (diff)
parent314fdb941e28d5f1fbe2acace6133d6216f4e36c (diff)
svn merge -r37276:38555 https://svn.blender.org/svnroot/bf-blender/trunk/blender .
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r--source/blender/makesdna/DNA_actuator_types.h2
-rw-r--r--source/blender/makesdna/DNA_image_types.h6
-rw-r--r--source/blender/makesdna/DNA_material_types.h2
-rw-r--r--source/blender/makesdna/DNA_object_fluidsim.h5
-rw-r--r--source/blender/makesdna/DNA_object_force.h2
-rw-r--r--source/blender/makesdna/DNA_object_types.h9
-rw-r--r--source/blender/makesdna/DNA_particle_types.h5
-rw-r--r--source/blender/makesdna/DNA_scene_types.h27
-rw-r--r--source/blender/makesdna/DNA_sequence_types.h45
-rw-r--r--source/blender/makesdna/DNA_space_types.h27
-rw-r--r--source/blender/makesdna/DNA_userdef_types.h8
-rw-r--r--source/blender/makesdna/intern/makesdna.c16
12 files changed, 83 insertions, 71 deletions
diff --git a/source/blender/makesdna/DNA_actuator_types.h b/source/blender/makesdna/DNA_actuator_types.h
index 683d8142cc9..887a0300ee2 100644
--- a/source/blender/makesdna/DNA_actuator_types.h
+++ b/source/blender/makesdna/DNA_actuator_types.h
@@ -133,7 +133,7 @@ typedef struct bIpoActuator {
typedef struct bCameraActuator {
struct Object *ob;
float height, min, max;
- float pad;
+ float damping;
short pad1, axis;
float pad2;
} bCameraActuator ;
diff --git a/source/blender/makesdna/DNA_image_types.h b/source/blender/makesdna/DNA_image_types.h
index 99ed2319415..dd033339ca4 100644
--- a/source/blender/makesdna/DNA_image_types.h
+++ b/source/blender/makesdna/DNA_image_types.h
@@ -102,7 +102,8 @@ typedef struct Image {
short animspeed;
/* for generated images */
- short gen_x, gen_y, gen_type;
+ short gen_x, gen_y;
+ char gen_type, gen_flag;
/* display aspect - for UV editing images resized for faster openGL display */
float aspx, aspy;
@@ -136,5 +137,8 @@ typedef struct Image {
#define IMA_MAX_RENDER_TEXT 512
#define IMA_MAX_RENDER_SLOT 8
+/* gen_flag */
+#define IMA_GEN_FLOAT 1
+
#endif
diff --git a/source/blender/makesdna/DNA_material_types.h b/source/blender/makesdna/DNA_material_types.h
index 1489593f7f6..060b1bf42d1 100644
--- a/source/blender/makesdna/DNA_material_types.h
+++ b/source/blender/makesdna/DNA_material_types.h
@@ -161,7 +161,7 @@ typedef struct Material {
int mapto_textured; /* render-time cache to optimise texture lookups */
short shadowonly_flag; /* "shadowsonly" type */
- short pad;
+ short index; /* custom index for render passes */
ListBase gpumaterial; /* runtime */
} Material;
diff --git a/source/blender/makesdna/DNA_object_fluidsim.h b/source/blender/makesdna/DNA_object_fluidsim.h
index 6f4c16cb7f3..578bf8dd415 100644
--- a/source/blender/makesdna/DNA_object_fluidsim.h
+++ b/source/blender/makesdna/DNA_object_fluidsim.h
@@ -69,7 +69,7 @@ typedef struct FluidsimSettings {
short viscosityMode;
short viscosityExponent;
/* gravity strength */
- float gravx,gravy,gravz;
+ float grav[3];
/* anim start end time (in seconds) */
float animStart, animEnd;
/* bake start end time (in blender frames) */
@@ -161,6 +161,9 @@ typedef struct FluidsimSettings {
#define OB_FSBND_FREESLIP (1<<(OB_TYPEFLAG_START+4))
#define OB_FSINFLOW_LOCALCOORD (1<<(OB_TYPEFLAG_START+5))
+/* surface generation flag (part of enabling chapter 6 of "Free Surface Flows with Moving and Deforming Objects for LBM") */
+#define OB_FSSG_NOOBS (1<<(OB_TYPEFLAG_START+6))
+
// guiDisplayMode particle flags
#define OB_FSDOM_GEOM 1
#define OB_FSDOM_PREVIEW 2
diff --git a/source/blender/makesdna/DNA_object_force.h b/source/blender/makesdna/DNA_object_force.h
index 37568a22f54..fc8ce1b5820 100644
--- a/source/blender/makesdna/DNA_object_force.h
+++ b/source/blender/makesdna/DNA_object_force.h
@@ -420,7 +420,7 @@ typedef struct SoftBody {
#define OB_SB_SELF 512
#define OB_SB_FACECOLL 1024
#define OB_SB_EDGECOLL 2048
-#define OB_SB_COLLFINAL 4096
+#define OB_SB_COLLFINAL 4096 /* deprecated */
#define OB_SB_BIG_UI 8192
#define OB_SB_AERO_ANGLE 16384
diff --git a/source/blender/makesdna/DNA_object_types.h b/source/blender/makesdna/DNA_object_types.h
index 54a885a0860..dfc7d42793d 100644
--- a/source/blender/makesdna/DNA_object_types.h
+++ b/source/blender/makesdna/DNA_object_types.h
@@ -250,12 +250,11 @@ typedef struct Object {
struct FluidsimSettings *fluidsimSettings; /* if fluidsim enabled, store additional settings */
struct DerivedMesh *derivedDeform, *derivedFinal;
- int lastDataMask; /* the custom data layer mask that was last used to calculate derivedDeform and derivedFinal */
+ unsigned int lastDataMask; /* the custom data layer mask that was last used to calculate derivedDeform and derivedFinal */
+ unsigned int customdata_mask; /* (extra) custom data layer mask to use for creating derivedmesh, set by depsgraph */
unsigned int state; /* bit masks of game controllers that are active */
unsigned int init_state; /* bit masks of initial state as recorded by the users */
- int pad2;
-
ListBase gpulamp; /* runtime, for lamps only */
ListBase pc_ids;
ListBase *duplilist; /* for temporary dupli list storage, only for use by RNA API */
@@ -291,10 +290,6 @@ typedef struct DupliObject {
float orco[3], uv[2];
} DupliObject;
-/* this work object is defined in object.c */
-extern Object workob;
-
-
/* **************** OBJECT ********************* */
/* used many places... should be specialized */
diff --git a/source/blender/makesdna/DNA_particle_types.h b/source/blender/makesdna/DNA_particle_types.h
index 09053848b28..69ee530c0b6 100644
--- a/source/blender/makesdna/DNA_particle_types.h
+++ b/source/blender/makesdna/DNA_particle_types.h
@@ -89,7 +89,8 @@ typedef struct ParticleDupliWeight {
struct ParticleDupliWeight *next, *prev;
struct Object *ob;
short count;
- short flag, rt[2];
+ short flag;
+ short index, rt; /* only updated on file save and used on file load */
} ParticleDupliWeight;
typedef struct ParticleData {
@@ -168,7 +169,7 @@ typedef struct ParticleSettings {
/* billboards */
short bb_align, bb_uv_split, bb_anim, bb_split_offset;
- float bb_tilt, bb_rand_tilt, bb_offset[2];
+ float bb_tilt, bb_rand_tilt, bb_offset[2], bb_size[2], bb_vel_head, bb_vel_tail;
/* draw color */
float color_vec_max;
diff --git a/source/blender/makesdna/DNA_scene_types.h b/source/blender/makesdna/DNA_scene_types.h
index 70e90cfc713..3c14dacf973 100644
--- a/source/blender/makesdna/DNA_scene_types.h
+++ b/source/blender/makesdna/DNA_scene_types.h
@@ -201,6 +201,7 @@ typedef struct SceneRenderLayer {
#define SCE_PASS_RAYHITS (1<<15)
#define SCE_PASS_EMIT (1<<16)
#define SCE_PASS_ENVIRONMENT (1<<17)
+#define SCE_PASS_INDEXMA (1<<18)
/* note, srl->passflag is treestore element 'nr' in outliner, short still... */
@@ -253,19 +254,12 @@ typedef struct RenderData {
*/
short yparts;
- short winpos, planes, imtype, subimtype;
-
- /** Mode bits: */
- /* 0: Enable backbuffering for images */
- short bufflag;
- short quality;
+ short planes, imtype, subimtype, quality;
/**
* Render to image editor, fullscreen or to new window.
*/
short displaymode;
-
- short rpad1, rpad2;
/**
* Flags for render settings. Use bit-masking to access the settings.
@@ -322,11 +316,7 @@ typedef struct RenderData {
/**
* Adjustment factors for the aspect ratio in the x direction, was a short in 2.45
*/
- float xasp;
- /**
- * Adjustment factors for the aspect ratio in the x direction, was a short in 2.45
- */
- float yasp;
+ float xasp, yasp;
float frs_sec_base;
@@ -349,8 +339,8 @@ typedef struct RenderData {
short bake_normal_space, bake_quad_split;
float bake_maxdist, bake_biasdist, bake_pad;
- /* paths to backbufffer, output */
- char backbuf[160], pic[160];
+ /* path to render output */
+ char pic[240];
/* stamps flags. */
int stamp;
@@ -440,7 +430,8 @@ typedef struct GameData {
/*
* Radius of the activity bubble, in Manhattan length. Objects
* outside the box are activity-culled. */
- float activityBoxRadius; //it's not being used ANYWHERE !!!!!!!!!!!!!!
+ float activityBoxRadius;
+
/*
* bit 3: (gameengine): Activity culling is enabled.
* bit 5: (gameengine) : enable Bullet DBVT tree for view frustrum culling
@@ -457,7 +448,8 @@ typedef struct GameData {
/* stereo/dome mode */
struct GameDome dome;
- short stereoflag, stereomode, xsch, ysch; //xsch and ysch used for backwards compat.
+ short stereoflag, stereomode;
+ short pad2, pad3;
float eyeseparation, pad1;
} GameData;
@@ -1082,6 +1074,7 @@ typedef struct Scene {
#define SCE_SNAP_ROTATE 2
#define SCE_SNAP_PEEL_OBJECT 4
#define SCE_SNAP_PROJECT 8
+#define SCE_SNAP_PROJECT_NO_SELF 16
/* toolsettings->snap_target */
#define SCE_SNAP_TARGET_CLOSEST 0
#define SCE_SNAP_TARGET_CENTER 1
diff --git a/source/blender/makesdna/DNA_sequence_types.h b/source/blender/makesdna/DNA_sequence_types.h
index f89cc9d518a..3e7654bcf47 100644
--- a/source/blender/makesdna/DNA_sequence_types.h
+++ b/source/blender/makesdna/DNA_sequence_types.h
@@ -253,27 +253,30 @@ typedef struct SpeedControlVars {
#define SEQ_NAME_MAXSTR 24
/* seq->flag */
-#define SEQ_LEFTSEL 2
-#define SEQ_RIGHTSEL 4
-#define SEQ_OVERLAP 8
-#define SEQ_FILTERY 16
-#define SEQ_MUTE 32
-#define SEQ_MAKE_PREMUL 64
-#define SEQ_REVERSE_FRAMES 128
-#define SEQ_IPO_FRAME_LOCKED 256
-#define SEQ_EFFECT_NOT_LOADED 512
-#define SEQ_FLAG_DELETE 1024
-#define SEQ_FLIPX 2048
-#define SEQ_FLIPY 4096
-#define SEQ_MAKE_FLOAT 8192
-#define SEQ_LOCK 16384
-#define SEQ_USE_PROXY 32768
-#define SEQ_USE_TRANSFORM 65536
-#define SEQ_USE_CROP 131072
-#define SEQ_USE_COLOR_BALANCE 262144
-#define SEQ_USE_PROXY_CUSTOM_DIR 524288
-#define SEQ_USE_PROXY_CUSTOM_FILE 2097152
-#define SEQ_USE_EFFECT_DEFAULT_FADE 4194304
+#define SEQ_LEFTSEL (1<<1)
+#define SEQ_RIGHTSEL (1<<2)
+#define SEQ_OVERLAP (1<<3)
+#define SEQ_FILTERY (1<<4)
+#define SEQ_MUTE (1<<5)
+#define SEQ_MAKE_PREMUL (1<<6)
+#define SEQ_REVERSE_FRAMES (1<<7)
+#define SEQ_IPO_FRAME_LOCKED (1<<8)
+#define SEQ_EFFECT_NOT_LOADED (1<<9)
+#define SEQ_FLAG_DELETE (1<<10)
+#define SEQ_FLIPX (1<<11)
+#define SEQ_FLIPY (1<<12)
+#define SEQ_MAKE_FLOAT (1<<13)
+#define SEQ_LOCK (1<<14)
+#define SEQ_USE_PROXY (1<<15)
+#define SEQ_USE_TRANSFORM (1<<16)
+#define SEQ_USE_CROP (1<<17)
+#define SEQ_USE_COLOR_BALANCE (1<<18)
+#define SEQ_USE_PROXY_CUSTOM_DIR (1<<19)
+
+#define SEQ_USE_PROXY_CUSTOM_FILE (1<<21)
+#define SEQ_USE_EFFECT_DEFAULT_FADE (1<<22)
+
+#define SEQ_INVALID_EFFECT (1<<31)
/* convenience define for all selection flags */
#define SEQ_ALLSEL (SELECT+SEQ_LEFTSEL+SEQ_RIGHTSEL)
diff --git a/source/blender/makesdna/DNA_space_types.h b/source/blender/makesdna/DNA_space_types.h
index e120cd14775..ff9f2269f53 100644
--- a/source/blender/makesdna/DNA_space_types.h
+++ b/source/blender/makesdna/DNA_space_types.h
@@ -696,18 +696,19 @@ enum FileSortTypeE {
#define FILE_OPENFILE 0
#define FILE_SAVE 1
-/* sfile->flag and simasel->flag */
-#define FILE_SHOWSHORT 1
-#define FILE_RELPATH 2 /* was FILE_STRINGCODE */
-#define FILE_LINK 4
-#define FILE_HIDE_DOT 8
-#define FILE_AUTOSELECT 16
-#define FILE_ACTIVELAY 32
-#define FILE_ATCURSOR 64
-#define FILE_SYNCPOSE 128
-#define FILE_FILTER 256
-#define FILE_BOOKMARKS 512
-#define FILE_GROUP_INSTANCE 1024
+/* sfile->params->flag and simasel->flag */
+#define FILE_SHOWSHORT (1<<0)
+#define FILE_RELPATH (1<<1) /* was FILE_STRINGCODE */
+#define FILE_LINK (1<<2)
+#define FILE_HIDE_DOT (1<<3)
+#define FILE_AUTOSELECT (1<<4)
+#define FILE_ACTIVELAY (1<<5)
+#define FILE_ATCURSOR (1<<6)
+#define FILE_DIRSEL_ONLY (1<<7)
+#define FILE_FILTER (1<<8)
+#define FILE_BOOKMARKS (1<<9)
+#define FILE_GROUP_INSTANCE (1<<10)
+
/* files in filesel list: file types */
#define BLENDERFILE (1<<2)
@@ -753,7 +754,7 @@ enum FileSortTypeE {
#define SI_EDITTILE (1<<1)
#define SI_CLIP_UV (1<<2)
#define SI_DRAWTOOL (1<<3)
-#define SI_DEPRECATED1 (1<<4) /* stick UVs to others in the same location */
+#define SI_NO_DRAWFACES (1<<4)
#define SI_DRAWSHADOW (1<<5)
#define SI_SELACTFACE (1<<6) /* deprecated */
#define SI_DEPRECATED2 (1<<7)
diff --git a/source/blender/makesdna/DNA_userdef_types.h b/source/blender/makesdna/DNA_userdef_types.h
index 78bc1c73ec9..a94c10a7aa0 100644
--- a/source/blender/makesdna/DNA_userdef_types.h
+++ b/source/blender/makesdna/DNA_userdef_types.h
@@ -305,7 +305,7 @@ typedef struct UserDef {
int savetime;
char tempdir[160]; // FILE_MAXDIR length
char fontdir[160];
- char renderdir[160];
+ char renderdir[240]; // FILE_MAX length
char textudir[160];
char plugtexdir[160];
char plugseqdir[160];
@@ -375,7 +375,8 @@ typedef struct UserDef {
short scrcastwait; /* milliseconds between screencast snapshots */
short widget_unit; /* defaults to 20 for 72 DPI setting */
- short pad[1];
+ short anisotropic_filter;
+ /*short pad[3]; */
float ndof_sensitivity; /* overall sensitivity of 3D mouse */
int ndof_flag; /* flags for 3D mouse */
@@ -387,8 +388,7 @@ typedef struct UserDef {
short autokey_mode; /* autokeying mode */
short autokey_flag; /* flags for autokeying */
- short text_render, pad9; /*options for text rendering*/
- float pad10;
+ short text_render, pad9[3]; /*options for text rendering*/
struct ColorBand coba_weight; /* from texture.h */
diff --git a/source/blender/makesdna/intern/makesdna.c b/source/blender/makesdna/intern/makesdna.c
index 8b841b67e54..80299d44a78 100644
--- a/source/blender/makesdna/intern/makesdna.c
+++ b/source/blender/makesdna/intern/makesdna.c
@@ -670,6 +670,8 @@ int arraysize(char *astr, int len)
}
else if( str[a]==']' && cp) {
str[a]= 0;
+ /* if 'cp' is a preprocessor definition, it will evaluate to 0,
+ * the caller needs to check for this case and throw an error */
mul*= atoi(cp);
}
}
@@ -713,7 +715,12 @@ static int calculate_structlens(int firststruct)
/* has the name an extra length? (array) */
mul= 1;
if( cp[namelen-1]==']') mul= arraysize(cp, namelen);
-
+
+ if (mul == 0) {
+ printf("Zero array size found or could not parse %s: '%.*s'\n", types[structtype], namelen + 1, cp);
+ dna_error = 1;
+ }
+
/* 4-8 aligned/ */
if(sizeof(void *) == 4) {
if (len % 4) {
@@ -743,7 +750,12 @@ static int calculate_structlens(int firststruct)
/* has the name an extra length? (array) */
mul= 1;
if( cp[namelen-1]==']') mul= arraysize(cp, namelen);
-
+
+ if (mul == 0) {
+ printf("Zero array size found or could not parse %s: '%.*s'\n", types[structtype], namelen + 1, cp);
+ dna_error = 1;
+ }
+
/* struct alignment */
if(type >= firststruct) {
if(sizeof(void *)==8 && (len % 8) ) {