[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [58528] branches/soc-2013-cycles_mblur/ intern/cycles/blender: Fix compile errors that cropped up in recent commits because I was

Gavin Howard gavin.d.howard at gmail.com
Tue Jul 23 07:28:05 CEST 2013


Revision: 58528
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=58528
Author:   gdh
Date:     2013-07-23 05:28:05 +0000 (Tue, 23 Jul 2013)
Log Message:
-----------
Fix compile errors that cropped up in recent commits because I was 
stupid and forgot to build before committing.

WARNING: Even those this commit fixes a build error, it introduces 
another problem: Cycles will crash Blender when switching to viewport 
render. I am working on the problem, but it is almost midnight, so I 
cannot guarantee that it will be fixed soon. If you test a build, TEST 
IT BEFORE THIS COMMIT.

Modified Paths:
--------------
    branches/soc-2013-cycles_mblur/intern/cycles/blender/blender_object.cpp
    branches/soc-2013-cycles_mblur/intern/cycles/blender/blender_sync.h

Modified: branches/soc-2013-cycles_mblur/intern/cycles/blender/blender_object.cpp
===================================================================
--- branches/soc-2013-cycles_mblur/intern/cycles/blender/blender_object.cpp	2013-07-23 05:14:11 UTC (rev 58527)
+++ branches/soc-2013-cycles_mblur/intern/cycles/blender/blender_object.cpp	2013-07-23 05:28:05 UTC (rev 58528)
@@ -262,9 +262,8 @@
 
 /* Object */
 
-Object *BlenderSync::sync_object(BL::Object b_parent, int persistent_id[OBJECT_PERSISTENT_ID_SIZE],
-                                 BL::DupliObject b_dupli_ob, Transform& tfm, uint layer_flag,
-                                 std::set<float> *object_export, float export_time, bool hide_tris)
+Object *BlenderSync::sync_object(BL::Object b_parent, int persistent_id[OBJECT_PERSISTENT_ID_SIZE], BL::DupliObject b_dupli_ob,
+                                 Transform& tfm, uint layer_flag, float export_time, bool hide_tris)
 {
 	BL::Object b_ob = (b_dupli_ob ? b_dupli_ob.object() : b_parent);
 	
@@ -353,12 +352,9 @@
 		
 		for (int i = 1; i <= half_steps; ++i) {
 			time = i * step_width;
-			object_export->insert(frame - time);
-			object_export->insert(frame + time);
+			object->export_times.insert(frame - time);
+			object->export_times.insert(frame + time);
 		}
-		
-		/* Add the new export times to the object. */
-		object->export_times = object_export;
 	}
 	
 	bool use_holdout = (layer_flag & render_layer.holdout_layer) != 0;
@@ -536,11 +532,12 @@
 
 							/* sync object and mesh or light data */
 							Object *object = sync_object(*b_ob, persistent_id.data, *b_dup, tfm,
-							                             ob_layer, &object_export, export_time, hide_tris);
+							                             ob_layer, export_time, hide_tris);
 							
 							/* Add this object's export times to the set. */
-							for (int i = 0; i < object_export.size(); ++i) {
-								export_times->insert(object_export[i]);
+							std::set<float>::iterator time;
+							for (time = object_export.begin(); time != object_export.end(); time++) {
+								export_times->insert(*time);
 							}
 
 							/* sync possible particle data, note particle_id
@@ -566,11 +563,12 @@
 				if(!object_render_hide(*b_ob, true, true, hide_tris)) {
 					/* object itself */
 					Transform tfm = get_transform(b_ob->matrix_world());
-					sync_object(*b_ob, NULL, PointerRNA_NULL, tfm, ob_layer, &object_export, export_time, hide_tris);
+					sync_object(*b_ob, NULL, PointerRNA_NULL, tfm, ob_layer, export_time, hide_tris);
 					
 					/* Add this object's export times to the set. */
-					for (int i = 0; i < object_export.size(); ++i) {
-						export_times->insert(object_export[i]);
+					std::set<float>::iterator time;
+					for (time = object_export.begin(); time != object_export.end(); time++) {
+						export_times->insert(*time);
 					}
 				}
 			}

Modified: branches/soc-2013-cycles_mblur/intern/cycles/blender/blender_sync.h
===================================================================
--- branches/soc-2013-cycles_mblur/intern/cycles/blender/blender_sync.h	2013-07-23 05:14:11 UTC (rev 58527)
+++ branches/soc-2013-cycles_mblur/intern/cycles/blender/blender_sync.h	2013-07-23 05:28:05 UTC (rev 58528)
@@ -84,9 +84,8 @@
 	void sync_nodes(Shader *shader, BL::ShaderNodeTree b_ntree);
 	Mesh *sync_mesh(BL::Object b_ob, bool object_updated, bool hide_tris);
 	void sync_curves(Mesh *mesh, BL::Mesh b_mesh, BL::Object b_ob, bool object_updated);
-	Object *sync_object(BL::Object b_parent, int persistent_id[OBJECT_PERSISTENT_ID_SIZE],
-                        BL::DupliObject b_dupli_object, Transform& tfm, uint layer_flag,
-                        std::set<float> *object_export, float export_time, bool hide_tris);
+	Object *sync_object(BL::Object b_parent, int persistent_id[OBJECT_PERSISTENT_ID_SIZE], BL::DupliObject b_dupli_ob,
+	                                 Transform& tfm, uint layer_flag, float export_time, bool hide_tris);
 	void sync_light(BL::Object b_parent, int persistent_id[OBJECT_PERSISTENT_ID_SIZE], BL::Object b_ob, Transform& tfm);
 	void sync_background_light();
 	void sync_mesh_motion(BL::Object b_ob, Mesh *mesh, int motion);




More information about the Bf-blender-cvs mailing list