From 4cb6d5d214529749bbeeb2a63018b2d54ffa3417 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Thu, 13 Sep 2012 01:50:21 +0000 Subject: code cleanup: reduce calls to CTX_ functions inline, add some docs to mask rasterizer. --- source/blender/editors/mask/mask_add.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source/blender/editors/mask/mask_add.c') diff --git a/source/blender/editors/mask/mask_add.c b/source/blender/editors/mask/mask_add.c index b37f758596b..7fe1ac09df6 100644 --- a/source/blender/editors/mask/mask_add.c +++ b/source/blender/editors/mask/mask_add.c @@ -556,6 +556,7 @@ static int add_vertex_new(const bContext *C, Mask *mask, MaskLayer *masklay, con static int add_vertex_exec(bContext *C, wmOperator *op) { + Scene *scene = CTX_data_scene(C); Mask *mask = CTX_data_edit_mask(C); MaskLayer *masklay; @@ -595,7 +596,7 @@ static int add_vertex_exec(bContext *C, wmOperator *op) BKE_mask_calc_handle_point_auto(spline, point_other, FALSE); /* TODO: only update this spline */ - BKE_mask_update_display(mask, CTX_data_scene(C)->r.cfra); + BKE_mask_update_display(mask, CFRA); WM_event_add_notifier(C, NC_MASK | NA_EDITED, mask); return OPERATOR_FINISHED; @@ -617,7 +618,7 @@ static int add_vertex_exec(bContext *C, wmOperator *op) } /* TODO: only update this spline */ - BKE_mask_update_display(mask, CTX_data_scene(C)->r.cfra); + BKE_mask_update_display(mask, CFRA); return OPERATOR_FINISHED; } -- cgit v1.2.3