support for rr channels in separate dirs

This commit is contained in:
Ondrej Samohel 2021-11-18 16:18:57 +01:00
parent d141384bc2
commit 37617172c4
No known key found for this signature in database
GPG key ID: 02376E18990A97C6

View file

@ -148,12 +148,27 @@ class OpenPypeContextSelector:
for k, v in env.items():
print(" {}: {}".format(k, v))
publishing_paths = [os.path.join(self.job.imageDir,
os.path.dirname(
self.job.imageFileName))]
# add additional channels
channel_idx = 0
channel = self.job.channelFileName(channel_idx)
while channel:
channel_path = os.path.dirname(
os.path.join(self.job.imageDir, channel))
if channel_path not in publishing_paths:
publishing_paths.append(channel_path)
channel_idx += 1
channel = self.job.channelFileName(channel_idx)
args = [os.path.join(self.openpype_root, self.openpype_executable),
'publish', '-t', "rr_control", "--gui",
os.path.join(self.job.imageDir,
os.path.dirname(self.job.imageFileName))
'publish', '-t', "rr_control", "--gui"
]
args += publishing_paths
print(">>> running {}".format(" ".join(args)))
orig = os.environ.copy()
orig.update(env)