[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [43063] branches/bmesh/blender: svn merge ^/trunk/blender -r43033:43062

Campbell Barton ideasman42 at gmail.com
Mon Jan 2 03:57:40 CET 2012


Revision: 43063
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=43063
Author:   campbellbarton
Date:     2012-01-02 02:57:36 +0000 (Mon, 02 Jan 2012)
Log Message:
-----------
svn merge ^/trunk/blender -r43033:43062

Revision Links:
--------------
    http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=43033

Modified Paths:
--------------
    branches/bmesh/blender/CMakeLists.txt
    branches/bmesh/blender/build_files/scons/config/win32-vc-config.py
    branches/bmesh/blender/build_files/scons/config/win64-vc-config.py
    branches/bmesh/blender/intern/cycles/device/device.cpp
    branches/bmesh/blender/intern/cycles/device/device.h
    branches/bmesh/blender/intern/cycles/device/device_cpu.cpp
    branches/bmesh/blender/intern/cycles/device/device_cuda.cpp
    branches/bmesh/blender/intern/cycles/device/device_multi.cpp
    branches/bmesh/blender/intern/cycles/kernel/kernel.cl
    branches/bmesh/blender/intern/cycles/kernel/kernel.cpp
    branches/bmesh/blender/intern/cycles/kernel/kernel.cu
    branches/bmesh/blender/intern/cycles/kernel/kernel.h
    branches/bmesh/blender/intern/cycles/kernel/kernel_displace.h
    branches/bmesh/blender/intern/cycles/kernel/kernel_optimized.cpp
    branches/bmesh/blender/intern/cycles/kernel/kernel_types.h
    branches/bmesh/blender/intern/cycles/render/mesh_displace.cpp
    branches/bmesh/blender/intern/tools/dump_rna2xml.py
    branches/bmesh/blender/release/scripts/modules/animsys_refactor.py
    branches/bmesh/blender/release/scripts/modules/rna_prop_ui.py
    branches/bmesh/blender/release/scripts/modules/sys_info.py
    branches/bmesh/blender/release/scripts/startup/bl_operators/object_randomize_transform.py
    branches/bmesh/blender/release/scripts/startup/bl_operators/wm.py
    branches/bmesh/blender/release/scripts/startup/bl_ui/properties_game.py
    branches/bmesh/blender/release/scripts/startup/bl_ui/properties_object.py
    branches/bmesh/blender/release/scripts/startup/bl_ui/properties_particle.py
    branches/bmesh/blender/release/scripts/startup/bl_ui/space_image.py
    branches/bmesh/blender/release/scripts/startup/bl_ui/space_userpref.py
    branches/bmesh/blender/release/scripts/startup/bl_ui/space_view3d.py
    branches/bmesh/blender/release/scripts/startup/bl_ui/space_view3d_toolbar.py
    branches/bmesh/blender/source/blender/blenkernel/intern/bvhutils.c
    branches/bmesh/blender/source/blender/blenlib/intern/edgehash.c
    branches/bmesh/blender/source/blender/editors/space_buttons/buttons_texture.c
    branches/bmesh/blender/source/blender/editors/space_node/node_templates.c
    branches/bmesh/blender/source/blender/makesrna/RNA_access.h
    branches/bmesh/blender/source/blender/makesrna/intern/makesrna.c
    branches/bmesh/blender/source/blender/makesrna/intern/rna_define.c
    branches/bmesh/blender/source/blender/modifiers/intern/MOD_explode.c
    branches/bmesh/blender/source/blender/modifiers/intern/MOD_remesh.c

Added Paths:
-----------
    branches/bmesh/blender/release/scripts/modules/rna_xml.py

Property Changed:
----------------
    branches/bmesh/blender/
    branches/bmesh/blender/release/


Property changes on: branches/bmesh/blender
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/soc-2011-cucumber:37517,38384,38387,38403-38404,38407,42997-42998
/branches/soc-2011-tomato:42376,42378-42379,42383,42385,42395,42397-42400,42407,42411,42418,42443-42444,42446,42467,42472,42486,42650-42652,42654-42655,42709-42710,42733-42734,42801
/trunk/blender:39992-43033
   + /branches/soc-2011-cucumber:37517,38384,38387,38403-38404,38407,42997-42998
/branches/soc-2011-tomato:42376,42378-42379,42383,42385,42395,42397-42400,42407,42411,42418,42443-42444,42446,42467,42472,42486,42650-42652,42654-42655,42709-42710,42733-42734,42801
/trunk/blender:39992-43062

Modified: branches/bmesh/blender/CMakeLists.txt
===================================================================
--- branches/bmesh/blender/CMakeLists.txt	2012-01-02 02:13:31 UTC (rev 43062)
+++ branches/bmesh/blender/CMakeLists.txt	2012-01-02 02:57:36 UTC (rev 43063)
@@ -1393,8 +1393,11 @@
 
 	# disable because it gives warnings for printf() & friends.
 	# ADD_CHECK_C_COMPILER_FLAG(C_WARNINGS C_WARN_DOUBLE_PROMOTION -Wdouble-promotion -Wno-error=double-promotion)
-	ADD_CHECK_C_COMPILER_FLAG(C_WARNINGS C_WARN_NO_ERROR_UNUSED_BUT_SET_VARIABLE -Wno-error=unused-but-set-variable)
 
+	if(NOT APPLE)
+		ADD_CHECK_C_COMPILER_FLAG(C_WARNINGS C_WARN_NO_ERROR_UNUSED_BUT_SET_VARIABLE -Wno-error=unused-but-set-variable)
+	endif()
+
 	ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_ALL -Wall)
 	ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_NO_INVALID_OFFSETOF -Wno-invalid-offsetof)
 	ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_NO_SIGN_COMPARE -Wno-sign-compare)
@@ -1405,8 +1408,11 @@
 	# flags to undo strict flags
 	ADD_CHECK_C_COMPILER_FLAG(CC_REMOVE_STRICT_FLAGS C_WARN_NO_DEPRECATED_DECLARATIONS -Wno-deprecated-declarations)
 	ADD_CHECK_C_COMPILER_FLAG(CC_REMOVE_STRICT_FLAGS C_WARN_NO_UNUSED_PARAMETER        -Wno-unused-parameter)
-	ADD_CHECK_C_COMPILER_FLAG(CC_REMOVE_STRICT_FLAGS C_WARN_NO_UNUSED_BUT_SET_VARIABLE -Wno-unused-but-set-variable)
 
+	if(NOT APPLE)
+		ADD_CHECK_C_COMPILER_FLAG(CC_REMOVE_STRICT_FLAGS C_WARN_NO_ERROR_UNUSED_BUT_SET_VARIABLE -Wno-error=unused-but-set-variable)
+	endif()
+
 elseif(CMAKE_C_COMPILER_ID MATCHES "Intel")
 
 	ADD_CHECK_C_COMPILER_FLAG(C_WARNINGS C_WARN_ALL -Wall)

Modified: branches/bmesh/blender/build_files/scons/config/win32-vc-config.py
===================================================================
--- branches/bmesh/blender/build_files/scons/config/win32-vc-config.py	2012-01-02 02:13:31 UTC (rev 43062)
+++ branches/bmesh/blender/build_files/scons/config/win32-vc-config.py	2012-01-02 02:57:36 UTC (rev 43063)
@@ -57,7 +57,7 @@
 BF_OPENEXR = LIBDIR + '/openexr'
 BF_OPENEXR_INC = '${BF_OPENEXR}/include ${BF_OPENEXR}/include/IlmImf ${BF_OPENEXR}/include/Iex ${BF_OPENEXR}/include/Imath '
 BF_OPENEXR_LIB = ' Iex Half IlmImf Imath IlmThread '
-BF_OPENEXR_LIBPATH = '${BF_OPENEXR}/lib_vs2008'
+BF_OPENEXR_LIBPATH = '${BF_OPENEXR}/lib'
 # Warning, this static lib configuration is untested! users of this OS please confirm.
 BF_OPENEXR_LIB_STATIC = '${BF_OPENEXR}/lib/libHalf.a ${BF_OPENEXR}/lib/libIlmImf.a ${BF_OPENEXR}/lib/libIex.a ${BF_OPENEXR}/lib/libImath.a ${BF_OPENEXR}/lib/libIlmThread.a'
 

Modified: branches/bmesh/blender/build_files/scons/config/win64-vc-config.py
===================================================================
--- branches/bmesh/blender/build_files/scons/config/win64-vc-config.py	2012-01-02 02:13:31 UTC (rev 43062)
+++ branches/bmesh/blender/build_files/scons/config/win64-vc-config.py	2012-01-02 02:57:36 UTC (rev 43063)
@@ -61,7 +61,7 @@
 BF_OPENEXR = LIBDIR + '/openexr'
 BF_OPENEXR_INC = '${BF_OPENEXR}/include ${BF_OPENEXR}/include/IlmImf ${BF_OPENEXR}/include/Iex ${BF_OPENEXR}/include/Imath '
 BF_OPENEXR_LIB = ' Iex Half IlmImf Imath IlmThread '
-BF_OPENEXR_LIBPATH = '${BF_OPENEXR}/lib_vs2008'
+BF_OPENEXR_LIBPATH = '${BF_OPENEXR}/lib'
 # Warning, this static lib configuration is untested! users of this OS please confirm.
 BF_OPENEXR_LIB_STATIC = '${BF_OPENEXR}/lib/libHalf.a ${BF_OPENEXR}/lib/libIlmImf.a ${BF_OPENEXR}/lib/libIex.a ${BF_OPENEXR}/lib/libImath.a ${BF_OPENEXR}/lib/libIlmThread.a'
 

Modified: branches/bmesh/blender/intern/cycles/device/device.cpp
===================================================================
--- branches/bmesh/blender/intern/cycles/device/device.cpp	2012-01-02 02:13:31 UTC (rev 43062)
+++ branches/bmesh/blender/intern/cycles/device/device.cpp	2012-01-02 02:57:36 UTC (rev 43063)
@@ -38,7 +38,8 @@
 DeviceTask::DeviceTask(Type type_)
 : type(type_), x(0), y(0), w(0), h(0), rng_state(0), rgba(0), buffer(0),
   sample(0), resolution(0),
-  displace_input(0), displace_offset(0), displace_x(0), displace_w(0)
+  shader_input(0), shader_output(0),
+  shader_eval_type(0), shader_x(0), shader_w(0)
 {
 }
 
@@ -46,8 +47,8 @@
 {
 	int num;
 
-	if(type == DISPLACE) {
-		num = (displace_w + max_size - 1)/max_size;
+	if(type == SHADER) {
+		num = (shader_w + max_size - 1)/max_size;
 	}
 	else {
 		max_size = max(1, max_size/w);
@@ -68,17 +69,17 @@
 
 void DeviceTask::split(list<DeviceTask>& tasks, int num)
 {
-	if(type == DISPLACE) {
-		num = min(displace_w, num);
+	if(type == SHADER) {
+		num = min(shader_w, num);
 
 		for(int i = 0; i < num; i++) {
-			int tx = displace_x + (displace_w/num)*i;
-			int tw = (i == num-1)? displace_w - i*(displace_w/num): displace_w/num;
+			int tx = shader_x + (shader_w/num)*i;
+			int tw = (i == num-1)? shader_w - i*(shader_w/num): shader_w/num;
 
 			DeviceTask task = *this;
 
-			task.displace_x = tx;
-			task.displace_w = tw;
+			task.shader_x = tx;
+			task.shader_w = tw;
 
 			tasks.push_back(task);
 		}

Modified: branches/bmesh/blender/intern/cycles/device/device.h
===================================================================
--- branches/bmesh/blender/intern/cycles/device/device.h	2012-01-02 02:13:31 UTC (rev 43062)
+++ branches/bmesh/blender/intern/cycles/device/device.h	2012-01-02 02:57:36 UTC (rev 43063)
@@ -52,7 +52,7 @@
 
 class DeviceTask {
 public:
-	typedef enum { PATH_TRACE, TONEMAP, DISPLACE } Type;
+	typedef enum { PATH_TRACE, TONEMAP, SHADER } Type;
 	Type type;
 
 	int x, y, w, h;
@@ -63,9 +63,10 @@
 	int resolution;
 	int offset, stride;
 
-	device_ptr displace_input;
-	device_ptr displace_offset;
-	int displace_x, displace_w;
+	device_ptr shader_input;
+	device_ptr shader_output;
+	int shader_eval_type;
+	int shader_x, shader_w;
 
 	DeviceTask(Type type = PATH_TRACE);
 

Modified: branches/bmesh/blender/intern/cycles/device/device_cpu.cpp
===================================================================
--- branches/bmesh/blender/intern/cycles/device/device_cpu.cpp	2012-01-02 02:13:31 UTC (rev 43062)
+++ branches/bmesh/blender/intern/cycles/device/device_cpu.cpp	2012-01-02 02:57:36 UTC (rev 43063)
@@ -141,8 +141,8 @@
 				thread_path_trace(task);
 			else if(task.type == DeviceTask::TONEMAP)
 				thread_tonemap(task);
-			else if(task.type == DeviceTask::DISPLACE)
-				thread_displace(task);
+			else if(task.type == DeviceTask::SHADER)
+				thread_shader(task);
 
 			tasks.worker_done();
 		}
@@ -207,7 +207,7 @@
 		}
 	}
 
-	void thread_displace(DeviceTask& task)
+	void thread_shader(DeviceTask& task)
 	{
 #ifdef WITH_OSL
 		if(kernel_osl_use(kg))
@@ -216,8 +216,8 @@
 
 #ifdef WITH_OPTIMIZED_KERNEL
 		if(system_cpu_support_optimized()) {
-			for(int x = task.displace_x; x < task.displace_x + task.displace_w; x++) {
-				kernel_cpu_optimized_displace(kg, (uint4*)task.displace_input, (float3*)task.displace_offset, x);
+			for(int x = task.shader_x; x < task.shader_x + task.shader_w; x++) {
+				kernel_cpu_optimized_shader(kg, (uint4*)task.shader_input, (float3*)task.shader_output, task.shader_eval_type, x);
 
 				if(tasks.worker_cancel())
 					break;
@@ -226,8 +226,8 @@
 		else
 #endif
 		{
-			for(int x = task.displace_x; x < task.displace_x + task.displace_w; x++) {
-				kernel_cpu_displace(kg, (uint4*)task.displace_input, (float3*)task.displace_offset, x);
+			for(int x = task.shader_x; x < task.shader_x + task.shader_w; x++) {
+				kernel_cpu_shader(kg, (uint4*)task.shader_input, (float3*)task.shader_output, task.shader_eval_type, x);
 
 				if(tasks.worker_cancel())
 					break;

Modified: branches/bmesh/blender/intern/cycles/device/device_cuda.cpp
===================================================================
--- branches/bmesh/blender/intern/cycles/device/device_cuda.cpp	2012-01-02 02:13:31 UTC (rev 43062)
+++ branches/bmesh/blender/intern/cycles/device/device_cuda.cpp	2012-01-02 02:57:36 UTC (rev 43063)
@@ -615,16 +615,16 @@
 		cuda_pop_context();
 	}
 
-	void displace(DeviceTask& task)
+	void shader(DeviceTask& task)
 	{
 		cuda_push_context();
 
 		CUfunction cuDisplace;
-		CUdeviceptr d_input = cuda_device_ptr(task.displace_input);
-		CUdeviceptr d_offset = cuda_device_ptr(task.displace_offset);
+		CUdeviceptr d_input = cuda_device_ptr(task.shader_input);
+		CUdeviceptr d_offset = cuda_device_ptr(task.shader_output);
 
 		/* get kernel function */
-		cuda_assert(cuModuleGetFunction(&cuDisplace, cuModule, "kernel_cuda_displace"))
+		cuda_assert(cuModuleGetFunction(&cuDisplace, cuModule, "kernel_cuda_shader"))
 		
 		/* pass in parameters */
 		int offset = 0;
@@ -635,12 +635,15 @@
 		cuda_assert(cuParamSetv(cuDisplace, offset, &d_offset, sizeof(d_offset)))
 		offset += sizeof(d_offset);
 
-		int displace_x = task.displace_x;
-		offset = cuda_align_up(offset, __alignof(displace_x));
+		int shader_eval_type = task.shader_eval_type;
+		offset = cuda_align_up(offset, __alignof(shader_eval_type));
 
-		cuda_assert(cuParamSeti(cuDisplace, offset, task.displace_x))
-		offset += sizeof(task.displace_x);
+		cuda_assert(cuParamSeti(cuDisplace, offset, task.shader_eval_type))
+		offset += sizeof(task.shader_eval_type);
 
+		cuda_assert(cuParamSeti(cuDisplace, offset, task.shader_x))
+		offset += sizeof(task.shader_x);
+
 		cuda_assert(cuParamSetSize(cuDisplace, offset))
 
 		/* launch kernel: todo find optimal size, cache config for fermi */
@@ -649,7 +652,7 @@
 #else
 		int xthreads = 8;
 #endif
-		int xblocks = (task.displace_w + xthreads - 1)/xthreads;
+		int xblocks = (task.shader_w + xthreads - 1)/xthreads;
 
 		cuda_assert(cuFuncSetCacheConfig(cuDisplace, CU_FUNC_CACHE_PREFER_L1))
 		cuda_assert(cuFuncSetBlockShape(cuDisplace, xthreads, 1, 1))
@@ -828,8 +831,8 @@
 			tonemap(task);

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list