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>2017-01-18 09:00:17 +0300
committerJoshua Leung <aligorith@gmail.com>2017-01-18 09:41:59 +0300
commit65ec429d1176404fcedd0dc29c03476972ab303f (patch)
tree16bfa75d52d5483ee2f25f53c40f67642c04a7b6 /source/blender/blenloader
parent224ae234439727628ec5c260d1fd4e22e6566e29 (diff)
GP Interpolate Sequence: Tool settings for controlling the shape of interpolation
This commit introduces the ability to use the Robert Penner easing equations or a Custom Curve to control the way that the "Interpolate Sequence" operator interpolates between keyframes. Previously, it was only possible to get linear interpolation between the gp frames. Workflow: 1) Place current frame between a pair of GP keyframes 2) Open the "Interpolate" panel in the Toolshelf 3) Choose the interpolation type (under "Sequence Options") 4) Adjust settings (e.g. if you're using "Custom Curve", use the curvemap widget to define the way that the interpolation proceeds) 5) Click "Sequence" to interpolate 6) Play back/scrub the animation to see if you've got the result you want 7) If you need to make some tweaks, undo, or delete the generated keyframes, then repeat the process again from step 4 until you've got the desired result.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c7
-rw-r--r--source/blender/blenloader/intern/writefile.c4
2 files changed, 11 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index a63b9ed7d19..61f19657349 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -5932,6 +5932,7 @@ static void direct_link_scene(FileData *fd, Scene *sce)
sce->toolsettings->wpaint->wpaint_prev = NULL;
sce->toolsettings->wpaint->tot = 0;
}
+
/* relink grease pencil drawing brushes */
link_list(fd, &sce->toolsettings->gp_brushes);
for (bGPDbrush *brush = sce->toolsettings->gp_brushes.first; brush; brush = brush->next) {
@@ -5948,6 +5949,12 @@ static void direct_link_scene(FileData *fd, Scene *sce)
direct_link_curvemapping(fd, brush->cur_jitter);
}
}
+
+ /* relink grease pencil interpolation curves */
+ sce->toolsettings->gp_interpolate.custom_ipo = newdataadr(fd, sce->toolsettings->gp_interpolate.custom_ipo);
+ if (sce->toolsettings->gp_interpolate.custom_ipo) {
+ direct_link_curvemapping(fd, sce->toolsettings->gp_interpolate.custom_ipo);
+ }
}
if (sce->ed) {
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index ad1999c0bc7..7b8b95f0005 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -2691,6 +2691,10 @@ static void write_scenes(WriteData *wd, ListBase *scebase)
write_curvemapping(wd, brush->cur_jitter);
}
}
+ /* write grease-pencil custom ipo curve to file */
+ if (tos->gp_interpolate.custom_ipo) {
+ write_curvemapping(wd, tos->gp_interpolate.custom_ipo);
+ }
write_paint(wd, &tos->imapaint.paint);