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:
authorAlexander Gavrilov <angavrilov@gmail.com>2019-09-04 14:59:18 +0300
committerAlexander Gavrilov <angavrilov@gmail.com>2019-09-06 07:58:13 +0300
commitf8362836a5c8feff3715ca823025caba249208c2 (patch)
treec3406460a139947c4613b86e392a1f4ffb6a5e2d /source/blender/makesdna/DNA_constraint_types.h
parentf4056e9ec3a89afbc592af3e3d169d2d584a9937 (diff)
Copy Transforms: add a mixing mode option.
Allow combining location, rotation and scale at the same time, using one constraint. The mixing modes are based on matrix multiplication, but handle scale in a way that avoids creating shear. Reviewers: brecht Differential Revision: https://developer.blender.org/D5640
Diffstat (limited to 'source/blender/makesdna/DNA_constraint_types.h')
-rw-r--r--source/blender/makesdna/DNA_constraint_types.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/source/blender/makesdna/DNA_constraint_types.h b/source/blender/makesdna/DNA_constraint_types.h
index a7f900ddc9b..d123cf21db9 100644
--- a/source/blender/makesdna/DNA_constraint_types.h
+++ b/source/blender/makesdna/DNA_constraint_types.h
@@ -307,6 +307,8 @@ typedef struct bSameVolumeConstraint {
/* Copy Transform Constraint */
typedef struct bTransLikeConstraint {
struct Object *tar;
+ char mix_mode;
+ char _pad[7];
/** MAX_ID_NAME-2. */
char subtarget[64];
} bTransLikeConstraint;
@@ -790,6 +792,16 @@ typedef enum eCopyScale_Flags {
SIZELIKE_UNIFORM = (1 << 5),
} eCopyScale_Flags;
+/* bTransLikeConstraint.mix_mode */
+typedef enum eCopyTransforms_MixMode {
+ /* Replace rotation channel values. */
+ TRANSLIKE_MIX_REPLACE = 0,
+ /* Multiply the copied transformation on the left, with anti-shear scale handling. */
+ TRANSLIKE_MIX_BEFORE,
+ /* Multiply the copied transformation on the right, with anti-shear scale handling. */
+ TRANSLIKE_MIX_AFTER,
+} eCopyTransforms_MixMode;
+
/* bTransformConstraint.to/from */
typedef enum eTransform_ToFrom {
TRANS_LOCATION = 0,