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

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Eisel <julian@blender.org>2022-07-20 16:42:48 +0300
committerJulian Eisel <julian@blender.org>2022-07-20 16:42:48 +0300
commit0f8e58e7b8eeecd00e3ac85bb2414fc175dd0933 (patch)
tree65d29fc1692bdcfdddad93e62d4f7c9849e1b6eb /source/blender/makesdna
parent6fc388743dffd9d297210790584f0fbab2c5d6e1 (diff)
parent4ffee9a48d1bc01442e554d44a1f55dfc459a221 (diff)
Merge commit 'c355be6faeac~1' into asset-browser-grid-view
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r--source/blender/makesdna/DNA_brush_enums.h11
-rw-r--r--source/blender/makesdna/DNA_brush_types.h7
-rw-r--r--source/blender/makesdna/DNA_collection_types.h4
-rw-r--r--source/blender/makesdna/DNA_constraint_types.h7
-rw-r--r--source/blender/makesdna/DNA_gpencil_modifier_defaults.h8
-rw-r--r--source/blender/makesdna/DNA_gpencil_modifier_types.h40
-rw-r--r--source/blender/makesdna/DNA_ipo_types.h2
-rw-r--r--source/blender/makesdna/DNA_layer_types.h1
-rw-r--r--source/blender/makesdna/DNA_light_types.h2
-rw-r--r--source/blender/makesdna/DNA_lineart_types.h17
-rw-r--r--source/blender/makesdna/DNA_mask_types.h3
-rw-r--r--source/blender/makesdna/DNA_material_types.h7
-rw-r--r--source/blender/makesdna/DNA_node_types.h15
-rw-r--r--source/blender/makesdna/DNA_object_types.h5
-rw-r--r--source/blender/makesdna/DNA_scene_defaults.h2
-rw-r--r--source/blender/makesdna/DNA_scene_types.h56
-rw-r--r--source/blender/makesdna/DNA_sequence_types.h15
-rw-r--r--source/blender/makesdna/DNA_space_defaults.h3
-rw-r--r--source/blender/makesdna/DNA_space_types.h5
-rw-r--r--source/blender/makesdna/DNA_texture_types.h3
-rw-r--r--source/blender/makesdna/DNA_windowmanager_types.h15
21 files changed, 167 insertions, 61 deletions
diff --git a/source/blender/makesdna/DNA_brush_enums.h b/source/blender/makesdna/DNA_brush_enums.h
index f2cd49b6dea..adda23c26f2 100644
--- a/source/blender/makesdna/DNA_brush_enums.h
+++ b/source/blender/makesdna/DNA_brush_enums.h
@@ -469,6 +469,11 @@ typedef enum eBrushCurvesSculptTool {
CURVES_SCULPT_TOOL_ADD = 3,
CURVES_SCULPT_TOOL_GROW_SHRINK = 4,
CURVES_SCULPT_TOOL_SELECTION_PAINT = 5,
+ CURVES_SCULPT_TOOL_PINCH = 6,
+ CURVES_SCULPT_TOOL_SMOOTH = 7,
+ CURVES_SCULPT_TOOL_PUFF = 8,
+ CURVES_SCULPT_TOOL_DENSITY = 9,
+ CURVES_SCULPT_TOOL_SLIDE = 10,
} eBrushCurvesSculptTool;
/** When #BRUSH_ACCUMULATE is used */
@@ -622,6 +627,12 @@ typedef enum eBrushCurvesSculptFlag {
BRUSH_CURVES_SCULPT_FLAG_INTERPOLATE_POINT_COUNT = (1 << 4),
} eBrushCurvesSculptFlag;
+typedef enum eBrushCurvesSculptDensityMode {
+ BRUSH_CURVES_SCULPT_DENSITY_MODE_AUTO = 0,
+ BRUSH_CURVES_SCULPT_DENSITY_MODE_ADD = 1,
+ BRUSH_CURVES_SCULPT_DENSITY_MODE_REMOVE = 2,
+} eBrushCurvesSculptDensityMode;
+
#define MAX_BRUSH_PIXEL_RADIUS 500
#define GP_MAX_BRUSH_PIXEL_RADIUS 1000
diff --git a/source/blender/makesdna/DNA_brush_types.h b/source/blender/makesdna/DNA_brush_types.h
index d13496b21f7..b24bb786593 100644
--- a/source/blender/makesdna/DNA_brush_types.h
+++ b/source/blender/makesdna/DNA_brush_types.h
@@ -148,6 +148,13 @@ typedef struct BrushCurvesSculptSettings {
float minimum_length;
/** Length of newly added curves when it is not interpolated from other curves. */
float curve_length;
+ /** Minimum distance between curve root points used by the Density brush. */
+ float minimum_distance;
+ /** How often the Density brush tries to add a new curve. */
+ int density_add_attempts;
+ /** #eBrushCurvesSculptDensityMode. */
+ uint8_t density_mode;
+ char _pad[7];
} BrushCurvesSculptSettings;
typedef struct Brush {
diff --git a/source/blender/makesdna/DNA_collection_types.h b/source/blender/makesdna/DNA_collection_types.h
index 8c437d69028..26011c990d4 100644
--- a/source/blender/makesdna/DNA_collection_types.h
+++ b/source/blender/makesdna/DNA_collection_types.h
@@ -40,6 +40,7 @@ enum eCollectionLineArt_Usage {
enum eCollectionLineArt_Flags {
COLLECTION_LRT_USE_INTERSECTION_MASK = (1 << 0),
+ COLLECTION_LRT_USE_INTERSECTION_PRIORITY = (1 << 1),
};
typedef struct Collection {
@@ -62,7 +63,8 @@ typedef struct Collection {
short lineart_usage; /* eCollectionLineArt_Usage */
unsigned char lineart_flags; /* eCollectionLineArt_Flags */
unsigned char lineart_intersection_mask;
- char _pad[6];
+ unsigned char lineart_intersection_priority;
+ char _pad[5];
int16_t color_tag;
diff --git a/source/blender/makesdna/DNA_constraint_types.h b/source/blender/makesdna/DNA_constraint_types.h
index 6557f35970d..8e0ce68f71a 100644
--- a/source/blender/makesdna/DNA_constraint_types.h
+++ b/source/blender/makesdna/DNA_constraint_types.h
@@ -105,8 +105,10 @@ typedef struct bConstraintTarget {
/* bConstraintTarget -> flag */
typedef enum eConstraintTargetFlag {
- /** 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),
+ /** Temporary target for the custom space reference. */
+ CONSTRAINT_TAR_CUSTOM_SPACE = (1 << 1),
} eConstraintTargetFlag;
/* bConstraintTarget/bConstraintOb -> type */
@@ -247,10 +249,9 @@ typedef struct bArmatureConstraint {
typedef struct bTrackToConstraint {
struct Object *tar;
/**
- * I'll be using reserved1 and reserved2 as Track and Up flags,
+ * NOTE(@theeth): I'll be using reserved1 and reserved2 as Track and Up flags,
* not sure if that's what they were intended for anyway.
* Not sure either if it would create backward incompatibility if I were to rename them.
- * - theeth
*/
int reserved1;
int reserved2;
diff --git a/source/blender/makesdna/DNA_gpencil_modifier_defaults.h b/source/blender/makesdna/DNA_gpencil_modifier_defaults.h
index ae47bf5d524..324252ca369 100644
--- a/source/blender/makesdna/DNA_gpencil_modifier_defaults.h
+++ b/source/blender/makesdna/DNA_gpencil_modifier_defaults.h
@@ -296,7 +296,7 @@
#define _DNA_DEFAULT_LineartGpencilModifierData \
{ \
- .edge_types = LRT_EDGE_FLAG_ALL_TYPE, \
+ .edge_types = LRT_EDGE_FLAG_INIT_TYPE, \
.thickness = 25, \
.opacity = 1.0f, \
.flags = LRT_GPENCIL_MATCH_OUTPUT_VGROUP, \
@@ -306,8 +306,12 @@
/* Do not split by default, this is for better chaining quality. */ \
.angle_splitting_threshold = 0.0f, \
.chaining_image_threshold = 0.001f, \
- .chain_smooth_tolerance = 0.2f,\
.stroke_depth_offset = 0.05,\
+ .chain_smooth_tolerance = 0.0f,\
+ .overscan = 0.1f,\
+ .shadow_camera_near = 0.1f, \
+ .shadow_camera_far = 200.0f, \
+ .shadow_camera_size = 200.0f, \
}
#define _DNA_DEFAULT_LengthGpencilModifierData \
diff --git a/source/blender/makesdna/DNA_gpencil_modifier_types.h b/source/blender/makesdna/DNA_gpencil_modifier_types.h
index 56963bae3e1..2bb95caddfb 100644
--- a/source/blender/makesdna/DNA_gpencil_modifier_types.h
+++ b/source/blender/makesdna/DNA_gpencil_modifier_types.h
@@ -998,6 +998,18 @@ typedef enum eLineartGpencilModifierSource {
LRT_SOURCE_SCENE = 2,
} eLineartGpencilModifierSource;
+typedef enum eLineartGpencilModifierShadowFilter {
+ LRT_SHADOW_FILTER_NONE = 0,
+ LRT_SHADOW_FILTER_LIT = 1,
+ LRT_SHADOW_FILTER_SHADED = 2,
+} eLineartGpencilModifierShadowFilter;
+
+typedef enum eLineartGpencilModifierSilhouetteFilter {
+ LRT_SILHOUETTE_FILTER_NONE = 0,
+ LRT_SILHOUETTE_FILTER_GROUP = (1 << 0),
+ LRT_SILHOUETTE_FILTER_INDIVIDUAL = (1 << 1),
+} eLineartGpencilModifierSilhouetteFilter;
+
/* This enum is for modifier internal state only. */
typedef enum eLineArtGPencilModifierFlags {
/* These two moved to #eLineartMainFlags to keep consistent with flag variable purpose. */
@@ -1008,6 +1020,7 @@ typedef enum eLineArtGPencilModifierFlags {
LRT_GPENCIL_USE_CACHE = (1 << 4),
LRT_GPENCIL_OFFSET_TOWARDS_CUSTOM_CAMERA = (1 << 5),
LRT_GPENCIL_INVERT_COLLECTION = (1 << 6),
+ LRT_GPENCIL_INVERT_SILHOUETTE_FILTER = (1 << 7),
} eLineArtGPencilModifierFlags;
typedef enum eLineartGpencilMaskSwitches {
@@ -1024,8 +1037,7 @@ struct LineartCache;
typedef struct LineartGpencilModifierData {
GpencilModifierData modifier;
- /** Line type enable flags, bits in #eLineartEdgeFlag. */
- short edge_types;
+ uint16_t edge_types; /* line type enable flags, bits in eLineartEdgeFlag */
/** Object or Collection, from #eLineartGpencilModifierSource. */
char source_type;
@@ -1035,6 +1047,7 @@ typedef struct LineartGpencilModifierData {
short level_end;
struct Object *source_camera;
+ struct Object *light_contour_object;
struct Object *source_object;
struct Collection *source_collection;
@@ -1049,14 +1062,19 @@ typedef struct LineartGpencilModifierData {
char source_vertex_group[64];
char vgname[64];
- /**
- * Camera focal length is divided by `1 + overscan`, before calculation, which give a wider FOV,
+ /* Camera focal length is divided by (1 + over-scan), before calculation, which give a wider FOV,
* this doesn't change coordinates range internally (-1, 1), but makes the calculated frame
* bigger than actual output. This is for the easier shifting calculation. A value of 0.5 means
- * the "internal" focal length become 2/3 of the actual camera.
- */
+ * the "internal" focal length become 2/3 of the actual camera. */
float overscan;
+ /* Values for point light and directional (sun) light. */
+ /* For point light, fov always gonna be 120 deg horizontal, with 3 "cameras" covering 360 deg. */
+ float shadow_camera_fov;
+ float shadow_camera_size;
+ float shadow_camera_near;
+ float shadow_camera_far;
+
float opacity;
short thickness;
@@ -1064,7 +1082,9 @@ typedef struct LineartGpencilModifierData {
unsigned char material_mask_bits;
unsigned char intersection_mask;
- char _pad[3];
+ unsigned char shadow_selection;
+ unsigned char silhouette_selection;
+ char _pad[1];
/** `0..1` range for cosine angle */
float crease_threshold;
@@ -1078,7 +1098,7 @@ typedef struct LineartGpencilModifierData {
/* CPU mode */
float chaining_image_threshold;
- /* Ported from SceneLineArt flags. */
+ /* eLineartMainFlags, for one time calculation. */
int calculation_flags;
/* #eLineArtGPencilModifierFlags, modifier internal state. */
@@ -1095,6 +1115,10 @@ typedef struct LineartGpencilModifierData {
char level_start_override;
char level_end_override;
short edge_types_override;
+ char shadow_selection_override;
+ char shadow_use_silhouette_override;
+
+ char _pad2[6];
struct LineartCache *cache;
/* Keep a pointer to the render buffer so we can call destroy from ModifierData. */
diff --git a/source/blender/makesdna/DNA_ipo_types.h b/source/blender/makesdna/DNA_ipo_types.h
index 70ee7c99d01..ef35b72d2ab 100644
--- a/source/blender/makesdna/DNA_ipo_types.h
+++ b/source/blender/makesdna/DNA_ipo_types.h
@@ -338,7 +338,7 @@ typedef struct Ipo {
#define CAM_STA 2
#define CAM_END 3
-/* yafray aperture & focal distance curves */
+/* YAFRAY aperture & focal distance curves. */
#define CAM_YF_APERT 4
#define CAM_YF_FDIST 5
diff --git a/source/blender/makesdna/DNA_layer_types.h b/source/blender/makesdna/DNA_layer_types.h
index 4ee5f34fcde..0af50b2bd4f 100644
--- a/source/blender/makesdna/DNA_layer_types.h
+++ b/source/blender/makesdna/DNA_layer_types.h
@@ -35,6 +35,7 @@ typedef enum eViewLayerEEVEEPassType {
EEVEE_RENDER_PASS_BLOOM = (1 << 14),
EEVEE_RENDER_PASS_AOV = (1 << 15),
EEVEE_RENDER_PASS_CRYPTOMATTE = (1 << 16),
+ EEVEE_RENDER_PASS_VECTOR = (1 << 17),
} eViewLayerEEVEEPassType;
#define EEVEE_RENDER_PASS_MAX_BIT 17
diff --git a/source/blender/makesdna/DNA_light_types.h b/source/blender/makesdna/DNA_light_types.h
index 9202d7c2d51..f1bf0580b94 100644
--- a/source/blender/makesdna/DNA_light_types.h
+++ b/source/blender/makesdna/DNA_light_types.h
@@ -120,7 +120,7 @@ typedef struct Light {
/* #define LA_NO_DIFF (1 << 11) */ /* not used anywhere */
/* #define LA_NO_SPEC (1 << 12) */ /* not used anywhere */
/* #define LA_SHAD_RAY (1 << 13) */ /* not used anywhere - cleaned */
-/* yafray: light shadowbuffer flag, softlight */
+/* YAFRAY: light shadow-buffer flag, soft-light. */
/* Since it is used with LOCAL light, can't use LA_SHAD */
/* #define LA_YF_SOFT (1 << 14) */ /* not used anymore */
/* #define LA_LAYER_SHADOW (1 << 15) */ /* not used anymore */
diff --git a/source/blender/makesdna/DNA_lineart_types.h b/source/blender/makesdna/DNA_lineart_types.h
index 444a0e6f247..1ff656f85ed 100644
--- a/source/blender/makesdna/DNA_lineart_types.h
+++ b/source/blender/makesdna/DNA_lineart_types.h
@@ -38,6 +38,8 @@ typedef enum eLineartMainFlags {
LRT_USE_BACK_FACE_CULLING = (1 << 19),
LRT_USE_IMAGE_BOUNDARY_TRIMMING = (1 << 20),
LRT_CHAIN_PRESERVE_DETAILS = (1 << 22),
+ LRT_SHADOW_ENCLOSED_SHAPES = (1 << 23),
+ LRT_SHADOW_USE_SILHOUETTE = (1 << 24),
} eLineartMainFlags;
typedef enum eLineartEdgeFlag {
@@ -47,14 +49,21 @@ typedef enum eLineartEdgeFlag {
LRT_EDGE_FLAG_MATERIAL = (1 << 3),
LRT_EDGE_FLAG_INTERSECTION = (1 << 4),
LRT_EDGE_FLAG_LOOSE = (1 << 5),
+ LRT_EDGE_FLAG_LIGHT_CONTOUR = (1 << 6),
/* LRT_EDGE_FLAG_FOR_FUTURE = (1 << 7), */
/**
* It's a legacy limit of 8 bits for feature lines that come from original mesh edges. It should
* not be needed in current object loading scheme, but might still be relevant if we are to
* implement edit-mesh loading, so don't exceed 8 bits just yet.
*/
- LRT_EDGE_FLAG_CHAIN_PICKED = (1 << 8),
- LRT_EDGE_FLAG_CLIPPED = (1 << 9),
+ LRT_EDGE_FLAG_PROJECTED_SHADOW = (1 << 8),
+ /* To determine an edge to be occluded from the front or back face it's lying on. */
+ LRT_EDGE_FLAG_SHADOW_FACING_LIGHT = (1 << 9),
+ /** Also used as discarded line mark. */
+ LRT_EDGE_FLAG_CHAIN_PICKED = (1 << 10),
+ LRT_EDGE_FLAG_CLIPPED = (1 << 11),
+ /** Used to specify contour from viewing camera when computing shadows. */
+ LRT_EDGE_FLAG_CONTOUR_SECONDARY = (1 << 12),
/** Limited to 16 bits for the entire thing. */
/** For object loading code to use only. */
@@ -63,4 +72,6 @@ typedef enum eLineartEdgeFlag {
LRT_EDGE_FLAG_NEXT_IS_DUPLICATION = (1 << 15),
} eLineartEdgeFlag;
-#define LRT_EDGE_FLAG_ALL_TYPE 0x3f
+#define LRT_EDGE_FLAG_ALL_TYPE 0x01ff
+#define LRT_EDGE_FLAG_INIT_TYPE 0x37 /* Without material & light contour */
+#define LRT_EDGE_FLAG_TYPE_MAX_BITS 7
diff --git a/source/blender/makesdna/DNA_mask_types.h b/source/blender/makesdna/DNA_mask_types.h
index 8efcef5addf..fbbcd340ae9 100644
--- a/source/blender/makesdna/DNA_mask_types.h
+++ b/source/blender/makesdna/DNA_mask_types.h
@@ -196,8 +196,9 @@ enum {
#define MASK_HIDE_RENDER (1 << 2)
/* SpaceClip->mask_draw_flag */
-#define MASK_DRAWFLAG_SMOOTH (1 << 0)
+/* #define MASK_DRAWFLAG_SMOOTH_DEPRECATED (1 << 0) */ /* Deprecated */
#define MASK_DRAWFLAG_OVERLAY (1 << 1)
+#define MASK_DRAWFLAG_SPLINE (1 << 2)
/* copy of eSpaceImage_UVDT */
/* SpaceClip->mask_draw_type */
diff --git a/source/blender/makesdna/DNA_material_types.h b/source/blender/makesdna/DNA_material_types.h
index 332317142c7..460670225c8 100644
--- a/source/blender/makesdna/DNA_material_types.h
+++ b/source/blender/makesdna/DNA_material_types.h
@@ -150,14 +150,15 @@ typedef struct MaterialLineArt {
/** Maximum 255 levels of equivalent occlusion. */
unsigned char mat_occlusion;
- unsigned char _pad[2];
+ unsigned char intersection_priority;
+
+ char _pad;
} MaterialLineArt;
typedef enum eMaterialLineArtFlags {
LRT_MATERIAL_MASK_ENABLED = (1 << 0),
-
- /* Deprecated, kept for versioning code. */
LRT_MATERIAL_CUSTOM_OCCLUSION_EFFECTIVENESS = (1 << 1),
+ LRT_MATERIAL_CUSTOM_INTERSECTION_PRIORITY = (1 << 2),
} eMaterialLineArtFlags;
typedef struct Material {
diff --git a/source/blender/makesdna/DNA_node_types.h b/source/blender/makesdna/DNA_node_types.h
index 25c8a1f1514..76d8207eead 100644
--- a/source/blender/makesdna/DNA_node_types.h
+++ b/source/blender/makesdna/DNA_node_types.h
@@ -1248,6 +1248,11 @@ typedef struct NodeGeometryVolumeToMesh {
uint8_t resolution_mode;
} NodeGeometryVolumeToMesh;
+typedef struct NodeGeometryMeshToVolume {
+ /* MeshToVolumeModifierResolutionMode */
+ uint8_t resolution_mode;
+} NodeGeometryMeshToVolume;
+
typedef struct NodeGeometrySubdivisionSurface {
/* eSubsurfUVSmooth. */
uint8_t uv_smooth;
@@ -1450,6 +1455,11 @@ typedef struct NodeGeometryViewer {
int8_t data_type;
} NodeGeometryViewer;
+typedef struct NodeGeometryUVUnwrap {
+ /* GeometryNodeUVUnwrapMethod. */
+ uint8_t method;
+} NodeGeometryUVUnwrap;
+
typedef struct NodeFunctionCompare {
/* NodeCompareOperation */
int8_t operation;
@@ -2000,6 +2010,11 @@ typedef enum GeometryNodeMergeByDistanceMode {
GEO_NODE_MERGE_BY_DISTANCE_MODE_CONNECTED = 1,
} GeometryNodeMergeByDistanceMode;
+typedef enum GeometryNodeUVUnwrapMethod {
+ GEO_NODE_UV_UNWRAP_METHOD_ANGLE_BASED = 0,
+ GEO_NODE_UV_UNWRAP_METHOD_CONFORMAL = 1,
+} GeometryNodeUVUnwrapMethod;
+
typedef enum GeometryNodeMeshLineMode {
GEO_NODE_MESH_LINE_MODE_END_POINTS = 0,
GEO_NODE_MESH_LINE_MODE_OFFSET = 1,
diff --git a/source/blender/makesdna/DNA_object_types.h b/source/blender/makesdna/DNA_object_types.h
index 698fbe8ee8f..db56c79de4e 100644
--- a/source/blender/makesdna/DNA_object_types.h
+++ b/source/blender/makesdna/DNA_object_types.h
@@ -215,6 +215,10 @@ typedef struct ObjectLineArt {
/** if OBJECT_LRT_OWN_CREASE is set */
float crease_threshold;
+
+ unsigned char intersection_priority;
+
+ char _pad[7];
} ObjectLineArt;
/**
@@ -231,6 +235,7 @@ enum eObjectLineArt_Usage {
enum eObjectLineArt_Flags {
OBJECT_LRT_OWN_CREASE = (1 << 0),
+ OBJECT_LRT_OWN_INTERSECTION_PRIORITY = (1 << 1),
};
typedef struct Object {
diff --git a/source/blender/makesdna/DNA_scene_defaults.h b/source/blender/makesdna/DNA_scene_defaults.h
index 74db1d14bbc..6cc01d254ce 100644
--- a/source/blender/makesdna/DNA_scene_defaults.h
+++ b/source/blender/makesdna/DNA_scene_defaults.h
@@ -337,7 +337,9 @@
.snap_mode = SCE_SNAP_MODE_INCREMENT, \
.snap_node_mode = SCE_SNAP_MODE_GRID, \
.snap_uv_mode = SCE_SNAP_MODE_INCREMENT, \
+ .snap_flag = SCE_SNAP_TO_INCLUDE_EDITED | SCE_SNAP_TO_INCLUDE_NONEDITED, \
.snap_transform_mode_flag = SCE_SNAP_TRANSFORM_MODE_TRANSLATE, \
+ .snap_face_nearest_steps = 1, \
\
.curve_paint_settings = _DNA_DEFAULTS_CurvePaintSettings, \
\
diff --git a/source/blender/makesdna/DNA_scene_types.h b/source/blender/makesdna/DNA_scene_types.h
index 1c62a550e60..f8fcd78d63b 100644
--- a/source/blender/makesdna/DNA_scene_types.h
+++ b/source/blender/makesdna/DNA_scene_types.h
@@ -1496,19 +1496,24 @@ typedef struct ToolSettings {
char transform_pivot_point;
char transform_flag;
/** Snap elements (per spacetype), #eSnapMode. */
- char snap_mode;
+ char _pad1[1];
+ short snap_mode;
char snap_node_mode;
char snap_uv_mode;
/** Generic flags (per spacetype), #eSnapFlag. */
- char snap_flag;
- char snap_flag_node;
- char snap_flag_seq;
- char snap_uv_flag;
+ short snap_flag;
+ short snap_flag_node;
+ short snap_flag_seq;
+ short snap_uv_flag;
/** Default snap source, #eSnapSourceSelect. */
- /* TODO(@gfxcoder): Rename `snap_target` to `snap_source_point`, because target is incorrect. */
+ /* TODO(@gfxcoder): Rename `snap_target` to `snap_source` to avoid previous ambiguity of
+ * "target" (now, "source" is geometry to be moved and "target" is geometry to which moved
+ * geometry is snapped). */
char snap_target;
/** Snap mask for transform modes, #eSnapTransformMode. */
char snap_transform_mode_flag;
+ /** Steps to break transformation into with face nearest snapping */
+ short snap_face_nearest_steps;
char proportional_edit, prop_mode;
/** Proportional edit, object mode. */
@@ -2049,10 +2054,6 @@ extern const char *RE_engine_id_CYCLES;
#define V3D_CAMERA_SCENE(scene, v3d) \
((!(v3d)->scenelock && (v3d)->camera) ? (v3d)->camera : (scene)->camera)
-#define CFRA (scene->r.cfra)
-#define SUBFRA (scene->r.subframe)
-#define SFRA (scene->r.sfra)
-#define EFRA (scene->r.efra)
#define PRVRANGEON (scene->r.flag & SCER_PRV_RANGE)
#define PSFRA ((PRVRANGEON) ? (scene->r.psfra) : (scene->r.sfra))
#define PEFRA ((PRVRANGEON) ? (scene->r.pefra) : (scene->r.efra))
@@ -2085,10 +2086,15 @@ typedef enum eSnapFlag {
SCE_SNAP = (1 << 0),
SCE_SNAP_ROTATE = (1 << 1),
SCE_SNAP_PEEL_OBJECT = (1 << 2),
- SCE_SNAP_PROJECT = (1 << 3),
- SCE_SNAP_NO_SELF = (1 << 4),
+ SCE_SNAP_PROJECT = (1 << 3), /* Project individual elements instead of whole object. */
+ SCE_SNAP_NOT_TO_ACTIVE = (1 << 4), /* Was `SCE_SNAP_NO_SELF`, but self should be active. */
SCE_SNAP_ABS_GRID = (1 << 5),
SCE_SNAP_BACKFACE_CULLING = (1 << 6),
+ SCE_SNAP_KEEP_ON_SAME_OBJECT = (1 << 7),
+ /* see #eSnapTargetSelect */
+ SCE_SNAP_TO_INCLUDE_EDITED = (1 << 8),
+ SCE_SNAP_TO_INCLUDE_NONEDITED = (1 << 9),
+ SCE_SNAP_TO_ONLY_SELECTABLE = (1 << 10),
} eSnapFlag;
/* Due to dependency conflicts with Cycles, header cannot directly include `BLI_utildefines.h`. */
/* TODO: move this macro to a more general place. */
@@ -2096,7 +2102,7 @@ typedef enum eSnapFlag {
ENUM_OPERATORS(eSnapFlag, SCE_SNAP_BACKFACE_CULLING)
#endif
-/** #ToolSettings.snap_target and #TransSnap.source_select */
+/** See #ToolSettings.snap_target (to be renamed `snap_source`) and #TransSnap.source_select */
typedef enum eSnapSourceSelect {
SCE_SNAP_SOURCE_CLOSEST = 0,
SCE_SNAP_SOURCE_CENTER = 1,
@@ -2104,13 +2110,15 @@ typedef enum eSnapSourceSelect {
SCE_SNAP_SOURCE_ACTIVE = 3,
} eSnapSourceSelect;
-/** #TransSnap.target_select and #ToolSettings.snap_flag (SCE_SNAP_NO_SELF) */
+/** #TransSnap.target_select and #ToolSettings.snap_flag (#SCE_SNAP_NOT_TO_ACTIVE,
+ * #SCE_SNAP_TO_INCLUDE_EDITED, #SCE_SNAP_TO_INCLUDE_NONEDITED, #SCE_SNAP_TO_ONLY_SELECTABLE) */
typedef enum eSnapTargetSelect {
SCE_SNAP_TARGET_ALL = 0,
- SCE_SNAP_TARGET_NOT_SELECTED = 1,
- SCE_SNAP_TARGET_NOT_ACTIVE = 2,
- SCE_SNAP_TARGET_NOT_EDITED = 3,
- SCE_SNAP_TARGET_ONLY_SELECTABLE = 4,
+ SCE_SNAP_TARGET_NOT_SELECTED = (1 << 0),
+ SCE_SNAP_TARGET_NOT_ACTIVE = (1 << 1),
+ SCE_SNAP_TARGET_NOT_EDITED = (1 << 2),
+ SCE_SNAP_TARGET_ONLY_SELECTABLE = (1 << 3),
+ SCE_SNAP_TARGET_NOT_NONEDITED = (1 << 4),
} eSnapTargetSelect;
/** #ToolSettings.snap_mode */
@@ -2118,19 +2126,21 @@ typedef enum eSnapMode {
SCE_SNAP_MODE_NONE = 0,
SCE_SNAP_MODE_VERTEX = (1 << 0),
SCE_SNAP_MODE_EDGE = (1 << 1),
- SCE_SNAP_MODE_FACE = (1 << 2), /* TODO(@gfxcoder): Rename to `SCE_SNAP_MODE_FACE_RAYCAST`
- when other face snapping methods are added. */
+ SCE_SNAP_MODE_FACE_RAYCAST = (1 << 2),
SCE_SNAP_MODE_VOLUME = (1 << 3),
SCE_SNAP_MODE_EDGE_MIDPOINT = (1 << 4),
SCE_SNAP_MODE_EDGE_PERPENDICULAR = (1 << 5),
- SCE_SNAP_MODE_GEOM = (SCE_SNAP_MODE_VERTEX | SCE_SNAP_MODE_EDGE | SCE_SNAP_MODE_FACE |
- SCE_SNAP_MODE_EDGE_PERPENDICULAR | SCE_SNAP_MODE_EDGE_MIDPOINT),
+ SCE_SNAP_MODE_FACE_NEAREST = (1 << 8),
+
+ SCE_SNAP_MODE_GEOM = (SCE_SNAP_MODE_VERTEX | SCE_SNAP_MODE_EDGE | SCE_SNAP_MODE_FACE_RAYCAST |
+ SCE_SNAP_MODE_EDGE_PERPENDICULAR | SCE_SNAP_MODE_EDGE_MIDPOINT |
+ SCE_SNAP_MODE_FACE_NEAREST),
/** #ToolSettings.snap_node_mode */
SCE_SNAP_MODE_NODE_X = (1 << 0),
SCE_SNAP_MODE_NODE_Y = (1 << 1),
- /* #ToolSettings.snap_mode and #ToolSettings.snap_node_mode and #ToolSettings.snap_uv_mode */
+ /** #ToolSettings.snap_mode and #ToolSettings.snap_node_mode and #ToolSettings.snap_uv_mode */
SCE_SNAP_MODE_INCREMENT = (1 << 6),
SCE_SNAP_MODE_GRID = (1 << 7),
} eSnapMode;
diff --git a/source/blender/makesdna/DNA_sequence_types.h b/source/blender/makesdna/DNA_sequence_types.h
index db24a775edb..a46d737ba9d 100644
--- a/source/blender/makesdna/DNA_sequence_types.h
+++ b/source/blender/makesdna/DNA_sequence_types.h
@@ -151,17 +151,17 @@ typedef struct Sequence {
* Start frame of contents of strip in absolute frame coordinates.
* For metastrips start of first strip startdisp.
*/
- int start;
+ float start;
/**
* Frames after the first frame where display starts,
* frames before the last frame where display ends.
*/
- int startofs, endofs;
+ float startofs, endofs;
/**
* Frames that use the first frame before data begins,
* frames that use the last frame after data ends.
*/
- int startstill, endstill;
+ float startstill, endstill;
/** Machine: the strip channel */
int machine;
int _pad3;
@@ -213,7 +213,7 @@ typedef struct Sequence {
float volume;
/** Pitch (-0.1..10), pan -2..2. */
- float pitch, pan;
+ float pitch DNA_DEPRECATED, pan;
float strobe;
/** Struct pointer for effect settings. */
@@ -249,6 +249,11 @@ typedef struct Sequence {
/* modifiers */
ListBase modifiers;
+ /* Playback rate of strip content in frames per second. */
+ float media_playback_rate;
+ /* Multiply strip playback speed. */
+ float speed_factor;
+
SequenceRuntime runtime;
} Sequence;
@@ -563,7 +568,7 @@ enum {
SEQ_LOCK = (1 << 14),
SEQ_USE_PROXY = (1 << 15),
SEQ_IGNORE_CHANNEL_LOCK = (1 << 16),
- SEQ_FLAG_UNUSED_22 = (1 << 17), /* cleared */
+ SEQ_AUTO_PLAYBACK_RATE = (1 << 17),
SEQ_FLAG_UNUSED_18 = (1 << 18), /* cleared */
SEQ_FLAG_UNUSED_19 = (1 << 19), /* cleared */
SEQ_FLAG_UNUSED_21 = (1 << 21), /* cleared */
diff --git a/source/blender/makesdna/DNA_space_defaults.h b/source/blender/makesdna/DNA_space_defaults.h
index e826cb4c2ef..6193c8c2ad1 100644
--- a/source/blender/makesdna/DNA_space_defaults.h
+++ b/source/blender/makesdna/DNA_space_defaults.h
@@ -15,9 +15,10 @@
#define _DNA_DEFAULT_MaskSpaceInfo \
{ \
- .draw_flag = 0, \
+ .draw_flag = MASK_DRAWFLAG_SPLINE, \
.draw_type = MASK_DT_OUTLINE, \
.overlay_mode = MASK_OVERLAY_ALPHACHANNEL, \
+ .blend_factor = 0.7f, \
}
#define _DNA_DEFAULT_SpaceClip \
diff --git a/source/blender/makesdna/DNA_space_types.h b/source/blender/makesdna/DNA_space_types.h
index f701a550296..61ccd45c23a 100644
--- a/source/blender/makesdna/DNA_space_types.h
+++ b/source/blender/makesdna/DNA_space_types.h
@@ -732,7 +732,8 @@ typedef struct MaskSpaceInfo {
char draw_flag;
char draw_type;
char overlay_mode;
- char _pad3[5];
+ char _pad3[1];
+ float blend_factor;
} MaskSpaceInfo;
/** #SpaceSeq.gizmo_flag */
@@ -1970,7 +1971,7 @@ typedef struct SpreadsheetRowFilter {
float value_float2[2];
float value_float3[3];
float value_color[4];
- uint8_t value_byte_color[4];
+ char _pad1[4];
} SpreadsheetRowFilter;
typedef enum eSpaceSpreadsheet_RowFilterFlag {
diff --git a/source/blender/makesdna/DNA_texture_types.h b/source/blender/makesdna/DNA_texture_types.h
index b725939dbab..e32d9dbe300 100644
--- a/source/blender/makesdna/DNA_texture_types.h
+++ b/source/blender/makesdna/DNA_texture_types.h
@@ -397,8 +397,7 @@ typedef struct ColorMapping {
/* return value */
#define TEX_INT 0
-#define TEX_RGB (1 << 0)
-#define TEX_NOR (1 << 1)
+#define TEX_RGB 1
/* pr_texture in material, world, light. */
#define TEX_PR_TEXTURE 0
diff --git a/source/blender/makesdna/DNA_windowmanager_types.h b/source/blender/makesdna/DNA_windowmanager_types.h
index cfd0c986df9..f7aaa1186db 100644
--- a/source/blender/makesdna/DNA_windowmanager_types.h
+++ b/source/blender/makesdna/DNA_windowmanager_types.h
@@ -463,14 +463,19 @@ typedef struct wmKeyMap {
/** #wmKeyMap.flag */
enum {
- KEYMAP_MODAL = (1 << 0), /* modal map, not using operatornames */
- KEYMAP_USER = (1 << 1), /* user keymap */
+ /** Modal map, not using operator-names. */
+ KEYMAP_MODAL = (1 << 0),
+ /** User key-map. */
+ KEYMAP_USER = (1 << 1),
KEYMAP_EXPANDED = (1 << 2),
KEYMAP_CHILDREN_EXPANDED = (1 << 3),
- KEYMAP_DIFF = (1 << 4), /* diff keymap for user preferences */
- KEYMAP_USER_MODIFIED = (1 << 5), /* keymap has user modifications */
+ /** Diff key-map for user preferences. */
+ KEYMAP_DIFF = (1 << 4),
+ /** Key-map has user modifications. */
+ KEYMAP_USER_MODIFIED = (1 << 5),
KEYMAP_UPDATE = (1 << 6),
- KEYMAP_TOOL = (1 << 7), /* keymap for active tool system */
+ /** key-map for active tool system. */
+ KEYMAP_TOOL = (1 << 7),
};
/**