diff options
author | Julian Eisel <julian@blender.org> | 2020-03-12 17:58:03 +0300 |
---|---|---|
committer | Julian Eisel <julian@blender.org> | 2020-03-12 17:58:03 +0300 |
commit | b86be9b2145458037fd0b17433b7af0efa7b6472 (patch) | |
tree | f333625555402992ebb35d258f93eda1130389e6 /source/blender/editors/gpencil/gpencil_weight_paint.c | |
parent | 00f83ec125207e90bf180b3eb7752d8cb6482a86 (diff) | |
parent | cb6cec904fa14ce0ab10a2a53af5c936d56376cf (diff) |
Merge branch 'temp-openxr-ghostxr' into temp-openxr-blenderside
Diffstat (limited to 'source/blender/editors/gpencil/gpencil_weight_paint.c')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_weight_paint.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/source/blender/editors/gpencil/gpencil_weight_paint.c b/source/blender/editors/gpencil/gpencil_weight_paint.c index 6b337afa559..c519129cdf7 100644 --- a/source/blender/editors/gpencil/gpencil_weight_paint.c +++ b/source/blender/editors/gpencil/gpencil_weight_paint.c @@ -110,7 +110,7 @@ typedef struct tGP_BrushWeightpaintData { /* Start of new paint */ bool first; - /* Is multiframe editing enabled, and are we using falloff for that? */ + /* Is multi-frame editing enabled, and are we using falloff for that? */ bool is_multiframe; bool use_multiframe_falloff; @@ -127,10 +127,10 @@ typedef struct tGP_BrushWeightpaintData { /* - Effect 2D vector */ float dvec[2]; - /* - multiframe falloff factor */ + /* - multi-frame falloff factor. */ float mf_falloff; - /* brush geometry (bounding box) */ + /* brush geometry (bounding box). */ rcti brush_rect; /* Temp data to save selected points */ @@ -206,7 +206,7 @@ static float brush_influence_calc(tGP_BrushWeightpaintData *gso, const int radiu float brush_fallof = BKE_brush_curve_strength(brush, distance, (float)radius); influence *= brush_fallof; - /* apply multiframe falloff */ + /* apply multi-frame falloff */ influence *= gso->mf_falloff; /* return influence */ @@ -585,7 +585,7 @@ static bool gp_weightpaint_brush_apply_to_layers(bContext *C, tGP_BrushWeightpai /* Active Frame or MultiFrame? */ if (gso->is_multiframe) { - /* init multiframe falloff options */ + /* init multi-frame falloff options */ int f_init = 0; int f_end = 0; @@ -596,10 +596,10 @@ static bool gp_weightpaint_brush_apply_to_layers(bContext *C, tGP_BrushWeightpai LISTBASE_FOREACH (bGPDframe *, gpf, &gpl->frames) { /* Always do active frame; Otherwise, only include selected frames */ if ((gpf == gpl->actframe) || (gpf->flag & GP_FRAME_SELECT)) { - /* compute multiframe falloff factor */ + /* Compute multi-frame falloff factor. */ if (gso->use_multiframe_falloff) { - /* Faloff depends on distance to active frame (relative to the overall frame range) - */ + /* Falloff depends on distance to active frame + * (relative to the overall frame range). */ gso->mf_falloff = BKE_gpencil_multiframe_falloff_calc( gpf, gpl->actframe->framenum, f_init, f_end, ts->gp_sculpt.cur_falloff); } @@ -656,7 +656,7 @@ static void gp_weightpaint_brush_apply(bContext *C, wmOperator *op, PointerRNA * gso->brush_rect.xmax = mouse[0] + radius; gso->brush_rect.ymax = mouse[1] + radius; - /* Calc 2D direction vector and relative angle. */ + /* Calculate 2D direction vector and relative angle. */ brush_calc_dvec_2d(gso); changed = gp_weightpaint_brush_apply_to_layers(C, gso); |