small fixes

This commit is contained in:
iLLiCiTiT 2021-12-02 11:33:07 +01:00
parent a3d3d6e3aa
commit f91045d497
4 changed files with 12 additions and 13 deletions

View file

@ -35,7 +35,7 @@ def main(launch_args):
# Create Communicator object and trigger launch
# - this must be done before anything is processed
communicator = CommunicationWrapper.create_communicator(qt_app)
communicator = CommunicationWrapper.create_qt_communicator(qt_app)
communicator.launch(launch_args)
def process_in_main_thread():

View file

@ -5,10 +5,6 @@ import tempfile
import avalon.io
from . import CommunicationWrapper
from .pipeline import (
list_instances,
write_instances
)
log = logging.getLogger(__name__)

View file

@ -15,7 +15,10 @@ from avalon.pipeline import AVALON_CONTAINER_ID
from openpype.hosts import tvpaint
from openpype.api import get_current_project_settings
from .communication_server import CommunicationWrapper
from .lib import (
execute_george,
execute_george_through_file
)
log = logging.getLogger(__name__)
@ -214,7 +217,7 @@ def get_workfile_metadata_string_for_keys(metadata_keys):
# Execute the script
george_script = "\n".join(george_script_parts)
CommunicationWrapper.execute_george_through_file(george_script)
execute_george_through_file(george_script)
# Load data from temp file
with open(output_filepath, "r") as stream:
@ -329,7 +332,7 @@ def write_workfile_metadata(metadata_key, value):
george_script = "\n".join(george_script_parts)
return CommunicationWrapper.execute_george_through_file(george_script)
return execute_george_through_file(george_script)
def get_current_workfile_context():
@ -443,7 +446,7 @@ def set_context_settings(asset_doc=None):
framerate = project_doc["data"].get("fps")
if framerate is not None:
CommunicationWrapper.execute_george(
execute_george(
"tv_framerate {} \"timestretch\"".format(framerate)
)
else:
@ -461,7 +464,7 @@ def set_context_settings(asset_doc=None):
if width is None or height is None:
print("Resolution was not found!")
else:
CommunicationWrapper.execute_george(
execute_george(
"tv_resizepage {} {} 0".format(width, height)
)
@ -484,5 +487,5 @@ def set_context_settings(asset_doc=None):
mark_in = 0
mark_out = mark_in + (frame_end - frame_start) + handle_start + handle_end
CommunicationWrapper.execute_george("tv_markin {} set".format(mark_in))
CommunicationWrapper.execute_george("tv_markout {} set".format(mark_out))
execute_george("tv_markin {} set".format(mark_in))
execute_george("tv_markout {} set".format(mark_out))

View file

@ -218,7 +218,7 @@ class CollectInstances(pyblish.api.ContextPlugin):
# - not 100% working as it was found out that layer ids can't be
# used as unified identifier across multiple workstations
layers_by_id = {
layer["id"]: layer
layer["layer_id"]: layer
for layer in layers_data
}
layer_ids = instance_data["layer_ids"]