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:
authorJacques Lucke <jacques@blender.org>2021-02-05 18:10:54 +0300
committerJacques Lucke <jacques@blender.org>2021-02-05 18:10:54 +0300
commit46e0efb462cb92e9ade39588b51391820491aed8 (patch)
tree7b109ecbe04d9a1f0c7f35b44a83558a76818a55 /source/blender/makesdna
parent56903024dccd0e5ae4fae40925348416f989144b (diff)
Geometry Nodes: support fixed pivot axis in Align Rotation to Vector node
When the pivot axis is not set to auto, the node will try to align the rotation to vector as best as possible, given the selected rotation axis. Ref T85211. Differential Revision: https://developer.blender.org/D10292
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r--source/blender/makesdna/DNA_node_types.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/source/blender/makesdna/DNA_node_types.h b/source/blender/makesdna/DNA_node_types.h
index edab43c752e..73b6a1b66c6 100644
--- a/source/blender/makesdna/DNA_node_types.h
+++ b/source/blender/makesdna/DNA_node_types.h
@@ -1148,12 +1148,12 @@ typedef struct NodeGeometryRotatePoints {
typedef struct NodeGeometryAlignRotationToVector {
/* GeometryNodeAlignRotationToVectorAxis */
uint8_t axis;
+ /* GeometryNodeAlignRotationToVectorPivotAxis */
+ uint8_t pivot_axis;
/* GeometryNodeAttributeInputMode */
uint8_t input_type_factor;
uint8_t input_type_vector;
-
- char _pad[5];
} NodeGeometryAlignRotationToVector;
typedef struct NodeGeometryPointScale {
@@ -1660,6 +1660,13 @@ typedef enum GeometryNodeAlignRotationToVectorAxis {
GEO_NODE_ALIGN_ROTATION_TO_VECTOR_AXIS_Z = 2,
} GeometryNodeAlignRotationToVectorAxis;
+typedef enum GeometryNodeAlignRotationToVectorPivotAxis {
+ GEO_NODE_ALIGN_ROTATION_TO_VECTOR_PIVOT_AXIS_AUTO = 0,
+ GEO_NODE_ALIGN_ROTATION_TO_VECTOR_PIVOT_AXIS_X = 1,
+ GEO_NODE_ALIGN_ROTATION_TO_VECTOR_PIVOT_AXIS_Y = 2,
+ GEO_NODE_ALIGN_ROTATION_TO_VECTOR_PIVOT_AXIS_Z = 3,
+} GeometryNodeAlignRotationToVectorPivotAxis;
+
typedef enum GeometryNodeTransformSpace {
GEO_NODE_TRANSFORM_SPACE_ORIGINAL = 0,
GEO_NODE_TRANSFORM_SPACE_RELATIVE = 1,