[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [43437] branches/bmesh/blender: svn merge ^/trunk/blender -r43420:43436

Campbell Barton ideasman42 at gmail.com
Tue Jan 17 03:20:30 CET 2012


Revision: 43437
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=43437
Author:   campbellbarton
Date:     2012-01-17 02:20:23 +0000 (Tue, 17 Jan 2012)
Log Message:
-----------
svn merge ^/trunk/blender -r43420:43436

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

Modified Paths:
--------------
    branches/bmesh/blender/CMakeLists.txt
    branches/bmesh/blender/build_files/scons/tools/btools.py
    branches/bmesh/blender/extern/CMakeLists.txt
    branches/bmesh/blender/extern/SConscript
    branches/bmesh/blender/intern/boolop/CMakeLists.txt
    branches/bmesh/blender/intern/boolop/SConscript
    branches/bmesh/blender/intern/boolop/intern/BOP_BSPNode.cpp
    branches/bmesh/blender/intern/boolop/intern/BOP_BSPNode.h
    branches/bmesh/blender/intern/boolop/intern/BOP_BSPTree.cpp
    branches/bmesh/blender/intern/boolop/intern/BOP_Edge.cpp
    branches/bmesh/blender/intern/boolop/intern/BOP_Face.h
    branches/bmesh/blender/intern/boolop/intern/BOP_Indexs.h
    branches/bmesh/blender/intern/boolop/intern/BOP_Interface.cpp
    branches/bmesh/blender/intern/boolop/intern/BOP_MathUtils.cpp
    branches/bmesh/blender/intern/boolop/intern/BOP_Merge.h
    branches/bmesh/blender/intern/boolop/intern/BOP_Merge2.h
    branches/bmesh/blender/intern/boolop/intern/BOP_Mesh.h
    branches/bmesh/blender/intern/boolop/intern/BOP_Segment.cpp
    branches/bmesh/blender/intern/boolop/intern/BOP_Segment.h
    branches/bmesh/blender/intern/boolop/intern/BOP_Splitter.cpp
    branches/bmesh/blender/intern/boolop/intern/BOP_Triangulator.cpp
    branches/bmesh/blender/intern/cycles/blender/addon/properties.py
    branches/bmesh/blender/intern/cycles/blender/addon/ui.py
    branches/bmesh/blender/intern/cycles/blender/blender_sync.cpp
    branches/bmesh/blender/intern/cycles/bvh/bvh.cpp
    branches/bmesh/blender/intern/cycles/bvh/bvh.h
    branches/bmesh/blender/intern/cycles/bvh/bvh_params.h
    branches/bmesh/blender/intern/cycles/render/mesh.cpp
    branches/bmesh/blender/intern/cycles/util/util_cache.cpp
    branches/bmesh/blender/intern/cycles/util/util_cache.h
    branches/bmesh/blender/intern/ghost/intern/GHOST_SystemWin32.cpp
    branches/bmesh/blender/release/scripts/startup/bl_ui/properties_physics_dynamicpaint.py
    branches/bmesh/blender/source/blender/blenkernel/BKE_blender.h
    branches/bmesh/blender/source/blender/blenkernel/BKE_text.h
    branches/bmesh/blender/source/blender/blenkernel/intern/dynamicpaint.c
    branches/bmesh/blender/source/blender/blenkernel/intern/softbody.c
    branches/bmesh/blender/source/blender/blenkernel/intern/text.c
    branches/bmesh/blender/source/blender/blenloader/intern/readfile.c
    branches/bmesh/blender/source/blender/editors/animation/anim_channels_edit.c
    branches/bmesh/blender/source/blender/editors/animation/anim_markers.c
    branches/bmesh/blender/source/blender/editors/animation/keyframing.c
    branches/bmesh/blender/source/blender/editors/armature/armature_ops.c
    branches/bmesh/blender/source/blender/editors/curve/curve_ops.c
    branches/bmesh/blender/source/blender/editors/interface/interface_layout.c
    branches/bmesh/blender/source/blender/editors/interface/interface_templates.c
    branches/bmesh/blender/source/blender/editors/interface/view2d_ops.c
    branches/bmesh/blender/source/blender/editors/mesh/mesh_ops.c
    branches/bmesh/blender/source/blender/editors/metaball/mball_ops.c
    branches/bmesh/blender/source/blender/editors/object/object_add.c
    branches/bmesh/blender/source/blender/editors/object/object_ops.c
    branches/bmesh/blender/source/blender/editors/physics/physics_ops.c
    branches/bmesh/blender/source/blender/editors/render/render_opengl.c
    branches/bmesh/blender/source/blender/editors/screen/screen_ops.c
    branches/bmesh/blender/source/blender/editors/sculpt_paint/paint_ops.c
    branches/bmesh/blender/source/blender/editors/space_clip/clip_ops.c
    branches/bmesh/blender/source/blender/editors/space_clip/space_clip.c
    branches/bmesh/blender/source/blender/editors/space_console/space_console.c
    branches/bmesh/blender/source/blender/editors/space_graph/graph_ops.c
    branches/bmesh/blender/source/blender/editors/space_nla/nla_ops.c
    branches/bmesh/blender/source/blender/editors/space_node/node_ops.c
    branches/bmesh/blender/source/blender/editors/space_outliner/outliner_ops.c
    branches/bmesh/blender/source/blender/editors/space_sequencer/sequencer_edit.c
    branches/bmesh/blender/source/blender/editors/space_sequencer/sequencer_ops.c
    branches/bmesh/blender/source/blender/editors/space_text/space_text.c
    branches/bmesh/blender/source/blender/editors/space_text/text_draw.c
    branches/bmesh/blender/source/blender/editors/space_text/text_intern.h
    branches/bmesh/blender/source/blender/editors/space_text/text_ops.c
    branches/bmesh/blender/source/blender/editors/space_view3d/view3d_header.c
    branches/bmesh/blender/source/blender/editors/space_view3d/view3d_ops.c
    branches/bmesh/blender/source/blender/editors/uvedit/uvedit_ops.c
    branches/bmesh/blender/source/blender/makesdna/DNA_dynamicpaint_types.h
    branches/bmesh/blender/source/blender/makesrna/intern/rna_dynamicpaint.c
    branches/bmesh/blender/source/blender/modifiers/intern/MOD_boolean.c
    branches/bmesh/blender/source/blenderplayer/CMakeLists.txt
    branches/bmesh/blender/source/creator/CMakeLists.txt
    branches/bmesh/blender/source/creator/creator.c
    branches/bmesh/blender/source/tests/bl_mesh_modifiers.py

Added Paths:
-----------
    branches/bmesh/blender/extern/carve/
    branches/bmesh/blender/intern/boolop/intern/BOP_CarveInterface.cpp

Property Changed:
----------------
    branches/bmesh/blender/
    branches/bmesh/blender/release/
    branches/bmesh/blender/source/blender/editors/space_outliner/


Property changes on: branches/bmesh/blender
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/soc-2011-cucumber:37517,38384,38387,38403-38404,38407,38968,38970,38973,39045,40845,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-43420
   + /branches/soc-2011-cucumber:37517,38384,38387,38403-38404,38407,38968,38970,38973,39045,40845,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-43436

Modified: branches/bmesh/blender/CMakeLists.txt
===================================================================
--- branches/bmesh/blender/CMakeLists.txt	2012-01-17 02:07:38 UTC (rev 43436)
+++ branches/bmesh/blender/CMakeLists.txt	2012-01-17 02:20:23 UTC (rev 43437)
@@ -208,6 +208,9 @@
 # Camera/motion tracking
 option(WITH_LIBMV         "Enable libmv structure from motion library" ON)
 
+# Mesh boolean lib
+option(WITH_CARVE         "Enable Carve library to handle mesh boolean operations" ON)
+
 # Misc
 option(WITH_INPUT_NDOF "Enable NDOF input devices (SpaceNavigator and friends)" ON)
 option(WITH_RAYOPTIMIZATION	"Enable use of SIMD (SSE) optimizations for the raytracer" ON)
@@ -300,9 +303,13 @@
 	set(WITH_HEADLESS ON)
 endif()
 
-# auto enable openimageio and boost for cycles
+# auto enable openimageio for cycles
 if(WITH_CYCLES)
 	set(WITH_OPENIMAGEIO ON)
+endif()
+
+# auto enable boost for cycles and carve
+if(WITH_CYCLES OR WITH_CARVE)
 	set(WITH_BOOST ON)
 endif()
 
@@ -1085,16 +1092,28 @@
 	endif()
 
 	if(WITH_PYTHON)
-		# we use precompiled libraries for py 3.2 and up by default
+		if(NOT WITH_PYTHON_MODULE)
+			# we use precompiled libraries for py 3.2 and up by default
 
-		# normally cached but not since we include them with blender
-		set(PYTHON_VERSION 3.2)
-		set(PYTHON_INCLUDE_DIR "${LIBDIR}/python/include/python${PYTHON_VERSION}")
-		# set(PYTHON_BINARY "${LIBDIR}/python/bin/python${PYTHON_VERSION}") # not used yet
-		set(PYTHON_LIBRARY python${PYTHON_VERSION})
-		set(PYTHON_LIBPATH "${LIBDIR}/python/lib/python${PYTHON_VERSION}")
-		# set(PYTHON_LINKFLAGS "-u _PyMac_Error")  # won't  build with this enabled
+			# normally cached but not since we include them with blender
+			set(PYTHON_VERSION 3.2)
+			set(PYTHON_INCLUDE_DIR "${LIBDIR}/python/include/python${PYTHON_VERSION}")
+			# set(PYTHON_BINARY "${LIBDIR}/python/bin/python${PYTHON_VERSION}") # not used yet
+			set(PYTHON_LIBRARY python${PYTHON_VERSION})
+			set(PYTHON_LIBPATH "${LIBDIR}/python/lib/python${PYTHON_VERSION}")
+			# set(PYTHON_LINKFLAGS "-u _PyMac_Error")  # won't  build with this enabled
+		else()
+			# module must be compiled against Python framework
 
+			# normally cached but not since we include them with blender
+			set(PYTHON_VERSION 3.2)
+			set(PYTHON_INCLUDE_DIR "/Library/Frameworks/Python.framework/Versions/${PYTHON_VERSION}/include/python${PYTHON_VERSION}m")
+			set(PYTHON_BINARY "/Library/Frameworks/Python.framework/Versions/${PYTHON_VERSION}/bin/python${PYTHON_VERSION}")
+			#set(PYTHON_LIBRARY python${PYTHON_VERSION})
+			set(PYTHON_LIBPATH "/Library/Frameworks/Python.framework/Versions/${PYTHON_VERSION}/lib/python${PYTHON_VERSION}/config-3.2m")
+			#set(PYTHON_LINKFLAGS "-u _PyMac_Error -framework Python")  # won't  build with this enabled
+		endif()
+		
 		# uncached vars
 		set(PYTHON_INCLUDE_DIRS "${PYTHON_INCLUDE_DIR}")
 		set(PYTHON_LIBRARIES  "${PYTHON_LIBRARY}")
@@ -1189,7 +1208,11 @@
 		set(PLATFORM_LINKFLAGS "-fexceptions -framework CoreServices -framework Foundation -framework IOKit -framework AppKit -framework Carbon -framework AGL -framework AudioUnit -framework AudioToolbox -framework CoreAudio -framework QuickTime")
 		set(WITH_INPUT_NDOF OFF)  # unsupported
 	endif()
-
+	
+	if(WITH_PYTHON_MODULE)
+		set(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} /Library/Frameworks/Python.framework/Versions/${PYTHON_VERSION}/python")# force cmake to link right framework
+	endif()
+	
 	if(WITH_OPENCOLLADA)
 		set(OPENCOLLADA ${LIBDIR}/opencollada)
 

Modified: branches/bmesh/blender/build_files/scons/tools/btools.py
===================================================================
--- branches/bmesh/blender/build_files/scons/tools/btools.py	2012-01-17 02:07:38 UTC (rev 43436)
+++ branches/bmesh/blender/build_files/scons/tools/btools.py	2012-01-17 02:20:23 UTC (rev 43437)
@@ -161,7 +161,7 @@
             'WITH_BF_CYCLES', 'WITH_BF_CYCLES_CUDA_BINARIES' 'BF_CYCLES_CUDA_NVCC', 'BF_CYCLES_CUDA_NVCC', 'WITH_BF_CYCLES_CUDA_THREADED_COMPILE',
             'WITH_BF_OIIO', 'WITH_BF_STATICOIIO', 'BF_OIIO', 'BF_OIIO_INC', 'BF_OIIO_LIB', 'BF_OIIO_LIB_STATIC', 'BF_OIIO_LIBPATH',
             'WITH_BF_BOOST', 'WITH_BF_STATICBOOST', 'BF_BOOST', 'BF_BOOST_INC', 'BF_BOOST_LIB', 'BF_BOOST_LIB_STATIC', 'BF_BOOST_LIBPATH',
-            'WITH_BF_LIBMV'
+            'WITH_BF_LIBMV', 'WITH_BF_CARVE'
             ]
     
     # Have options here that scons expects to be lists
@@ -521,6 +521,7 @@
         
         (BoolVariable('WITH_BF_LZO', 'Enable fast LZO pointcache compression', True)),
         (BoolVariable('WITH_BF_LZMA', 'Enable best LZMA pointcache compression', True)),
+        (BoolVariable('WITH_BF_CARVE', 'Enable carve library for mesh boolean operations', True)),
         
         (BoolVariable('WITH_BF_LIBMV', 'Enable libmv structure from motion library', True)),
 

Modified: branches/bmesh/blender/extern/CMakeLists.txt
===================================================================
--- branches/bmesh/blender/extern/CMakeLists.txt	2012-01-17 02:07:38 UTC (rev 43436)
+++ branches/bmesh/blender/extern/CMakeLists.txt	2012-01-17 02:20:23 UTC (rev 43437)
@@ -67,3 +67,7 @@
 if(WITH_LIBMV)
 	add_subdirectory(libmv)
 endif()
+
+if(WITH_CARVE)
+	add_subdirectory(carve)
+endif()

Modified: branches/bmesh/blender/extern/SConscript
===================================================================
--- branches/bmesh/blender/extern/SConscript	2012-01-17 02:07:38 UTC (rev 43436)
+++ branches/bmesh/blender/extern/SConscript	2012-01-17 02:20:23 UTC (rev 43437)
@@ -31,3 +31,6 @@
 
 if env['WITH_BF_LIBMV']:
     SConscript(['libmv/SConscript'])
+
+if env['WITH_BF_CARVE']:
+    SConscript(['carve/SConscript'])

Modified: branches/bmesh/blender/intern/boolop/CMakeLists.txt
===================================================================
--- branches/bmesh/blender/intern/boolop/CMakeLists.txt	2012-01-17 02:07:38 UTC (rev 43436)
+++ branches/bmesh/blender/intern/boolop/CMakeLists.txt	2012-01-17 02:20:23 UTC (rev 43437)
@@ -39,43 +39,71 @@
 
 )
 
-set(SRC
-	intern/BOP_BBox.cpp
-	intern/BOP_BSPNode.cpp
-	intern/BOP_BSPTree.cpp
-	intern/BOP_Edge.cpp
-	intern/BOP_Face.cpp
-	intern/BOP_Face2Face.cpp
-	intern/BOP_Interface.cpp
-	intern/BOP_MathUtils.cpp
-	intern/BOP_Merge.cpp
-	intern/BOP_Merge2.cpp
-	intern/BOP_Mesh.cpp
-	intern/BOP_Segment.cpp
-	intern/BOP_Splitter.cpp
-	intern/BOP_Tag.cpp
-	intern/BOP_Triangulator.cpp
-	intern/BOP_Vertex.cpp
+if(NOT WITH_CARVE)
+	set(SRC
+		intern/BOP_BBox.cpp
+		intern/BOP_BSPNode.cpp
+		intern/BOP_BSPTree.cpp
+		intern/BOP_Edge.cpp
+		intern/BOP_Face.cpp
+		intern/BOP_Face2Face.cpp
+		intern/BOP_Interface.cpp
+		intern/BOP_MathUtils.cpp
+		intern/BOP_Merge.cpp
+		intern/BOP_Merge2.cpp
+		intern/BOP_Mesh.cpp
+		intern/BOP_Segment.cpp
+		intern/BOP_Splitter.cpp
+		intern/BOP_Tag.cpp
+		intern/BOP_Triangulator.cpp
+		intern/BOP_Vertex.cpp
 
-	extern/BOP_Interface.h
-	intern/BOP_BBox.h
-	intern/BOP_BSPNode.h
-	intern/BOP_BSPTree.h
-	intern/BOP_Chrono.h
-	intern/BOP_Edge.h
-	intern/BOP_Face.h
-	intern/BOP_Face2Face.h
-	intern/BOP_Indexs.h
-	intern/BOP_MathUtils.h
-	intern/BOP_Merge.h
-	intern/BOP_Merge2.h
-	intern/BOP_Mesh.h
-	intern/BOP_Misc.h
-	intern/BOP_Segment.h
-	intern/BOP_Splitter.h
-	intern/BOP_Tag.h
-	intern/BOP_Triangulator.h
-	intern/BOP_Vertex.h
-)
+		extern/BOP_Interface.h
+		intern/BOP_BBox.h
+		intern/BOP_BSPNode.h
+		intern/BOP_BSPTree.h
+		intern/BOP_Chrono.h
+		intern/BOP_Edge.h
+		intern/BOP_Face.h
+		intern/BOP_Face2Face.h
+		intern/BOP_Indexs.h
+		intern/BOP_MathUtils.h
+		intern/BOP_Merge.h
+		intern/BOP_Merge2.h
+		intern/BOP_Mesh.h
+		intern/BOP_Misc.h
+		intern/BOP_Segment.h
+		intern/BOP_Splitter.h
+		intern/BOP_Tag.h
+		intern/BOP_Triangulator.h
+		intern/BOP_Vertex.h
+	)
+else()
+	set(SRC
+		intern/BOP_CarveInterface.cpp
+		extern/BOP_Interface.h
+	)
 
+	list(APPEND INC
+		../../extern/carve/include
+	)
+
+	if(WITH_BOOST)
+		if(NOT MSVC)
+			# Boost is setting as preferred collections library in the Carve code when using MSVC compiler
+			add_definitions(
+				-DHAVE_BOOST_UNORDERED_COLLECTIONS
+			)
+		endif()
+
+		add_definitions(
+			-DCARVE_SYSTEM_BOOST
+		)
+
+		list(APPEND INC
+			${BOOST_INCLUDE_DIR}
+		)
+	endif()
+endif()
+
 blender_add_lib(bf_intern_bop "${SRC}" "${INC}" "${INC_SYS}")

Modified: branches/bmesh/blender/intern/boolop/SConscript
===================================================================
--- branches/bmesh/blender/intern/boolop/SConscript	2012-01-17 02:07:38 UTC (rev 43436)
+++ branches/bmesh/blender/intern/boolop/SConscript	2012-01-17 02:20:23 UTC (rev 43437)
@@ -1,14 +1,29 @@
 #!/usr/bin/python
 Import ('env')
 
-sources = env.Glob('intern/*.cpp')
-
 incs = '. intern extern ../moto/include ../container ../memutil'
 incs += ' ../../source/blender/makesdna ../../intern/guardedalloc'
 incs += ' ../../source/blender/blenlib'
 
+defs = []
+
+if not env['WITH_BF_CARVE']:
+    sources = env.Glob('intern/*.cpp')
+    sources.remove('intern' + os.sep + 'BOP_CarveInterface.cpp')
+else:
+    sources = env.Glob('intern/BOP_CarveInterface.cpp')
+    incs += ' ../../extern/carve/include'
+
+    if env['WITH_BF_BOOST']:
+        if env['OURPLATFORM'] not in ('win32-vc', 'win64-vc'):
+            # Boost is setting as preferred collections library in the Carve code when using MSVC compiler
+            defs.append('HAVE_BOOST_UNORDERED_COLLECTIONS')
+
+        defs.append('CARVE_SYSTEM_BOOST')
+        incs +=  ' ' + env['BF_BOOST_INC']
+
 if (env['OURPLATFORM'] == 'win32-mingw'):
     env.BlenderLib ('bf_intern_bop', sources, Split(incs) , [], libtype='intern', priority = 5 )
 else:
-    env.BlenderLib ('bf_intern_bop', sources, Split(incs) , [], libtype='intern', priority = 5 )

@@ Diff output truncated at 10240 characters. @@


More information about the Bf-blender-cvs mailing list