[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [40209] branches/cycles/intern/cycles: Cycles: attempted fixes for OS X preview render problem, and disable

Brecht Van Lommel brechtvanlommel at pandora.be
Thu Sep 15 00:26:56 CEST 2011


Revision: 40209
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=40209
Author:   blendix
Date:     2011-09-14 22:26:55 +0000 (Wed, 14 Sep 2011)
Log Message:
-----------
Cycles: attempted fixes for OS X preview render problem, and disable
kernel cache there now as well since it seems to give issues there.

Modified Paths:
--------------
    branches/cycles/intern/cycles/CMakeLists.txt
    branches/cycles/intern/cycles/device/device.cpp
    branches/cycles/intern/cycles/device/device_network.h
    branches/cycles/intern/cycles/device/device_opencl.cpp
    branches/cycles/intern/cycles/render/session.h
    branches/cycles/intern/cycles/render/tile.cpp

Modified: branches/cycles/intern/cycles/CMakeLists.txt
===================================================================
--- branches/cycles/intern/cycles/CMakeLists.txt	2011-09-14 20:47:20 UTC (rev 40208)
+++ branches/cycles/intern/cycles/CMakeLists.txt	2011-09-14 22:26:55 UTC (rev 40209)
@@ -8,7 +8,7 @@
 # Build Flags
 
 set(GCC_WARNING_FLAGS "-Wall -Wextra -Wno-unused-parameter -Wno-long-long")
-set(GCC_OPTIM_FLAGS "-ffast-math -fPIC -msse -msse2 -msse3 -mtune=native")
+set(GCC_OPTIM_FLAGS "-ffast-math -msse -msse2 -msse3 -mtune=native")
 
 if(APPLE)
 	set(CMAKE_CXX_FLAGS "${GCC_WARNING_FLAGS} ${GCC_OPTIM_FLAGS}")

Modified: branches/cycles/intern/cycles/device/device.cpp
===================================================================
--- branches/cycles/intern/cycles/device/device.cpp	2011-09-14 20:47:20 UTC (rev 40208)
+++ branches/cycles/intern/cycles/device/device.cpp	2011-09-14 22:26:55 UTC (rev 40209)
@@ -108,7 +108,7 @@
 
 	/* for multi devices, this assumes the ineffecient method that we allocate
 	   all pixels on the device even though we only render to a subset */
-	pixels += sizeof(uint8_t)*4*y*w;
+	pixels += 4*y*w;
 
 	glDrawPixels(w, h, GL_RGBA, GL_UNSIGNED_BYTE, pixels);
 

Modified: branches/cycles/intern/cycles/device/device_network.h
===================================================================
--- branches/cycles/intern/cycles/device/device_network.h	2011-09-14 20:47:20 UTC (rev 40208)
+++ branches/cycles/intern/cycles/device/device_network.h	2011-09-14 22:26:55 UTC (rev 40209)
@@ -19,6 +19,8 @@
 #ifndef __DEVICE_NETWORK_H__
 #define __DEVICE_NETWORK_H__
 
+#ifdef WITH_NETWORK
+
 #include <boost/archive/text_iarchive.hpp>
 #include <boost/archive/text_oarchive.hpp>
 #include <boost/array.hpp>
@@ -300,5 +302,7 @@
 
 CCL_NAMESPACE_END
 
+#endif
+
 #endif /* __DEVICE_NETWORK_H__ */
 

Modified: branches/cycles/intern/cycles/device/device_opencl.cpp
===================================================================
--- branches/cycles/intern/cycles/device/device_opencl.cpp	2011-09-14 20:47:20 UTC (rev 40208)
+++ branches/cycles/intern/cycles/device/device_opencl.cpp	2011-09-14 22:26:55 UTC (rev 40209)
@@ -353,19 +353,23 @@
 		string clbin = string_printf("cycles_kernel_%s_%s.clbin", device_md5.c_str(), kernel_md5.c_str());;
 		clbin = path_user_get(path_join("cache", clbin));
 
+#ifndef __APPLE__
 		if(path_exists(clbin)) {
 			/* if exists already, try use it */
 			if(!load_binary(kernel_path, clbin))
 				return false;
 		}
 		else {
+#endif
 			/* compile kernel */
 			if(!compile_kernel(kernel_path, kernel_md5))
 				return false;
 
+#ifndef __APPLE__
 			/* save binary for reuse */
 			save_binary(clbin);
 		}
+#endif
 
 		/* find kernels */
 		ckPathTraceKernel = clCreateKernel(cpProgram, "kernel_ocl_path_trace", &ciErr);

Modified: branches/cycles/intern/cycles/render/session.h
===================================================================
--- branches/cycles/intern/cycles/render/session.h	2011-09-14 20:47:20 UTC (rev 40208)
+++ branches/cycles/intern/cycles/render/session.h	2011-09-14 22:26:55 UTC (rev 40209)
@@ -58,7 +58,7 @@
 		background = false;
 		output_path = "";
 
-		progressive = true;
+		progressive = false;
 		passes = INT_MAX;
 		tile_size = 64;
 		min_size = 64;

Modified: branches/cycles/intern/cycles/render/tile.cpp
===================================================================
--- branches/cycles/intern/cycles/render/tile.cpp	2011-09-14 20:47:20 UTC (rev 40208)
+++ branches/cycles/intern/cycles/render/tile.cpp	2011-09-14 22:26:55 UTC (rev 40209)
@@ -96,7 +96,7 @@
 
 bool TileManager::done()
 {
-	return (state.pass+1 >= passes && state.resolution == 1);
+	return (state.pass+1 >= passes);
 }
 
 bool TileManager::next()




More information about the Bf-blender-cvs mailing list