[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [21328] branches/soc-2009-aligorith/source /blender/editors: NLA SoC: Added buttons for animating NLA-Strip Influence/ Speed
Joshua Leung
aligorith at gmail.com
Fri Jul 3 01:36:16 CEST 2009
Revision: 21328
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=21328
Author: aligorith
Date: 2009-07-03 01:36:16 +0200 (Fri, 03 Jul 2009)
Log Message:
-----------
NLA SoC: Added buttons for animating NLA-Strip Influence/Speed
These buttons are found in the Evaluation panel, but are currently disabled as I've yet to add the proper code to ensure that animating these will work correctly. They will hopefully be working before the end of the day.
Modified Paths:
--------------
branches/soc-2009-aligorith/source/blender/editors/animation/fmodifier_ui.c
branches/soc-2009-aligorith/source/blender/editors/space_nla/nla_buttons.c
Modified: branches/soc-2009-aligorith/source/blender/editors/animation/fmodifier_ui.c
===================================================================
--- branches/soc-2009-aligorith/source/blender/editors/animation/fmodifier_ui.c 2009-07-02 23:27:11 UTC (rev 21327)
+++ branches/soc-2009-aligorith/source/blender/editors/animation/fmodifier_ui.c 2009-07-02 23:36:16 UTC (rev 21328)
@@ -215,7 +215,7 @@
/* draw controls for each pair of coefficients */
row= uiLayoutRow(layout, 1);
block= uiLayoutGetBlock(row);
- uiDefBut(block, LABEL, 1, "y = ", 0, 0, 50, 20, NULL, 0.0, 0.0, 0, 0, "");
+ uiDefBut(block, LABEL, 1, "y=", 0, 0, 50, 20, NULL, 0.0, 0.0, 0, 0, "");
cp= data->coefficients;
for (i=0; (i < data->poly_order) && (cp); i++, cp+=2) {
@@ -225,7 +225,7 @@
/* coefficients */
uiDefButF(block, NUM, B_FMODIFIER_REDRAW, "", 0, 0, 100, 20, cp, -UI_FLT_MAX, UI_FLT_MAX, 10, 3, "Coefficient of x");
- uiDefBut(block, LABEL, 1, "x + ", 0, 0, 40, 20, NULL, 0.0, 0.0, 0, 0, "");
+ uiDefBut(block, LABEL, 1, "x+", 0, 0, 40, 20, NULL, 0.0, 0.0, 0, 0, "");
uiDefButF(block, NUM, B_FMODIFIER_REDRAW, "", 0, 0, 100, 20, cp+1, -UI_FLT_MAX, UI_FLT_MAX, 10, 3, "Second coefficient");
Modified: branches/soc-2009-aligorith/source/blender/editors/space_nla/nla_buttons.c
===================================================================
--- branches/soc-2009-aligorith/source/blender/editors/space_nla/nla_buttons.c 2009-07-02 23:27:11 UTC (rev 21327)
+++ branches/soc-2009-aligorith/source/blender/editors/space_nla/nla_buttons.c 2009-07-02 23:36:16 UTC (rev 21328)
@@ -289,7 +289,7 @@
{
PointerRNA strip_ptr;
uiLayout *layout= pa->layout;
- //uiLayout *column, *row, *subcol;
+ uiLayout *column;
uiBlock *block;
/* check context and also validity of pointer */
@@ -299,10 +299,15 @@
block= uiLayoutGetBlock(layout);
uiBlockSetHandleFunc(block, do_nla_region_buttons, NULL);
- // influence
- // strip_time
- // animated_influence
- // animated_time
+ column= uiLayoutColumn(layout, 1);
+ uiLayoutSetEnabled(column, 0); // XXX for now, don't allow user to edit
+ uiItemR(column, NULL, 0, &strip_ptr, "animated_influence", 0, 0, 0);
+ uiItemR(column, NULL, 0, &strip_ptr, "influence", 0, 0, 0);
+
+ column= uiLayoutColumn(layout, 1);
+ uiLayoutSetEnabled(column, 0); // XXX for now, don't allow user to edit
+ uiItemR(column, NULL, 0, &strip_ptr, "animated_time", 0, 0, 0);
+ uiItemR(column, NULL, 0, &strip_ptr, "strip_time", 0, 0, 0);
}
/* F-Modifiers for active NLA-Strip */
More information about the Bf-blender-cvs
mailing list