diff options
author | Joshua Leung <aligorith@gmail.com> | 2010-01-19 23:30:04 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2010-01-19 23:30:04 +0300 |
commit | a8a5defc0caac44b1fa6fcd330ca8fb262b55547 (patch) | |
tree | 82a0fbf31a068ccffcc9d3ec1e36d5ac087b9e60 /source/blender/editors/space_graph | |
parent | 21004122847fb2570fd61de6677d2b0c8f96444a (diff) |
Preview Range Tweak:
Made preview range be turned on/off using a proper flag instead of just relying on checking for start-frame = 0. It is no longer satisfactory to do that since we can have negative frame numbers, and also having it as a proper flag means that the range can be toggled on/off non-destructively.
Diffstat (limited to 'source/blender/editors/space_graph')
-rw-r--r-- | source/blender/editors/space_graph/graph_edit.c | 1 | ||||
-rw-r--r-- | source/blender/editors/space_graph/space_graph.c | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/editors/space_graph/graph_edit.c b/source/blender/editors/space_graph/graph_edit.c index db63499d645..9fda92a5852 100644 --- a/source/blender/editors/space_graph/graph_edit.c +++ b/source/blender/editors/space_graph/graph_edit.c @@ -174,6 +174,7 @@ static int graphkeys_previewrange_exec(bContext *C, wmOperator *op) /* set the range directly */ get_graph_keyframe_extents(&ac, &min, &max, NULL, NULL); + scene->r.flag |= SCER_PRV_RANGE; scene->r.psfra= (int)floor(min + 0.5f); scene->r.pefra= (int)floor(max + 0.5f); diff --git a/source/blender/editors/space_graph/space_graph.c b/source/blender/editors/space_graph/space_graph.c index cf99e3602dd..bd37eb996ce 100644 --- a/source/blender/editors/space_graph/space_graph.c +++ b/source/blender/editors/space_graph/space_graph.c @@ -151,8 +151,8 @@ static SpaceLink *graph_new(const bContext *C) ar->v2d.cur= ar->v2d.tot; - ar->v2d.min[0]= 0.001f; - ar->v2d.min[1]= 0.001f; + ar->v2d.min[0]= 0.00001f; + ar->v2d.min[1]= 0.00001f; ar->v2d.max[0]= MAXFRAMEF; ar->v2d.max[1]= 50000.0f; |