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

Allow to set an explicit AOV identifier for USD render product using attribute ayon:aov_identifier #120

Open
wants to merge 9 commits into
base: develop
Choose a base branch
from
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,15 @@ def get_aov_identifier(self, render_product):
str: The AOV identifier

"""
# Allow explicit naming through custom attribute on the render product
aov_identifier = render_product.GetPrim().GetAttribute(
"ayon:aov_identifier").Get()
MustafaJafar marked this conversation as resolved.
Show resolved Hide resolved
if aov_identifier:
self.log.debug(
"Using explicit ayon:aov_identifier on render product"
" '{render_product}': {aov_identifier}")
MustafaJafar marked this conversation as resolved.
Show resolved Hide resolved
return str(aov_identifier)

targets = render_product.GetOrderedVarsRel().GetTargets()
if len(targets) > 1:
# Cryptomattes usually are combined render vars, for example:
Expand Down