[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [39114] branches/soc-2011-onion/source/ blender: renamed PAINT_USE_THREADED to PAINT_THREADED

Jason Wilkins Jason.A.Wilkins at gmail.com
Sun Aug 7 04:08:03 CEST 2011


Revision: 39114
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=39114
Author:   jwilkins
Date:     2011-08-07 02:08:02 +0000 (Sun, 07 Aug 2011)
Log Message:
-----------
renamed PAINT_USE_THREADED to PAINT_THREADED

PAINT_USE_THREADED uses the RNA naming convention but in C the "use" is ommitted.

Modified Paths:
--------------
    branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_bspace.c
    branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_controls.c
    branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_utils.c
    branches/soc-2011-onion/source/blender/editors/sculpt_paint/sculpt_tools.c
    branches/soc-2011-onion/source/blender/makesdna/DNA_scene_types.h
    branches/soc-2011-onion/source/blender/makesrna/intern/rna_sculpt_paint.c

Modified: branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_bspace.c
===================================================================
--- branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_bspace.c	2011-08-07 02:05:56 UTC (rev 39113)
+++ branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_bspace.c	2011-08-07 02:08:02 UTC (rev 39114)
@@ -991,7 +991,7 @@
 
 	zero_v3(an);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flag & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flag & PAINT_THREADED)
 	for(n=0; n<totnode; n++) {
 		PBVHVertexIter vd;
 		PaintStrokeTest test;
@@ -1113,7 +1113,7 @@
 
 	zero_v3(fc);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flag & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flag & PAINT_THREADED)
 	for(n=0; n<totnode; n++) {
 		PBVHVertexIter vd;
 		PaintStrokeTest test;
@@ -1175,7 +1175,7 @@
 	// fc
 	zero_v3(fc);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flag & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flag & PAINT_THREADED)
 	for(n=0; n<totnode; n++) {
 		PBVHVertexIter vd;
 		PaintStrokeTest test;

Modified: branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_controls.c
===================================================================
--- branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_controls.c	2011-08-07 02:05:56 UTC (rev 39113)
+++ branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_controls.c	2011-08-07 02:08:02 UTC (rev 39114)
@@ -300,7 +300,7 @@
 
 		buffer = MEM_mallocN(sizeof(GLubyte)*size*size, "paint_load_overlay_tex");
 
-		#pragma omp parallel for schedule(static) if (sd->paint.flags & PAINT_USE_THREADED)
+		#pragma omp parallel for schedule(static) if (sd->paint.flags & PAINT_THREADED)
 		for (j= 0; j < size; j++) {
 			int i;
 			float y;
@@ -956,7 +956,7 @@
 				vc->obact->paint->pbvh, 
 				nodes, 
 				totnode, 
-				sd->paint.flag & PAINT_USE_THREADED);
+				sd->paint.flag & PAINT_THREADED);
 #endif
 			if (nodes)
 				MEM_freeN(nodes);

Modified: branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_utils.c
===================================================================
--- branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_utils.c	2011-08-07 02:05:56 UTC (rev 39113)
+++ branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_utils.c	2011-08-07 02:08:02 UTC (rev 39114)
@@ -552,7 +552,7 @@
 {
 	struct Scene *scene= CTX_data_scene(C);
 	struct Paint *paint= paint_get_active(scene);
-	return paint->flags & PAINT_USE_THREADED;
+	return paint->flags & PAINT_THREADED;
 }
 
 void paint_threaded_init(struct Paint *p)
@@ -563,7 +563,7 @@
 	   Justification: Empirically I've found that two threads per
 	   processor gives higher throughput. */
 	if (p &&
-		(p->flags & PAINT_USE_THREADED) &&
+		(p->flags & PAINT_THREADED) &&
 		p->cache &&
 		!(p->cache->threaded_started))
 	{

Modified: branches/soc-2011-onion/source/blender/editors/sculpt_paint/sculpt_tools.c
===================================================================
--- branches/soc-2011-onion/source/blender/editors/sculpt_paint/sculpt_tools.c	2011-08-07 02:05:56 UTC (rev 39113)
+++ branches/soc-2011-onion/source/blender/editors/sculpt_paint/sculpt_tools.c	2011-08-07 02:08:02 UTC (rev 39114)
@@ -355,7 +355,7 @@
 	//set_adaptive_space_factor(sd, ob, stroke, nodes, totnode, NULL);
 
 	for(iteration = 0; iteration <= count; ++iteration) {
-		#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+		#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 		for(n=0; n<totnode; n++) {
 
 			if(ob->paint->multires_active)
@@ -452,7 +452,7 @@
 	mul_v3_fl(offset, bstrength);
 
 	/* threaded loop over nodes */
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n=0; n<totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -524,7 +524,7 @@
 	if(brush->sculpt_tool == SCULPT_TOOL_BLOB) flippedbstrength *= -1.0f;
 
 	/* threaded loop over nodes */
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n=0; n<totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -577,7 +577,7 @@
 
 	//set_adaptive_space_factor(sd, ob, stroke,nodes, totnode, NULL);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n=0; n<totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -647,7 +647,7 @@
 		add_v3_v3(grab_total, an);
 	}
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n=0; n<totnode; n++) {
 		PBVHVertexIter vd;
 		SculptUndoNode* unode;
@@ -701,7 +701,7 @@
 	cross_v3_v3v3(tmp, bspace->disp_vector, bspace->grab_delta);
 	cross_v3_v3v3(cono, tmp, bspace->disp_vector);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n = 0; n < totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -762,7 +762,7 @@
 		add_v3_v3(grab_delta, an);
 	}
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n = 0; n < totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -814,7 +814,7 @@
 	cross_v3_v3v3(tmp, bspace->disp_vector, bspace->grab_delta);
 	cross_v3_v3v3(tangent, tmp, bspace->disp_vector);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n = 0; n < totnode; n++) {
 		PBVHVertexIter vd;
 		SculptUndoNode* unode;
@@ -865,7 +865,7 @@
 
 	axis_angle_to_mat3(m, bspace->disp_vector, angle);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n=0; n<totnode; n++) {
 		PBVHVertexIter vd;
 		SculptUndoNode* unode;
@@ -911,7 +911,7 @@
 
 	//set_adaptive_space_factor(sd, ob, stroke,nodes, totnode, NULL);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n=0; n<totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -978,7 +978,7 @@
 	mul_v3_fl(temp, displace);
 	add_v3_v3v3(fc, bspace->area_centroid, temp);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for(n = 0; n < totnode; n++) {
 		PBVHVertexIter  vd;
 		struct PaintStrokeTest test;
@@ -1061,7 +1061,7 @@
 
 	//add_v3_v3v3(p, bspace->location, an);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for (n = 0; n < totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -1165,7 +1165,7 @@
 	mul_m4_m4m4(tmat, scale, mat);
 	invert_m4_m4(mat, tmat);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for (n = 0; n < totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -1240,7 +1240,7 @@
 	mul_v3_fl(temp, displace);
 	add_v3_v3v3(fc, bspace->area_centroid, temp);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for (n = 0; n < totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -1312,7 +1312,7 @@
 	mul_v3_fl(temp, displace);
 	add_v3_v3v3(fc, bspace->area_centroid, temp);
 
-	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+	#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 	for (n = 0; n < totnode; n++) {
 		PBVHVertexIter vd;
 		struct PaintStrokeTest test;
@@ -1423,7 +1423,7 @@
 		SculptUndoNode** unodes;
 		struct SculptData *mode_data= paint_stroke_mode_data(stroke);
 		float bstrength= mode_data->bstrength;
-		int use_threaded= sd->paint.flags & PAINT_USE_THREADED;
+		int use_threaded= sd->paint.flags & PAINT_THREADED;
 
 		sculpt_undo_get_unodes(
 			&unodes,
@@ -1637,7 +1637,7 @@
 		case SCULPT_TOOL_GRAB:
 		case SCULPT_TOOL_ROTATE:
 		case SCULPT_TOOL_THUMB:
-			#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+			#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 			for (n= 0; n < totnode; n++) {
 				PBVHVertexIter vd;
 				PBVHProxyNode* proxies;
@@ -1683,7 +1683,7 @@
 		case SCULPT_TOOL_SCRAPE:
 		case SCULPT_TOOL_SNAKE_HOOK:
 		case SCULPT_TOOL_LAYER:
-			#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_USE_THREADED)
+			#pragma omp parallel for schedule(guided) if (sd->paint.flags & PAINT_THREADED)
 			for (n= 0; n < totnode; n++) {
 				PBVHVertexIter vd;
 				PBVHProxyNode* proxies;

Modified: branches/soc-2011-onion/source/blender/makesdna/DNA_scene_types.h
===================================================================
--- branches/soc-2011-onion/source/blender/makesdna/DNA_scene_types.h	2011-08-07 02:05:56 UTC (rev 39113)
+++ branches/soc-2011-onion/source/blender/makesdna/DNA_scene_types.h	2011-08-07 02:08:02 UTC (rev 39114)
@@ -1146,7 +1146,7 @@
 	PAINT_SHOW_BRUSH =            (1<<0),
 	PAINT_FAST_NAVIGATE =         (1<<1),
 	PAINT_SHOW_BRUSH_ON_SURFACE = (1<<2),
-	PAINT_USE_THREADED =          (1<<3),
+	PAINT_THREADED =          (1<<3),
 	PAINT_ONLY_DEFORM =           (1<<4),
 
 	PAINT_LOCK_X =                (1<<8),

Modified: branches/soc-2011-onion/source/blender/makesrna/intern/rna_sculpt_paint.c

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list