Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Maya: Fix Collect Render for V-Ray, Redshift and Renderman for missing colorspace #4650

Merged
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 19 additions & 8 deletions openpype/hosts/maya/api/lib_renderproducts.py
Original file line number Diff line number Diff line change
Expand Up @@ -857,6 +857,7 @@ def get_render_products(self):
if default_ext in {"exr (multichannel)", "exr (deep)"}:
default_ext = "exr"

colorspace = lib.get_color_management_output_transform()
products = []

# add beauty as default when not disabled
Expand All @@ -868,7 +869,7 @@ def get_render_products(self):
productName="",
ext=default_ext,
camera=camera,
colorspace=lib.get_color_management_output_transform(),
colorspace=colorspace,
multipart=self.multipart
)
)
Expand All @@ -882,6 +883,7 @@ def get_render_products(self):
productName="Alpha",
ext=default_ext,
camera=camera,
colorspace=colorspace,
multipart=self.multipart
)
)
Expand Down Expand Up @@ -917,7 +919,8 @@ def get_render_products(self):
product = RenderProduct(productName=name,
ext=default_ext,
aov=aov,
camera=camera)
camera=camera,
colorspace=colorspace)
products.append(product)
# Continue as we've processed this special case AOV
continue
Expand All @@ -929,7 +932,7 @@ def get_render_products(self):
ext=default_ext,
aov=aov,
camera=camera,
colorspace=lib.get_color_management_output_transform()
colorspace=colorspace
)
products.append(product)

Expand Down Expand Up @@ -1130,6 +1133,7 @@ def get_render_products(self):
products = []
light_groups_enabled = False
has_beauty_aov = False
colorspace = lib.get_color_management_output_transform()
for aov in aovs:
enabled = self._get_attr(aov, "enabled")
if not enabled:
Expand Down Expand Up @@ -1173,7 +1177,8 @@ def get_render_products(self):
ext=ext,
multipart=False,
camera=camera,
driver=aov)
driver=aov,
colorspace=colorspace)
products.append(product)

if light_groups:
Expand All @@ -1188,7 +1193,8 @@ def get_render_products(self):
ext=ext,
multipart=False,
camera=camera,
driver=aov)
driver=aov,
colorspace=colorspace)
products.append(product)

# When a Beauty AOV is added manually, it will be rendered as
Expand All @@ -1204,7 +1210,8 @@ def get_render_products(self):
RenderProduct(productName=beauty_name,
ext=ext,
multipart=self.multipart,
camera=camera))
camera=camera,
colorspace=colorspace))

return products

Expand Down Expand Up @@ -1236,6 +1243,8 @@ def get_render_products(self):
"""
from rfm2.api.displays import get_displays # noqa

colorspace = lib.get_color_management_output_transform()

cameras = [
self.sanitize_camera_name(c)
for c in self.get_renderable_cameras()
Expand Down Expand Up @@ -1302,7 +1311,8 @@ def get_render_products(self):
productName=aov_name,
ext=extensions,
camera=camera,
multipart=True
multipart=True,
colorspace=colorspace
)

if has_cryptomatte and matte_enabled:
Expand All @@ -1311,7 +1321,8 @@ def get_render_products(self):
aov=cryptomatte_aov,
ext=extensions,
camera=camera,
multipart=True
multipart=True,
colorspace=colorspace
)
else:
# this code should handle the case where no multipart
Expand Down