diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2017-10-24 03:04:58 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2017-10-24 03:05:41 +0300 |
commit | f5456df095291c6cb2d0223a179746c8e514cd15 (patch) | |
tree | 76384b0c91806c95d55b007850ee225889a3250e /source/blender/editors | |
parent | 254daf8f8c276a4e5292e5a12fcfa88296131878 (diff) | |
parent | 070a668d04844610059aaedc80c49e9038fd1779 (diff) |
Merge branch 'master' into blender2.8
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/include/UI_view2d.h | 2 | ||||
-rw-r--r-- | source/blender/editors/interface/view2d.c | 4 | ||||
-rw-r--r-- | source/blender/editors/space_sequencer/sequencer_draw.c | 5 |
3 files changed, 5 insertions, 6 deletions
diff --git a/source/blender/editors/include/UI_view2d.h b/source/blender/editors/include/UI_view2d.h index 4c0493a881c..f6e31e0bd22 100644 --- a/source/blender/editors/include/UI_view2d.h +++ b/source/blender/editors/include/UI_view2d.h @@ -169,7 +169,7 @@ void UI_view2d_view_restore(const struct bContext *C); View2DGrid *UI_view2d_grid_calc(struct Scene *scene, struct View2D *v2d, short xunits, short xclamp, short yunits, short yclamp, int winx, int winy); void UI_view2d_grid_draw(struct View2D *v2d, View2DGrid *grid, int flag); -void UI_view2d_constant_grid_draw(struct View2D *v2d); +void UI_view2d_constant_grid_draw(struct View2D *v2d, float step); void UI_view2d_multi_grid_draw(struct View2D *v2d, int colorid, float step, int level_size, int totlevels); void UI_view2d_grid_size(View2DGrid *grid, float *r_dx, float *r_dy); void UI_view2d_grid_free(View2DGrid *grid); diff --git a/source/blender/editors/interface/view2d.c b/source/blender/editors/interface/view2d.c index bb625bc0ff8..a94ef0d1d5b 100644 --- a/source/blender/editors/interface/view2d.c +++ b/source/blender/editors/interface/view2d.c @@ -1439,9 +1439,9 @@ void UI_view2d_grid_draw(View2D *v2d, View2DGrid *grid, int flag) } /* Draw a constant grid in given 2d-region */ -void UI_view2d_constant_grid_draw(View2D *v2d) +void UI_view2d_constant_grid_draw(View2D *v2d, float step) { - float start_x, start_y, step = 25.0f; + float start_x, start_y; int count_x, count_y; start_x = v2d->cur.xmin; diff --git a/source/blender/editors/space_sequencer/sequencer_draw.c b/source/blender/editors/space_sequencer/sequencer_draw.c index c14e427b133..01b7c8793ba 100644 --- a/source/blender/editors/space_sequencer/sequencer_draw.c +++ b/source/blender/editors/space_sequencer/sequencer_draw.c @@ -1688,9 +1688,8 @@ void draw_timeline_seq(const bContext *C, ARegion *ar) /* draw backdrop */ draw_seq_backdrop(v2d); - /* regular grid-pattern over the rest of the view (i.e. 25-frame grid lines) */ - // NOTE: the gridlines are currently spaced every 25 frames, which is only fine for 25 fps, but maybe not for 30... - UI_view2d_constant_grid_draw(v2d); + /* regular grid-pattern over the rest of the view (i.e. 1-second grid lines) */ + UI_view2d_constant_grid_draw(v2d, FPS); /* Only draw backdrop in pure sequence view. */ if (sseq->view == SEQ_VIEW_SEQUENCE && sseq->draw_flag & SEQ_DRAW_BACKDROP) { |