Changeset View
Changeset View
Standalone View
Standalone View
uv_texture_atlas.py
| Show First 20 Lines • Show All 89 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| col = self.layout.column() | col = self.layout.column() | ||||
| row = self.layout.row() | row = self.layout.row() | ||||
| split = self.layout.split() | split = self.layout.split() | ||||
| row.template_list("UI_UL_list", "template_list_controls", scene, | row.template_list("UI_UL_list", "template_list_controls", scene, | ||||
| "ms_lightmap_groups", scene, "ms_lightmap_groups_index", rows=2, maxrows=5) | "ms_lightmap_groups", scene, "ms_lightmap_groups_index", rows=2, maxrows=5) | ||||
| col = row.column(align=True) | col = row.column(align=True) | ||||
| col.operator("scene.ms_add_lightmap_group", icon='ZOOMIN', text="") | col.operator("scene.ms_add_lightmap_group", icon='ADD', text="") | ||||
| col.operator("scene.ms_del_lightmap_group", icon='ZOOMOUT', text="") | col.operator("scene.ms_del_lightmap_group", icon='REMOVE', text="") | ||||
| row = self.layout.row(align=True) | row = self.layout.row(align=True) | ||||
| # Resolution and Unwrap types (only if Lightmap group is added) | # Resolution and Unwrap types (only if Lightmap group is added) | ||||
| if context.scene.ms_lightmap_groups: | if context.scene.ms_lightmap_groups: | ||||
| group = scene.ms_lightmap_groups[scene.ms_lightmap_groups_index] | group = scene.ms_lightmap_groups[scene.ms_lightmap_groups_index] | ||||
| row.label(text="Resolution:") | row.label(text="Resolution:") | ||||
| row.prop(group, 'resolutionX', text='') | row.prop(group, 'resolutionX', text='') | ||||
| Show All 14 Lines | def draw(self, context): | ||||
| row.operator("scene.ms_select_group", | row.operator("scene.ms_select_group", | ||||
| text="SelectGroup", icon="GROUP") | text="SelectGroup", icon="GROUP") | ||||
| #self.layout.separator() | #self.layout.separator() | ||||
| self.layout.label(text="Auto Unwrap:") | self.layout.label(text="Auto Unwrap:") | ||||
| self.layout.prop(group, 'unwrap_type', text='Lightmap', expand=True) | self.layout.prop(group, 'unwrap_type', text='Lightmap', expand=True) | ||||
| row = self.layout.row() | row = self.layout.row() | ||||
| row.operator( | row.operator( | ||||
| "object.ms_auto", text="Auto Unwrap", icon="LAMP_SPOT") | "object.ms_auto", text="Auto Unwrap", icon="LIGHT_SPOT") | ||||
| row.prop(group, 'autoUnwrapPrecision', text='') | row.prop(group, 'autoUnwrapPrecision', text='') | ||||
| self.layout.label(text="Manual Unwrap:") | self.layout.label(text="Manual Unwrap:") | ||||
| row = self.layout.row() | row = self.layout.row() | ||||
| row.operator( | row.operator( | ||||
| "object.ms_run", text="StartManualUnwrap", icon="LAMP_SPOT") | "object.ms_run", text="StartManualUnwrap", icon="LIGHT_SPOT") | ||||
| row.operator( | row.operator( | ||||
| "object.ms_run_remove", text="FinishManualUnwrap", icon="LAMP_SPOT") | "object.ms_run_remove", text="FinishManualUnwrap", icon="LIGHT_SPOT") | ||||
| class TexAtl_RunAuto(Operator): | class TexAtl_RunAuto(Operator): | ||||
| bl_idname = "object.ms_auto" | bl_idname = "object.ms_auto" | ||||
| bl_label = "Auto Unwrapping" | bl_label = "Auto Unwrapping" | ||||
| bl_description = "Auto Unwrapping" | bl_description = "Auto Unwrapping" | ||||
| def execute(self, context): | def execute(self, context): | ||||
| ▲ Show 20 Lines • Show All 680 Lines • Show Last 20 Lines | |||||