From 4c6a063102106936d0a1df611b1c0d4931fcbd4f Mon Sep 17 00:00:00 2001 From: Milan Kolar Date: Wed, 12 Jun 2019 11:18:59 +0200 Subject: [PATCH] (hotfix) maya 2019 compatibility for quicktime extraction --- pype/maya/lib.py | 12 +++++++++--- pype/plugins/maya/publish/extract_quicktime.py | 6 +++--- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/pype/maya/lib.py b/pype/maya/lib.py index f45ca3000b..26d6256969 100644 --- a/pype/maya/lib.py +++ b/pype/maya/lib.py @@ -2171,11 +2171,14 @@ def load_capture_preset(path=None, data=None): temp_options2['textureMaxResolution'] = 1024 temp_options2['enableTextureMaxRes'] = True - if key == 'alphaCut' : + if key == 'alphaCut': temp_options2['transparencyAlgorithm'] = 5 temp_options2['transparencyQuality'] = 1 - if key == 'headsUpDisplay' : + if key == 'ssaoEnable': + temp_options2['ssaoEnable'] = True + + if key == 'headsUpDisplay': temp_options['headsUpDisplay'] = True if key == 'displayLights': @@ -2183,7 +2186,10 @@ def load_capture_preset(path=None, data=None): else: temp_options[str(key)] = preset[id][key] - for key in ['override_viewport_options', 'high_quality', 'alphaCut']: + for key in ['override_viewport_options', 'high_quality', 'alphaCut', "gpuCacheDisplayFilter"]: + temp_options.pop(key, None) + + for key in ['ssaoEnable']: temp_options.pop(key, None) options['viewport_options'] = temp_options diff --git a/pype/plugins/maya/publish/extract_quicktime.py b/pype/plugins/maya/publish/extract_quicktime.py index 868abdc3cd..a6e2ffc4c9 100644 --- a/pype/plugins/maya/publish/extract_quicktime.py +++ b/pype/plugins/maya/publish/extract_quicktime.py @@ -6,10 +6,10 @@ import capture_gui import clique import pype.maya.lib as lib +reload(lib) import pype.api import avalon.maya -from pypeapp import config from maya import cmds, mel import pymel.core as pm from pype.vendor import ffmpeg @@ -59,7 +59,7 @@ class ExtractQuicktime(pype.api.Extractor): preset = lib.load_capture_preset(data=capture_preset) except: preset = {} - self.log.info('using viewport preset: {}'.format(capture_preset)) + self.log.info('using viewport preset: {}'.format(preset)) preset['camera'] = camera preset['format'] = "image" @@ -111,7 +111,7 @@ class ExtractQuicktime(pype.api.Extractor): movieFile = filename + ".mov" # movieFileBurnin = filename + "Burn" + ".mov" - movieFilefull_movie_path = os.path.join(stagingdir, movieFile) + full_movie_path = os.path.join(stagingdir, movieFile) self.log.info("output {}".format(full_movie_path)) with avalon.maya.suspended_refresh(): try: