[Bf-blender-cvs] [88ddf29] soc-2016-pbvh-painting: Cleanup: Reduce diff from master (mostly emty lines...).

Bastien Montagne noreply at git.blender.org
Tue Sep 13 14:18:00 CEST 2016


Commit: 88ddf296bbc994f29bdaa4638fcfffaeda106997
Author: Bastien Montagne
Date:   Tue Sep 13 14:13:40 2016 +0200
Branches: soc-2016-pbvh-painting
https://developer.blender.org/rB88ddf296bbc994f29bdaa4638fcfffaeda106997

Cleanup: Reduce diff from master (mostly emty lines...).

===================================================================

M	release/scripts/startup/bl_ui/space_view3d_toolbar.py
M	source/blender/editors/sculpt_paint/paint_vertex.c
M	source/blender/editors/sculpt_paint/sculpt.c

===================================================================

diff --git a/release/scripts/startup/bl_ui/space_view3d_toolbar.py b/release/scripts/startup/bl_ui/space_view3d_toolbar.py
index ee9b7e5..4fd87da 100644
--- a/release/scripts/startup/bl_ui/space_view3d_toolbar.py
+++ b/release/scripts/startup/bl_ui/space_view3d_toolbar.py
@@ -1788,6 +1788,7 @@ class VIEW3D_PT_tools_vertexpaint(Panel, View3DPaintPanel):
         col.prop(vpaint, "use_spray")
 
         self.unified_paint_settings(col, context)
+
 # Commented out because the Apply button isn't an operator yet, making these settings useless
 #~         col.label(text="Gamma:")
 #~         col.prop(vpaint, "gamma", text="")
diff --git a/source/blender/editors/sculpt_paint/paint_vertex.c b/source/blender/editors/sculpt_paint/paint_vertex.c
index c2ce7be..0904cdf 100644
--- a/source/blender/editors/sculpt_paint/paint_vertex.c
+++ b/source/blender/editors/sculpt_paint/paint_vertex.c
@@ -798,6 +798,7 @@ static unsigned int vpaint_blend(VPaint *vp, unsigned int col, unsigned int colo
 {
 	Brush *brush = BKE_paint_brush(&vp->paint);
 	const int tool = brush->vertexpaint_tool;
+
 	col = vpaint_blend_tool(tool, col, paintcol, alpha_i);
 
 	/* if no spray, clip color adding with colorig & orig alpha */
@@ -1560,6 +1561,7 @@ static void do_weight_paint_vertex_single(
 	{
 		dw->weight = wpaint_blend(wp, dw->weight, alpha, paintweight,
 		                          wpi->brush_alpha_value, wpi->do_flip);
+
 		/* WATCH IT: take care of the ordering of applying mirror -> normalize,
 		 * can give wrong results [#26193], least confusing if normalize is done last */
 
@@ -1764,6 +1766,7 @@ static int wpaint_mode_toggle_exec(bContext *C, wmOperator *op)
 	Scene *scene = CTX_data_scene(C);
 	VPaint *wp = scene->toolsettings->wpaint;
 	Mesh *me;
+
 	if (!is_mode_set) {
 		if (!ED_object_mode_compat_set(C, ob, mode_flag, op->reports)) {
 			return OPERATOR_CANCELLED;
@@ -1786,7 +1789,6 @@ static int wpaint_mode_toggle_exec(bContext *C, wmOperator *op)
 		ED_mesh_mirror_spatial_table(NULL, NULL, NULL, NULL, 'e');
 		ED_mesh_mirror_topo_table(NULL, NULL, 'e');
 
-
 		/* If the cache is not released by a cancel or a done, free it now. */
 		if (ob->sculpt->cache){
 			sculpt_cache_free(ob->sculpt->cache);
@@ -1802,6 +1804,7 @@ static int wpaint_mode_toggle_exec(bContext *C, wmOperator *op)
 
 		if (wp == NULL)
 			wp = scene->toolsettings->wpaint = new_vpaint(1);
+
 		paint_cursor_start(C, weight_paint_poll);
 
 		BKE_paint_init(scene, ePaintWeight, PAINT_CURSOR_WEIGHT_PAINT);
@@ -2057,7 +2060,6 @@ static void vwpaint_update_cache_variants(bContext *C, VPaint *vd, Object *ob, P
 	cache->radius_squared = cache->radius * cache->radius;
 }
 
-
 static bool wpaint_stroke_test_start(bContext *C, wmOperator *op, const float mouse[2])
 {
 	Scene *scene = CTX_data_scene(C);
@@ -2071,7 +2073,7 @@ static bool wpaint_stroke_test_start(bContext *C, wmOperator *op, const float mo
 	bool *defbase_sel;
 	SculptSession *ss = ob->sculpt;
 	VPaint *vd = CTX_data_tool_settings(C)->wpaint;
-	
+
 	float mat[4][4], imat[4][4];
 
 	if (wpaint_ensure_data(C, op, WPAINT_ENSURE_MIRROR, &vgroup_index) == false) {
@@ -3010,7 +3012,7 @@ static int vpaint_mode_toggle_exec(bContext *C, wmOperator *op)
 
 		if (vp == NULL)
 			vp = scene->toolsettings->vpaint = new_vpaint(0);
-    
+		
 		paint_cursor_start(C, vertex_paint_poll);
 
 		BKE_paint_init(scene, ePaintVertex, PAINT_CURSOR_VERTEX_PAINT);
@@ -3166,6 +3168,7 @@ static void UNUSED_FUNCTION(Nvpaint_paint_poly)(VPaint *vp, VPaintData *vpd, Mes
 	float alpha;
 	int i, j;
 	int totloop = mpoly->totloop;
+
 	int brush_alpha_pressure_i = (int)(brush_alpha_pressure * 255.0f);
 
 	if (brush->vertexpaint_tool == PAINT_BLEND_BLUR) {
@@ -3660,7 +3663,6 @@ static void vpaint_stroke_update_step(bContext *C, struct PaintStroke *stroke, P
 		/* If using new VBO drawing, mark mcol as dirty to force colors gpu buffer refresh! */
 		ob->derivedFinal->dirty |= DM_DIRTY_MCOL_UPDATE_DRAW;
 	}
-
 }
 
 static void vpaint_stroke_done(const bContext *C, struct PaintStroke *stroke)
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index e66dda1..d454291 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -527,6 +527,7 @@ BLI_INLINE bool sculpt_brush_test_clipping(const SculptBrushTest *test, const fl
 bool sculpt_brush_test(SculptBrushTest *test, const float co[3])
 {
 	float distsq = len_squared_v3v3(co, test->location);
+
 	if (distsq <= test->radius_squared) {
 		if (sculpt_brush_test_clipping(test, co)) {
 			return 0;
@@ -1142,12 +1143,12 @@ float tex_strength(SculptSession *ss, Brush *br,
 
 	/* Falloff curve */
 	avg *= BKE_brush_curve_strength(br, len, cache->radius);
-	
+
 	avg *= frontface(br, cache->view_normal, vno, fno);
-	
+
 	/* Paint mask */
 	avg *= 1.0f - mask;
-	
+
 	return avg;
 }




More information about the Bf-blender-cvs mailing list