Cleanup: comment line length (DNA)

Prevents clang-format wrapping text before comments.
This commit is contained in:
2019-01-15 23:14:35 +11:00
parent 39acbebe46
commit 328a0f975b
37 changed files with 625 additions and 349 deletions

View File

@@ -133,11 +133,13 @@ enum {
/*->flag*/
enum {
/* This IDProp may be statically overridden. Should only be used/be relevant for custom properties. */
/** This IDProp may be statically overridden.
* Should only be used/be relevant for custom properties. */
IDP_FLAG_OVERRIDABLE_STATIC = 1 << 0,
IDP_FLAG_GHOST = 1 << 7, /* this means the property is set but RNA will return false when checking
* 'RNA_property_is_set', currently this is a runtime flag */
/** This means the property is set but RNA will return false when checking
* 'RNA_property_is_set', currently this is a runtime flag */
IDP_FLAG_GHOST = 1 << 7,
};
/* add any future new id property types here.*/
@@ -186,8 +188,10 @@ enum {
/* IDOverridePropertyOperation->flag. */
enum {
IDOVERRIDESTATIC_FLAG_MANDATORY = 1 << 0, /* User cannot remove that override operation. */
IDOVERRIDESTATIC_FLAG_LOCKED = 1 << 1, /* User cannot change that override operation. */
/** User cannot remove that override operation. */
IDOVERRIDESTATIC_FLAG_MANDATORY = 1 << 0,
/** User cannot change that override operation. */
IDOVERRIDESTATIC_FLAG_LOCKED = 1 << 1,
};
/** A single overridden property, contain all operations on this one. */
@@ -408,13 +412,13 @@ typedef enum ID_Type {
/* NOTE! Fake IDs, needed for g.sipo->blocktype or outliner */
#define ID_SEQ MAKE_ID2('S', 'Q')
/* constraint */
/* constraint */
#define ID_CO MAKE_ID2('C', 'O')
/* pose (action channel, used to be ID_AC in code, so we keep code for backwards compat) */
/* pose (action channel, used to be ID_AC in code, so we keep code for backwards compat) */
#define ID_PO MAKE_ID2('A', 'C')
/* used in outliner... */
/* used in outliner... */
#define ID_NLA MAKE_ID2('N', 'L')
/* fluidsim Ipo */
/* fluidsim Ipo */
#define ID_FLUIDSIM MAKE_ID2('F', 'S')
#define ID_FAKE_USERS(id) ((((ID *)id)->flag & LIB_FAKEUSER) ? 1 : 0)
@@ -464,31 +468,38 @@ enum {
*
* Those flags belong to three different categories, which have different expected handling in code:
*
* - RESET_BEFORE_USE: piece of code that wants to use such flag has to ensure they are properly 'reset' first.
* - RESET_AFTER_USE: piece of code that wants to use such flag has to ensure they are properly 'reset' after usage
* (though 'lifetime' of those flags is a bit fuzzy, e.g. _RECALC ones are reset on depsgraph
* evaluation...).
* - RESET_NEVER: those flags are 'status' one, and never actually need any reset (except on initialization
* during .blend file reading).
* - RESET_BEFORE_USE: piece of code that wants to use such flag
* has to ensure they are properly 'reset' first.
* - RESET_AFTER_USE: piece of code that wants to use such flag has to ensure they are properly
* 'reset' after usage
* (though 'lifetime' of those flags is a bit fuzzy, e.g. _RECALC ones are reset on depsgraph
* evaluation...).
* - RESET_NEVER: those flags are 'status' one, and never actually need any reset
* (except on initialization during .blend file reading).
*/
enum {
/* RESET_NEVER Datablock is from current .blend file. */
LIB_TAG_LOCAL = 0,
/* RESET_NEVER Datablock is from a library, but is used (linked) directly by current .blend file. */
/* RESET_NEVER Datablock is from a library,
* but is used (linked) directly by current .blend file. */
LIB_TAG_EXTERN = 1 << 0,
/* RESET_NEVER Datablock is from a library, and is only used (linked) inderectly through other libraries. */
/* RESET_NEVER Datablock is from a library,
* and is only used (linked) inderectly through other libraries. */
LIB_TAG_INDIRECT = 1 << 1,
/* RESET_AFTER_USE Three flags used internally in readfile.c, to mark IDs needing to be read (only done once). */
/* RESET_AFTER_USE Three flags used internally in readfile.c,
* to mark IDs needing to be read (only done once). */
LIB_TAG_NEED_EXPAND = 1 << 3,
LIB_TAG_TESTEXT = (LIB_TAG_NEED_EXPAND | LIB_TAG_EXTERN),
LIB_TAG_TESTIND = (LIB_TAG_NEED_EXPAND | LIB_TAG_INDIRECT),
/* RESET_AFTER_USE Flag used internally in readfile.c, to mark IDs needing to be linked from a library. */
/* RESET_AFTER_USE Flag used internally in readfile.c,
* to mark IDs needing to be linked from a library. */
LIB_TAG_READ = 1 << 4,
/* RESET_AFTER_USE */
LIB_TAG_NEED_LINK = 1 << 5,
/* RESET_NEVER tag datablock as a place-holder (because the real one could not be linked from its library e.g.). */
/* RESET_NEVER tag datablock as a place-holder
* (because the real one could not be linked from its library e.g.). */
LIB_TAG_MISSING = 1 << 6,
/* RESET_NEVER tag datablock as being up-to-date regarding its reference. */
@@ -515,7 +526,8 @@ enum {
LIB_TAG_COPIED_ON_WRITE_EVAL_RESULT = 1 << 13,
LIB_TAG_LOCALIZED = 1 << 14,
/* RESET_NEVER tag datablock for freeing etc. behavior (usually set when copying real one into temp/runtime one). */
/* RESET_NEVER tag datablock for freeing etc. behavior
* (usually set when copying real one into temp/runtime one). */
LIB_TAG_NO_MAIN = 1 << 15, /* Datablock is not listed in Main database. */
LIB_TAG_NO_USER_REFCOUNT = 1 << 16, /* Datablock does not refcount usages of other IDs. */
/* Datablock was not allocated by standard system (BKE_libblock_alloc), do not free its memory

View File

@@ -200,11 +200,12 @@ typedef enum eMotionPaths_ViewFlag {
/* bAnimVizSettings->path_bakeflag */
typedef enum eMotionPaths_BakeFlag {
/* motion paths directly associated with this block of settings needs updating */
/** motion paths directly associated with this block of settings needs updating */
MOTIONPATH_BAKE_NEEDS_RECALC = (1 << 0),
/* for bones - calculate head-points for curves instead of tips */
/** for bones - calculate head-points for curves instead of tips */
MOTIONPATH_BAKE_HEADS = (1 << 1),
/* motion paths exist for AnimVizSettings instance - set when calc for first time, and unset when clearing */
/** motion paths exist for AnimVizSettings instance - set when calc for first time,
* and unset when clearing */
MOTIONPATH_BAKE_HAS_PATHS = (1 << 2)
} eMotionPath_BakeFlag;
@@ -746,20 +747,26 @@ typedef struct bDopeSheet {
/* DopeSheet filter-flag */
typedef enum eDopeSheet_FilterFlag {
/* general filtering */
ADS_FILTER_ONLYSEL = (1 << 0), /* only include channels relating to selected data */
/** only include channels relating to selected data */
ADS_FILTER_ONLYSEL = (1 << 0),
/* temporary filters */
ADS_FILTER_ONLYDRIVERS = (1 << 1), /* for 'Drivers' editor - only include Driver data from AnimData */
ADS_FILTER_ONLYNLA = (1 << 2), /* for 'NLA' editor - only include NLA data from AnimData */
ADS_FILTER_SELEDIT = (1 << 3), /* for Graph Editor - used to indicate whether to include a filtering flag or not */
/** for 'Drivers' editor - only include Driver data from AnimData */
ADS_FILTER_ONLYDRIVERS = (1 << 1),
/** for 'NLA' editor - only include NLA data from AnimData */
ADS_FILTER_ONLYNLA = (1 << 2),
/** for Graph Editor - used to indicate whether to include a filtering flag or not */
ADS_FILTER_SELEDIT = (1 << 3),
/* general filtering */
ADS_FILTER_SUMMARY = (1 << 4), /* for 'DopeSheet' Editors - include 'summary' line */
/** for 'DopeSheet' Editors - include 'summary' line */
ADS_FILTER_SUMMARY = (1 << 4),
/* datatype-based filtering */
ADS_FILTER_NOSHAPEKEYS = (1 << 6),
ADS_FILTER_NOMESH = (1 << 7),
ADS_FILTER_NOOBJ = (1 << 8), /* for animdata on object level, if we only want to concentrate on materials/etc. */
/** for animdata on object level, if we only want to concentrate on materials/etc. */
ADS_FILTER_NOOBJ = (1 << 8),
ADS_FILTER_NOLAT = (1 << 9),
ADS_FILTER_NOCAM = (1 << 10),
ADS_FILTER_NOMAT = (1 << 11),
@@ -779,26 +786,35 @@ typedef enum eDopeSheet_FilterFlag {
/* NOTE: all new datablock filters will have to go in filterflag2 (see below) */
/* NLA-specific filters */
ADS_FILTER_NLA_NOACT = (1 << 25), /* if the AnimData block has no NLA data, don't include to just show Action-line */
/** if the AnimData block has no NLA data, don't include to just show Action-line */
ADS_FILTER_NLA_NOACT = (1 << 25),
/* general filtering 3 */
ADS_FILTER_INCL_HIDDEN = (1 << 26), /* include 'hidden' channels too (i.e. those from hidden Objects/Bones) */
ADS_FILTER_ONLY_ERRORS = (1 << 28), /* show only F-Curves which are disabled/have errors - for debugging drivers */
/** include 'hidden' channels too (i.e. those from hidden Objects/Bones) */
ADS_FILTER_INCL_HIDDEN = (1 << 26),
/** show only F-Curves which are disabled/have errors - for debugging drivers */
ADS_FILTER_ONLY_ERRORS = (1 << 28),
/* GPencil Mode */
ADS_FILTER_GP_3DONLY = (1 << 29), /* GP Mode - Only show datablocks used in the scene */
/** GP Mode - Only show datablocks used in the scene */
ADS_FILTER_GP_3DONLY = (1 << 29),
/* combination filters (some only used at runtime) */
/** combination filters (some only used at runtime) */
ADS_FILTER_NOOBDATA = (ADS_FILTER_NOCAM | ADS_FILTER_NOMAT | ADS_FILTER_NOLAM | ADS_FILTER_NOCUR | ADS_FILTER_NOPART | ADS_FILTER_NOARM | ADS_FILTER_NOSPK | ADS_FILTER_NOMODIFIERS)
} eDopeSheet_FilterFlag;
/* DopeSheet general flags */
typedef enum eDopeSheet_Flag {
ADS_FLAG_SUMMARY_COLLAPSED = (1 << 0), /* when summary is shown, it is collapsed, so all other channels get hidden */
ADS_FLAG_SHOW_DBFILTERS = (1 << 1), /* show filters for datablocks */
/** when summary is shown, it is collapsed, so all other channels get hidden */
ADS_FLAG_SUMMARY_COLLAPSED = (1 << 0),
/** show filters for datablocks */
ADS_FLAG_SHOW_DBFILTERS = (1 << 1),
ADS_FLAG_FUZZY_NAMES = (1 << 2), /* use fuzzy/partial string matches when ADS_FILTER_BY_FCU_NAME is enabled (WARNING: expensive operation) */
ADS_FLAG_NO_DB_SORT = (1 << 3), /* do not sort datablocks (mostly objects) by name (NOTE: potentially expensive operation) */
/** use fuzzy/partial string matches when ADS_FILTER_BY_FCU_NAME is enabled
* (WARNING: expensive operation) */
ADS_FLAG_FUZZY_NAMES = (1 << 2),
/** do not sort datablocks (mostly objects) by name (NOTE: potentially expensive operation) */
ADS_FLAG_NO_DB_SORT = (1 << 3),
/* NOTE: datablock filter flags continued (1 << 10) onwards... */
} eDopeSheet_Flag;

View File

@@ -89,7 +89,8 @@ typedef enum eFModifier_Types {
FMODIFIER_TYPE_ENVELOPE = 3,
FMODIFIER_TYPE_CYCLES = 4,
FMODIFIER_TYPE_NOISE = 5,
FMODIFIER_TYPE_FILTER = 6, /* unimplemented - for applying: fft, high/low pass filters, etc. */
/** unimplemented - for applying: fft, high/low pass filters, etc. */
FMODIFIER_TYPE_FILTER = 6,
FMODIFIER_TYPE_PYTHON = 7,
FMODIFIER_TYPE_LIMITS = 8,
FMODIFIER_TYPE_STEPPED = 9,
@@ -226,10 +227,14 @@ typedef struct FMod_Cycles {
/* cycling modes */
typedef enum eFMod_Cycling_Modes {
FCM_EXTRAPOLATE_NONE = 0, /* don't do anything */
FCM_EXTRAPOLATE_CYCLIC, /* repeat keyframe range as-is */
FCM_EXTRAPOLATE_CYCLIC_OFFSET, /* repeat keyframe range, but with offset based on gradient between values */
FCM_EXTRAPOLATE_MIRROR /* alternate between forward and reverse playback of keyframe range */
/** don't do anything */
FCM_EXTRAPOLATE_NONE = 0,
/** repeat keyframe range as-is */
FCM_EXTRAPOLATE_CYCLIC,
/** repeat keyframe range, but with offset based on gradient between values */
FCM_EXTRAPOLATE_CYCLIC_OFFSET,
/** alternate between forward and reverse playback of keyframe range */
FCM_EXTRAPOLATE_MIRROR
} eFMod_Cycling_Modes;
@@ -598,50 +603,60 @@ typedef struct FCurve {
/* user-editable flags/settings */
typedef enum eFCurve_Flags {
/* curve/keyframes are visible in editor */
/** curve/keyframes are visible in editor */
FCURVE_VISIBLE = (1<<0),
/* curve is selected for editing */
/** curve is selected for editing */
FCURVE_SELECTED = (1<<1),
/* curve is active one */
/** curve is active one */
FCURVE_ACTIVE = (1<<2),
/* keyframes (beztriples) cannot be edited */
/** keyframes (beztriples) cannot be edited */
FCURVE_PROTECTED = (1<<3),
/* fcurve will not be evaluated for the next round */
/** fcurve will not be evaluated for the next round */
FCURVE_MUTED = (1<<4),
/* fcurve uses 'auto-handles', which stay horizontal... */
// DEPRECATED
/** fcurve uses 'auto-handles', which stay horizontal... */
// DEPRECATED
FCURVE_AUTO_HANDLES = (1<<5),
FCURVE_MOD_OFF = (1<<6),
/* skip evaluation, as RNA-path cannot be resolved (similar to muting, but cannot be set by user) */
/** skip evaluation, as RNA-path cannot be resolved
* (similar to muting, but cannot be set by user) */
FCURVE_DISABLED = (1<<10),
/* curve can only have whole-number values (integer types) */
/** curve can only have whole-number values (integer types) */
FCURVE_INT_VALUES = (1<<11),
/* curve can only have certain discrete-number values (no interpolation at all, for enums/booleans) */
/** curve can only have certain discrete-number values
* (no interpolation at all, for enums/booleans) */
FCURVE_DISCRETE_VALUES = (1<<12),
/* temporary tag for editing */
/** temporary tag for editing */
FCURVE_TAGGED = (1<<15)
} eFCurve_Flags;
/* extrapolation modes (only simple value 'extending') */
typedef enum eFCurve_Extend {
FCURVE_EXTRAPOLATE_CONSTANT = 0, /* just extend min/max keyframe value */
FCURVE_EXTRAPOLATE_LINEAR /* just extend gradient of segment between first segment keyframes */
/** just extend min/max keyframe value */
FCURVE_EXTRAPOLATE_CONSTANT = 0,
/** just extend gradient of segment between first segment keyframes */
FCURVE_EXTRAPOLATE_LINEAR
} eFCurve_Extend;
/* curve coloring modes */
typedef enum eFCurve_Coloring {
FCURVE_COLOR_AUTO_RAINBOW = 0, /* automatically determine color using rainbow (calculated at drawtime) */
FCURVE_COLOR_AUTO_RGB = 1, /* automatically determine color using XYZ (array index) <-> RGB */
FCURVE_COLOR_AUTO_YRGB = 3, /* automatically determine color where XYZ <-> RGB, but index(X) != 0 */
FCURVE_COLOR_CUSTOM = 2, /* custom color */
/** automatically determine color using rainbow (calculated at drawtime) */
FCURVE_COLOR_AUTO_RAINBOW = 0,
/** automatically determine color using XYZ (array index) <-> RGB */
FCURVE_COLOR_AUTO_RGB = 1,
/** automatically determine color where XYZ <-> RGB, but index(X) != 0 */
FCURVE_COLOR_AUTO_YRGB = 3,
/** custom color */
FCURVE_COLOR_CUSTOM = 2,
} eFCurve_Coloring;
/* curve smoothing modes */
typedef enum eFCurve_Smoothing {
FCURVE_SMOOTH_NONE = 0, /* legacy mode: auto handles only consider adjacent points */
FCURVE_SMOOTH_CONT_ACCEL = 1, /* maintain continuity of the acceleration */
/** legacy mode: auto handles only consider adjacent points */
FCURVE_SMOOTH_NONE = 0,
/** maintain continuity of the acceleration */
FCURVE_SMOOTH_CONT_ACCEL = 1,
} eFCurve_Smoothing;
/* ************************************************ */
@@ -724,11 +739,12 @@ typedef enum eNlaStrip_Blend_Mode {
/* NLA Strip Extrpolation Mode */
typedef enum eNlaStrip_Extrapolate_Mode {
/* extend before first frame if no previous strips in track, and always hold+extend last frame */
/* extend before first frame if no previous strips in track,
* and always hold+extend last frame */
NLASTRIP_EXTEND_HOLD = 0,
/* only hold+extend last frame */
/* only hold+extend last frame */
NLASTRIP_EXTEND_HOLD_FORWARD = 1,
/* don't contribute at all */
/* don't contribute at all */
NLASTRIP_EXTEND_NOTHING = 2
} eNlaStrip_Extrapolate_Mode;
@@ -741,7 +757,9 @@ typedef enum eNlaStrip_Flag {
NLASTRIP_FLAG_SELECT = (1<<1),
// NLASTRIP_FLAG_SELECT_L = (1<<2), // left handle selected
// NLASTRIP_FLAG_SELECT_R = (1<<3), // right handle selected
/* NLA strip uses the same action that the action being tweaked uses (not set for the twaking one though) */
/* NLA strip uses the same action that the action being tweaked uses
* (not set for the twaking one though) */
NLASTRIP_FLAG_TWEAKUSER = (1<<4),
/* controls driven by local F-Curves */
@@ -801,7 +819,8 @@ typedef struct NlaTrack {
/** Settings for this track. */
int flag;
/** Index of the track in the stack (NOTE: not really useful, but we need a pad var anyways!). */
/** Index of the track in the stack
* \note not really useful, but we need a pad var anyways! */
int index;
/** Short user-description of this track - MAX_ID_NAME-2. */
@@ -810,18 +829,20 @@ typedef struct NlaTrack {
/* settings for track */
typedef enum eNlaTrack_Flag {
/* track is the one that settings can be modified on, also indicates if track is being 'tweaked' */
/** track is the one that settings can be modified on,
* also indicates if track is being 'tweaked' */
NLATRACK_ACTIVE = (1<<0),
/* track is selected in UI for relevant editing operations */
/** track is selected in UI for relevant editing operations */
NLATRACK_SELECTED = (1<<1),
/* track is not evaluated */
/** track is not evaluated */
NLATRACK_MUTED = (1<<2),
/* track is the only one evaluated (must be used in conjunction with adt->flag) */
/** track is the only one evaluated (must be used in conjunction with adt->flag) */
NLATRACK_SOLO = (1<<3),
/* track's settings (and strips) cannot be edited (to guard against unwanted changes) */
/** track's settings (and strips) cannot be edited (to guard against unwanted changes) */
NLATRACK_PROTECTED = (1<<4),
/* track is not allowed to execute, usually as result of tweaking being enabled (internal flag) */
/** track is not allowed to execute,
* usually as result of tweaking being enabled (internal flag) */
NLATRACK_DISABLED = (1<<10)
} eNlaTrack_Flag;
@@ -936,18 +957,28 @@ typedef enum eKS_Settings {
/* Flags for use by keyframe creation/deletion calls */
typedef enum eInsertKeyFlags {
INSERTKEY_NOFLAGS = 0,
INSERTKEY_NEEDED = (1<<0), /* only insert keyframes where they're needed */
INSERTKEY_MATRIX = (1<<1), /* insert 'visual' keyframes where possible/needed */
INSERTKEY_FAST = (1<<2), /* don't recalculate handles,etc. after adding key */
INSERTKEY_FASTR = (1<<3), /* don't realloc mem (or increase count, as array has already been set out) */
INSERTKEY_REPLACE = (1<<4), /* only replace an existing keyframe (this overrides INSERTKEY_NEEDED) */
INSERTKEY_XYZ2RGB = (1<<5), /* transform F-Curves should have XYZ->RGB color mode */
INSERTKEY_NO_USERPREF = (1<<6), /* ignore user-prefs (needed for predictable API use) */
/* Allow to make a full copy of new key into existing one, if any, instead of 'reusing' existing handles.
/** only insert keyframes where they're needed */
INSERTKEY_NEEDED = (1<<0),
/** insert 'visual' keyframes where possible/needed */
INSERTKEY_MATRIX = (1<<1),
/** don't recalculate handles,etc. after adding key */
INSERTKEY_FAST = (1<<2),
/** don't realloc mem (or increase count, as array has already been set out) */
INSERTKEY_FASTR = (1<<3),
/** only replace an existing keyframe (this overrides INSERTKEY_NEEDED) */
INSERTKEY_REPLACE = (1<<4),
/** transform F-Curves should have XYZ->RGB color mode */
INSERTKEY_XYZ2RGB = (1<<5),
/** ignore user-prefs (needed for predictable API use) */
INSERTKEY_NO_USERPREF = (1<<6),
/** Allow to make a full copy of new key into existing one, if any,
* instead of 'reusing' existing handles.
* Used by copy/paste code. */
INSERTKEY_OVERWRITE_FULL = (1<<7),
INSERTKEY_DRIVER = (1<<8), /* for driver FCurves, use driver's "input" value - for easier corrective driver setup */
INSERTKEY_CYCLE_AWARE = (1<<9), /* for cyclic FCurves, adjust key timing to preserve the cycle period and flow */
/** for driver FCurves, use driver's "input" value - for easier corrective driver setup */
INSERTKEY_DRIVER = (1<<8),
/** for cyclic FCurves, adjust key timing to preserve the cycle period and flow */
INSERTKEY_CYCLE_AWARE = (1<<9),
} eInsertKeyFlags;
/* ************************************************ */
@@ -961,8 +992,8 @@ typedef enum eInsertKeyFlags {
* yet keyframed (thus, would get overwritten by the animation system before the user had a chance
* to see the changes that were made).
*
* It is probably not needed for overriding keyframed values in most cases, as those will only get evaluated
* on frame-change now. That situation may change in future.
* It is probably not needed for overriding keyframed values in most cases, as those will only get
* evaluated on frame-change now. That situation may change in future.
*/
typedef struct AnimOverride {
struct AnimOverride *next, *prev;
@@ -988,14 +1019,15 @@ typedef struct AnimOverride {
* blocks may override local settings.
*
* This datablock should be placed immediately after the ID block where it is used, so that
* the code which retrieves this data can do so in an easier manner. See blenkernel/intern/anim_sys.c for details.
* the code which retrieves this data can do so in an easier manner.
* See blenkernel/intern/anim_sys.c for details.
*/
typedef struct AnimData {
/* active action - acts as the 'tweaking track' for the NLA */
/** active action - acts as the 'tweaking track' for the NLA */
bAction *action;
/* temp-storage for the 'real' active action (i.e. the one used before the tweaking-action
* took over to be edited in the Animation Editors)
*/
/** temp-storage for the 'real' active action (i.e. the one used before the tweaking-action
* took over to be edited in the Animation Editors)
*/
bAction *tmpact;
/* nla-tracks */
@@ -1016,7 +1048,8 @@ typedef struct AnimData {
*/
/** Standard user-created Drivers/Expressions (used as part of a rig). */
ListBase drivers;
/** Temp storage (AnimOverride) of values for settings that are animated (but the value hasn't been keyframed). */
/** Temp storage (AnimOverride) of values for settings that are animated
* (but the value hasn't been keyframed). */
ListBase overrides;
/** Runtime data, for depsgraph evaluation. */

View File

@@ -156,7 +156,8 @@ typedef struct bArmature {
/* don't use bit 7, was saved in files to disable stuff */
typedef enum eArmature_Flag {
ARM_RESTPOS = (1<<0),
ARM_DRAWXRAY = (1<<1), /* XRAY is here only for backwards converting */
/** XRAY is here only for backwards converting */
ARM_DRAWXRAY = (1<<1),
ARM_DRAWAXES = (1<<2),
ARM_DRAWNAMES = (1<<3),
ARM_POSEMODE = (1<<4),
@@ -165,11 +166,16 @@ typedef enum eArmature_Flag {
ARM_DONT_USE = (1<<7),
ARM_MIRROR_EDIT = (1<<8),
ARM_AUTO_IK = (1<<9),
ARM_NO_CUSTOM = (1<<10), /* made option negative, for backwards compat */
ARM_COL_CUSTOM = (1<<11), /* draw custom colors */
ARM_GHOST_ONLYSEL = (1<<12), /* when ghosting, only show selected bones (this should belong to ghostflag instead) */ /* XXX deprecated */
ARM_DS_EXPAND = (1<<13), /* dopesheet channel is expanded */
ARM_HAS_VIZ_DEPS = (1<<14), /* other objects are used for visualizing various states (hack for efficient updates) */
/** made option negative, for backwards compat */
ARM_NO_CUSTOM = (1<<10),
/** draw custom colors */
ARM_COL_CUSTOM = (1<<11),
/** when ghosting, only show selected bones (this should belong to ghostflag instead) */
ARM_GHOST_ONLYSEL = (1<<12), /* XXX deprecated */
/** dopesheet channel is expanded */
ARM_DS_EXPAND = (1<<13),
/** other objects are used for visualizing various states (hack for efficient updates) */
ARM_HAS_VIZ_DEPS = (1<<14),
} eArmature_Flag;
/* armature->drawtype */
@@ -223,28 +229,49 @@ typedef enum eBone_Flag {
BONE_SELECTED = (1 << 0),
BONE_ROOTSEL = (1 << 1),
BONE_TIPSEL = (1 << 2),
BONE_TRANSFORM = (1 << 3), /* Used instead of BONE_SELECTED during transform (clear before use) */
BONE_CONNECTED = (1 << 4), /* when bone has a parent, connect head of bone to parent's tail*/
/** Used instead of BONE_SELECTED during transform (clear before use) */
BONE_TRANSFORM = (1 << 3),
/** when bone has a parent, connect head of bone to parent's tail*/
BONE_CONNECTED = (1 << 4),
/* 32 used to be quatrot, was always set in files, do not reuse unless you clear it always */
BONE_HIDDEN_P = (1 << 6), /* hidden Bones when drawing PoseChannels */
BONE_DONE = (1 << 7), /* For detecting cyclic dependencies */
BONE_DRAW_ACTIVE = (1 << 8), /* active is on mouse clicks only - deprecated, ONLY USE FOR DRAWING */
BONE_HINGE = (1 << 9), /* No parent rotation or scale */
BONE_HIDDEN_A = (1 << 10), /* hidden Bones when drawing Armature Editmode */
BONE_MULT_VG_ENV = (1 << 11), /* multiplies vgroup with envelope */
BONE_NO_DEFORM = (1 << 12), /* bone doesn't deform geometry */
BONE_UNKEYED = (1 << 13), /* set to prevent destruction of its unkeyframed pose (after transform) */
BONE_HINGE_CHILD_TRANSFORM = (1 << 14), /* set to prevent hinge child bones from influencing the transform center */
BONE_NO_SCALE = (1 << 15), /* No parent scale */
BONE_HIDDEN_PG = (1 << 16), /* hidden bone when drawing PoseChannels (for ghost drawing) */
BONE_DRAWWIRE = (1 << 17), /* bone should be drawn as OB_WIRE, regardless of draw-types of view+armature */
BONE_NO_CYCLICOFFSET = (1 << 18), /* when no parent, bone will not get cyclic offset */
BONE_EDITMODE_LOCKED = (1 << 19), /* bone transforms are locked in EditMode */
BONE_TRANSFORM_CHILD = (1 << 20), /* Indicates that a parent is also being transformed */
BONE_UNSELECTABLE = (1 << 21), /* bone cannot be selected */
BONE_NO_LOCAL_LOCATION = (1 << 22), /* bone location is in armature space */
BONE_RELATIVE_PARENTING = (1 << 23), /* object child will use relative transform (like deform) */
BONE_ADD_PARENT_END_ROLL = (1 << 24) /* it will add the parent end roll to the inroll */
/** hidden Bones when drawing PoseChannels */
BONE_HIDDEN_P = (1 << 6),
/** For detecting cyclic dependencies */
BONE_DONE = (1 << 7),
/** active is on mouse clicks only - deprecated, ONLY USE FOR DRAWING */
BONE_DRAW_ACTIVE = (1 << 8),
/** No parent rotation or scale */
BONE_HINGE = (1 << 9),
/** hidden Bones when drawing Armature Editmode */
BONE_HIDDEN_A = (1 << 10),
/** multiplies vgroup with envelope */
BONE_MULT_VG_ENV = (1 << 11),
/** bone doesn't deform geometry */
BONE_NO_DEFORM = (1 << 12),
/** set to prevent destruction of its unkeyframed pose (after transform) */
BONE_UNKEYED = (1 << 13),
/** set to prevent hinge child bones from influencing the transform center */
BONE_HINGE_CHILD_TRANSFORM = (1 << 14),
/** No parent scale */
BONE_NO_SCALE = (1 << 15),
/** hidden bone when drawing PoseChannels (for ghost drawing) */
BONE_HIDDEN_PG = (1 << 16),
/** bone should be drawn as OB_WIRE, regardless of draw-types of view+armature */
BONE_DRAWWIRE = (1 << 17),
/** when no parent, bone will not get cyclic offset */
BONE_NO_CYCLICOFFSET = (1 << 18),
/** bone transforms are locked in EditMode */
BONE_EDITMODE_LOCKED = (1 << 19),
/** Indicates that a parent is also being transformed */
BONE_TRANSFORM_CHILD = (1 << 20),
/** bone cannot be selected */
BONE_UNSELECTABLE = (1 << 21),
/** bone location is in armature space */
BONE_NO_LOCAL_LOCATION = (1 << 22),
/** object child will use relative transform (like deform) */
BONE_RELATIVE_PARENTING = (1 << 23),
/** it will add the parent end roll to the inroll */
BONE_ADD_PARENT_END_ROLL = (1 << 24)
} eBone_Flag;

View File

@@ -36,18 +36,32 @@
typedef enum eBoidRuleType {
eBoidRuleType_None = 0,
eBoidRuleType_Goal = 1, /* go to goal assigned object or loudest assigned signal source */
eBoidRuleType_Avoid = 2, /* get away from assigned object or loudest assigned signal source */
eBoidRuleType_AvoidCollision = 3, /* manoeuver to avoid collisions with other boids and deflector object in near future */
eBoidRuleType_Separate = 4, /* keep from going through other boids */
eBoidRuleType_Flock = 5, /* move to center of neighbors and match their velocity */
eBoidRuleType_FollowLeader = 6, /* follow a boid or assigned object */
eBoidRuleType_AverageSpeed = 7, /* maintain speed, flight level or wander*/
eBoidRuleType_Fight = 8, /* go to closest enemy and attack when in range */
//eBoidRuleType_Protect = 9, /* go to enemy closest to target and attack when in range */
//eBoidRuleType_Hide = 10, /* find a deflector move to it's other side from closest enemy */
//eBoidRuleType_FollowPath = 11, /* move along a assigned curve or closest curve in a group */
//eBoidRuleType_FollowWall = 12, /* move next to a deflector object's in direction of it's tangent */
/** go to goal assigned object or loudest assigned signal source */
eBoidRuleType_Goal = 1,
/** get away from assigned object or loudest assigned signal source */
eBoidRuleType_Avoid = 2,
/** manoeuver to avoid collisions with other boids and deflector object in near future */
eBoidRuleType_AvoidCollision = 3,
/** keep from going through other boids */
eBoidRuleType_Separate = 4,
/** move to center of neighbors and match their velocity */
eBoidRuleType_Flock = 5,
/** follow a boid or assigned object */
eBoidRuleType_FollowLeader = 6,
/** maintain speed, flight level or wander*/
eBoidRuleType_AverageSpeed = 7,
/** go to closest enemy and attack when in range */
eBoidRuleType_Fight = 8,
#if 0
/** go to enemy closest to target and attack when in range */
eBoidRuleType_Protect = 9,
/** find a deflector move to it's other side from closest enemy */
eBoidRuleType_Hide = 10,
/** move along a assigned curve or closest curve in a group */
eBoidRuleType_FollowPath = 11,
/** move next to a deflector object's in direction of it's tangent */
eBoidRuleType_FollowWall = 12,
#endif
NUM_BOID_RULE_TYPES
} eBoidRuleType;

View File

@@ -463,7 +463,8 @@ typedef enum eBrushSculptTool {
SCULPT_TOOL_THUMB, \
SCULPT_TOOL_LAYER, \
\
/* These brushes could handle dynamic topology, but user feedback indicates it's better not to */ \
/* These brushes could handle dynamic topology, \
* but user feedback indicates it's better not to */ \
SCULPT_TOOL_SMOOTH, \
SCULPT_TOOL_MASK \
) == 0)

View File

@@ -191,7 +191,8 @@ typedef struct Scopes {
typedef struct ColorManagedViewSettings {
int flag, pad;
/** Look which is being applied when displaying buffer on the screen (prior to view transform). */
/** Look which is being applied when displaying buffer on the screen
* (prior to view transform). */
char look[64];
/** View transform which is being applied when displaying buffer on the screen. */
char view_transform[64];

View File

@@ -121,15 +121,20 @@ typedef struct bConstraintTarget {
/* bConstraintTarget -> flag */
typedef enum eConstraintTargetFlag {
CONSTRAINT_TAR_TEMP = (1<<0) /* temporary target-struct that needs to be freed after use */
/** temporary target-struct that needs to be freed after use */
CONSTRAINT_TAR_TEMP = (1<<0)
} eConstraintTargetFlag;
/* bConstraintTarget/bConstraintOb -> type */
typedef enum eConstraintObType {
CONSTRAINT_OBTYPE_OBJECT = 1, /* string is "" */
CONSTRAINT_OBTYPE_BONE = 2, /* string is bone-name */
CONSTRAINT_OBTYPE_VERT = 3, /* string is vertex-group name */
CONSTRAINT_OBTYPE_CV = 4 /* string is vertex-group name - is not available until curves get vgroups */
/** string is "" */
CONSTRAINT_OBTYPE_OBJECT = 1,
/** string is bone-name */
CONSTRAINT_OBTYPE_BONE = 2,
/** string is vertex-group name */
CONSTRAINT_OBTYPE_VERT = 3,
/** string is vertex-group name - is not available until curves get vgroups */
CONSTRAINT_OBTYPE_CV = 4
} eConstraintObType;
@@ -201,8 +206,10 @@ typedef struct bKinematicConstraint {
} bKinematicConstraint;
typedef enum eConstraint_IK_Type {
CONSTRAINT_IK_COPYPOSE = 0, /* 'standard' IK constraint: match position and/or orientation of target */
CONSTRAINT_IK_DISTANCE = 1 /* maintain distance with target */
/** 'standard' IK constraint: match position and/or orientation of target */
CONSTRAINT_IK_COPYPOSE = 0,
/** maintain distance with target */
CONSTRAINT_IK_DISTANCE = 1
} eConstraint_IK_Type;
@@ -606,37 +613,60 @@ typedef struct bTransformCacheConstraint {
* broken as their correct value cannot be resolved
*/
typedef enum eBConstraint_Types {
CONSTRAINT_TYPE_NULL = 0, /* Invalid/legacy constraint */
CONSTRAINT_TYPE_CHILDOF = 1, /* Unimplemented non longer :) - during constraints recode, Aligorith */
/** Invalid/legacy constraint */
CONSTRAINT_TYPE_NULL = 0,
/** Unimplemented non longer :) - during constraints recode, Aligorith */
CONSTRAINT_TYPE_CHILDOF = 1,
CONSTRAINT_TYPE_TRACKTO = 2,
CONSTRAINT_TYPE_KINEMATIC = 3,
CONSTRAINT_TYPE_FOLLOWPATH = 4,
CONSTRAINT_TYPE_ROTLIMIT = 5, /* Unimplemented no longer :) - Aligorith */
CONSTRAINT_TYPE_LOCLIMIT = 6, /* Unimplemented no longer :) - Aligorith */
CONSTRAINT_TYPE_SIZELIMIT = 7, /* Unimplemented no longer :) - Aligorith */
/** Unimplemented no longer :) - Aligorith */
CONSTRAINT_TYPE_ROTLIMIT = 5,
/** Unimplemented no longer :) - Aligorith */
CONSTRAINT_TYPE_LOCLIMIT = 6,
/** Unimplemented no longer :) - Aligorith */
CONSTRAINT_TYPE_SIZELIMIT = 7,
CONSTRAINT_TYPE_ROTLIKE = 8,
CONSTRAINT_TYPE_LOCLIKE = 9,
CONSTRAINT_TYPE_SIZELIKE = 10,
CONSTRAINT_TYPE_PYTHON = 11, /* Unimplemented no longer :) - Aligorith. Scripts */
/** Unimplemented no longer :) - Aligorith. Scripts */
CONSTRAINT_TYPE_PYTHON = 11,
CONSTRAINT_TYPE_ACTION = 12,
CONSTRAINT_TYPE_LOCKTRACK = 13, /* New Tracking constraint that locks an axis in place - theeth */
CONSTRAINT_TYPE_DISTLIMIT = 14, /* limit distance */
CONSTRAINT_TYPE_STRETCHTO = 15, /* claiming this to be mine :) is in tuhopuu bjornmose */
CONSTRAINT_TYPE_MINMAX = 16, /* floor constraint */
/** New Tracking constraint that locks an axis in place - theeth */
CONSTRAINT_TYPE_LOCKTRACK = 13,
/** limit distance */
CONSTRAINT_TYPE_DISTLIMIT = 14,
/** claiming this to be mine :) is in tuhopuu bjornmose */
CONSTRAINT_TYPE_STRETCHTO = 15,
/** floor constraint */
CONSTRAINT_TYPE_MINMAX = 16,
/* CONSTRAINT_TYPE_DEPRECATED = 17 */
CONSTRAINT_TYPE_CLAMPTO = 18, /* clampto constraint */
CONSTRAINT_TYPE_TRANSFORM = 19, /* transformation (loc/rot/size -> loc/rot/size) constraint */
CONSTRAINT_TYPE_SHRINKWRAP = 20, /* shrinkwrap (loc/rot) constraint */
CONSTRAINT_TYPE_DAMPTRACK = 21, /* New Tracking constraint that minimizes twisting */
CONSTRAINT_TYPE_SPLINEIK = 22, /* Spline-IK - Align 'n' bones to a curve */
CONSTRAINT_TYPE_TRANSLIKE = 23, /* Copy transform matrix */
CONSTRAINT_TYPE_SAMEVOL = 24, /* Maintain volume during scaling */
CONSTRAINT_TYPE_PIVOT = 25, /* Pivot Constraint */
CONSTRAINT_TYPE_FOLLOWTRACK = 26, /* Follow Track Constraint */
CONSTRAINT_TYPE_CAMERASOLVER = 27, /* Camera Solver Constraint */
CONSTRAINT_TYPE_OBJECTSOLVER = 28, /* Object Solver Constraint */
CONSTRAINT_TYPE_TRANSFORM_CACHE = 29, /* Transform Cache Constraint */
CONSTRAINT_TYPE_ARMATURE = 30, /* Armature Deform Constraint */
/** clampto constraint */
CONSTRAINT_TYPE_CLAMPTO = 18,
/** transformation (loc/rot/size -> loc/rot/size) constraint */
CONSTRAINT_TYPE_TRANSFORM = 19,
/** shrinkwrap (loc/rot) constraint */
CONSTRAINT_TYPE_SHRINKWRAP = 20,
/** New Tracking constraint that minimizes twisting */
CONSTRAINT_TYPE_DAMPTRACK = 21,
/** Spline-IK - Align 'n' bones to a curve */
CONSTRAINT_TYPE_SPLINEIK = 22,
/** Copy transform matrix */
CONSTRAINT_TYPE_TRANSLIKE = 23,
/** Maintain volume during scaling */
CONSTRAINT_TYPE_SAMEVOL = 24,
/** Pivot Constraint */
CONSTRAINT_TYPE_PIVOT = 25,
/** Follow Track Constraint */
CONSTRAINT_TYPE_FOLLOWTRACK = 26,
/** Camera Solver Constraint */
CONSTRAINT_TYPE_CAMERASOLVER = 27,
/** Object Solver Constraint */
CONSTRAINT_TYPE_OBJECTSOLVER = 28,
/** Transform Cache Constraint */
CONSTRAINT_TYPE_TRANSFORM_CACHE = 29,
/** Armature Deform Constraint */
CONSTRAINT_TYPE_ARMATURE = 30,
/* NOTE: no constraints are allowed to be added after this */
NUM_CONSTRAINT_TYPES
@@ -644,27 +674,28 @@ typedef enum eBConstraint_Types {
/* bConstraint->flag */
/* flags 0x2 (1<<1) and 0x8 (1<<3) were used in past */
/* flag 0x20 (1<<5) was used to indicate that a constraint was evaluated using a 'local' hack for posebones only */
/* flag 0x20 (1<<5) was used to indicate that a constraint was evaluated
* using a 'local' hack for posebones only. */
typedef enum eBConstraint_Flags {
/* expand for UI */
/* expand for UI */
CONSTRAINT_EXPAND = (1<<0),
/* pre-check for illegal object name or bone name */
/* pre-check for illegal object name or bone name */
CONSTRAINT_DISABLE = (1<<2),
/* to indicate which Ipo should be shown, maybe for 3d access later too */
/* to indicate which Ipo should be shown, maybe for 3d access later too */
CONSTRAINT_ACTIVE = (1<<4),
/* to indicate that the owner's space should only be changed into ownspace, but not out of it */
/* to indicate that the owner's space should only be changed into ownspace, but not out of it */
CONSTRAINT_SPACEONCE = (1<<6),
/* influence ipo is on constraint itself, not in action channel */
/* influence ipo is on constraint itself, not in action channel */
CONSTRAINT_OWN_IPO = (1<<7),
/* indicates that constraint was added locally (i.e. didn't come from the proxy-lib) */
/* indicates that constraint was added locally (i.e. didn't come from the proxy-lib) */
CONSTRAINT_PROXY_LOCAL = (1<<8),
/* indicates that constraint is temporarily disabled (only used in GE) */
/* indicates that constraint is temporarily disabled (only used in GE) */
CONSTRAINT_OFF = (1<<9),
/* use bbone curve shape when calculating headtail values (also used by dependency graph!) */
/* use bbone curve shape when calculating headtail values (also used by dependency graph!) */
CONSTRAINT_BBONE_SHAPE = (1<<10),
/* That constraint has been inserted in local override (i.e. it can be fully edited!). */
/* That constraint has been inserted in local override (i.e. it can be fully edited!). */
CONSTRAINT_STATICOVERRIDE_LOCAL = (1 << 11),
/* use full transformation (not just segment locations) - only set at runtime */
/* use full transformation (not just segment locations) - only set at runtime */
CONSTRAINT_BBONE_SHAPE_FULL = (1 << 12),
} eBConstraint_Flags;
@@ -882,9 +913,12 @@ typedef enum eSplineIK_XZScaleModes {
/* bArmatureConstraint -> flag */
typedef enum eArmature_Flags {
CONSTRAINT_ARMATURE_QUATERNION = (1<<0), /* use dual quaternion blending */
CONSTRAINT_ARMATURE_ENVELOPE = (1<<1), /* use envelopes */
CONSTRAINT_ARMATURE_CUR_LOCATION = (1<<2), /* use current bone location */
/** use dual quaternion blending */
CONSTRAINT_ARMATURE_QUATERNION = (1<<0),
/** use envelopes */
CONSTRAINT_ARMATURE_ENVELOPE = (1<<1),
/** use current bone location */
CONSTRAINT_ARMATURE_CUR_LOCATION = (1<<2),
} eArmature_Flags;
/* MinMax (floor) flags */

View File

@@ -123,7 +123,8 @@ typedef struct BezTriple {
/** F1, f2, f3: used for selection status. */
char f1, f2, f3;
/** Hide: used to indicate whether BezTriple is hidden (3D), type of keyframe (eBezTriple_KeyframeType). */
/** Hide: used to indicate whether BezTriple is hidden (3D),
* type of keyframe (eBezTriple_KeyframeType). */
char hide;
/** Easing: easing type for interpolation mode (eBezTriple_Easing). */
@@ -333,10 +334,14 @@ enum {
CU_FAST = 1 << 9, /* Font: no filling inside editmode */
/* CU_RETOPO = 1 << 10, */ /* DEPRECATED */
CU_DS_EXPAND = 1 << 11,
CU_PATH_RADIUS = 1 << 12, /* make use of the path radius if this is enabled (default for new curves) */
CU_DEFORM_FILL = 1 << 13, /* fill 2d curve after deformation */
CU_FILL_CAPS = 1 << 14, /* fill bevel caps */
CU_MAP_TAPER = 1 << 15, /* map taper object to beveled area */
/** make use of the path radius if this is enabled (default for new curves) */
CU_PATH_RADIUS = 1 << 12,
/** fill 2d curve after deformation */
CU_DEFORM_FILL = 1 << 13,
/** fill bevel caps */
CU_FILL_CAPS = 1 << 14,
/** map taper object to beveled area */
CU_MAP_TAPER = 1 << 15,
};
/* Curve.twist_mode */
@@ -501,10 +506,13 @@ enum {
CU_CHINFO_BOLD = 1 << 0,
CU_CHINFO_ITALIC = 1 << 1,
CU_CHINFO_UNDERLINE = 1 << 2,
CU_CHINFO_WRAP = 1 << 3, /* wordwrap occurred here */
/** wordwrap occurred here */
CU_CHINFO_WRAP = 1 << 3,
CU_CHINFO_SMALLCAPS = 1 << 4,
CU_CHINFO_SMALLCAPS_CHECK = 1 << 5, /* set at runtime, checks if case switching is needed */
CU_CHINFO_OVERFLOW = 1 << 6, /* Set at runtime, indicates char that doesn't fit in text boxes. */
/** set at runtime, checks if case switching is needed */
CU_CHINFO_SMALLCAPS_CHECK = 1 << 5,
/** Set at runtime, indicates char that doesn't fit in text boxes. */
CU_CHINFO_OVERFLOW = 1 << 6,
};
/* mixed with KEY_LINEAR but define here since only curve supports */

View File

@@ -163,9 +163,11 @@ enum {
/* This should not be needed, having a valid WEIGHT_MCOL layer should be enough.
* And if not, should be a general flag. But seems unnecessary for now... */
#if 0
MOD_DPAINT_PREVIEW_READY = 1 << 0, /* if viewport preview is ready */
/** if viewport preview is ready */
MOD_DPAINT_PREVIEW_READY = 1 << 0,
#endif
MOD_DPAINT_BAKING = 1 << 1, /* surface is already baking, so it wont get updated (loop) */
/** surface is already baking, so it wont get updated (loop) */
MOD_DPAINT_BAKING = 1 << 1,
};
/* Canvas settings */
@@ -186,20 +188,31 @@ typedef struct DynamicPaintCanvasSettings {
/* flags */
enum {
MOD_DPAINT_PART_RAD = 1 << 0, /* use particle radius */
/** use particle radius */
MOD_DPAINT_PART_RAD = 1 << 0,
//MOD_DPAINT_USE_MATERIAL = 1 << 1, /* DNA_DEPRECATED */
MOD_DPAINT_ABS_ALPHA = 1 << 2, /* don't increase alpha unless paint alpha is higher than existing */
MOD_DPAINT_ERASE = 1 << 3, /* removes paint */
/** don't increase alpha unless paint alpha is higher than existing */
MOD_DPAINT_ABS_ALPHA = 1 << 2,
/** removes paint */
MOD_DPAINT_ERASE = 1 << 3,
MOD_DPAINT_RAMP_ALPHA = 1 << 4, /* only read falloff ramp alpha */
MOD_DPAINT_PROX_PROJECT = 1 << 5, /* do proximity check only in defined dir */
MOD_DPAINT_INVERSE_PROX = 1 << 6, /* inverse proximity painting */
MOD_DPAINT_NEGATE_VOLUME = 1 << 7, /* negates volume influence on "volume + prox" mode */
/** only read falloff ramp alpha */
MOD_DPAINT_RAMP_ALPHA = 1 << 4,
/** do proximity check only in defined dir */
MOD_DPAINT_PROX_PROJECT = 1 << 5,
/** inverse proximity painting */
MOD_DPAINT_INVERSE_PROX = 1 << 6,
/** negates volume influence on "volume + prox" mode */
MOD_DPAINT_NEGATE_VOLUME = 1 << 7,
MOD_DPAINT_DO_SMUDGE = 1 << 8, /* brush smudges existing paint */
MOD_DPAINT_VELOCITY_ALPHA = 1 << 9, /* multiply brush influence by velocity */
MOD_DPAINT_VELOCITY_COLOR = 1 << 10, /* replace brush color by velocity color ramp */
MOD_DPAINT_VELOCITY_DEPTH = 1 << 11, /* multiply brush intersection depth by velocity */
/** brush smudges existing paint */
MOD_DPAINT_DO_SMUDGE = 1 << 8,
/** multiply brush influence by velocity */
MOD_DPAINT_VELOCITY_ALPHA = 1 << 9,
/** replace brush color by velocity color ramp */
MOD_DPAINT_VELOCITY_COLOR = 1 << 10,
/** multiply brush intersection depth by velocity */
MOD_DPAINT_VELOCITY_DEPTH = 1 << 11,
MOD_DPAINT_USES_VELOCITY = (MOD_DPAINT_DO_SMUDGE | MOD_DPAINT_VELOCITY_ALPHA |
MOD_DPAINT_VELOCITY_COLOR | MOD_DPAINT_VELOCITY_DEPTH),

View File

@@ -72,11 +72,14 @@ typedef enum eSDNA_Type {
* For use with #DNA_struct_reconstruct & #DNA_struct_get_compareflags
*/
enum eSDNA_StructCompare {
/* Struct has disappeared (values of this struct type will not be loaded by the current Blender) */
/* Struct has disappeared
* (values of this struct type will not be loaded by the current Blender) */
SDNA_CMP_REMOVED = 0,
/* Struct is the same (can be loaded with straight memory copy after any necessary endian conversion) */
/* Struct is the same
* (can be loaded with straight memory copy after any necessary endian conversion) */
SDNA_CMP_EQUAL = 1,
/* Struct is different in some way (needs to be copied/converted field by field) */
/* Struct is different in some way
* (needs to be copied/converted field by field) */
SDNA_CMP_NOT_EQUAL = 2,
};

View File

@@ -223,11 +223,13 @@ typedef enum eGPDstroke_Flag {
GP_STROKE_2DIMAGE = (1 << 2),
/* stroke is selected */
GP_STROKE_SELECT = (1 << 3),
/* Recalculate geometry data (triangulation, UVs, Bound Box,... (when true, force a new recalc) */
/* Recalculate geometry data (triangulation, UVs, Bound Box,...
* (when true, force a new recalc) */
GP_STROKE_RECALC_GEOMETRY = (1 << 4),
/* Flag used to indicate that stroke is closed and draw edge between last and first point */
GP_STROKE_CYCLIC = (1 << 7),
/* Flag used to indicate that stroke is used for fill close and must use fill color for stroke and no fill area */
/* Flag used to indicate that stroke is used for fill close and must use
* fill color for stroke and no fill area */
GP_STROKE_NOFILL = (1 << 8),
/* only for use with stroke-buffer (while drawing eraser) */
GP_STROKE_ERASER = (1 << 15)
@@ -303,7 +305,8 @@ typedef struct bGPDlayer {
/** Per-layer onion-skinning flags (eGPDlayer_OnionFlag). */
short onion_flag;
/** Color for strokes in layers. Used for annotations, and for ruler (which uses GPencil internally). */
/** Color for strokes in layers. Used for annotations, and for ruler
* (which uses GPencil internally). */
float color[4];
/** Fill color for strokes in layers. Not used anymore (was only for). */
float fill[4];
@@ -551,7 +554,8 @@ typedef enum eGPdata_Flag {
GP_DATA_DEPTH_STROKE_ENDPOINTS = (1 << 7),
/* ------------------------------------------------ DEPRECATED */
/* Stroke Editing Mode - Toggle to enable alternative keymap for easier editing of stroke points */
/* Stroke Editing Mode - Toggle to enable alternative keymap
* for easier editing of stroke points */
GP_DATA_STROKE_EDITMODE = (1 << 8),
/* Main flag to switch onion skinning on/off */

View File

@@ -109,7 +109,8 @@ typedef struct Ipo {
/** Rect defining extents of keyframes?. */
rctf cur;
/** Blocktype: self-explanatory; showkey: either 0 or 1 (show vertical yellow lines for editing). */
/** Blocktype: self-explanatory; showkey: either 0 or 1
* (show vertical yellow lines for editing). */
short blocktype, showkey;
/** Muteipo: either 0 or 1 (whether ipo block is muted). */
short muteipo, pad;

View File

@@ -55,7 +55,7 @@ typedef struct TexPaintSlot {
/** Do we have a valid image and UV map. */
int valid;
/** Copy of node inteporlation setting. */
int interp;
int interp;
} TexPaintSlot;
typedef struct MaterialGPencilStyle {
@@ -255,7 +255,8 @@ typedef struct Material {
#define TEXCO_TANGENT (1 << 12)
/* still stored in vertex->accum, 1 D */
#define TEXCO_STRAND (1 << 13)
#define TEXCO_PARTICLE (1 << 13) /* strand is used for normal materials, particle for halo materials */
/** strand is used for normal materials, particle for halo materials */
#define TEXCO_PARTICLE (1 << 13)
#define TEXCO_STRESS (1 << 14)
#define TEXCO_SPEED (1 << 15)

View File

@@ -73,8 +73,9 @@ typedef struct EditMeshData {
* \warning Typical access is done via #BKE_mesh_runtime_looptri_ensure, #BKE_mesh_runtime_looptri_len.
*/
struct MLoopTri_Store {
/* WARNING! swapping between array (ready-to-be-used data) and array_wip (where data is actually computed)
* shall always be protected by same lock as one used for looptris computing. */
/* WARNING! swapping between array (ready-to-be-used data) and array_wip
* (where data is actually computed)
* shall always be protected by same lock as one used for looptris computing. */
struct MLoopTri *array, *array_wip;
int len;
int len_alloc;

View File

@@ -276,8 +276,11 @@ typedef struct MDisps {
int level;
float (*disps)[3];
/* Used for hiding parts of a multires mesh. Essentially the multires equivalent of MVert.flag's ME_HIDE bit.
* NOTE: This is a bitmap, keep in sync with type used in BLI_bitmap.h
/**
* Used for hiding parts of a multires mesh.
* Essentially the multires equivalent of MVert.flag's ME_HIDE bit.
*
* \note This is a bitmap, keep in sync with type used in BLI_bitmap.h
*/
unsigned int *hidden;
} MDisps;
@@ -347,19 +350,20 @@ typedef struct GridPaintMask {
} GridPaintMask;
typedef enum eMVertSkinFlag {
/* Marks a vertex as the edge-graph root, used for calculating rotations for all connected edges (recursively).
* Also used to choose a root when generating an armature.
/** Marks a vertex as the edge-graph root, used for calculating rotations for all connected
* edges (recursively). Also used to choose a root when generating an armature.
*/
MVERT_SKIN_ROOT = 1,
/* Marks a branch vertex (vertex with more than two connected edges), so that it's neighbors are
* directly hulled together, rather than the default of generating intermediate frames.
/** Marks a branch vertex (vertex with more than two connected edges), so that it's neighbors
* are directly hulled together, rather than the default of generating intermediate frames.
*/
MVERT_SKIN_LOOSE = 2,
} eMVertSkinFlag;
typedef struct MVertSkin {
/* Radii of the skin, define how big the generated frames are. Currently only the first two elements are used. */
/* Radii of the skin, define how big the generated frames are.
* Currently only the first two elements are used. */
float radius[3];
/* eMVertSkinFlag */

View File

@@ -383,9 +383,11 @@ typedef struct BevelModifierData {
short pad2;
/** Controls profile shape (0->1, .5 is round). */
float profile;
/* if the MOD_BEVEL_ANGLE is set, this will be how "sharp" an edge must be before it gets beveled */
/** if the MOD_BEVEL_ANGLE is set,
* this will be how "sharp" an edge must be before it gets beveled */
float bevel_angle;
/* if the MOD_BEVEL_VWEIGHT option is set, this will be the name of the vert group, MAX_VGROUP_NAME */
/** if the MOD_BEVEL_VWEIGHT option is set,
* this will be the name of the vert group, MAX_VGROUP_NAME */
char defgrp_name[64];
struct BevelModNorEditData clnordata;
} BevelModifierData;
@@ -980,8 +982,8 @@ typedef struct ShrinkwrapModifierData {
/** Axis to project over. */
char projAxis;
/* If using projection over vertex normal this controls the level of subsurface that must be done
* before getting the vertex coordinates and normal
/** If using projection over vertex normal this controls the level of subsurface that must be
* done before getting the vertex coordinates and normal
*/
char subsurfLevels;
@@ -998,32 +1000,33 @@ enum {
/* Shrinkwrap->shrinkMode */
enum {
/* Move vertex to the surface of the target object (keepDist towards original position) */
/** Move vertex to the surface of the target object (keepDist towards original position) */
MOD_SHRINKWRAP_ON_SURFACE = 0,
/* Move the vertex inside the target object; don't change if already inside */
/** Move the vertex inside the target object; don't change if already inside */
MOD_SHRINKWRAP_INSIDE = 1,
/* Move the vertex outside the target object; don't change if already outside */
/** Move the vertex outside the target object; don't change if already outside */
MOD_SHRINKWRAP_OUTSIDE = 2,
/* Move vertex to the surface of the target object, with keepDist towards the outside */
/** Move vertex to the surface of the target object, with keepDist towards the outside */
MOD_SHRINKWRAP_OUTSIDE_SURFACE = 3,
/* Move vertex to the surface of the target object, with keepDist along the normal */
/** Move vertex to the surface of the target object, with keepDist along the normal */
MOD_SHRINKWRAP_ABOVE_SURFACE = 4,
};
/* Shrinkwrap->shrinkOpts */
enum {
/* allow shrinkwrap to move the vertex in the positive direction of axis */
/** allow shrinkwrap to move the vertex in the positive direction of axis */
MOD_SHRINKWRAP_PROJECT_ALLOW_POS_DIR = (1 << 0),
/* allow shrinkwrap to move the vertex in the negative direction of axis */
/** allow shrinkwrap to move the vertex in the negative direction of axis */
MOD_SHRINKWRAP_PROJECT_ALLOW_NEG_DIR = (1 << 1),
/* ignore vertex moves if a vertex ends projected on a front face of the target */
/** ignore vertex moves if a vertex ends projected on a front face of the target */
MOD_SHRINKWRAP_CULL_TARGET_FRONTFACE = (1 << 3),
/* ignore vertex moves if a vertex ends projected on a back face of the target */
/** ignore vertex moves if a vertex ends projected on a back face of the target */
MOD_SHRINKWRAP_CULL_TARGET_BACKFACE = (1 << 4),
#ifdef DNA_DEPRECATED_ALLOW
MOD_SHRINKWRAP_KEEP_ABOVE_SURFACE = (1 << 5), /* distance is measure to the front face of the target */
/** distance is measure to the front face of the target */
MOD_SHRINKWRAP_KEEP_ABOVE_SURFACE = (1 << 5),
#endif
MOD_SHRINKWRAP_INVERT_VGROUP = (1 << 6),
@@ -1034,7 +1037,8 @@ enum {
/* Shrinkwrap->projAxis */
enum {
MOD_SHRINKWRAP_PROJECT_OVER_NORMAL = 0, /* projection over normal is used if no axis is selected */
/** projection over normal is used if no axis is selected */
MOD_SHRINKWRAP_PROJECT_OVER_NORMAL = 0,
MOD_SHRINKWRAP_PROJECT_OVER_X_AXIS = (1 << 0),
MOD_SHRINKWRAP_PROJECT_OVER_Y_AXIS = (1 << 1),
MOD_SHRINKWRAP_PROJECT_OVER_Z_AXIS = (1 << 2),
@@ -1095,7 +1099,8 @@ typedef struct SolidifyModifierData {
float offset;
/** Midpoint of the offset . */
float offset_fac;
/* factor for the minimum weight to use when vgroups are used, avoids 0.0 weights giving duplicate geometry */
/** factor for the minimum weight to use when vgroups are used,
* avoids 0.0 weights giving duplicate geometry */
float offset_fac_vg;
/** Clamp offset based on surrounding geometry. */
float offset_clamp;

View File

@@ -139,13 +139,15 @@ typedef struct bNodeSocket {
int own_index DNA_DEPRECATED;
/* XXX deprecated, only used for restoring old group node links */
int to_index DNA_DEPRECATED;
/* XXX deprecated, still forward compatible since verification restores pointer from matching own_index. */
/* XXX deprecated, still forward compatible since verification
* restores pointer from matching own_index. */
struct bNodeSocket *groupsock DNA_DEPRECATED;
/** A link pointer, set in ntreeUpdateTree. */
struct bNodeLink *link;
/* XXX deprecated, socket input values are stored in default_value now. kept for forward compatibility */
/* XXX deprecated, socket input values are stored in default_value now.
* kept for forward compatibility */
/** Custom data for inputs, only UI writes in this. */
bNodeStack ns DNA_DEPRECATED;
} bNodeSocket;
@@ -178,14 +180,22 @@ typedef enum eNodeSocketInOut {
/* sock->flag, first bit is select */
typedef enum eNodeSocketFlag {
SOCK_HIDDEN = (1 << 1), /* hidden is user defined, to hide unused */
SOCK_IN_USE = (1 << 2), /* for quick check if socket is linked */
SOCK_UNAVAIL = (1 << 3), /* unavailable is for dynamic sockets */
// SOCK_DYNAMIC = (1 << 4), /* DEPRECATED dynamic socket (can be modified by user) */
// SOCK_INTERNAL = (1 << 5), /* DEPRECATED group socket should not be exposed */
SOCK_COLLAPSED = (1 << 6), /* socket collapsed in UI */
SOCK_HIDE_VALUE = (1 << 7), /* hide socket value, if it gets auto default */
SOCK_AUTO_HIDDEN__DEPRECATED = (1 << 8), /* socket hidden automatically, to distinguish from manually hidden */
/** hidden is user defined, to hide unused */
SOCK_HIDDEN = (1 << 1),
/** for quick check if socket is linked */
SOCK_IN_USE = (1 << 2),
/** unavailable is for dynamic sockets */
SOCK_UNAVAIL = (1 << 3),
// /** DEPRECATED dynamic socket (can be modified by user) */
// SOCK_DYNAMIC = (1 << 4),
// /** DEPRECATED group socket should not be exposed */
// SOCK_INTERNAL = (1 << 5),
/** socket collapsed in UI */
SOCK_COLLAPSED = (1 << 6),
/** hide socket value, if it gets auto default */
SOCK_HIDE_VALUE = (1 << 7),
/** socket hidden automatically, to distinguish from manually hidden */
SOCK_AUTO_HIDDEN__DEPRECATED = (1 << 8),
SOCK_NO_INTERNAL_LINK = (1 << 9),
} eNodeSocketFlag;
@@ -395,7 +405,8 @@ typedef struct bNodeLink {
#define NTREE_CHUNCKSIZE_1024 1024
/* the basis for a Node tree, all links and nodes reside internal here */
/* only re-usable node trees are in the library though, materials and textures allocate own tree struct */
/* only re-usable node trees are in the library though,
* materials and textures allocate own tree struct */
typedef struct bNodeTree {
ID id;
/** Animation data (must be immediately after id for utilities to use it). */
@@ -497,7 +508,9 @@ typedef struct bNodeTree {
#define NTREE_COM_GROUPNODE_BUFFER (1 << 3) /* use groupnode buffers */
#define NTREE_VIEWER_BORDER (1 << 4) /* use a border for viewer nodes */
/* NOTE: DEPRECATED, use (id->tag & LIB_TAG_LOCALIZED) instead. */
/* #define NTREE_IS_LOCALIZED (1 << 5) */ /* tree is localized copy, free when deleting node groups */
/* tree is localized copy, free when deleting node groups */
/* #define NTREE_IS_LOCALIZED (1 << 5) */
/* XXX not nice, but needed as a temporary flags
* for group updates after library linking.
@@ -771,7 +784,8 @@ typedef struct NodeScriptDict {
/* qdn: glare node */
typedef struct NodeGlare {
char quality, type, iter;
/* XXX angle is only kept for backward/forward compatibility, was used for two different things, see T50736. */
/* XXX angle is only kept for backward/forward compatibility,
* was used for two different things, see T50736. */
char angle DNA_DEPRECATED, pad_c1, size, star_45, streaks;
float colmod, mix, threshold, fade;
float angle_ofs, pad_f1;

View File

@@ -166,7 +166,8 @@ 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") */
/* 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

View File

@@ -41,21 +41,35 @@ extern "C" {
/* pd->forcefield: Effector Fields types */
typedef enum ePFieldType {
PFIELD_NULL = 0, /* (this is used for general effector weight) */
PFIELD_FORCE = 1, /* Force away/towards a point depending on force strength */
PFIELD_VORTEX = 2, /* Force around the effector normal */
PFIELD_MAGNET = 3, /* Force from the cross product of effector normal and point velocity */
PFIELD_WIND = 4, /* Force away and towards a point depending which side of the effector */
/* normal the point is */
PFIELD_GUIDE = 5, /* Force along curve for dynamics, a shaping curve for hair paths */
PFIELD_TEXTURE = 6, /* Force based on texture values calculated at point coordinates */
PFIELD_HARMONIC = 7, /* Force of a harmonic (damped) oscillator */
PFIELD_CHARGE = 8, /* Force away/towards a point depending on point charge */
PFIELD_LENNARDJ = 9, /* Force due to a Lennard-Jones potential */
PFIELD_BOID = 10, /* Defines predator / goal for boids */
PFIELD_TURBULENCE = 11, /* Force defined by BLI_gTurbulence */
PFIELD_DRAG = 12, /* Linear & quadratic drag */
PFIELD_SMOKEFLOW = 13, /* Force based on smoke simulation air flow */
/** (this is used for general effector weight). */
PFIELD_NULL = 0,
/** Force away/towards a point depending on force strength. */
PFIELD_FORCE = 1,
/** Force around the effector normal. */
PFIELD_VORTEX = 2,
/** Force from the cross product of effector normal and point velocity. */
PFIELD_MAGNET = 3,
/** Force away and towards a point depending which side of the effector normal the point is. */
PFIELD_WIND = 4,
/** Force along curve for dynamics, a shaping curve for hair paths. */
PFIELD_GUIDE = 5,
/** Force based on texture values calculated at point coordinates. */
PFIELD_TEXTURE = 6,
/** Force of a harmonic (damped) oscillator. */
PFIELD_HARMONIC = 7,
/** Force away/towards a point depending on point charge. */
PFIELD_CHARGE = 8,
/** Force due to a Lennard-Jones potential. */
PFIELD_LENNARDJ = 9,
/** Defines predator / goal for boids. */
PFIELD_BOID = 10,
/** Force defined by BLI_gTurbulence. */
PFIELD_TURBULENCE = 11,
/** Linear & quadratic drag. */
PFIELD_DRAG = 12,
/** Force based on smoke simulation air flow. */
PFIELD_SMOKEFLOW = 13,
NUM_PFIELD_TYPES
} ePFieldType;
@@ -409,27 +423,38 @@ typedef struct SoftBody {
/* pd->flag: various settings */
#define PFIELD_USEMAX (1 << 0)
/*#define PDEFLE_DEFORM (1 << 1)*/ /*UNUSED*/
#define PFIELD_GUIDE_PATH_ADD (1 << 2) /* TODO: do_versions for below */
#define PFIELD_PLANAR (1 << 3) /* used for do_versions */
/** TODO: do_versions for below */
#define PFIELD_GUIDE_PATH_ADD (1 << 2)
/** used for do_versions */
#define PFIELD_PLANAR (1 << 3)
#define PDEFLE_KILL_PART (1 << 4)
#define PFIELD_POSZ (1 << 5) /* used for do_versions */
/** used for do_versions */
#define PFIELD_POSZ (1 << 5)
#define PFIELD_TEX_OBJECT (1 << 6)
#define PFIELD_GLOBAL_CO (1 << 6) /* used for turbulence */
/** used for turbulence */
#define PFIELD_GLOBAL_CO (1 << 6)
#define PFIELD_TEX_2D (1 << 7)
#define PFIELD_MULTIPLE_SPRINGS (1 << 7) /* used for harmonic force */
/** used for harmonic force */
#define PFIELD_MULTIPLE_SPRINGS (1 << 7)
#define PFIELD_USEMIN (1 << 8)
#define PFIELD_USEMAXR (1 << 9)
#define PFIELD_USEMINR (1 << 10)
#define PFIELD_TEX_ROOTCO (1 << 11)
#define PFIELD_SURFACE (1 << 12) /* used for do_versions */
/** used for do_versions */
#define PFIELD_SURFACE (1 << 12)
#define PFIELD_VISIBILITY (1 << 13)
#define PFIELD_DO_LOCATION (1 << 14)
#define PFIELD_DO_ROTATION (1 << 15)
#define PFIELD_GUIDE_PATH_WEIGHT (1 << 16) /* apply curve weights */
#define PFIELD_SMOKE_DENSITY (1 << 17) /* multiply smoke force by density */
#define PFIELD_GRAVITATION (1 << 18) /* used for (simple) force */
#define PFIELD_CLOTH_USE_CULLING (1<< 19) /* Enable cloth collision side detection based on normal. */
#define PFIELD_CLOTH_USE_NORMAL (1 << 20) /* Replace collision direction with collider normal. */
/** apply curve weights */
#define PFIELD_GUIDE_PATH_WEIGHT (1 << 16)
/** multiply smoke force by density */
#define PFIELD_SMOKE_DENSITY (1 << 17)
/** used for (simple) force */
#define PFIELD_GRAVITATION (1 << 18)
/** Enable cloth collision side detection based on normal. */
#define PFIELD_CLOTH_USE_CULLING (1<< 19)
/** Replace collision direction with collider normal. */
#define PFIELD_CLOTH_USE_NORMAL (1 << 20)
/* pd->falloff */
#define PFIELD_FALL_SPHERE 0
@@ -461,13 +486,15 @@ typedef struct SoftBody {
//#define PTCACHE_BAKE_EDIT (1 << 4)
//#define PTCACHE_BAKE_EDIT_ACTIVE (1 << 5)
#define PTCACHE_DISK_CACHE (1 << 6)
//#define PTCACHE_QUICK_CACHE (1 << 7) /* removed since 2.64 - [#30974], could be added back in a more useful way */
///* removed since 2.64 - [#30974], could be added back in a more useful way */
//#define PTCACHE_QUICK_CACHE (1 << 7)
#define PTCACHE_FRAMES_SKIPPED (1 << 8)
#define PTCACHE_EXTERNAL (1 << 9)
#define PTCACHE_READ_INFO (1 << 10)
/* don't use the filename of the blendfile the data is linked from (write a local cache) */
/** don't use the filename of the blendfile the data is linked from (write a local cache) */
#define PTCACHE_IGNORE_LIBPATH (1 << 11)
/* high resolution cache is saved for smoke for backwards compatibility, so set this flag to know it's a "fake" cache */
/** high resolution cache is saved for smoke for backwards compatibility,
* so set this flag to know it's a "fake" cache */
#define PTCACHE_FAKE_SMOKE (1 << 12)
#define PTCACHE_IGNORE_CLEAR (1 << 13)

View File

@@ -259,7 +259,8 @@ typedef struct Object {
float obmat[4][4];
/** Inverse result of parent, so that object doesn't 'stick' to parent. */
float parentinv[4][4];
/** Inverse result of constraints. doesn't include effect of parent or object local transform. */
/** Inverse result of constraints.
* doesn't include effect of parent or object local transform. */
float constinv[4][4];
/**
* Inverse matrix of 'obmat' for any other use than rendering!
@@ -612,7 +613,8 @@ enum {
/* NOTE: BA_HAS_RECALC_DATA can be re-used later if freed in readfile.c. */
// BA_HAS_RECALC_OB = (1 << 2), /* DEPRECATED */
// BA_HAS_RECALC_DATA = (1 << 3), /* DEPRECATED */
BA_SNAP_FIX_DEPS_FIASCO = (1 << 2), /* DEPRECATED, was runtime only, but was reusing an older flag. */
/** DEPRECATED, was runtime only, but was reusing an older flag. */
BA_SNAP_FIX_DEPS_FIASCO = (1 << 2),
};
/* NOTE: this was used as a proper setting in past, so nullify before using */

View File

@@ -305,8 +305,11 @@ typedef struct ParticleSettings {
} ParticleSettings;
typedef struct ParticleSystem {
/* note1: make sure all (runtime) are NULL's in 'copy_particlesystem' XXX, this function is no more! - need to invstigate */
/* note2: make sure any uses of this struct in DNA are accounted for in 'BKE_object_copy_particlesystems' */
/* note1: make sure all (runtime) are NULL's in 'copy_particlesystem' XXX,
* this function is no more! - need to invstigate */
/* note2: make sure any uses of this struct in DNA are
* accounted for in 'BKE_object_copy_particlesystems' */
struct ParticleSystem *next, *prev;

View File

@@ -312,29 +312,30 @@ typedef struct RigidBodyCon {
/* Participation types for RigidBodyOb */
typedef enum eRigidBodyCon_Type {
/* lets bodies rotate around a specified point */
/** lets bodies rotate around a specified point */
RBC_TYPE_POINT = 0,
/* lets bodies rotate around a specified axis */
/** lets bodies rotate around a specified axis */
RBC_TYPE_HINGE,
/* simulates wheel suspension */
/** simulates wheel suspension */
RBC_TYPE_HINGE2,
/* restricts movent to a specified axis */
/** restricts movent to a specified axis */
RBC_TYPE_SLIDER,
/* lets object rotate within a cpecified cone */
/** lets object rotate within a cpecified cone */
RBC_TYPE_CONE_TWIST,
/* allows user to specify constraint axes */
/** allows user to specify constraint axes */
RBC_TYPE_6DOF,
/* like 6DOF but has springs */
/** like 6DOF but has springs */
RBC_TYPE_6DOF_SPRING,
/* simulates a universal joint */
/** simulates a universal joint */
RBC_TYPE_UNIVERSAL,
/* glues two bodies together */
/** glues two bodies together */
RBC_TYPE_FIXED,
/* similar to slider but also allows rotation around slider axis */
/** similar to slider but also allows rotation around slider axis */
RBC_TYPE_PISTON,
/* Simplified spring constraint with only once axis that's automatically placed between the connected bodies */
/** Simplified spring constraint with only once axis that's
* automatically placed between the connected bodies */
RBC_TYPE_SPRING,
/* dirves bodies by applying linear and angular forces */
/** dirves bodies by applying linear and angular forces */
RBC_TYPE_MOTOR,
} eRigidBodyCon_Type;

View File

@@ -125,9 +125,12 @@ typedef enum eFFMpegPreset {
* WEBM/VP9 use these values directly, whereas h.264 map those to
* respectively the MEDIUM, SLOWER, and SUPERFAST presets.
*/
FFM_PRESET_GOOD = 10, /* the default and recommended for most applications */
FFM_PRESET_BEST, /* recommended if you have lots of time and want the best compression efficiency */
FFM_PRESET_REALTIME, /* recommended for live / fast encoding */
/** the default and recommended for most applications */
FFM_PRESET_GOOD = 10,
/** recommended if you have lots of time and want the best compression efficiency */
FFM_PRESET_BEST,
/** recommended for live / fast encoding */
FFM_PRESET_REALTIME,
} eFFMpegPreset;
/* Mapping from easily-understandable descriptions to CRF values.
@@ -1265,7 +1268,8 @@ typedef struct UnifiedPaintSettings {
char draw_anchored;
char do_linear_conversion;
/* store last location of stroke or whether the mesh was hit. Valid only while stroke is active */
/* store last location of stroke or whether the mesh was hit.
* Valid only while stroke is active */
float last_location[3];
int last_hit;
@@ -1911,7 +1915,8 @@ enum {
/* RenderData.color_mgt_flag */
enum {
R_COLOR_MANAGEMENT = (1 << 0), /* deprecated, should only be used in versioning code only */
/** deprecated, should only be used in versioning code only */
R_COLOR_MANAGEMENT = (1 << 0),
/*R_COLOR_MANAGEMENT_PREDIVIDE = (1 << 1)*/ /* deprecated, shouldn't be used */
};
@@ -2255,9 +2260,12 @@ enum {
/* ToolSettings.uvcalc_flag */
#define UVCALC_FILLHOLES (1 << 0)
#define UVCALC_NO_ASPECT_CORRECT (1 << 1) /* would call this UVCALC_ASPECT_CORRECT, except it should be default with old file */
#define UVCALC_TRANSFORM_CORRECT (1 << 2) /* adjust UV's while transforming to avoid distortion */
#define UVCALC_USESUBSURF (1 << 3) /* Use mesh data after subsurf to compute UVs*/
/** would call this UVCALC_ASPECT_CORRECT, except it should be default with old file */
#define UVCALC_NO_ASPECT_CORRECT (1 << 1)
/** adjust UV's while transforming to avoid distortion */
#define UVCALC_TRANSFORM_CORRECT (1 << 2)
/** Use mesh data after subsurf to compute UVs*/
#define UVCALC_USESUBSURF (1 << 3)
/* ToolSettings.uv_flag */
#define UV_SYNC_SELECTION 1

View File

@@ -470,7 +470,8 @@ enum {
// AREA_FLAG_DEPRECATED_5 = (1 << 5),
/* used to check if we should switch back to prevspace (of a different type) */
AREA_FLAG_TEMP_TYPE = (1 << 6),
/* for temporary fullscreens (file browser, image editor render) that are opened above user set fullscreens */
/* for temporary fullscreens (file browser, image editor render)
* that are opened above user set fullscreens */
AREA_FLAG_STACKED_FULLSCREEN = (1 << 7),
/* update action zones (even if the mouse is not intersecting them) */
AREA_FLAG_ACTIONZONES_UPDATE = (1 << 8),
@@ -554,12 +555,15 @@ enum {
/* uiList filter sort type */
enum {
/* Plain values (only one is valid at a time, once masked with UILST_FLT_SORT_MASK. */
UILST_FLT_SORT_INDEX = 0, /* Just for sake of consistency. */
/** Just for sake of consistency. */
UILST_FLT_SORT_INDEX = 0,
UILST_FLT_SORT_ALPHA = 1,
/* Bitflags affecting behavior of any kind of sorting. */
UILST_FLT_SORT_LOCK = 1u << 30, /* Special flag to indicate that order is locked (not user-changeable). */
UILST_FLT_SORT_REVERSE = 1u << 31 /* Special value, bitflag used to reverse order! */
/** Special flag to indicate that order is locked (not user-changeable). */
UILST_FLT_SORT_LOCK = 1u << 30,
/** Special value, bitflag used to reverse order! */
UILST_FLT_SORT_REVERSE = 1u << 31
};
#define UILST_FLT_SORT_MASK (((unsigned int)(UILST_FLT_SORT_REVERSE | UILST_FLT_SORT_LOCK)) - 1)

View File

@@ -183,7 +183,8 @@ typedef struct Sequence {
/** Old animation system, deprecated for 2.5. */
struct Ipo *ipo DNA_DEPRECATED;
/* these ID vars should never be NULL but can be when linked libs fail to load, so check on access */
/** these ID vars should never be NULL but can be when linked libs fail to load,
* so check on access */
struct Scene *scene;
/** Override scene camera. */
struct Object *scene_camera;

View File

@@ -227,7 +227,8 @@ typedef struct SmokeDomainSettings {
char data_depth;
char pad[2];
/* Smoke uses only one cache from now on (index [0]), but keeping the array for now for reading old files. */
/* Smoke uses only one cache from now on (index [0]),
* but keeping the array for now for reading old files. */
/** Definition is in DNA_object_force_types.h. */
struct PointCache *point_cache[2];
struct ListBase ptcaches[2];

View File

@@ -218,7 +218,8 @@ typedef enum eSpaceButtons_Flag {
SB_PIN_CONTEXT = (1 << 1),
SB_FLAG_DEPRECATED_2 = (1 << 2),
SB_FLAG_DEPRECATED_3 = (1 << 3),
SB_TEX_USER_LIMITED = (1 << 3), /* Do not add materials, particles, etc. in TemplateTextureUser list. */
/** Do not add materials, particles, etc. in TemplateTextureUser list. */
SB_TEX_USER_LIMITED = (1 << 3),
SB_SHADING_CONTEXT = (1 << 4),
} eSpaceButtons_Flag;
@@ -261,7 +262,9 @@ typedef struct SpaceOops {
char pad;
short filter_id_type;
/* pointers to treestore elements, grouped by (id, type, nr) in hashtable for faster searching */
/**
* Pointers to treestore elements, grouped by (id, type, nr)
* in hashtable for faster searching */
void *treehash;
} SpaceOops;
@@ -389,7 +392,8 @@ typedef struct SpaceIpo {
/** Deprecated, copied to region. */
View2D v2d DNA_DEPRECATED;
/** Settings for filtering animation data (NOTE: we use a pointer due to code-linking issues). */
/** Settings for filtering animation data
* \note we use a pointer due to code-linking issues. */
struct bDopeSheet *ads;
/** Mode for the Graph editor (eGraphEdit_Mode). */
@@ -820,14 +824,17 @@ typedef enum eFileSel_File_Types {
FILE_TYPE_SOUND = (1 << 8),
FILE_TYPE_TEXT = (1 << 9),
/* 1 << 10 was FILE_TYPE_MOVIE_ICON, got rid of this so free slot for future type... */
FILE_TYPE_FOLDER = (1 << 11), /* represents folders for filtering */
/** represents folders for filtering */
FILE_TYPE_FOLDER = (1 << 11),
FILE_TYPE_BTX = (1 << 12),
FILE_TYPE_COLLADA = (1 << 13),
FILE_TYPE_OPERATOR = (1 << 14), /* from filter_glob operator property */
/** from filter_glob operator property */
FILE_TYPE_OPERATOR = (1 << 14),
FILE_TYPE_APPLICATIONBUNDLE = (1 << 15),
FILE_TYPE_ALEMBIC = (1 << 16),
FILE_TYPE_DIR = (1 << 30), /* An FS directory (i.e. S_ISDIR on its path is true). */
/** An FS directory (i.e. S_ISDIR on its path is true). */
FILE_TYPE_DIR = (1 << 30),
FILE_TYPE_BLENDERLIB = (1u << 31),
} eFileSel_File_Types;
@@ -902,7 +909,8 @@ typedef struct FileDirEntry {
char *name;
char *description;
/* Either point to active variant/revision if available, or own entry (in mere filebrowser case). */
/* Either point to active variant/revision if available, or own entry
* (in mere filebrowser case). */
FileDirEntryRevision *entry;
/** #eFileSel_File_Types. */
@@ -1325,7 +1333,8 @@ typedef enum eSpaceNode_Flag {
SNODE_FLAG_DEPRECATED_10 = (1 << 10), /* cleared */
SNODE_FLAG_DEPRECATED_11 = (1 << 11), /* cleared */
SNODE_PIN = (1 << 12),
SNODE_SKIP_INSOFFSET = (1 << 13), /* automatically offset following nodes in a chain on insertion */
/** automatically offset following nodes in a chain on insertion */
SNODE_SKIP_INSOFFSET = (1 << 13),
} eSpaceNode_Flag;
/* SpaceNode.texfrom */

View File

@@ -181,7 +181,8 @@ typedef struct Tex {
/* newnoise: distorted noise amount, musgrave & voronoi output scale */
float dist_amount, ns_outscale;
/* newnoise: voronoi nearest neighbor weights, minkovsky exponent, distance metric & color type */
/* newnoise: voronoi nearest neighbor weights, minkovsky exponent,
* distance metric & color type */
float vn_w1;
float vn_w2;
float vn_w3;

View File

@@ -261,7 +261,8 @@ typedef struct MovieTrackingSettings {
short default_pattern_size;
/** Size of search area for new tracks. */
short default_search_size;
/** Number of frames to be tarcked during single tracking session (if TRACKING_FRAMES_LIMIT is set). */
/** Number of frames to be tarcked during single tracking session
* (if TRACKING_FRAMES_LIMIT is set). */
short default_frames_limit;
/** Margin from frame boundaries. */
short default_margin;
@@ -337,7 +338,8 @@ typedef struct MovieTrackingStabilization {
int filter;
/* initialization and run-time data */
/** Without effect now, we initialize on every frame. Formerly used for caching of init values. */
/** Without effect now, we initialize on every frame.
* Formerly used for caching of init values. */
int ok DNA_DEPRECATED;
} MovieTrackingStabilization;

View File

@@ -720,7 +720,8 @@ typedef struct UserDef {
/** #eMultiSample_Type, amount of samples for OpenGL FSA, if zero no FSA. */
short ogl_multisamples;
/* eImageDrawMethod, Method to be used to draw the images (AUTO, GLSL, Textures or DrawPixels) */
/** eImageDrawMethod, Method to be used to draw the images
* (AUTO, GLSL, Textures or DrawPixels) */
short image_draw_method;
float glalphaclip;
@@ -936,7 +937,8 @@ typedef enum eAutokey_Mode {
/* AUTOKEY_ON is a bitflag */
AUTOKEY_ON = 1,
/* AUTOKEY_ON + 2**n... (i.e. AUTOKEY_MODE_NORMAL = AUTOKEY_ON + 2) to preserve setting, even when autokey turned off */
/** AUTOKEY_ON + 2**n... (i.e. AUTOKEY_MODE_NORMAL = AUTOKEY_ON + 2)
* to preserve setting, even when autokey turned off */
AUTOKEY_MODE_NORMAL = 3,
AUTOKEY_MODE_EDITKEYS = 5
} eAutokey_Mode;

View File

@@ -69,7 +69,8 @@ typedef struct View2D {
/** Storage of current winx/winy values, set in UI_view2d_size_update. */
short winx, winy;
/** Storage of previous winx/winy values encountered by UI_view2d_curRect_validate(), for keepaspect. */
/** Storage of previous winx/winy values encountered by UI_view2d_curRect_validate(),
* for keepaspect. */
short oldwinx, oldwiny;
/** Pivot point for transforms (rotate and scale). */
@@ -122,18 +123,20 @@ enum {
/* view extent restrictions (v2d->keeptot) */
enum {
/* 'cur' view can be out of extents of 'tot' */
/** 'cur' view can be out of extents of 'tot' */
V2D_KEEPTOT_FREE = 0,
/* 'cur' rect is adjusted so that it satisfies the extents of 'tot', with some compromises */
/** 'cur' rect is adjusted so that it satisfies the extents of 'tot', with some compromises */
V2D_KEEPTOT_BOUNDS = 1,
/* 'cur' rect is moved so that the 'minimum' bounds of the 'tot' rect are always respected (particularly in x-axis) */
/** 'cur' rect is moved so that the 'minimum' bounds of the 'tot' rect are always respected
* (particularly in x-axis) */
V2D_KEEPTOT_STRICT = 2,
};
/* general refresh settings (v2d->flag) */
enum {
/* global view2d horizontal locking (for showing same time interval) */
/* TODO: this flag may be set in old files but is not accessible currently, should be exposed from RNA - Campbell */
/* TODO: this flag may be set in old files but is not accessible currently,
* should be exposed from RNA - Campbell */
V2D_VIEWSYNC_SCREEN_TIME = (1 << 0),
/* within area (i.e. between regions) view2d vertical locking */
V2D_VIEWSYNC_AREA_VERTICAL = (1 << 1),
@@ -163,7 +166,8 @@ enum {
/* induce hiding of scrollbars - set by region drawing in response to size of region */
V2D_SCROLL_VERTICAL_HIDE = (1 << 7),
V2D_SCROLL_HORIZONTAL_HIDE = (1 << 8),
/* scrollbar extends beyond its available window - set when calculating scrollbars for drawing */
/* scrollbar extends beyond its available window -
* set when calculating scrollbars for drawing */
V2D_SCROLL_VERTICAL_FULLR = (1 << 9),
V2D_SCROLL_HORIZONTAL_FULLR = (1 << 10),
};

View File

@@ -83,7 +83,8 @@ typedef struct RegionView3D {
/** User defined clipping planes. */
float clip[6][4];
/** Clip in object space, means we can test for clipping in editmode without first going into worldspace. */
/** Clip in object space,
* means we can test for clipping in editmode without first going into worldspace. */
float clip_local[6][4];
struct BoundBox *clipbb;

View File

@@ -245,7 +245,8 @@ typedef struct wmWindow {
short modalcursor;
/** Cursor grab mode. */
short grabcursor;
/** Internal: tag this for extra mousemove event, makes cursors/buttons active on UI switching. */
/** Internal: tag this for extra mousemove event,
* makes cursors/buttons active on UI switching. */
short addmousemove;
short pad[4];
@@ -511,16 +512,17 @@ enum {
/* wmOperator flag */
enum {
/* low level flag so exec() operators can tell if they were invoked, use with care.
* typically this shouldn't make any difference, but it rare cases its needed (see smooth-view) */
/** low level flag so exec() operators can tell if they were invoked, use with care.
* Typically this shouldn't make any difference, but it rare cases its needed
* (see smooth-view) */
OP_IS_INVOKE = (1 << 0),
/* So we can detect if an operators exec() call is activated from an interactive repeat. */
/** So we can detect if an operators exec() call is activated from an interactive repeat. */
OP_IS_REPEAT = (1 << 1),
/* When the cursor is grabbed */
/** When the cursor is grabbed */
OP_IS_MODAL_GRAB_CURSOR = (1 << 2),
/* allow modal operators to have the region under the cursor for their context
/** Allow modal operators to have the region under the cursor for their context
* (the regiontype is maintained to prevent errors) */
OP_IS_MODAL_CURSOR_REGION = (1 << 3),
};

View File

@@ -112,7 +112,8 @@ typedef struct WorkSpaceLayout {
struct WorkSpaceLayout *next, *prev;
struct bScreen *screen;
/* The name of this layout, we override the RNA name of the screen with this (but not ID name itself) */
/* The name of this layout, we override the RNA name of the screen with this
* (but not ID name itself) */
/** MAX_NAME. */
char name[64] DNA_PRIVATE_WORKSPACE;
} WorkSpaceLayout;
@@ -192,7 +193,8 @@ typedef struct WorkSpace {
typedef struct WorkSpaceDataRelation {
struct WorkSpaceDataRelation *next, *prev;
/* the data used to identify the relation (e.g. to find screen-layout (= value) from/for a hook) */
/* the data used to identify the relation
* (e.g. to find screen-layout (= value) from/for a hook) */
void *parent;
/* The value for this parent-data/workspace relation */
void *value;
@@ -208,7 +210,8 @@ typedef struct WorkSpaceInstanceHook {
WorkSpace *active DNA_PRIVATE_WORKSPACE;
struct WorkSpaceLayout *act_layout DNA_PRIVATE_WORKSPACE;
/* Needed because we can't change workspaces/layouts in running handler loop, it would break context. */
/* Needed because we can't change workspaces/layouts in running handler loop,
* it would break context. */
WorkSpace *temp_workspace_store;
struct WorkSpaceLayout *temp_layout_store;
} WorkSpaceInstanceHook;

View File

@@ -492,7 +492,8 @@ static bool init_structDNA(
/* this is a patch, to change struct names without a conflict with SDNA */
/* be careful to use it, in this case for a system-struct (opengl/X) */
/* struct Screen was already used by X, 'bScreen' replaces the old IrisGL 'Screen' struct */
/* struct Screen was already used by X,
* 'bScreen' replaces the old IrisGL 'Screen' struct */
if (strcmp("bScreen", cp) == 0) {
sdna->types[nr] = cp + 1;
}
@@ -844,7 +845,8 @@ static eSDNA_Type sdna_type_nr(const char *dna_type)
else if ( strcmp(dna_type, "double") == 0) return SDNA_TYPE_DOUBLE;
else if ( strcmp(dna_type, "int64_t") == 0) return SDNA_TYPE_INT64;
else if ( strcmp(dna_type, "uint64_t") == 0) return SDNA_TYPE_UINT64;
else return -1; /* invalid! */
/* invalid! */
else return -1;
}
/**
@@ -1155,8 +1157,11 @@ static void reconstruct_elem(
curdata, olddata);
}
else if (strcmp(type, otype) == 0) { /* type equal */
mul = len / oldsize; /* size of single old array element */
mul *= (cursize < oldsize) ? cursize : oldsize; /* smaller of sizes of old and new arrays */
/* size of single old array element */
mul = len / oldsize;
/* smaller of sizes of old and new arrays */
mul *= (cursize < oldsize) ? cursize : oldsize;
memcpy(curdata, olddata, mul);
if (oldsize > cursize && strcmp(type, "char") == 0) {

View File

@@ -142,15 +142,21 @@ static int maxdata = 500000, maxnr = 50000;
static int nr_names = 0;
static int nr_types = 0;
static int nr_structs = 0;
static char **names, *namedata; /* at address names[a] is string a */
static char **types, *typedata; /* at address types[a] is string a */
static short *typelens_native; /* at typelens[a] is the length of type 'a' on this systems bitness (32 or 64) */
static short *typelens_32; /* contains sizes as they are calculated on 32 bit systems */
static short *typelens_64; /* contains sizes as they are calculated on 64 bit systems */
static short **structs, *structdata; /* at sp = structs[a] is the first address of a struct definition
* sp[0] is type number
* sp[1] is amount of elements
* sp[2] sp[3] is typenr, namenr (etc) */
/** at address names[a] is string a */
static char **names, *namedata;
/** at address types[a] is string a */
static char **types, *typedata;
/** at typelens[a] is the length of type 'a' on this systems bitness (32 or 64) */
static short *typelens_native;
/** contains sizes as they are calculated on 32 bit systems */
static short *typelens_32;
/** contains sizes as they are calculated on 64 bit systems */
static short *typelens_64;
/** at sp = structs[a] is the first address of a struct definition
* sp[0] is type number
* sp[1] is amount of elements
* sp[2] sp[3] is typenr, namenr (etc) */
static short **structs, *structdata;
/**
* Variable to control debug output of makesdna.
* debugSDNA:
@@ -827,7 +833,8 @@ static int calculate_structlens(int firststruct)
}
else if (cp[0] == '[') {
/* parsing can cause names "var" and "[3]" to be found for "float var [3]" ... */
/* parsing can cause names "var" and "[3]"
* to be found for "float var [3]" */
fprintf(stderr, "Parse error in struct, invalid member name: %s %s\n",
types[structtype], cp);
dna_error = 1;