mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
add changes needed for Maya
This commit is contained in:
parent
76cd4207d0
commit
d8ce82b916
3 changed files with 19 additions and 3 deletions
|
|
@ -192,7 +192,10 @@ class CollectMayaRender(pyblish.api.ContextPlugin):
|
|||
render_products = layer_render_products.layer_data.products
|
||||
assert render_products, "no render products generated"
|
||||
exp_files = []
|
||||
multipart = False
|
||||
for product in render_products:
|
||||
if product.multipart:
|
||||
multipart = True
|
||||
product_name = product.productName
|
||||
if product.camera and layer_render_products.has_camera_token():
|
||||
product_name = "{}{}".format(
|
||||
|
|
@ -205,7 +208,7 @@ class CollectMayaRender(pyblish.api.ContextPlugin):
|
|||
})
|
||||
|
||||
self.log.info("multipart: {}".format(
|
||||
layer_render_products.multipart))
|
||||
multipart))
|
||||
assert exp_files, "no file names were generated, this is bug"
|
||||
self.log.info(exp_files)
|
||||
|
||||
|
|
@ -300,7 +303,7 @@ class CollectMayaRender(pyblish.api.ContextPlugin):
|
|||
"subset": expected_layer_name,
|
||||
"attachTo": attach_to,
|
||||
"setMembers": layer_name,
|
||||
"multipartExr": layer_render_products.multipart,
|
||||
"multipartExr": multipart,
|
||||
"review": render_instance.data.get("review") or False,
|
||||
"publish": True,
|
||||
|
||||
|
|
|
|||
|
|
@ -445,9 +445,14 @@ class ProcessSubmittedJobOnFarm(pyblish.api.InstancePlugin):
|
|||
preview = True
|
||||
break
|
||||
|
||||
if instance_data.get("multipartExr"):
|
||||
preview = True
|
||||
|
||||
new_instance = copy(instance_data)
|
||||
new_instance["subset"] = subset_name
|
||||
new_instance["subsetGroup"] = group_name
|
||||
if preview:
|
||||
new_instance["review"] = True
|
||||
|
||||
# create represenation
|
||||
if isinstance(col, (list, tuple)):
|
||||
|
|
@ -527,6 +532,10 @@ class ProcessSubmittedJobOnFarm(pyblish.api.InstancePlugin):
|
|||
if bake_renders:
|
||||
preview = False
|
||||
|
||||
# toggle preview on if multipart is on
|
||||
if instance.get("multipartExr", False):
|
||||
preview = True
|
||||
|
||||
staging = os.path.dirname(list(collection)[0])
|
||||
success, rootless_staging_dir = (
|
||||
self.anatomy.find_root_template_from_path(staging)
|
||||
|
|
|
|||
|
|
@ -32,11 +32,15 @@ class ExtractJpegEXR(pyblish.api.InstancePlugin):
|
|||
|
||||
def process(self, instance):
|
||||
self.log.info("subset {}".format(instance.data['subset']))
|
||||
|
||||
# skip crypto passes.
|
||||
if 'crypto' in instance.data['subset']:
|
||||
self.log.info("Skipping crypto passes.")
|
||||
return
|
||||
|
||||
# Skip review when requested.
|
||||
# Skip if review not set.
|
||||
if not instance.data.get("review", True):
|
||||
self.log.info("Skipping - no review set on instance.")
|
||||
return
|
||||
|
||||
filtered_repres = self._get_filtered_repres(instance)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue