[Bf-blender-cvs] [0834015] master: Fix/Workaround T46412: Defocus node not working on Windows 32 bit

Sergey Sharybin noreply at git.blender.org
Thu Jan 28 11:47:45 CET 2016


Commit: 0834015b7410e6939e7310dd5e4ad01dabad2dfc
Author: Sergey Sharybin
Date:   Thu Jan 28 11:39:17 2016 +0100
Branches: master
https://developer.blender.org/rB0834015b7410e6939e7310dd5e4ad01dabad2dfc

Fix/Workaround T46412: Defocus node not working on Windows 32 bit

The issue was caused by some functions in compositor returning
garbage values. Partially the issue was caused by vc12_xp toolset
we're using, but even with regular vc120 toolset nodes like bokeh
image did not work correct.

This is a bit weird solution, which could indicate some sort
of compiler bug, but is also actually makes sense because we do
use SSE intrinsics in the compositor now. Maybe it all gets
interfered in some way.

In any case, if someone wants to find a real solution for the
issue please go ahead.

This shouldn't have affect on supported platform because we
already demand CPU to have SSE2 support.

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

M	source/blender/compositor/CMakeLists.txt

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

diff --git a/source/blender/compositor/CMakeLists.txt b/source/blender/compositor/CMakeLists.txt
index 9ecbab4..f0ac709 100644
--- a/source/blender/compositor/CMakeLists.txt
+++ b/source/blender/compositor/CMakeLists.txt
@@ -547,6 +547,11 @@ if(WITH_COMPOSITOR_WERROR)
 	ADD_CHECK_CXX_COMPILER_FLAG(CMAKE_CXX_FLAGS C_WERROR -Werror)
 endif()
 
+if(MSVC)
+	set(CMAKE_C_FLAGS "${CMAKE_CXX_FLAGS} /arch:SSE2")
+	set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /arch:SSE2")
+endif()
+
 data_to_c(${CMAKE_CURRENT_SOURCE_DIR}/operations/COM_OpenCLKernels.cl
           ${CMAKE_CURRENT_BINARY_DIR}/operations/COM_OpenCLKernels.cl.h SRC)




More information about the Bf-blender-cvs mailing list