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:
authorJoshua Leung <aligorith@gmail.com>2007-04-15 13:48:53 +0400
committerJoshua Leung <aligorith@gmail.com>2007-04-15 13:48:53 +0400
commit185a7799a051acdab8ad9a20f7213c3ab8fd6ea9 (patch)
tree86be2eb591b3313602406a2136525489b84b28e9 /source/blender/src/drawnla.c
parenta6113b005908778bebfead6356061b0df13a5ce4 (diff)
== NLA Editor - Auto-Blending for ActionStrips ==
This is just a little time-saver for NLA-workflow. With the 'Auto-Blending' option turned on in the Transform Properties (NKEY) for an ActionStrip, that strip's blendin/blendout values are determined based on the number of frames that the previous and/or next actionstrip(s) on overlap over the start and end of it. It is turned on by default for new actionstrips added using the Shift-N hotkey. Caveats: * Only the actionstrips immediately on either side of the strip being evaluated, will have any effect * A strip that is longer-than, and extends over the sides of the strip being evaluated, will have no effect Additional Notes: * Blendin/Blendout have been renamed In/Out in UI for brevity * Button layout in NLA Transform Properties has changed slightly again, but hopefully that shouldn't be too much of an issue.
Diffstat (limited to 'source/blender/src/drawnla.c')
-rw-r--r--source/blender/src/drawnla.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/source/blender/src/drawnla.c b/source/blender/src/drawnla.c
index 6704d360f96..5d9334e452b 100644
--- a/source/blender/src/drawnla.c
+++ b/source/blender/src/drawnla.c
@@ -579,8 +579,18 @@ static void nla_panel_properties(short cntrl) // NLA_HANDLER_PROPERTIES
}
uiBlockBeginAlign(block);
- uiDefButF(block, NUM, B_NLA_PANEL, "Blendin:", 10,100,145,19, &strip->blendin, 0.0, strip->end-strip->start, 100, 0, "Number of frames of ease-in");
- uiDefButF(block, NUM, B_NLA_PANEL, "Blendout:", 10,80,145,19, &strip->blendout, 0.0, strip->end-strip->start, 100, 0, "Number of frames of ease-out");
+ uiDefButBitS(block, TOG, ACTSTRIP_AUTO_BLENDS, B_NLA_LOCK, "Auto-Blending", 10,100,145,19, &(strip->flag), 0, 0, 0, 0, "Toggles automatic calculation of blendin/out values");
+ if (strip->flag & ACTSTRIP_AUTO_BLENDS) {
+ char str[32];
+ sprintf(str, "In: %.2f", strip->blendin);
+ uiDefBut(block, LABEL, B_NOP, str, 10,80,77,19, NULL, 0.0, 0.0, 0, 0, "Number of frames of ease-in");
+ sprintf(str, "Out: %.2f", strip->blendout);
+ uiDefBut(block, LABEL, B_NOP, str, 77,80,78,19, NULL, 0.0, 0.0, 0, 0, "Number of frames of ease-out");
+ }
+ else {
+ uiDefButF(block, NUM, B_NLA_PANEL, "In:", 10,80,77,19, &strip->blendin, 0.0, strip->end-strip->start, 100, 0, "Number of frames of ease-in");
+ uiDefButF(block, NUM, B_NLA_PANEL, "Out:", 77,80,78,19, &strip->blendout, 0.0, strip->end-strip->start, 100, 0, "Number of frames of ease-out");
+ }
uiDefButBitS(block, TOG, ACTSTRIP_MUTE, B_NLA_PANEL, "Mute", 10,60,145,19, &strip->flag, 0, 0, 0, 0, "Toggles whether the strip contributes to the NLA solution");
uiBlockBeginAlign(block);