def __init__(self, *args, **kwargs):
        """
        :type args: list
        :type kwargs: dict
        """
        mayabaseplugin.CreateWidget.__init__(self, *args, **kwargs)

        self._sequencePath = None
        start, end = mutils.currentFrameRange()

        self.ui.sequenceWidget = studioqt.ImageSequenceWidget(self)

        icon = studiolibraryplugins.resource().icon("thumbnail")
        self.ui.sequenceWidget.setIcon(icon)

        self.ui.layout().insertWidget(1, self.ui.sequenceWidget)
        self.ui.snapshotButton.parent().hide()
        self.ui.sequenceWidget.setStyleSheet(self.ui.snapshotButton.styleSheet())

        validator = QtGui.QIntValidator(-50000000, 50000000, self)
        self.ui.endFrameEdit.setValidator(validator)
        self.ui.startFrameEdit.setValidator(validator)

        self.ui.endFrameEdit.setText(str(int(end)))
        self.ui.startFrameEdit.setText(str(int(start)))

        self.ui.byFrameEdit.setValidator(QtGui.QIntValidator(1, 1000, self))
        self.ui.byFrameEdit.setText(str(self.settings().get("byFrame")))

        self.ui.sequenceWidget.clicked.connect(self.snapshot)
        self.ui.setEndFrameButton.clicked.connect(self.setEndFrame)
        self.ui.setStartFrameButton.clicked.connect(self.setStartFrame)
示例#2
0
    def optionChanged(self, text, save=True):
        """
        :type text: str
        """
        imageText = text

        if text == "replace all":
            imageText = "replaceCompletely"
            self.ui.connectCheckBox.setEnabled(False)
        else:
            self.ui.connectCheckBox.setEnabled(True)

        connect = ""
        if self.ui.connectCheckBox.isChecked() and text != "replace all":
            connect = "Connect"

        basename = "{0}{1}".format(imageText, connect)
        imageIcon = studiolibraryplugins.resource().icon(basename)

        self.ui.helpImage.setIcon(imageIcon)
        index = self.ui.option.findText(text)
        if index:
            self.ui.option.setCurrentIndex(index)
        if save:
            self.saveSettings()
    def optionChanged(self, text, save=True):
        """
        :type text: str
        """
        imageText = text

        if text == "replace all":
            imageText = "replaceCompletely"
            self.ui.connectCheckBox.setEnabled(False)
        else:
            self.ui.connectCheckBox.setEnabled(True)

        connect = ""
        if self.ui.connectCheckBox.isChecked() and text != "replace all":
            connect = "Connect"

        basename = "{0}{1}".format(imageText, connect)
        imageIcon = studiolibraryplugins.resource().icon(basename)

        self.ui.helpImage.setIcon(imageIcon)
        index = self.ui.option.findText(text)
        if index:
            self.ui.option.setCurrentIndex(index)
        if save:
            self.saveSettings()
示例#4
0
    def __init__(self, *args, **kwargs):
        """
        :type args: list
        :type kwargs: dict
        """
        mayabaseplugin.CreateWidget.__init__(self, *args, **kwargs)

        self._sequencePath = None
        start, end = mutils.currentFrameRange()

        self.ui.sequenceWidget = studioqt.ImageSequenceWidget(self)

        icon = studiolibraryplugins.resource().icon("thumbnail")
        self.ui.sequenceWidget.setIcon(icon)

        self.ui.layout().insertWidget(1, self.ui.sequenceWidget)
        self.ui.snapshotButton.parent().hide()
        self.ui.sequenceWidget.setStyleSheet(
            self.ui.snapshotButton.styleSheet())

        validator = QtGui.QIntValidator(-50000000, 50000000, self)
        self.ui.endFrameEdit.setValidator(validator)
        self.ui.startFrameEdit.setValidator(validator)

        self.ui.endFrameEdit.setText(str(int(end)))
        self.ui.startFrameEdit.setText(str(int(start)))

        self.ui.byFrameEdit.setValidator(QtGui.QIntValidator(1, 1000, self))
        self.ui.byFrameEdit.setText(str(self.settings().get("byFrame")))

        self.ui.sequenceWidget.clicked.connect(self.snapshot)
        self.ui.setEndFrameButton.clicked.connect(self.setEndFrame)
        self.ui.setStartFrameButton.clicked.connect(self.setStartFrame)
def selectContentAction(record, parent=None):
    """
    :param record: mayabaseplugin.Record
    :param parent: QtGui.QMenu
    """
    icon = studiolibraryplugins.resource().icon("arrow")
    action = QtGui.QAction(icon, "Select content", parent)
    action.triggered.connect(record.selectContent)
    return action
def selectContentAction(record, parent=None):
    """
    :param record: mayabaseplugin.Record
    :param parent: QtGui.QMenu
    """
    icon = studiolibraryplugins.resource().icon("arrow")
    action = QtGui.QAction(icon, "Select content", parent)
    action.triggered.connect(record.selectContent)
    return action
示例#7
0
    def __init__(self, *args, **kwargs):
        """
        :type args:
        """
        studiolibrary.Plugin.__init__(self, *args, **kwargs)

        iconPath = studiolibraryplugins.resource().get("icons", "lock.png")

        self.setName("lock")  # Must set a name for the plugin
        self.setIconPath(iconPath)
    def __init__(self, library):
        """
        :type library: studiolibrary.Library
        """
        mayabaseplugin.Plugin.__init__(self, library)

        iconPath = studiolibraryplugins.resource().get("icons", "pose.png")

        self.setName("Pose")
        self.setIconPath(iconPath)
示例#9
0
    def __init__(self, library):
        """
        :type library: studiolibrary.Library
        """
        mayabaseplugin.Plugin.__init__(self, library)

        iconPath = studiolibraryplugins.resource().get("icons", "pose.png")

        self.setName("Pose")
        self.setIconPath(iconPath)
    def __init__(self, library):
        """
        :type library: studiolibrary.Library
        """
        mayabaseplugin.Plugin.__init__(self, library)

        iconPath = studiolibraryplugins.resource().get("icons", "selectionSet.png")

        self.setName("Selection Set")
        self.setIconPath(iconPath)
        self.setExtension("set")
    def __init__(self, library):
        """
        :type library: studiolibrary.Library
        """
        studiolibrary.Plugin.__init__(self, library)

        iconPath = studiolibraryplugins.resource().get("icons", "mirrortable.png")

        self.setName("Mirror Table")
        self.setIconPath(iconPath)
        self.setExtension("mirror")
示例#12
0
    def __init__(self, library):
        """
        :type library: studiolibrary.Library
        """
        mayabaseplugin.Plugin.__init__(self, library)

        iconPath = studiolibraryplugins.resource().get("icons",
                                                       "selectionSet.png")

        self.setName("Selection Set")
        self.setIconPath(iconPath)
        self.setExtension("set")
示例#13
0
    def __init__(self, library):
        """
        :type library: studiolibrary.Library
        """
        studiolibrary.Plugin.__init__(self, library)

        iconPath = studiolibraryplugins.resource().get("icons",
                                                       "mirrortable.png")

        self.setName("Mirror Table")
        self.setIconPath(iconPath)
        self.setExtension("mirror")
示例#14
0
    def __init__(self, *args, **kwargs):
        """
        :type args:
        """
        studiolibrary.Plugin.__init__(self, *args, **kwargs)

        iconPath = studiolibraryplugins.resource().get("icons", "lock.png")

        self.setName("lock")  # Must set a name for the plugin
        self.setIconPath(iconPath)

        self._superusers = []
        self._lockFolder = re.compile("")
        self._unlockFolder = re.compile("")
    def __init__(self, *args, **kwargs):
        """
        :type args:
        """
        studiolibrary.Plugin.__init__(self, *args, **kwargs)

        iconPath = studiolibraryplugins.resource().get("icons", "lock.png")

        self.setName("lock")  # Must set a name for the plugin
        self.setIconPath(iconPath)

        self._superusers = []
        self._lockFolder = re.compile("")
        self._unlockFolder = re.compile("")
示例#16
0
    def __init__(self, library):
        """
        :type library: studiolibrary.Library
        """
        mayabaseplugin.Plugin.__init__(self, library)

        iconPath = studiolibraryplugins.resource().get("icons", "animation.png")

        self.setName("Animation")
        self.setExtension("anim")
        self.setIconPath(iconPath)

        settings = self.settings()
        settings.setdefault('byFrame', 1)
        settings.setdefault('currentTime', False)
        settings.setdefault('byFrameDialog', True)
        settings.setdefault('connectOption', False)
        settings.setdefault('showHelpImage', False)
        settings.setdefault('pasteOption', "replace")
示例#17
0
    def __init__(self, library):
        """
        :type library: studiolibrary.Library
        """
        mayabaseplugin.Plugin.__init__(self, library)

        iconPath = studiolibraryplugins.resource().get("icons", "animation.png")

        self.setName("Animation")
        self.setExtension("anim")
        self.setIconPath(iconPath)

        settings = self.settings()
        settings.setdefault('byFrame', 1)
        settings.setdefault('currentTime', False)
        settings.setdefault('byFrameDialog', True)
        settings.setdefault('connectOption', False)
        settings.setdefault('showHelpImage', False)
        settings.setdefault('pasteOption', "replace")
示例#18
0
    def __init__(
            self,
            record,
            parent=None,
            namespaces=None,
            enableSelectContent=True,
    ):
        """
        :type record: mayabaseplugin.Record
        :type parent: QtGui.QMenu
        :type namespaces: list[str]
        :type enableSelectContent: bool
        """
        QtGui.QMenu.__init__(self, "Selection Sets", parent)

        icon = studiolibraryplugins.resource().icon("selectionSet")
        self.setIcon(icon)

        self._record = record
        self._namespaces = namespaces
        self._enableSelectContent = enableSelectContent
        self.reload()
    def __init__(
        self,
        record,
        parent=None,
        namespaces=None,
        enableSelectContent=True,
    ):
        """
        :type record: mayabaseplugin.Record
        :type parent: QtGui.QMenu
        :type namespaces: list[str]
        :type enableSelectContent: bool
        """
        QtGui.QMenu.__init__(self, "Selection Sets", parent)

        icon = studiolibraryplugins.resource().icon("selectionSet")
        self.setIcon(icon)

        self._record = record
        self._namespaces = namespaces
        self._enableSelectContent = enableSelectContent
        self.reload()