🎨 add split export support for redshift

This commit is contained in:
Ondřej Samohel 2024-01-06 00:01:14 +01:00
parent 91a1fb1cdb
commit fd87751c36
No known key found for this signature in database
GPG key ID: 02376E18990A97C6
4 changed files with 31 additions and 2 deletions

View file

@ -45,6 +45,25 @@ class CollectRedshiftROPRenderProducts(pyblish.api.InstancePlugin):
beauty_suffix = rop.evalParm("RS_outputBeautyAOVSuffix")
render_products = []
# Store whether we are splitting the render job (export + render)
split_render = bool(rop.parm("RS_archive_enable").eval())
instance.data["splitRender"] = split_render
export_prefix = None
export_products = []
if split_render:
export_prefix = evalParmNoFrame(
rop, "RS_archive_file", pad_character="0"
)
beauty_export_product = self.get_render_product_name(
prefix=export_prefix,
suffix=None)
export_products.append(beauty_export_product)
self.log.debug(
"Found export product: {}".format(beauty_export_product)
)
instance.data["ifdFile"] = beauty_export_product
instance.data["exportFiles"] = list(export_products)
# Default beauty AOV
beauty_product = self.get_render_product_name(
prefix=default_prefix, suffix=beauty_suffix

View file

@ -41,6 +41,11 @@ class VrayRenderPluginInfo():
SeparateFilesPerFrame = attr.ib(default=True)
@attr.s
class RedshiftRenderPluginInfo():
SceneFile = attr.ib(default=None)
Version = attr.ib(default=None)
class HoudiniSubmitDeadline(
abstract_submit_deadline.AbstractSubmitDeadline,
OpenPypePyblishPluginMixin
@ -262,6 +267,11 @@ class HoudiniSubmitDeadline(
plugin_info = VrayRenderPluginInfo(
InputFilename=instance.data["ifdFile"],
)
elif family == "redshift_rop":
plugin_info = RedshiftRenderPluginInfo(
SceneFile=instance.data["ifdFile"],
Version=os.getenv("REDSHIFT_VERSION", "3.5.22"),
)
else:
self.log.error(
"Family '%s' not supported yet to split render job",

View file

@ -1 +1 @@
__version__ = "0.1.5"
__version__ = "0.1.6"

View file

@ -1 +1 @@
__version__ = "0.2.10"
__version__ = "0.2.11"