mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
maya can handle ext_mapping from AYON
This commit is contained in:
parent
cd1ac5c15b
commit
8d830ae374
8 changed files with 35 additions and 27 deletions
|
|
@ -112,9 +112,11 @@ class ExtractCameraMayaScene(publish.Extractor,
|
|||
def process(self, instance):
|
||||
"""Plugin entry point."""
|
||||
# get settings
|
||||
ext_mapping = (
|
||||
instance.context.data["project_settings"]["maya"]["ext_mapping"]
|
||||
)
|
||||
maya_settings = instance.context.data["project_settings"]["maya"]
|
||||
ext_mapping = {
|
||||
item["name"]: item["value"]
|
||||
for item in maya_settings["ext_mapping"]
|
||||
}
|
||||
if ext_mapping:
|
||||
self.log.debug("Looking in settings for scene type ...")
|
||||
# use extension mapping for first family found
|
||||
|
|
|
|||
|
|
@ -37,9 +37,11 @@ class ExtractImportReference(publish.Extractor,
|
|||
if not self.is_active(instance.data):
|
||||
return
|
||||
|
||||
ext_mapping = (
|
||||
instance.context.data["project_settings"]["maya"]["ext_mapping"]
|
||||
)
|
||||
maya_settings = instance.context.data["project_settings"]["maya"]
|
||||
ext_mapping = {
|
||||
item["name"]: item["value"]
|
||||
for item in maya_settings["ext_mapping"]
|
||||
}
|
||||
if ext_mapping:
|
||||
self.log.debug("Looking in settings for scene type ...")
|
||||
# use extension mapping for first family found
|
||||
|
|
|
|||
|
|
@ -431,9 +431,11 @@ class ExtractLook(publish.Extractor):
|
|||
project settings.
|
||||
|
||||
"""
|
||||
ext_mapping = (
|
||||
instance.context.data["project_settings"]["maya"]["ext_mapping"]
|
||||
)
|
||||
maya_settings = instance.context.data["project_settings"]["maya"]
|
||||
ext_mapping = {
|
||||
item["name"]: item["value"]
|
||||
for item in maya_settings["ext_mapping"]
|
||||
}
|
||||
if ext_mapping:
|
||||
self.log.debug("Looking in settings for scene type ...")
|
||||
# use extension mapping for first family found
|
||||
|
|
|
|||
|
|
@ -43,9 +43,11 @@ class ExtractMayaSceneRaw(publish.Extractor, AYONPyblishPluginMixin):
|
|||
|
||||
def process(self, instance):
|
||||
"""Plugin entry point."""
|
||||
ext_mapping = (
|
||||
instance.context.data["project_settings"]["maya"]["ext_mapping"]
|
||||
)
|
||||
maya_settings = instance.context.data["project_settings"]["maya"]
|
||||
ext_mapping = {
|
||||
item["name"]: item["value"]
|
||||
for item in maya_settings["ext_mapping"]
|
||||
}
|
||||
if ext_mapping:
|
||||
self.log.debug("Looking in settings for scene type ...")
|
||||
# use extension mapping for first family found
|
||||
|
|
|
|||
|
|
@ -35,9 +35,11 @@ class ExtractModel(publish.Extractor,
|
|||
if not self.is_active(instance.data):
|
||||
return
|
||||
|
||||
ext_mapping = (
|
||||
instance.context.data["project_settings"]["maya"]["ext_mapping"]
|
||||
)
|
||||
maya_settings = instance.context.data["project_settings"]["maya"]
|
||||
ext_mapping = {
|
||||
item["name"]: item["value"]
|
||||
for item in maya_settings["ext_mapping"]
|
||||
}
|
||||
if ext_mapping:
|
||||
self.log.debug("Looking in settings for scene type ...")
|
||||
# use extension mapping for first family found
|
||||
|
|
|
|||
|
|
@ -18,9 +18,11 @@ class ExtractRig(publish.Extractor):
|
|||
|
||||
def process(self, instance):
|
||||
"""Plugin entry point."""
|
||||
ext_mapping = (
|
||||
instance.context.data["project_settings"]["maya"]["ext_mapping"]
|
||||
)
|
||||
maya_settings = instance.context.data["project_settings"]["maya"]
|
||||
ext_mapping = {
|
||||
item["name"]: item["value"]
|
||||
for item in maya_settings["ext_mapping"]
|
||||
}
|
||||
if ext_mapping:
|
||||
self.log.debug("Looking in settings for scene type ...")
|
||||
# use extension mapping for first family found
|
||||
|
|
|
|||
|
|
@ -100,9 +100,11 @@ class ExtractYetiRig(publish.Extractor):
|
|||
|
||||
def process(self, instance):
|
||||
"""Plugin entry point."""
|
||||
ext_mapping = (
|
||||
instance.context.data["project_settings"]["maya"]["ext_mapping"]
|
||||
)
|
||||
maya_settings = instance.context.data["project_settings"]["maya"]
|
||||
ext_mapping = {
|
||||
item["name"]: item["value"]
|
||||
for item in maya_settings["ext_mapping"]
|
||||
}
|
||||
if ext_mapping:
|
||||
self.log.debug("Looking in settings for scene type ...")
|
||||
# use extension mapping for first family found
|
||||
|
|
|
|||
|
|
@ -333,12 +333,6 @@ def _convert_maya_project_settings(ayon_settings, output):
|
|||
|
||||
ayon_maya = ayon_settings["maya"]
|
||||
|
||||
# Convert extensions mapping
|
||||
ayon_maya["ext_mapping"] = {
|
||||
item["name"]: item["value"]
|
||||
for item in ayon_maya["ext_mapping"]
|
||||
}
|
||||
|
||||
# Maya dirmap
|
||||
ayon_maya_dirmap = ayon_maya.pop("maya_dirmap")
|
||||
ayon_maya_dirmap_path = ayon_maya_dirmap["paths"]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue