本文整理匯總了Python中bpy_extras.io_utils.ExportHelper.invoke方法的典型用法代碼示例。如果您正苦於以下問題:Python ExportHelper.invoke方法的具體用法?Python ExportHelper.invoke怎麽用?Python ExportHelper.invoke使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類bpy_extras.io_utils.ExportHelper
的用法示例。
在下文中一共展示了ExportHelper.invoke方法的13個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
if self.image_format == 'PNG':
self.filename_ext = ".png"
else:
self.filename_ext = ".exr"
return ExportHelper.invoke(self, context, event)
示例2: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
self.exporter = (self.exporter_str or self.exporter) # make sure properties are up-to-date
if self.use_file_browser:
self.filepath = context.blend_data.filepath or "untitled"
self.generate_name(context)
return ExportHelper.invoke(self, context, event)
else:
return self.execute(context)
示例3: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
settings = context.scene.get(constants.EXPORT_SETTINGS_KEY)
if settings:
try:
restore_export_settings(self.properties, settings)
except AttributeError as e:
logging.error("Loading export settings failed:")
logging.exception(e)
logging.debug("Removed corrupted settings")
del context.scene[constants.EXPORT_SETTINGS_KEY]
return ExportHelper.invoke(self, context, event)
示例4: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
CurrentFormatProperties._clear_props()
if self.format:
op = get_op(self.format)
op_class = type(op.get_instance())
CurrentFormatProperties._add_props(op_class)
if self.format == "wm.collada_export":
# Special case: Collada (built-in) -- has no
# explicitly defined Python properties
CurrentFormatProperties.second_life = bpy.props.BoolProperty(
name="Export for Second Life",
description="Compatibility mode for Second Life",
default=False,
)
else:
self.visible_name = "Blend"
self.filename_ext = ".blend"
self.filter_glob = "*.blend"
self.filepath = context.object.name + self.filename_ext
return ExportHelper.invoke(self, context, event)
示例5: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
self.filepath = "Production Folder"
return ExportHelper.invoke(self, context, event)
示例6: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
restore_settings_export(self.properties)
return ExportHelper.invoke(self, context, event)
示例7: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
self.fill_props()
self.prepare_filepath(context)
return ExportHelper.invoke(self, context, event)
示例8: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
if context.active_object != None:
self.filepath = context.active_object.name + self.filename_ext
return ExportHelper.invoke(self, context, event)
示例9: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
self.fill_props()
self.filepath = context.object.name + self.filename_ext
return ExportHelper.invoke(self, context, event)
示例10: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
return ExportHelper.invoke(self, context, event)
示例11: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, evt):
if context.scene.yabee_settings.first_run:
context.scene.yabee_settings.reset_defaults()
return ExportHelper.invoke(self, context, evt)
示例12: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
obj = context.active_object
if obj != None:
self.filepath = strip_nnn(obj.name) + self.filename_ext
return ExportHelper.invoke(self, context, event)
示例13: invoke
# 需要導入模塊: from bpy_extras.io_utils import ExportHelper [as 別名]
# 或者: from bpy_extras.io_utils.ExportHelper import invoke [as 別名]
def invoke(self, context, event):
self.restore()
return ExportHelper.invoke(self, context, event)