[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [55860] trunk/blender: SVN maintenance.
gsr b3d
gsr.b3d at infernal-iceberg.com
Sun Apr 7 01:14:30 CEST 2013
Revision: 55860
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=55860
Author: gsrb3d
Date: 2013-04-06 23:14:28 +0000 (Sat, 06 Apr 2013)
Log Message:
-----------
SVN maintenance.
Modified Paths:
--------------
trunk/blender/release/scripts/startup/bl_operators/freestyle.py
trunk/blender/release/scripts/startup/bl_ui/properties_freestyle.py
trunk/blender/release/scripts/startup/bl_ui/properties_render_layer.py
trunk/blender/source/blender/blenkernel/BKE_freestyle.h
trunk/blender/source/blender/blenkernel/BKE_linestyle.h
trunk/blender/source/blender/blenkernel/intern/freestyle.c
trunk/blender/source/blender/blenkernel/intern/linestyle.c
trunk/blender/source/blender/bmesh/operators/bmo_poke.c
trunk/blender/source/blender/makesdna/DNA_freestyle_types.h
trunk/blender/source/blender/makesdna/DNA_linestyle_types.h
trunk/blender/source/blender/makesrna/intern/rna_linestyle.c
Property Changed:
----------------
trunk/blender/extern/libmv/third_party/ceres/internal/ceres/blas.h
trunk/blender/intern/cycles/kernel/closure/bssrdf.h
trunk/blender/intern/cycles/kernel/kernel_subsurface.h
trunk/blender/intern/cycles/kernel/osl/osl_bssrdf.cpp
trunk/blender/intern/cycles/kernel/osl/osl_bssrdf.h
trunk/blender/intern/cycles/render/bssrdf.cpp
trunk/blender/intern/cycles/render/tables.cpp
trunk/blender/release/scripts/startup/bl_operators/freestyle.py
trunk/blender/release/scripts/startup/bl_ui/properties_freestyle.py
trunk/blender/release/scripts/startup/bl_ui/properties_render_layer.py
trunk/blender/source/blender/blenkernel/BKE_freestyle.h
trunk/blender/source/blender/blenkernel/BKE_linestyle.h
trunk/blender/source/blender/blenkernel/intern/freestyle.c
trunk/blender/source/blender/blenkernel/intern/linestyle.c
trunk/blender/source/blender/bmesh/operators/bmo_poke.c
trunk/blender/source/blender/makesdna/DNA_freestyle_types.h
trunk/blender/source/blender/makesdna/DNA_linestyle_types.h
trunk/blender/source/blender/makesrna/intern/rna_linestyle.c
trunk/blender/source/blender/nodes/shader/nodes/node_shader_subsurface_scattering.c
Property changes on: trunk/blender/extern/libmv/third_party/ceres/internal/ceres/blas.h
___________________________________________________________________
Added: svn:eol-style
+ native
Property changes on: trunk/blender/intern/cycles/kernel/closure/bssrdf.h
___________________________________________________________________
Added: svn:eol-style
+ native
Property changes on: trunk/blender/intern/cycles/kernel/kernel_subsurface.h
___________________________________________________________________
Added: svn:eol-style
+ native
Property changes on: trunk/blender/intern/cycles/kernel/osl/osl_bssrdf.cpp
___________________________________________________________________
Added: svn:eol-style
+ native
Property changes on: trunk/blender/intern/cycles/kernel/osl/osl_bssrdf.h
___________________________________________________________________
Added: svn:eol-style
+ native
Property changes on: trunk/blender/intern/cycles/render/bssrdf.cpp
___________________________________________________________________
Added: svn:eol-style
+ native
Property changes on: trunk/blender/intern/cycles/render/tables.cpp
___________________________________________________________________
Added: svn:eol-style
+ native
Modified: trunk/blender/release/scripts/startup/bl_operators/freestyle.py
===================================================================
--- trunk/blender/release/scripts/startup/bl_operators/freestyle.py 2013-04-06 23:08:06 UTC (rev 55859)
+++ trunk/blender/release/scripts/startup/bl_operators/freestyle.py 2013-04-06 23:14:28 UTC (rev 55860)
@@ -1,135 +1,135 @@
-# ##### BEGIN GPL LICENSE BLOCK #####
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License
-# as published by the Free Software Foundation; either version 2
-# of the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software Foundation,
-# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-#
-# ##### END GPL LICENSE BLOCK #####
-
-import sys
-import bpy
-
-from bpy.props import (EnumProperty, StringProperty)
-
-
-class SCENE_OT_freestyle_fill_range_by_selection(bpy.types.Operator):
- '''Fill the Range Min/Max entries by the min/max distance between selected mesh objects and the source object
- (either a user-specified object or the active camera)'''
- bl_idname = "scene.freestyle_fill_range_by_selection"
- bl_label = "Fill Range by Selection"
-
- type = EnumProperty(name="Type", description="Type of the modifier to work on",
- items=(("COLOR", "Color", "Color modifier type"),
- ("ALPHA", "Alpha", "Alpha modifier type"),
- ("THICKNESS", "Thickness", "Thickness modifier type")))
- name = StringProperty(name="Name", description="Name of the modifier to work on")
-
- def execute(self, context):
- rl = context.scene.render.layers.active
- lineset = rl.freestyle_settings.linesets.active
- linestyle = lineset.linestyle
- # Find the modifier to work on
- if self.type == 'COLOR':
- m = linestyle.color_modifiers[self.name]
- elif self.type == 'ALPHA':
- m = linestyle.alpha_modifiers[self.name]
- else:
- m = linestyle.thickness_modifiers[self.name]
- # Find the source object
- if m.type == 'DISTANCE_FROM_CAMERA':
- source = context.scene.camera
- elif m.type == 'DISTANCE_FROM_OBJECT':
- if m.target is None:
- self.report({'ERROR'}, "Target object not specified")
- return {'CANCELLED'}
- source = m.target
- else:
- self.report({'ERROR'}, "Unexpected modifier type: " + m.type)
- return {'CANCELLED'}
- # Find selected mesh objects
- selection = [ob for ob in context.scene.objects if ob.select and ob.type == 'MESH' and ob.name != source.name]
- if len(selection) > 0:
- # Compute the min/max distance between selected mesh objects and the source
- min_dist = sys.float_info.max
- max_dist = -min_dist
- for ob in selection:
- for vert in ob.data.vertices:
- dist = (ob.matrix_world * vert.co - source.location).length
- min_dist = min(dist, min_dist)
- max_dist = max(dist, max_dist)
- # Fill the Range Min/Max entries with the computed distances
- m.range_min = min_dist
- m.range_max = max_dist
- return {'FINISHED'}
-
-
-class SCENE_OT_freestyle_add_edge_marks_to_keying_set(bpy.types.Operator):
- '''Add the data paths to the Freestyle Edge Mark property of selected edges to the active keying set'''
- bl_idname = "scene.freestyle_add_edge_marks_to_keying_set"
- bl_label = "Add Edge Marks to Keying Set"
- bl_options = {'UNDO'}
-
- @classmethod
- def poll(cls, context):
- ob = context.active_object
- return (ob and ob.type == 'MESH')
-
- def execute(self, context):
- # active keying set
- scene = context.scene
- ks = scene.keying_sets.active
- if ks is None:
- ks = scene.keying_sets.new(idname="FreestyleEdgeMarkKeyingSet", name="Freestyle Edge Mark Keying Set")
- ks.bl_description = ""
- # add data paths to the keying set
- ob = context.active_object
- ob_mode = ob.mode
- mesh = ob.data
- bpy.ops.object.mode_set(mode='OBJECT', toggle=False)
- for i, edge in enumerate(mesh.edges):
- if not edge.hide and edge.select:
- path = 'edges[%d].use_freestyle_edge_mark' % i
- ks.paths.add(mesh, path, index=0)
- bpy.ops.object.mode_set(mode=ob_mode, toggle=False)
- return {'FINISHED'}
-
-
-class SCENE_OT_freestyle_add_face_marks_to_keying_set(bpy.types.Operator):
- '''Add the data paths to the Freestyle Face Mark property of selected polygons to the active keying set'''
- bl_idname = "scene.freestyle_add_face_marks_to_keying_set"
- bl_label = "Add Face Marks to Keying Set"
- bl_options = {'UNDO'}
-
- @classmethod
- def poll(cls, context):
- ob = context.active_object
- return (ob and ob.type == 'MESH')
-
- def execute(self, context):
- # active keying set
- scene = context.scene
- ks = scene.keying_sets.active
- if ks is None:
- ks = scene.keying_sets.new(idname="FreestyleFaceMarkKeyingSet", name="Freestyle Face Mark Keying Set")
- ks.bl_description = ""
- # add data paths to the keying set
- ob = context.active_object
- ob_mode = ob.mode
- mesh = ob.data
- bpy.ops.object.mode_set(mode='OBJECT', toggle=False)
- for i, polygon in enumerate(mesh.polygons):
- if not polygon.hide and polygon.select:
- path = 'polygons[%d].use_freestyle_face_mark' % i
- ks.paths.add(mesh, path, index=0)
- bpy.ops.object.mode_set(mode=ob_mode, toggle=False)
- return {'FINISHED'}
+# ##### BEGIN GPL LICENSE BLOCK #####
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software Foundation,
+# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+#
+# ##### END GPL LICENSE BLOCK #####
+
+import sys
+import bpy
+
+from bpy.props import (EnumProperty, StringProperty)
+
+
+class SCENE_OT_freestyle_fill_range_by_selection(bpy.types.Operator):
+ '''Fill the Range Min/Max entries by the min/max distance between selected mesh objects and the source object
+ (either a user-specified object or the active camera)'''
+ bl_idname = "scene.freestyle_fill_range_by_selection"
+ bl_label = "Fill Range by Selection"
+
+ type = EnumProperty(name="Type", description="Type of the modifier to work on",
+ items=(("COLOR", "Color", "Color modifier type"),
+ ("ALPHA", "Alpha", "Alpha modifier type"),
+ ("THICKNESS", "Thickness", "Thickness modifier type")))
+ name = StringProperty(name="Name", description="Name of the modifier to work on")
+
+ def execute(self, context):
+ rl = context.scene.render.layers.active
+ lineset = rl.freestyle_settings.linesets.active
+ linestyle = lineset.linestyle
+ # Find the modifier to work on
+ if self.type == 'COLOR':
+ m = linestyle.color_modifiers[self.name]
+ elif self.type == 'ALPHA':
+ m = linestyle.alpha_modifiers[self.name]
+ else:
+ m = linestyle.thickness_modifiers[self.name]
+ # Find the source object
+ if m.type == 'DISTANCE_FROM_CAMERA':
+ source = context.scene.camera
+ elif m.type == 'DISTANCE_FROM_OBJECT':
+ if m.target is None:
+ self.report({'ERROR'}, "Target object not specified")
+ return {'CANCELLED'}
+ source = m.target
+ else:
+ self.report({'ERROR'}, "Unexpected modifier type: " + m.type)
+ return {'CANCELLED'}
+ # Find selected mesh objects
+ selection = [ob for ob in context.scene.objects if ob.select and ob.type == 'MESH' and ob.name != source.name]
+ if len(selection) > 0:
+ # Compute the min/max distance between selected mesh objects and the source
+ min_dist = sys.float_info.max
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list