Ejemplo n.º 1
0
Archivo: EditUI.py Proyecto: hdd/ue
    def __init__(self, spec=ueSpec.Spec(os.getenv("PROJ"), "edt", "master"), parent=None):
        AbstractEdit.__init__(self, "edit", spec, parent)

        self.setWindowTitle("Edit (sequence)")

        self.parent.edit = ueEdit.getEdit(spec)

        for sequence in self.parent.edit["sequences"]:
                sequenceItem = QtGui.QTreeWidgetItem(self.editTree)
                sequenceItem.setText(0, sequence)
                for shot in self.parent.edit[sequence]["shots"]:
                        shotItem = QtGui.QTreeWidgetItem(sequenceItem)
                        shotItem.setText(0, shot)
Ejemplo n.º 2
0
def main():
    spec = ueSpec.Spec(options["spec"])

    edit = ueEdit.getEdit(spec)

    if options["assets"]:
        if options["print"]:
            for sequence in edit["sequences"]:
                print "-> %s" % sequence
                for shot in edit[sequence]["shots"]:
                    print "---> %s" % shot
        elif options["create"]:
            # Get the group and check agains the data in the edit file to see if anything has changed
            spec = ueSpec.Spec(proj=os.getenv("PROJ"))
            for sequence in edit["sequences"]:
                print "-> Creating sequence %s ..." % sequence
                spec.grp = sequence
                ueCreate.createGroup(spec, "default")
                for shot in edit[sequence]["shots"]:
                    if shot not in excludedShotNames:
                        print "---> Creating shot %s ..." % shot
                        spec.asst = shot
                        ueCreate.createAsset(spec, "default", dbMeta=edit[sequence][shot])
    elif options["play"]:
        shots = []
        for sequence in edit:
            spec.grp = sequence
            for shot in edit[sequence]:
                spec.asst = shot
                spec.eltype = "storyboard"
                spec.elname = "master"
                spec.elclass = "sb"

                versions = ueAssetUtils.getVersions(spec)

                if len(versions) == 0:
                    print "Nothing"
                    shots.append(os.path.join(os.getenv("UE_PATH"), "lib", "placeholders", "edit.1-24.png"))
                else:
                    print "Something"
                    shots.append(os.path.join(versions[-1]["path"], "edit.1-24.png"))

        arguments = ""
        for path in shots:
            arguments += " %s" % (path)

        print arguments

        os.system("rv %s" % arguments)
Ejemplo n.º 3
0
    def __init__(self,
                 spec=ueSpec.Spec(os.getenv("PROJ"), "edt", "master"),
                 parent=None):
        AbstractEdit.__init__(self, "edit", spec, parent)

        self.setWindowTitle("Edit (sequence)")

        self.parent.edit = ueEdit.getEdit(spec)

        for sequence in self.parent.edit["sequences"]:
            sequenceItem = QtGui.QTreeWidgetItem(self.editTree)
            sequenceItem.setText(0, sequence)
            for shot in self.parent.edit[sequence]["shots"]:
                shotItem = QtGui.QTreeWidgetItem(sequenceItem)
                shotItem.setText(0, shot)