[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [21203] branches/soc-2009-yukishiro: merge till 21202

Jingyuan Huang jingyuan.huang at gmail.com
Sun Jun 28 01:16:29 CEST 2009


Revision: 21203
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=21203
Author:   yukishiro
Date:     2009-06-28 01:16:29 +0200 (Sun, 28 Jun 2009)

Log Message:
-----------
merge till 21202

Modified Paths:
--------------
    branches/soc-2009-yukishiro/CMake/macros.cmake
    branches/soc-2009-yukishiro/CMakeLists.txt
    branches/soc-2009-yukishiro/release/ui/buttons_data_mesh.py
    branches/soc-2009-yukishiro/release/ui/buttons_data_modifier.py
    branches/soc-2009-yukishiro/release/ui/buttons_object_constraint.py
    branches/soc-2009-yukishiro/release/ui/buttons_particle.py
    branches/soc-2009-yukishiro/release/ui/buttons_physic_cloth.py
    branches/soc-2009-yukishiro/release/ui/space_image.py
    branches/soc-2009-yukishiro/release/ui/space_text.py
    branches/soc-2009-yukishiro/source/blender/blenkernel/BKE_cloth.h
    branches/soc-2009-yukishiro/source/blender/blenkernel/BKE_particle.h
    branches/soc-2009-yukishiro/source/blender/blenkernel/BKE_pointcache.h
    branches/soc-2009-yukishiro/source/blender/blenkernel/intern/cloth.c
    branches/soc-2009-yukishiro/source/blender/blenkernel/intern/depsgraph.c
    branches/soc-2009-yukishiro/source/blender/blenkernel/intern/implicit.c
    branches/soc-2009-yukishiro/source/blender/blenkernel/intern/modifier.c
    branches/soc-2009-yukishiro/source/blender/blenkernel/intern/particle.c
    branches/soc-2009-yukishiro/source/blender/blenkernel/intern/particle_system.c
    branches/soc-2009-yukishiro/source/blender/blenkernel/intern/pointcache.c
    branches/soc-2009-yukishiro/source/blender/blenloader/intern/readfile.c
    branches/soc-2009-yukishiro/source/blender/blenloader/intern/writefile.c
    branches/soc-2009-yukishiro/source/blender/editors/include/ED_object.h
    branches/soc-2009-yukishiro/source/blender/editors/include/ED_view3d.h
    branches/soc-2009-yukishiro/source/blender/editors/include/UI_interface.h
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface.c
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface_handlers.c
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface_icons.c
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface_intern.h
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface_layout.c
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface_panel.c
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface_regions.c
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface_templates.c
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface_utils.c
    branches/soc-2009-yukishiro/source/blender/editors/interface/interface_widgets.c
    branches/soc-2009-yukishiro/source/blender/editors/interface/view2d.c
    branches/soc-2009-yukishiro/source/blender/editors/mesh/editmesh_add.c
    branches/soc-2009-yukishiro/source/blender/editors/mesh/editmesh_mods.c
    branches/soc-2009-yukishiro/source/blender/editors/mesh/editmesh_tools.c
    branches/soc-2009-yukishiro/source/blender/editors/object/object_edit.c
    branches/soc-2009-yukishiro/source/blender/editors/physics/ed_pointcache.c
    branches/soc-2009-yukishiro/source/blender/editors/sculpt_paint/sculpt.c
    branches/soc-2009-yukishiro/source/blender/editors/space_buttons/buttons_header.c
    branches/soc-2009-yukishiro/source/blender/editors/space_buttons/buttons_intern.h
    branches/soc-2009-yukishiro/source/blender/editors/space_buttons/buttons_ops.c
    branches/soc-2009-yukishiro/source/blender/editors/space_buttons/space_buttons.c
    branches/soc-2009-yukishiro/source/blender/editors/space_view3d/space_view3d.c
    branches/soc-2009-yukishiro/source/blender/editors/space_view3d/view3d_toolbar.c
    branches/soc-2009-yukishiro/source/blender/editors/transform/transform_conversions.c
    branches/soc-2009-yukishiro/source/blender/editors/util/undo.c
    branches/soc-2009-yukishiro/source/blender/makesdna/DNA_object_force.h
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/makesrna.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_access.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_armature.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_cloth.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_constraint.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_main.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_mesh.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_object.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_object_force.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_particle.c
    branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_ui_api.c
    branches/soc-2009-yukishiro/source/blender/python/intern/bpy_rna.c
    branches/soc-2009-yukishiro/source/blender/render/intern/source/pipeline.c
    branches/soc-2009-yukishiro/source/blender/windowmanager/WM_api.h
    branches/soc-2009-yukishiro/source/blender/windowmanager/intern/wm.c
    branches/soc-2009-yukishiro/source/blender/windowmanager/intern/wm_event_system.c
    branches/soc-2009-yukishiro/source/blender/windowmanager/intern/wm_files.c

Modified: branches/soc-2009-yukishiro/CMake/macros.cmake
===================================================================
--- branches/soc-2009-yukishiro/CMake/macros.cmake	2009-06-27 22:48:39 UTC (rev 21202)
+++ branches/soc-2009-yukishiro/CMake/macros.cmake	2009-06-27 23:16:29 UTC (rev 21203)
@@ -61,7 +61,7 @@
   SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${PLATFORM_LINKFLAGS} ")
   #TARGET_LINK_LIBRARIES(${target} ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY} ${PYTHON_LIB} ${PYTHON_LINKFLAGS} ${JPEG_LIB} ${PNG_LIB} ${ZLIB_LIB} ${SDL_LIB} ${LLIBS})
 
-  TARGET_LINK_LIBRARIES(${target} ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY} ${PYTHON_LINKFLAGS} ${JPEG_LIB} ${PNG_LIB} ${ZLIB_LIB} ${SDL_LIB} ${LLIBS})
+  TARGET_LINK_LIBRARIES(${target} ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY} ${PYTHON_LINKFLAGS} ${JPEG_LIBRARY} ${PNG_LIBRARIES} ${ZLIB_LIBRARIES} ${SDL_LIB} ${LLIBS})
 
   # since we are using the local libs for python when compiling msvc projects, we need to add _d when compiling debug versions
 

Modified: branches/soc-2009-yukishiro/CMakeLists.txt
===================================================================
--- branches/soc-2009-yukishiro/CMakeLists.txt	2009-06-27 22:48:39 UTC (rev 21202)
+++ branches/soc-2009-yukishiro/CMakeLists.txt	2009-06-27 23:16:29 UTC (rev 21203)
@@ -89,7 +89,7 @@
 
 IF(UNIX)
   IF(WITH_OPENAL)
-    INCLUDE(${CMAKE_ROOT}/Modules/FindOpenAL.cmake)
+    FIND_PACKAGE(OpenAL)
     IF(OPENAL_FOUND)
       SET(WITH_OPENAL ON)
       SET(OPENAL_LIB ${OPENAL_LIBRARY})
@@ -102,22 +102,12 @@
   FIND_LIBRARY(INTL_LIBRARY
     NAMES intl
     PATHS
-    /usr/local/lib
-    /usr/lib
     /sw/lib
-    /opt/local/lib
-    /opt/csw/lib
-    /opt/lib
   )
   FIND_LIBRARY(ICONV_LIBRARY
     NAMES iconv
     PATHS
-    /usr/local/lib
-    /usr/lib
     /sw/lib
-    /opt/local/lib
-    /opt/csw/lib
-    /opt/lib
   )
   IF(INTL_LIBRARY AND ICONV_LIBRARY)
     SET(GETTEXT_LIB ${INTL_LIBRARY} ${ICONV_LIBRARY})
@@ -136,14 +126,14 @@
   )
   SET(FREETYPE_LIB freetype)
 
-  INCLUDE(${CMAKE_ROOT}/Modules/FindPythonLibs.cmake)
+  FIND_PACKAGE(PythonLibs)
   SET(PYTHON_INC "${PYTHON_INCLUDE_PATH}" CACHE STRING "")
   SET(PYTHON_LIB "${PYTHON_LIBRARIES}" CACHE STRING "")
-  INCLUDE(${CMAKE_ROOT}/Modules/FindPythonInterp.cmake)
+  FIND_PACKAGE(PythonInterp)
   SET(PYTHON_BINARY ${PYTHON_EXECUTABLE} CACHE STRING "")
   SET(PYTHON_LINKFLAGS "-Xlinker -export-dynamic")
 
-  INCLUDE(${CMAKE_ROOT}/Modules/FindSDL.cmake)
+  FIND_PACKAGE(SDL)
   SET(SDL_INC ${SDL_INCLUDE_DIR})
   SET(SDL_LIB ${SDL_LIBRARY})
 
@@ -164,11 +154,11 @@
   SET(FFMPEG_LIB avformat avcodec avutil avdevice swscale)
   SET(FFMPEG_LIBPATH ${FFMPEG}/lib)
 
-  SET(JPEG_LIB jpeg)
+  FIND_PACKAGE(JPEG REQUIRED)
 
-  SET(PNG_LIB png)
+  FIND_PACKAGE(PNG REQUIRED)
 
-  SET(ZLIB_LIB z)
+  FIND_PACKAGE(ZLIB REQUIRED)
 
   SET(LLIBS "-lXi -lutil -lc -lm -lpthread -lstdc++ -lX11 -ldl -llapack")
 
@@ -185,12 +175,13 @@
   # Better warnings
   SET(C_WARNINGS "-Wall -Wno-char-subscripts -Wpointer-arith -Wcast-align -Wnested-externs -Wdeclaration-after-statement")
 
-  INCLUDE_DIRECTORIES(/usr/include /usr/local/include)
+  INCLUDE_DIRECTORIES(${JPEG_INCLUDE_DIR} ${PNG_INCLUDE_DIR} ${ZLIB_INCLUDE_DIR} )
 ENDIF(UNIX)
 
 IF(WIN32)
 
-  INCLUDE(${CMAKE_ROOT}/Modules/Platform/Windows-cl.cmake)
+  # this file is included anyway when building under Windows with cl.exe
+  #  INCLUDE(${CMAKE_ROOT}/Modules/Platform/Windows-cl.cmake)
   
   SET(LIBDIR ${CMAKE_SOURCE_DIR}/../lib/windows)
 
@@ -218,15 +209,15 @@
   ENDIF(CMAKE_CL_64)
 
   IF(CMAKE_CL_64)
-  	SET(PNG_LIB libpng)
+	SET(PNG_LIBRARIES libpng)
   ELSE(CMAKE_CL_64)
-  	SET(PNG_LIB libpng_st)
+    SET(PNG_LIBRARIES libpng_st)
   ENDIF(CMAKE_CL_64)
-  SET(JPEG_LIB libjpeg)
+  SET(JPEG_LIBRARY libjpeg)
 
   SET(ZLIB ${LIBDIR}/zlib)
   SET(ZLIB_INC ${ZLIB}/include)
-  SET(ZLIB_LIB libz)
+  SET(ZLIB_LIBRARIES zlib)
   SET(ZLIB_LIBPATH ${ZLIB}/lib)
   
   SET(PTHREADS ${LIBDIR}/pthreads)
@@ -334,7 +325,7 @@
   ENDIF(CMAKE_OSX_ARCHITECTURES MATCHES i386)
 
   IF(WITH_OPENAL)
-    INCLUDE(${CMAKE_ROOT}/Modules/FindOpenAL.cmake)
+    FIND_PACKAGE(OpenAL)
     IF(OPENAL_FOUND)
       SET(WITH_OPENAL ON)
       SET(OPENAL_LIB ${OPENAL_LIBRARY})
@@ -361,12 +352,12 @@
   SET(GETTEXT_LIB intl iconv)
   SET(GETTEXT_LIBPATH ${GETTEXT}/lib)
 
-  SET(PNG_LIB png)
-  SET(JPEG_LIB jpeg)
+  SET(PNG_LIBRARIES png)
+  SET(JPEG_LIBRARY jpeg)
 
   SET(ZLIB /usr)
   SET(ZLIB_INC "${ZLIB}/include")
-  SET(ZLIB_LIB z)
+  SET(ZLIB_LIBRARIES z)
 
   SET(FREETYPE ${LIBDIR}/freetype)
   SET(FREETYPE_INC ${FREETYPE}/include ${FREETYPE}/include/freetype2)
@@ -441,7 +432,7 @@
 
 #-----------------------------------------------------------------------------
 # Configure OpenGL.
-INCLUDE(${CMAKE_ROOT}/Modules/FindOpenGL.cmake)
+FIND_PACKAGE(OpenGL)
 INCLUDE_DIRECTORIES(${OPENGL_INCLUDE_DIR})
 #-----------------------------------------------------------------------------
 # Extra compile flags

Modified: branches/soc-2009-yukishiro/release/ui/buttons_data_mesh.py
===================================================================
--- branches/soc-2009-yukishiro/release/ui/buttons_data_mesh.py	2009-06-27 22:48:39 UTC (rev 21202)
+++ branches/soc-2009-yukishiro/release/ui/buttons_data_mesh.py	2009-06-27 23:16:29 UTC (rev 21203)
@@ -74,6 +74,18 @@
 		row.itemO("OBJECT_OT_material_slot_select", text="Select");
 		row.itemO("OBJECT_OT_material_slot_deselect", text="Deselect");
 
+		layout.itemS()
+
+		box= layout.box()
+
+		row = box.row()
+		row.template_list(ob, "materials", "active_material_index", compact=True)
+
+		subrow = row.row(align=True)
+		subrow.itemO("OBJECT_OT_material_slot_add", icon="ICON_ZOOMIN", text="")
+		subrow.itemO("OBJECT_OT_material_slot_remove", icon="ICON_ZOOMOUT", text="")
+
+
 bpy.types.register(DATA_PT_mesh)
 bpy.types.register(DATA_PT_materials)
 

Modified: branches/soc-2009-yukishiro/release/ui/buttons_data_modifier.py
===================================================================
--- branches/soc-2009-yukishiro/release/ui/buttons_data_modifier.py	2009-06-27 22:48:39 UTC (rev 21202)
+++ branches/soc-2009-yukishiro/release/ui/buttons_data_modifier.py	2009-06-27 23:16:29 UTC (rev 21203)
@@ -23,68 +23,68 @@
 
 			if box:
 				if md.type == 'ARMATURE':
-					self.armature(box, md)
+					self.armature(box, ob, md)
 				if md.type == 'ARRAY':
-					self.array(box, md)
+					self.array(box, ob, md)
 				if md.type == 'BEVEL':
-					self.bevel(box, md)
+					self.bevel(box, ob, md)
 				if md.type == 'BOOLEAN':
-					self.boolean(box, md)
+					self.boolean(box, ob, md)
 				if md.type == 'BUILD':
-					self.build(box, md)
+					self.build(box, ob, md)
 				if md.type == 'CAST':
-					self.cast(box, md)
+					self.cast(box, ob, md)
 				if md.type == 'CLOTH':
-					self.cloth(box, md)
+					self.cloth(box, ob, md)
 				if md.type == 'COLLISION':
-					self.collision(box, md)
+					self.collision(box, ob, md)
 				if md.type == 'CURVE':
-					self.curve(box, md)
+					self.curve(box, ob, md)
 				if md.type == 'DECIMATE':
-					self.decimate(box, md)
+					self.decimate(box, ob, md)
 				if md.type == 'DISPLACE':
-					self.displace(box, md)
+					self.displace(box, ob, md)
 				if md.type == 'EDGE_SPLIT':
-					self.edgesplit(box, md)
+					self.edgesplit(box, ob, md)
 				if md.type == 'EXPLODE':
-					self.explode(box, md)
+					self.explode(box, ob, md)
 				if md.type == 'FLUID_SIMULATION':
-					self.fluid(box, md)
+					self.fluid(box, ob, md)
 				if md.type == 'HOOK':
-					self.hook(box, md)
+					self.hook(box, ob, md)
 				if md.type == 'LATTICE':
-					self.lattice(box, md)
+					self.lattice(box, ob, md)
 				if md.type == 'MASK':
-					self.mask(box, md)
+					self.mask(box, ob, md)
 				if md.type == 'MESH_DEFORM':
-					self.mesh_deform(box, md)
+					self.mesh_deform(box, ob, md)
 				if md.type == 'MIRROR':
-					self.mirror(box, md)
+					self.mirror(box, ob, md)
 				if md.type == 'MULTIRES':
-					self.multires(box, md)
+					self.multires(box, ob, md)
 				if md.type == 'PARTICLE_INSTANCE':
-					self.particleinstance(box, md)
+					self.particleinstance(box, ob, md)
 				if md.type == 'PARTICLE_SYSTEM':
-					self.particlesystem(box, md)
+					self.particlesystem(box, ob, md)
 				if md.type == 'SHRINKWRAP':
-					self.shrinkwrap(box, md)
+					self.shrinkwrap(box, ob, md)
 				if md.type == 'SIMPLE_DEFORM':
-					self.simpledeform(box, md)
+					self.simpledeform(box, ob, md)
 				if md.type == 'SMOOTH':
-					self.smooth(box, md)
+					self.smooth(box, ob, md)
 				if md.type == 'SOFTBODY':
-					self.softbody(box, md)
+					self.softbody(box, ob, md)
 				if md.type == 'SUBSURF':
-					self.subsurf(box, md)
+					self.subsurf(box, ob, md)
 				if md.type == 'UV_PROJECT':
-					self.uvproject(box, md)
+					self.uvproject(box, ob, md)
 				if md.type == 'WAVE':
-					self.wave(box, md)
+					self.wave(box, ob, md)
 							
-	def armature(self, layout, md):
+	def armature(self, layout, ob, md):
 		layout.itemR(md, "object")
 		row = layout.row()
-		row.itemR(md, "vertex_group")
+		row.item_pointerR(md, "vertex_group", ob, "vertex_groups")
 		row.itemR(md, "invert")
 		flow = layout.column_flow()
 		flow.itemR(md, "use_vertex_groups", text="Vertex Groups")
@@ -92,7 +92,7 @@
 		flow.itemR(md, "quaternion")
 		flow.itemR(md, "multi_modifier")
 		
-	def array(self, layout, md):
+	def array(self, layout, ob, md):
 		layout.itemR(md, "fit_type")
 		if md.fit_type == 'FIXED_COUNT':
 			layout.itemR(md, "count")
@@ -141,7 +141,7 @@
 		col.itemR(md, "start_cap")
 		col.itemR(md, "end_cap")
 	
-	def bevel(self, layout, md):
+	def bevel(self, layout, ob, md):
 		row = layout.row()
 		row.itemR(md, "width")
 		row.itemR(md, "only_vertices")
@@ -156,11 +156,11 @@
 			row = layout.row()
 			row.itemR(md, "edge_weight_method", expand=True)
 			
-	def boolean(self, layout, md):
+	def boolean(self, layout, ob, md):
 		layout.itemR(md, "operation")
 		layout.itemR(md, "object")
 		
-	def build(self, layout, md):
+	def build(self, layout, ob, md):
 		split = layout.split()
 		
 		col = split.column()
@@ -175,7 +175,7 @@
 			
 		
 			
-	def cast(self, layout, md):
+	def cast(self, layout, ob, md):
 		layout.itemR(md, "cast_type")
 		col = layout.column_flow()
 		col.itemR(md, "x")
@@ -184,26 +184,26 @@
 		col.itemR(md, "factor")
 		col.itemR(md, "radius")
 		col.itemR(md, "size")
-		layout.itemR(md, "vertex_group")
+		layout.item_pointerR(md, "vertex_group", ob, "vertex_groups")
 		#Missing: "OB" and "From Radius"
 		
-	def cloth(self, layout, md):

@@ Diff output truncated at 10240 characters. @@




More information about the Bf-blender-cvs mailing list