Merge pull request #3274 from pypeclub/bugfix/look-skip-empty-filename-attributes

Maya look: skip empty file attributes
This commit is contained in:
Ondřej Samohel 2022-06-14 10:04:01 +02:00 committed by GitHub
commit 45d7238bd3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -603,6 +603,18 @@ class CollectLook(pyblish.api.InstancePlugin):
source,
computed_source))
# renderman allows nodes to have filename attribute empty while
# you can have another incoming connection from different node.
pxr_nodes = set()
if cmds.pluginInfo("RenderMan_for_Maya", query=True, loaded=True):
pxr_nodes = set(
cmds.pluginInfo("RenderMan_for_Maya",
query=True,
dependNode=True)
)
if not source and cmds.nodeType(node) in pxr_nodes:
self.log.info("Renderman: source is empty, skipping...")
continue
# We replace backslashes with forward slashes because V-Ray
# can't handle the UDIM files with the backslashes in the
# paths as the computed patterns