[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37436] branches/soc-2011-salad: Merging r37388 through r37435 from trunk into soc-2011-salad
Sergey Sharybin
g.ulairi at gmail.com
Sun Jun 12 20:28:40 CEST 2011
Revision: 37436
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=37436
Author: nazgul
Date: 2011-06-12 18:28:40 +0000 (Sun, 12 Jun 2011)
Log Message:
-----------
Merging r37388 through r37435 from trunk into soc-2011-salad
Revision Links:
--------------
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=37388
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=37435
Modified Paths:
--------------
branches/soc-2011-salad/build_files/cmake/FindPythonLibsUnix.cmake
branches/soc-2011-salad/build_files/cmake/macros.cmake
branches/soc-2011-salad/release/scripts/modules/console/intellisense.py
branches/soc-2011-salad/release/scripts/startup/bl_operators/object_quick_effects.py
branches/soc-2011-salad/release/scripts/startup/bl_ui/properties_render.py
branches/soc-2011-salad/source/blender/blenkernel/BKE_particle.h
branches/soc-2011-salad/source/blender/blenkernel/intern/bvhutils.c
branches/soc-2011-salad/source/blender/blenkernel/intern/particle_system.c
branches/soc-2011-salad/source/blender/editors/interface/interface_widgets.c
branches/soc-2011-salad/source/blender/editors/mesh/editmesh_tools.c
branches/soc-2011-salad/source/blender/editors/render/render_internal.c
branches/soc-2011-salad/source/blender/editors/space_console/console_draw.c
branches/soc-2011-salad/source/blender/editors/space_image/image_buttons.c
branches/soc-2011-salad/source/blender/editors/space_node/node_edit.c
branches/soc-2011-salad/source/blender/editors/space_sequencer/sequencer_edit.c
branches/soc-2011-salad/source/blender/makesdna/DNA_scene_types.h
branches/soc-2011-salad/source/blender/makesrna/intern/rna_controller.c
branches/soc-2011-salad/source/blender/modifiers/intern/MOD_explode.c
branches/soc-2011-salad/source/blender/render/extern/include/RE_pipeline.h
branches/soc-2011-salad/source/blender/render/intern/include/render_types.h
branches/soc-2011-salad/source/blender/render/intern/source/convertblender.c
branches/soc-2011-salad/source/blender/render/intern/source/envmap.c
branches/soc-2011-salad/source/blender/render/intern/source/pipeline.c
branches/soc-2011-salad/source/blender/render/intern/source/pixelshading.c
branches/soc-2011-salad/source/blenderplayer/CMakeLists.txt
branches/soc-2011-salad/source/creator/CMakeLists.txt
branches/soc-2011-salad/source/gameengine/Physics/Bullet/CcdPhysicsController.h
Property Changed:
----------------
branches/soc-2011-salad/
Property changes on: branches/soc-2011-salad
___________________________________________________________________
Modified: svn:mergeinfo
- /branches/soc-2010-jwilkins:28499-37009
/branches/soc-2010-nicolasbishop:28448-30783
/branches/soc-2011-cucumber:36829-36994
/branches/soc-2011-onion:36833-37387
/branches/soc-2011-pepper:36830-37151
/trunk/blender:36834-37387
+ /branches/soc-2010-jwilkins:28499-37009
/branches/soc-2010-nicolasbishop:28448-30783
/branches/soc-2011-cucumber:36829-36994
/branches/soc-2011-onion:36833-37387
/branches/soc-2011-pepper:36830-37151
/trunk/blender:36834-37435
Modified: branches/soc-2011-salad/build_files/cmake/FindPythonLibsUnix.cmake
===================================================================
--- branches/soc-2011-salad/build_files/cmake/FindPythonLibsUnix.cmake 2011-06-12 18:25:31 UTC (rev 37435)
+++ branches/soc-2011-salad/build_files/cmake/FindPythonLibsUnix.cmake 2011-06-12 18:28:40 UTC (rev 37436)
@@ -53,8 +53,17 @@
if(NOT _Found_PYTHON_H)
message(FATAL_ERROR "Python.h not found")
endif()
+
+ unset(_Found_PYTHON_H)
+ unset(_Python_HEADER)
+ unset(_CURRENT_ABI_FLAGS)
+ unset(_CURRENT_PATH)
+
endif()
+unset(_Python_ABI_FLAGS)
+unset(_Python_PATHS)
+
#=============================================================================
# now the python versions are found
Modified: branches/soc-2011-salad/build_files/cmake/macros.cmake
===================================================================
--- branches/soc-2011-salad/build_files/cmake/macros.cmake 2011-06-12 18:25:31 UTC (rev 37435)
+++ branches/soc-2011-salad/build_files/cmake/macros.cmake 2011-06-12 18:28:40 UTC (rev 37436)
@@ -5,22 +5,28 @@
# use it instead of include_directories()
macro(blender_include_dirs
includes)
-
- foreach(inc ${ARGV})
- get_filename_component(abs_inc ${inc} ABSOLUTE)
- list(APPEND all_incs ${abs_inc})
+ set(_ALL_INCS "")
+ foreach(_INC ${ARGV})
+ get_filename_component(_ABS_INC ${_INC} ABSOLUTE)
+ list(APPEND _ALL_INCS ${_ABS_INC})
endforeach()
- include_directories(${all_incs})
+ include_directories(${_ALL_INCS})
+ unset(_INC)
+ unset(_ABS_INC)
+ unset(_ALL_INCS)
endmacro()
macro(blender_include_dirs_sys
includes)
-
- foreach(inc ${ARGV})
- get_filename_component(abs_inc ${inc} ABSOLUTE)
- list(APPEND all_incs ${abs_inc})
+ set(_ALL_INCS "")
+ foreach(_INC ${ARGV})
+ get_filename_component(_ABS_INC ${_INC} ABSOLUTE)
+ list(APPEND _ALL_INCS ${_ABS_INC})
endforeach()
- include_directories(SYSTEM ${all_incs})
+ include_directories(SYSTEM ${_ALL_INCS})
+ unset(_INC)
+ unset(_ABS_INC)
+ unset(_ALL_INCS)
endmacro()
macro(blender_source_group
@@ -29,14 +35,17 @@
# Group by location on disk
source_group("Source Files" FILES CMakeLists.txt)
- foreach(SRC ${sources})
- get_filename_component(SRC_EXT ${SRC} EXT)
- if(${SRC_EXT} MATCHES ".h" OR ${SRC_EXT} MATCHES ".hpp")
- source_group("Header Files" FILES ${SRC})
+ foreach(_SRC ${sources})
+ get_filename_component(_SRC_EXT ${_SRC} EXT)
+ if(${_SRC_EXT} MATCHES ".h" OR ${_SRC_EXT} MATCHES ".hpp")
+ source_group("Header Files" FILES ${_SRC})
else()
- source_group("Source Files" FILES ${SRC})
+ source_group("Source Files" FILES ${_SRC})
endif()
endforeach()
+
+ unset(_SRC)
+ unset(_SRC_EXT)
endmacro()
@@ -196,10 +205,11 @@
endif()
if(WITH_IMAGE_OPENEXR)
if(WIN32 AND NOT UNIX)
- foreach(loop_var ${OPENEXR_LIB})
- target_link_libraries(${target} debug ${loop_var}_d)
- target_link_libraries(${target} optimized ${loop_var})
+ foreach(_LOOP_VAR ${OPENEXR_LIB})
+ target_link_libraries(${target} debug ${_LOOP_VAR}_d)
+ target_link_libraries(${target} optimized ${_LOOP_VAR})
endforeach()
+ unset(_LOOP_VAR)
else()
target_link_libraries(${target} ${OPENEXR_LIB})
endif()
@@ -212,10 +222,11 @@
endif()
if(WITH_OPENCOLLADA)
if(WIN32 AND NOT UNIX)
- foreach(loop_var ${OPENCOLLADA_LIB})
- target_link_libraries(${target} debug ${loop_var}_d)
- target_link_libraries(${target} optimized ${loop_var})
+ foreach(_LOOP_VAR ${OPENCOLLADA_LIB})
+ target_link_libraries(${target} debug ${_LOOP_VAR}_d)
+ target_link_libraries(${target} optimized ${_LOOP_VAR})
endforeach()
+ unset(_LOOP_VAR)
target_link_libraries(${target} debug ${PCRE_LIB}_d)
target_link_libraries(${target} optimized ${PCRE_LIB})
if(EXPAT_LIB)
@@ -472,4 +483,13 @@
unset(_reset_standard_cflags_rel)
unset(_reset_standard_cxxflags_rel)
+
+ # --------------------------------------------------
+ # workaround for omission in cmake 2.8.4's GNU.cmake
+ if(CMAKE_COMPILER_IS_GNUCC)
+ if(NOT DARWIN)
+ set(CMAKE_INCLUDE_SYSTEM_FLAG_C "-isystem ")
+ endif()
+ endif()
+
endmacro()
Modified: branches/soc-2011-salad/release/scripts/modules/console/intellisense.py
===================================================================
--- branches/soc-2011-salad/release/scripts/modules/console/intellisense.py 2011-06-12 18:25:31 UTC (rev 37435)
+++ branches/soc-2011-salad/release/scripts/modules/console/intellisense.py 2011-06-12 18:28:40 UTC (rev 37436)
@@ -120,22 +120,25 @@
from . import complete_calltip
matches, word, scrollback = complete_calltip.complete(line,
cursor, namespace)
+ prefix = os.path.commonprefix(matches)[len(word):]
no_calltip = False
else:
matches, word = complete(line, cursor, namespace, private)
+ prefix = os.path.commonprefix(matches)[len(word):]
if len(matches) == 1:
scrollback = ''
else:
# causes blender bug [#27495] since string keys may contain '.'
# scrollback = ' '.join([m.split('.')[-1] for m in matches])
+ word_prefix = word + prefix
scrollback = ' '.join(
- [m[len(word):]
- if (word and m.startswith(word))
+ [m[len(word_prefix):]
+ if (word_prefix and m.startswith(word_prefix))
else m.split('.')[-1]
for m in matches])
no_calltip = True
- prefix = os.path.commonprefix(matches)[len(word):]
+
if prefix:
line = line[:cursor] + prefix + line[cursor:]
cursor += len(prefix)
Modified: branches/soc-2011-salad/release/scripts/startup/bl_operators/object_quick_effects.py
===================================================================
--- branches/soc-2011-salad/release/scripts/startup/bl_operators/object_quick_effects.py 2011-06-12 18:25:31 UTC (rev 37435)
+++ branches/soc-2011-salad/release/scripts/startup/bl_operators/object_quick_effects.py 2011-06-12 18:28:40 UTC (rev 37436)
@@ -22,10 +22,9 @@
import bpy
from bpy.props import BoolProperty, EnumProperty, IntProperty, FloatProperty, FloatVectorProperty
-
-class MakeFur(bpy.types.Operator):
- bl_idname = "object.make_fur"
- bl_label = "Make Fur"
+class QuickFur(bpy.types.Operator):
+ bl_idname = "object.quick_fur"
+ bl_label = "Quick Fur"
bl_options = {'REGISTER', 'UNDO'}
density = EnumProperty(items=(
@@ -79,7 +78,156 @@
return {'FINISHED'}
+class QuickExplode(bpy.types.Operator):
+ bl_idname = "object.quick_explode"
+ bl_label = "Quick Explode"
+ bl_options = {'REGISTER', 'UNDO'}
+ style = EnumProperty(items=(
+ ('EXPLODE', "Explode", ""),
+ ('BLEND', "Blend", "")),
+ name="Explode Style",
+ description="",
+ default='EXPLODE')
+
+ amount = IntProperty(name="Amount of pieces",
+ default=100, min=2, max=10000, soft_min=2, soft_max=10000)
+
+ duration = IntProperty(name="Duration",
+ default=50, min=1, max=10000, soft_min=1, soft_max=10000)
+
+ start_frame = IntProperty(name="Start Frame",
+ default=1, min=1, max=10000, soft_min=1, soft_max=10000)
+
+ end_frame = IntProperty(name="End Frame",
+ default=10, min=1, max=10000, soft_min=1, soft_max=10000)
+
+ velocity = FloatProperty(name="Outwards Velocity",
+ default=1, min=0, max=1000, soft_min=0, soft_max=10)
+
+ fade = BoolProperty(name="Fade",
+ description="Fade the pieces over time.",
+ default=True)
+
+ invert_order = BoolProperty(name="Invert Order",
+ description="Blend objects in the opposite direction (only for Blend style explosion).",
+ default=False)
+
+ def execute(self, context):
+ fake_context = bpy.context.copy()
+ mesh_objects = [obj for obj in context.selected_objects if obj.type == 'MESH']
+
+ if self.style == 'BLEND' and len(mesh_objects) != 2:
+ self.report({'ERROR'}, "Select two mesh objects.")
+ return {'CANCELLED'}
+ elif not mesh_objects:
+ self.report({'ERROR'}, "Select at least one mesh object.")
+ return {'CANCELLED'}
+
+ for obj in mesh_objects:
+ if len(obj.particle_systems) > 0:
+ self.report({'ERROR'}, "Selected object's can't have particle systems.")
+ return {'CANCELLED'}
+
+ if self.fade:
+ tex = bpy.data.textures.new("Explode fade", 'BLEND')
+ tex.use_color_ramp = True
+
+ if self.style == 'BLEND':
+ tex.color_ramp.elements[0].position = 0.333
+ tex.color_ramp.elements[1].position = 0.666
+
+ tex.color_ramp.elements[0].color[3] = 1
+ tex.color_ramp.elements[1].color[3] = 0
+
+ if self.style == 'BLEND':
+ if self.invert_order:
+ from_obj = mesh_objects[1]
+ to_obj = mesh_objects[0]
+ else:
+ from_obj = mesh_objects[0]
+ to_obj = mesh_objects[1]
+
+ for obj in mesh_objects:
+ fake_context["object"] = obj
+ bpy.ops.object.particle_system_add(fake_context)
+
+ settings = obj.particle_systems[-1].settings
+ settings.count = self.amount
+ settings.frame_start = self.start_frame
+ settings.frame_end = self.end_frame - self.duration
+ settings.lifetime = self.duration
+ settings.normal_factor = self.velocity
+ settings.render_type = 'NONE'
+
+ bpy.ops.object.modifier_add(fake_context, type='EXPLODE')
+ explode = obj.modifiers[-1]
+ explode.use_edge_cut = True
+
+ if self.fade:
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list