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>2009-08-01 09:10:57 +0400
committerJoshua Leung <aligorith@gmail.com>2009-08-01 09:10:57 +0400
commitdc90e758b4c91a0c7e6406498301e82ccecf2fdb (patch)
treeea9f248f3cf1f6d4392d84b65ba6e49c3a115ef6 /source/blender/editors/space_time
parentc1438a57db01dfd69c48672451cc6b81d518015f (diff)
2.5 - More tweaks to realtime record
* New NLA Tracks/Strips are now only created if the 'layered' button (visible in the timeline header when autokeying is on, and the playback is running) is enabled. This multiple bones to be able to be animated in the same action, but done in multiple passes. * Made Alt-A work in timeline header too.
Diffstat (limited to 'source/blender/editors/space_time')
-rw-r--r--source/blender/editors/space_time/space_time.c2
-rw-r--r--source/blender/editors/space_time/time_header.c15
2 files changed, 13 insertions, 4 deletions
diff --git a/source/blender/editors/space_time/space_time.c b/source/blender/editors/space_time/space_time.c
index 61488db0007..8445f1b47e7 100644
--- a/source/blender/editors/space_time/space_time.c
+++ b/source/blender/editors/space_time/space_time.c
@@ -422,7 +422,7 @@ void ED_spacetype_time(void)
art= MEM_callocN(sizeof(ARegionType), "spacetype time region");
art->regionid = RGN_TYPE_HEADER;
art->minsizey= HEADERY;
- art->keymapflag= ED_KEYMAP_UI|ED_KEYMAP_VIEW2D;
+ art->keymapflag= ED_KEYMAP_UI|ED_KEYMAP_VIEW2D|ED_KEYMAP_FRAMES;
art->init= time_header_area_init;
art->draw= time_header_area_draw;
diff --git a/source/blender/editors/space_time/time_header.c b/source/blender/editors/space_time/time_header.c
index 436a841deb8..fb8c28fd751 100644
--- a/source/blender/editors/space_time/time_header.c
+++ b/source/blender/editors/space_time/time_header.c
@@ -447,6 +447,7 @@ void time_header_buttons(const bContext *C, ARegion *ar)
ScrArea *sa= CTX_wm_area(C);
SpaceTime *stime= CTX_wm_space_time(C);
Scene *scene= CTX_data_scene(C);
+ wmTimer *animtimer= CTX_wm_screen(C)->animtimer;
uiBlock *block;
uiBut *but;
int xco, yco= 3;
@@ -536,7 +537,7 @@ void time_header_buttons(const bContext *C, ARegion *ar)
RNA_boolean_set(uiButGetOperatorPtrRNA(but), "next", 0);
xco+= XIC;
- if(CTX_wm_screen(C)->animtimer) {
+ if (animtimer) {
/* pause button 2*size to keep buttons in place */
uiDefIconBut(block, BUT, B_TL_STOP, ICON_PAUSE,
xco, yco, XIC*2, YIC, 0, 0, 0, 0, 0, "Stop Playing Timeline");
@@ -568,13 +569,21 @@ void time_header_buttons(const bContext *C, ARegion *ar)
uiDefIconButBitS(block, TOG, AUTOKEY_ON, B_REDRAWALL, ICON_REC,
xco, yco, XIC, YIC, &(scene->toolsettings->autokey_mode), 0, 0, 0, 0, "Automatic keyframe insertion for Objects and Bones");
xco+= XIC;
-
- if(IS_AUTOKEY_ON(scene)) {
+
+ if (IS_AUTOKEY_ON(scene)) {
uiDefButS(block, MENU, B_REDRAWALL,
"Auto-Keying Mode %t|Add/Replace Keys%x3|Replace Keys %x5",
xco, yco, (int)5.5*XIC, YIC, &(scene->toolsettings->autokey_mode), 0, 1, 0, 0,
"Mode of automatic keyframe insertion for Objects and Bones");
xco+= (5.5*XIC);
+
+ if (animtimer) {
+ uiDefButBitS(block, TOG, ANIMRECORD_FLAG_WITHNLA, B_REDRAWALL, "Layered",
+ xco,yco, XIC*2.5, YIC,
+ &(scene->toolsettings->autokey_flag),0, 1, 0, 0,
+ "Add a new NLA Track + Strip for every loop/pass made over the animation to allow non-destructive tweaking.");
+ xco+= (3*XIC);
+ }
}
else
xco+= 6;