From 4f3ca854e1e25d855c7c2b8f6458edd6aae385c5 Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Tue, 26 Feb 2013 21:58:06 +0000 Subject: Fix various warnings with clang build, and adjust cmake clang warnings flags to include a few more that gcc is using too. --- source/blender/makesdna/DNA_image_types.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'source/blender/makesdna') diff --git a/source/blender/makesdna/DNA_image_types.h b/source/blender/makesdna/DNA_image_types.h index 682f54481fc..54ec07c1855 100644 --- a/source/blender/makesdna/DNA_image_types.h +++ b/source/blender/makesdna/DNA_image_types.h @@ -101,10 +101,12 @@ typedef struct Image { float lastupdate; int lastused; short animspeed; + short pad2; /* for generated images */ - short gen_x, gen_y; + int gen_x, gen_y; char gen_type, gen_flag; + char gen_pad[2]; /* display aspect - for UV editing images resized for faster openGL display */ float aspx, aspy; -- cgit v1.2.3 From 3d7867d7f0955cb856c28425e52b18d1a1925d1e Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Wed, 27 Feb 2013 10:26:58 +0000 Subject: Added RGBA|RGB channels toggle to sequencer preview Main purpose of this is to be more compatible with older versions of blender (before alpha cleanup) where sequencer used to display premultiplied image on an straight opengl viewport. Now sequencer preview would behave closer to image editor However adding Alpha and R|G|B displays is not so simple because sequencer is using 2D textures. Would be nice to implement this options as well, but this is not so much important IMO. This hall fix - #34453: VSE: Subtract function does not work properly TODO: Make RGBA display default for our startup.blend --- source/blender/makesdna/DNA_space_types.h | 1 + 1 file changed, 1 insertion(+) (limited to 'source/blender/makesdna') diff --git a/source/blender/makesdna/DNA_space_types.h b/source/blender/makesdna/DNA_space_types.h index 1dfcff4a3c4..b8ba58d7a6d 100644 --- a/source/blender/makesdna/DNA_space_types.h +++ b/source/blender/makesdna/DNA_space_types.h @@ -497,6 +497,7 @@ typedef enum eSpaceSeq_Flag { SEQ_DRAW_SAFE_MARGINS = (1 << 3), SEQ_SHOW_GPENCIL = (1 << 4), SEQ_NO_DRAW_CFRANUM = (1 << 5), + SEQ_USE_ALPHA = (1 << 6), /* use RGBA display mode for preview */ } eSpaceSeq_Flag; /* sseq->view */ -- cgit v1.2.3 From ac6c218cf423ab2ea059ea169df54250ed81af97 Mon Sep 17 00:00:00 2001 From: Joshua Leung Date: Thu, 28 Feb 2013 07:13:33 +0000 Subject: Invalid Driver Targets are now indicated appropriately (using Red Backgrounds) in the UI This is the second part of the fixes for [#32492], making it easier to identify which part of a driver (i.e. which of its targets) is causing problems A number of additional/related changes needed to be made: * Red-alert status for layouts is now propagated down to child layouts when they are created. This is needed as otherwise some of the templates used in the Graph Editor driver settings won't actually get the red-alert status flushed down to them. Also, note that this status needs to be set before any widgets are added to the layout, or else the settings aren't applied when the relevant widgets get created. * "Single Property" RNA-Paths resulting in out of bounds array access will now trigger an error status and appropriate warnings TODO: * The error tagging doesn't get applied immediately after variables are created, or their types changed * There was also some other weirdness involved when a higher-value flag (1<<10) was used for this setting, which needs further attention --- source/blender/makesdna/DNA_anim_types.h | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'source/blender/makesdna') diff --git a/source/blender/makesdna/DNA_anim_types.h b/source/blender/makesdna/DNA_anim_types.h index 1ac6e6db94b..73e2a9f433b 100644 --- a/source/blender/makesdna/DNA_anim_types.h +++ b/source/blender/makesdna/DNA_anim_types.h @@ -284,15 +284,18 @@ typedef enum eDriverTarget_Flag { /* used for targets that use the pchan_name instead of RNA path * (i.e. rotation difference) */ - DTAR_FLAG_STRUCT_REF = (1<<0), + DTAR_FLAG_STRUCT_REF = (1 << 0), /* idtype can only be 'Object' */ - DTAR_FLAG_ID_OB_ONLY = (1<<1), + DTAR_FLAG_ID_OB_ONLY = (1 << 1), /* "localspace" flags */ /* base flag - basically "pre parent+constraints" */ - DTAR_FLAG_LOCALSPACE = (1<<2), + DTAR_FLAG_LOCALSPACE = (1 << 2), /* include constraints transformed to space including parents */ - DTAR_FLAG_LOCAL_CONSTS = (1<<3), + DTAR_FLAG_LOCAL_CONSTS = (1 << 3), + + /* error flags */ + DTAR_FLAG_INVALID = (1 << 4), } eDriverTarget_Flag; /* Transform Channels for Driver Targets */ -- cgit v1.2.3 From 2de9ce794015181c7c6ff9fdaddc166b067399db Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 1 Mar 2013 06:17:59 +0000 Subject: keymap filter by keybindings in the userpreferences. - optional, select between name/keybinding. - when key input can't be parsed, alert red to give the user some feedback. - key shortcut parsing could be improved or swapped out for button which grabs shortcut. --- source/blender/makesdna/DNA_space_types.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/blender/makesdna') diff --git a/source/blender/makesdna/DNA_space_types.h b/source/blender/makesdna/DNA_space_types.h index b8ba58d7a6d..4c28199481f 100644 --- a/source/blender/makesdna/DNA_space_types.h +++ b/source/blender/makesdna/DNA_space_types.h @@ -1004,8 +1004,8 @@ typedef struct SpaceUserPref { ListBase regionbase; /* storage of regions for inactive spaces */ int spacetype; - int pad; - + char pad[3]; + char filter_type; char filter[64]; /* search term for filtering in the UI */ } SpaceUserPref; -- cgit v1.2.3 From 0ac07404baf41aef65367395b86957ab1efa655f Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 1 Mar 2013 14:47:06 +0000 Subject: style cleanup: braces with multi-line statements, also add some comments. --- source/blender/makesdna/DNA_key_types.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source/blender/makesdna') diff --git a/source/blender/makesdna/DNA_key_types.h b/source/blender/makesdna/DNA_key_types.h index 6e5861043c1..4783247420c 100644 --- a/source/blender/makesdna/DNA_key_types.h +++ b/source/blender/makesdna/DNA_key_types.h @@ -29,6 +29,10 @@ /** \file DNA_key_types.h * \ingroup DNA + * + * This file defines structures for Shape-Keys (not animation keyframes), + * attached to Mesh, Curve and Lattice Data. Even though Key's are ID blocks they + * aren't intended to be shared between multiple data blocks as with other ID types. */ #include "DNA_defs.h" -- cgit v1.2.3 From f186f89a42575622a9939a6fbe3f240d2a1ba85a Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Fri, 1 Mar 2013 15:37:15 +0000 Subject: Fix #34461: Inconsistent behavior of "Color Mix Node" and "Alpha Over Node" Added compatibility option "Straight Alpha Output" to image input node When this option is enabled, image input node will convert float buffer to straight alpha. This is not what you'll usually want with new alpha pipeline, nit this is needed to preserve compatibility with older files saved in 2.65. In that version byte image are resulting with straight alpha passing to the compositor and alpha-overing required extra premultiplication of inputs. So, that's why Straight Alpha Output is needed -- it's set in versioning code for byte node images so they'll still output straight alpha. This option is currently only available in N-panel. Additional change: added Alpha Mode for image input node to N-panel. --- source/blender/makesdna/DNA_node_types.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'source/blender/makesdna') diff --git a/source/blender/makesdna/DNA_node_types.h b/source/blender/makesdna/DNA_node_types.h index 5aaf46a541f..62c997b72c6 100644 --- a/source/blender/makesdna/DNA_node_types.h +++ b/source/blender/makesdna/DNA_node_types.h @@ -854,4 +854,7 @@ typedef struct NodeShaderNormalMap { #define CMP_NODE_MASK_MBLUR_SAMPLES_MAX 64 +/* image */ +#define CMP_NODE_IMAGE_USE_STRAIGHT_OUTPUT 1 + #endif -- cgit v1.2.3 From 8f01b50e147b701fb0b3e2251fec88bec645df50 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 2 Mar 2013 07:27:19 +0000 Subject: code cleanup: clarify comment about virtial-modifiers, also add comments to DNA headers when its not so obvious what their purpose is. --- source/blender/makesdna/DNA_action_types.h | 6 +++++- source/blender/makesdna/DNA_actuator_types.h | 6 +++--- source/blender/makesdna/DNA_controller_types.h | 5 +++-- source/blender/makesdna/DNA_customdata_types.h | 4 +++- source/blender/makesdna/DNA_defs.h | 2 ++ source/blender/makesdna/DNA_group_types.h | 4 +++- source/blender/makesdna/DNA_mask_types.h | 3 +++ source/blender/makesdna/DNA_property_types.h | 5 +++-- source/blender/makesdna/DNA_sensor_types.h | 4 +++- source/blender/makesdna/DNA_sequence_types.h | 10 +++++++++- source/blender/makesdna/DNA_space_types.h | 4 +++- source/blender/makesdna/DNA_text_types.h | 5 ++++- source/blender/makesdna/DNA_tracking_types.h | 4 +++- source/blender/makesdna/DNA_vfont_types.h | 5 ++++- 14 files changed, 51 insertions(+), 16 deletions(-) (limited to 'source/blender/makesdna') diff --git a/source/blender/makesdna/DNA_action_types.h b/source/blender/makesdna/DNA_action_types.h index f227af78dab..b27abb519d9 100644 --- a/source/blender/makesdna/DNA_action_types.h +++ b/source/blender/makesdna/DNA_action_types.h @@ -27,6 +27,10 @@ /** \file DNA_action_types.h * \ingroup DNA + * + * Define actions data-block for the animation system. + * A collection of animation curves and drivers to be assigned to data-blocks + * or sequenced in the non-linear-editor (NLA). */ #ifndef __DNA_ACTION_TYPES_H__ @@ -689,4 +693,4 @@ typedef enum ACHAN_FLAG { ACHAN_MOVED = (1 << 31) } ACHAN_FLAG; -#endif +#endif /* __DNA_ACTION_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_actuator_types.h b/source/blender/makesdna/DNA_actuator_types.h index 7c4772f24e8..1495ba1b1a5 100644 --- a/source/blender/makesdna/DNA_actuator_types.h +++ b/source/blender/makesdna/DNA_actuator_types.h @@ -27,6 +27,8 @@ /** \file DNA_actuator_types.h * \ingroup DNA + * + * #bActuator type is specifically for use by Object logic-bricks in the game-engine. */ #ifndef __DNA_ACTUATOR_TYPES_H__ @@ -535,6 +537,4 @@ typedef struct bActuator { #define ACT_STEERING_AUTOMATICFACING 4 #define ACT_STEERING_NORMALUP 8 -#endif - - +#endif /* __DNA_ACTUATOR_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_controller_types.h b/source/blender/makesdna/DNA_controller_types.h index bdfedb5b4d1..0c1aaf5fd20 100644 --- a/source/blender/makesdna/DNA_controller_types.h +++ b/source/blender/makesdna/DNA_controller_types.h @@ -27,6 +27,8 @@ /** \file DNA_controller_types.h * \ingroup DNA + * + * #bController type is specifically for use by Object logic-bricks in the game-engine. */ #ifndef __DNA_CONTROLLER_TYPES_H__ @@ -89,5 +91,4 @@ typedef struct bController { #define CONT_PY_SCRIPT 0 #define CONT_PY_MODULE 1 -#endif - +#endif /* __DNA_CONTROLLER_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_customdata_types.h b/source/blender/makesdna/DNA_customdata_types.h index e28b8780250..4a3debe756b 100644 --- a/source/blender/makesdna/DNA_customdata_types.h +++ b/source/blender/makesdna/DNA_customdata_types.h @@ -27,6 +27,8 @@ /** \file DNA_customdata_types.h * \ingroup DNA + * + * Used for custom mesh data types (stored per vert/edge/loop/face) */ #ifndef __DNA_CUSTOMDATA_TYPES_H__ @@ -177,4 +179,4 @@ typedef struct CustomData { } #endif -#endif +#endif /* __DNA_CUSTOMDATA_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_defs.h b/source/blender/makesdna/DNA_defs.h index 774fbcf081a..ffe4fc970b1 100644 --- a/source/blender/makesdna/DNA_defs.h +++ b/source/blender/makesdna/DNA_defs.h @@ -22,6 +22,8 @@ /** \file DNA_defs.h * \ingroup DNA + * + * Group generic defines for all DNA headers may use in this file. */ #ifndef __DNA_DEFS_H__ diff --git a/source/blender/makesdna/DNA_group_types.h b/source/blender/makesdna/DNA_group_types.h index a084bee1c2d..2740281b4c0 100644 --- a/source/blender/makesdna/DNA_group_types.h +++ b/source/blender/makesdna/DNA_group_types.h @@ -27,6 +27,8 @@ /** \file DNA_group_types.h * \ingroup DNA + * + * \brief Object groups, one object can be in many groups at once. */ #ifndef __DNA_GROUP_TYPES_H__ @@ -58,4 +60,4 @@ typedef struct Group { float dupli_ofs[3]; } Group; -#endif +#endif /* __DNA_GROUP_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_mask_types.h b/source/blender/makesdna/DNA_mask_types.h index 5b25d1a072c..1b6b802f2de 100644 --- a/source/blender/makesdna/DNA_mask_types.h +++ b/source/blender/makesdna/DNA_mask_types.h @@ -30,6 +30,9 @@ * \ingroup DNA * \since march-2012 * \author Sergey Sharybin + * + * Mask data-blocks are collections of 2D curves to be used + * for image masking in the compositor and sequencer. */ #ifndef __DNA_MASK_TYPES_H__ diff --git a/source/blender/makesdna/DNA_property_types.h b/source/blender/makesdna/DNA_property_types.h index c1b810cd42b..c8275a41404 100644 --- a/source/blender/makesdna/DNA_property_types.h +++ b/source/blender/makesdna/DNA_property_types.h @@ -31,6 +31,8 @@ * \author nzc * \attention Renderrecipe and scene decription. The fact that there is a * hierarchy here is a bit strange, and not desirable. + * + * #bProperty type is specifically for use by Objects game-logic. */ #ifndef __DNA_PROPERTY_TYPES_H__ @@ -60,5 +62,4 @@ typedef struct bProperty { #define MAX_PROPSTRING 128 -#endif - +#endif /* __DNA_PROPERTY_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_sensor_types.h b/source/blender/makesdna/DNA_sensor_types.h index 05927e3a486..d8cf80d047b 100644 --- a/source/blender/makesdna/DNA_sensor_types.h +++ b/source/blender/makesdna/DNA_sensor_types.h @@ -29,6 +29,8 @@ * \ingroup DNA * \since mar-2001 * \author nzc + * + * #bSensor type is specifically for use by Object logic-bricks in the game-engine. */ #ifndef __DNA_SENSOR_TYPES_H__ @@ -324,5 +326,5 @@ typedef struct bJoystickSensor { #define SENS_DELAY_REPEAT 1 // should match JOYINDEX_MAX in SCA_JoystickDefines.h */ #define SENS_JOY_MAXINDEX 8 -#endif +#endif /* __DNA_SENSOR_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_sequence_types.h b/source/blender/makesdna/DNA_sequence_types.h index 0aa466f7245..455350d8310 100644 --- a/source/blender/makesdna/DNA_sequence_types.h +++ b/source/blender/makesdna/DNA_sequence_types.h @@ -28,6 +28,14 @@ * \ingroup DNA * \since mar-2001 * \author nzc + * + * Structs for use by the 'Sequencer' (Video Editor) + * + * Note on terminology + * - #Sequence: video/effect/audio data you can select and manipulate in the sequencer. + * - #Sequence.machine: Strange name for the channel. + * - #Strip: The data referenced by the #Sequence + * - Meta Strip (SEQ_TYPE_META): Support for nesting Sequences. */ #ifndef __DNA_SEQUENCE_TYPES_H__ @@ -441,4 +449,4 @@ enum { SEQUENCE_MASK_INPUT_ID = 1 }; -#endif +#endif /* __DNA_SEQUENCE_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_space_types.h b/source/blender/makesdna/DNA_space_types.h index 4c28199481f..0873c2278c5 100644 --- a/source/blender/makesdna/DNA_space_types.h +++ b/source/blender/makesdna/DNA_space_types.h @@ -28,6 +28,8 @@ * \ingroup DNA * \since mar-2001 * \author nzc + * + * Structs for each of space type in the user interface. */ #ifndef __DNA_SPACE_TYPES_H__ @@ -1133,4 +1135,4 @@ typedef enum eSpace_Type { #define IMG_SIZE_FALLBACK 256 -#endif +#endif /* __DNA_SPACE_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_text_types.h b/source/blender/makesdna/DNA_text_types.h index 3194adba3a0..8b18ecd7253 100644 --- a/source/blender/makesdna/DNA_text_types.h +++ b/source/blender/makesdna/DNA_text_types.h @@ -28,6 +28,9 @@ * \ingroup DNA * \since mar-2001 * \author nzc + * + * Text blocks used for Python-Scripts, OpenShadingLanguage + * and arbitrary text data to store in blend files. */ #ifndef __DNA_TEXT_TYPES_H__ @@ -75,4 +78,4 @@ typedef struct Text { #define TXT_FOLLOW 0x0200 /* always follow cursor (console) */ #define TXT_TABSTOSPACES 0x0400 /* use space instead of tabs */ -#endif +#endif /* __DNA_TEXT_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_tracking_types.h b/source/blender/makesdna/DNA_tracking_types.h index 8789a17a7f7..73cda070fd2 100644 --- a/source/blender/makesdna/DNA_tracking_types.h +++ b/source/blender/makesdna/DNA_tracking_types.h @@ -30,6 +30,8 @@ * \ingroup DNA * \since may-2011 * \author Sergey Sharybin + * + * Structs used for camera tracking and the movie-clip editor. */ #ifndef __DNA_TRACKING_TYPES_H__ @@ -431,4 +433,4 @@ enum { TRACKING_COVERAGE_OK = 2 }; -#endif +#endif /* __DNA_TRACKING_TYPES_H__ */ diff --git a/source/blender/makesdna/DNA_vfont_types.h b/source/blender/makesdna/DNA_vfont_types.h index 7aaeaf23db2..416c5f594a3 100644 --- a/source/blender/makesdna/DNA_vfont_types.h +++ b/source/blender/makesdna/DNA_vfont_types.h @@ -29,6 +29,9 @@ * \ingroup DNA * \since mar-2001 * \author nzc + * + * Vector Fonts used for text in the 3D view-port + * (unrelated to text used to render the GUI). */ #ifndef __DNA_VFONT_TYPES_H__ @@ -63,5 +66,5 @@ typedef struct VFont { #define FO_SELCHANGE 10 #define FO_BUILTIN_NAME "" -#endif +#endif /* __DNA_VFONT_TYPES_H__ */ -- cgit v1.2.3 From ceaf8e48ef5fbdb7e45a06b84bf24365ec5c5ed1 Mon Sep 17 00:00:00 2001 From: Sergej Reich Date: Sun, 3 Mar 2013 06:09:48 +0000 Subject: rigidbody: Revert to running simulation on frame update Instead of flagging the rigid body world for frame update just call BKE_rigidbody_do_simulation() recursively for all scenes. This avoids having to constantly check if the simulation needs to be updated. --- source/blender/makesdna/DNA_rigidbody_types.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'source/blender/makesdna') diff --git a/source/blender/makesdna/DNA_rigidbody_types.h b/source/blender/makesdna/DNA_rigidbody_types.h index c144bc4e588..4a96c324f04 100644 --- a/source/blender/makesdna/DNA_rigidbody_types.h +++ b/source/blender/makesdna/DNA_rigidbody_types.h @@ -80,9 +80,7 @@ typedef enum eRigidBodyWorld_Flag { /* sim data needs to be rebuilt */ RBW_FLAG_NEEDS_REBUILD = (1 << 1), /* usse split impulse when stepping the simulation */ - RBW_FLAG_USE_SPLIT_IMPULSE = (1 << 2), - /* need to step simulation after frame update */ - RBW_FLAG_FRAME_UPDATE = (1 << 3) + RBW_FLAG_USE_SPLIT_IMPULSE = (1 << 2) } eRigidBodyWorld_Flag; /* ******************************** */ -- cgit v1.2.3