mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-02 00:44:52 +01:00
fix lookassigner imports for python3 compatibility
This commit is contained in:
parent
bb97c3cdd2
commit
86cd93c0ac
2 changed files with 14 additions and 8 deletions
|
|
@ -13,8 +13,14 @@ from maya import cmds
|
|||
import maya.OpenMaya
|
||||
import maya.api.OpenMaya as om
|
||||
|
||||
from . import widgets
|
||||
from . import commands
|
||||
from .widgets import (
|
||||
AssetOutliner,
|
||||
LookOutliner
|
||||
)
|
||||
from .commands import (
|
||||
get_workfile,
|
||||
remove_unused_looks
|
||||
)
|
||||
from . vray_proxies import vrayproxy_assign_look
|
||||
|
||||
|
||||
|
|
@ -32,7 +38,7 @@ class App(QtWidgets.QWidget):
|
|||
# Store callback references
|
||||
self._callbacks = []
|
||||
|
||||
filename = commands.get_workfile()
|
||||
filename = get_workfile()
|
||||
|
||||
self.setObjectName("lookManager")
|
||||
self.setWindowTitle("Look Manager 1.3.0 - [{}]".format(filename))
|
||||
|
|
@ -57,13 +63,13 @@ class App(QtWidgets.QWidget):
|
|||
"""Build the UI"""
|
||||
|
||||
# Assets (left)
|
||||
asset_outliner = widgets.AssetOutliner()
|
||||
asset_outliner = AssetOutliner()
|
||||
|
||||
# Looks (right)
|
||||
looks_widget = QtWidgets.QWidget()
|
||||
looks_layout = QtWidgets.QVBoxLayout(looks_widget)
|
||||
|
||||
look_outliner = widgets.LookOutliner() # Database look overview
|
||||
look_outliner = LookOutliner() # Database look overview
|
||||
|
||||
assign_selected = QtWidgets.QCheckBox("Assign to selected only")
|
||||
assign_selected.setToolTip("Whether to assign only to selected nodes "
|
||||
|
|
@ -124,7 +130,7 @@ class App(QtWidgets.QWidget):
|
|||
lambda: self.echo("Loaded assets.."))
|
||||
|
||||
self.look_outliner.menu_apply_action.connect(self.on_process_selected)
|
||||
self.remove_unused.clicked.connect(commands.remove_unused_looks)
|
||||
self.remove_unused.clicked.connect(remove_unused_looks)
|
||||
|
||||
# Maya renderlayer switch callback
|
||||
callback = om.MEventMessage.addEventCallback(
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ from openpype.hosts.maya.api import lib
|
|||
from avalon import io, api
|
||||
|
||||
|
||||
import vray_proxies
|
||||
from .vray_proxies import get_alembic_ids_cache
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
|
|
@ -146,7 +146,7 @@ def create_items_from_nodes(nodes):
|
|||
vray_proxy_nodes = cmds.ls(nodes, type="VRayProxy")
|
||||
for vp in vray_proxy_nodes:
|
||||
path = cmds.getAttr("{}.fileName".format(vp))
|
||||
ids = vray_proxies.get_alembic_ids_cache(path)
|
||||
ids = get_alembic_ids_cache(path)
|
||||
parent_id = {}
|
||||
for k, _ in ids.items():
|
||||
pid = k.split(":")[0]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue