mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
implemented base classes of auto creator and hidden creator for maya
This commit is contained in:
parent
8c73d22d27
commit
464e621880
1 changed files with 51 additions and 6 deletions
|
|
@ -8,13 +8,24 @@ from maya import cmds
|
|||
from maya.app.renderSetup.model import renderSetup
|
||||
|
||||
from openpype.lib import BoolDef, Logger
|
||||
from openpype.pipeline import AVALON_CONTAINER_ID, Anatomy, CreatedInstance
|
||||
from openpype.pipeline import Creator as NewCreator
|
||||
from openpype.pipeline import (
|
||||
CreatorError, LegacyCreator, LoaderPlugin, get_representation_path,
|
||||
legacy_io)
|
||||
from openpype.pipeline.load import LoadError
|
||||
from openpype.settings import get_project_settings
|
||||
from openpype.pipeline import (
|
||||
AVALON_CONTAINER_ID,
|
||||
Anatomy,
|
||||
|
||||
CreatedInstance,
|
||||
Creator as NewCreator,
|
||||
AutoCreator,
|
||||
HiddenCreator,
|
||||
|
||||
CreatorError,
|
||||
LegacyCreator,
|
||||
LoaderPlugin,
|
||||
get_representation_path,
|
||||
|
||||
legacy_io,
|
||||
)
|
||||
from openpype.pipeline.load import LoadError
|
||||
|
||||
from . import lib
|
||||
from .lib import imprint, read
|
||||
|
|
@ -248,6 +259,40 @@ class MayaCreator(NewCreator, MayaCreatorBase):
|
|||
]
|
||||
|
||||
|
||||
class MayaAutoCreator(AutoCreator, MayaCreatorBase):
|
||||
"""Automatically triggered creator for Maya.
|
||||
|
||||
The plugin is not visible in UI, and 'create' method does not expect
|
||||
any arguments.
|
||||
"""
|
||||
|
||||
def collect_instances(self):
|
||||
return self._default_collect_instances()
|
||||
|
||||
def update_instances(self, update_list):
|
||||
return self._default_update_instances(update_list)
|
||||
|
||||
def remove_instances(self, instances):
|
||||
return self._default_remove_instances(instances)
|
||||
|
||||
|
||||
class MayaHiddenCreator(HiddenCreator, MayaCreatorBase):
|
||||
"""Hidden creator for Maya.
|
||||
|
||||
The plugin is not visible in UI, and it does not have strictly defined
|
||||
arguments for 'create' method.
|
||||
"""
|
||||
|
||||
def collect_instances(self):
|
||||
return self._default_collect_instances()
|
||||
|
||||
def update_instances(self, update_list):
|
||||
return self._default_update_instances(update_list)
|
||||
|
||||
def remove_instances(self, instances):
|
||||
return self._default_remove_instances(instances)
|
||||
|
||||
|
||||
def ensure_namespace(namespace):
|
||||
"""Make sure the namespace exists.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue