Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2009-11-04 21:35:32 +0300
committerCampbell Barton <ideasman42@gmail.com>2009-11-04 21:35:32 +0300
commit51943096a97c7317473de7aba7a4ab4a06697156 (patch)
tree0b3a3d598562a3219107920c6ef97b15ede669eb /release/scripts/io/export_ply.py
parentfe82c2674e5d014b4e4c75f9337627957449dc99 (diff)
bugfix [#19804] .MDD is not working?? // Also filetype issue?
- made all exporters default to the blend filename with the extension replaced - MDD's poll function now checks for an active mesh - multiline docstrings are written as multiline docs when generating epydocs
Diffstat (limited to 'release/scripts/io/export_ply.py')
-rw-r--r--release/scripts/io/export_ply.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/release/scripts/io/export_ply.py b/release/scripts/io/export_ply.py
index 7235d51450e..99fa3233278 100644
--- a/release/scripts/io/export_ply.py
+++ b/release/scripts/io/export_ply.py
@@ -252,7 +252,7 @@ def write(filename, scene, ob, \
from bpy.props import *
-class EXPORT_OT_ply(bpy.types.Operator):
+class ExportPLY(bpy.types.Operator):
'''Export a single object as a stanford PLY with normals, colours and texture coordinates.'''
bl_idname = "export.ply"
bl_label = "Export PLY"
@@ -292,10 +292,14 @@ class EXPORT_OT_ply(bpy.types.Operator):
return ('RUNNING_MODAL',)
-bpy.ops.add(EXPORT_OT_ply)
+bpy.ops.add(ExportPLY)
import dynamic_menu
-menu_func = lambda self, context: self.layout.itemO("export.ply", text="Stanford (.ply)...")
+
+def menu_func(self, context):
+ default_path = bpy.data.filename.replace(".blend", ".ply")
+ self.layout.item_stringO(ExportPLY.bl_idname, "path", default_path, text="Stanford (.ply)...")
+
menu_item = dynamic_menu.add(bpy.types.INFO_MT_file_export, menu_func)
if __name__ == "__main__":