From 09e8535797c3e9b14b4e1fd9783e136e6632d626 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Wed, 1 Aug 2012 02:35:29 +0300 Subject: [PATCH] Use a custom drawing function to group the properties in a sensible way --- blender/io_mesh_mspgl/__init__.py | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/blender/io_mesh_mspgl/__init__.py b/blender/io_mesh_mspgl/__init__.py index 0b7b31df..e7fa07ce 100644 --- a/blender/io_mesh_mspgl/__init__.py +++ b/blender/io_mesh_mspgl/__init__.py @@ -44,6 +44,28 @@ class ExportMspGLBase(ExportHelper): for k, v in self.as_keywords().items(): setattr(exporter, k, v) + def draw(self, context): + col = self.layout.column() + col.prop(self, "export_lines") + col.prop(self, "compound") + col.prop(self, "smoothing") + self.layout.separator() + col = self.layout.column() + col.label("Triangle strips") + col.prop(self, "use_strips") + col.prop(self, "use_degen_tris") + col.prop(self, "max_strip_len") + self.layout.separator() + col = self.layout.column() + col.label("Vertex cache") + col.prop(self, "optimize_cache") + col.prop(self, "cache_size") + self.layout.separator() + col = self.layout.column() + col.label("TBN vectors") + col.prop(self, "tbn_vecs") + col.prop(self, "tbn_uvtex") + class ExportMspGLMesh(bpy.types.Operator, ExportMspGLBase): bl_idname = "export_mesh.mspgl_mesh" bl_label = "Export Msp GL mesh" @@ -66,6 +88,14 @@ class ExportMspGLObject(bpy.types.Operator, ExportMspGLBase): super().prepare_exporter(exporter) exporter.object = True + def draw(self, context): + super().draw(context) + self.layout.separator() + col = self.layout.column() + col.label("Texturing") + col.prop(self, "textures") + col.prop(self, "material_tex") + def menu_func_export(self, context): self.layout.operator(ExportMspGLMesh.bl_idname, text="Msp GL mesh") self.layout.operator(ExportMspGLObject.bl_idname, text="Msp GL object") -- 2.45.2