diff options
author | Matt Ebb <matt@mke3.net> | 2010-01-25 09:24:05 +0300 |
---|---|---|
committer | Matt Ebb <matt@mke3.net> | 2010-01-25 09:24:05 +0300 |
commit | 0c5998e7998cba70d1dceacc5ed8109a5bba9e23 (patch) | |
tree | f9e250055d9de1647b283e7c493902bc51f0a9a5 /source/blender/makesdna | |
parent | c94f385fce14fa5beb8637590ad4d4662cd733c6 (diff) |
Radians -> Degrees (in UI)
Rotations are now stored internally as radians, while exposing degrees in the UI -
in the graph editor and UI controls. This is done in two areas:
1) Using the unit system to convert RNA data to display as degrees in the UI controls
2) FCurves now use degrees for rotation, so you can edit in the graph editor what
you see in the UI.
All rotation data is consistently accessible in DNA and RNA as radians, degrees are only
used for the UI controls and graph editor.
This commit includes conversions will convert old files (stored data and also fcurve data)
to the new units, hopefully everything should go smoothly!
Part of this also changes a few properties that were hard-coded as degrees before (such
as IK pole angle and brush texture rotation) to also use the same consistent system of
radians (dna/rna) and degrees (ui).
Thanks to Joshua for hints and review here too.
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r-- | source/blender/makesdna/DNA_anim_types.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/makesdna/DNA_anim_types.h b/source/blender/makesdna/DNA_anim_types.h index d1fa4616cbc..8230c7b46d0 100644 --- a/source/blender/makesdna/DNA_anim_types.h +++ b/source/blender/makesdna/DNA_anim_types.h @@ -445,6 +445,9 @@ typedef enum eFCurve_Flags { FCURVE_INT_VALUES = (1<<11), /* curve can only have certain discrete-number values (no interpolation at all, for enums/booleans) */ FCURVE_DISCRETE_VALUES = (1<<12), + /* curve represents a rotation value stored internally in the curve in degrees */ + FCURVE_ROTATION_DEGREES = (1<<13), + } eFCurve_Flags; /* extrapolation modes (only simple value 'extending') */ |