Ejemplo n.º 1
0
def uiFunc_build_controller_connection_column(self, parent, connection):
    mc.setParent(parent)
    cgmUI.add_LineSubBreak()

    # Connection Column
    #
    connectionColumn = mUI.MelColumnLayout(parent,useTemplate = 'cgmUISubTemplate')

    for label in self.connectionDict[connection]:
        add_connection_row(self, connectionColumn, connection, label, self.connectionDict[connection][label])
    #
    # End Connection Column

    _row = mUI.MelHLayout(parent,ut='cgmUISubTemplate',padding = _padding)
    
    btn = cgmUI.add_Button(_row,'Add Connection',
        cgmGEN.Callback(add_connection,self, connectionColumn, connection),                         
        #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
        'Add Connection Button',h=25)

    btn = cgmUI.add_Button(_row,'Clear All',
        cgmGEN.Callback(uiFunc_clear_connections,self, connectionColumn, connection),                         
        #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
        'Clear Connections Button',h=25)
    _row.layout()

    mc.setParent(parent)
    cgmUI.add_LineSubBreak()
Ejemplo n.º 2
0
        def build_layoutWrapper(self, parent):
            uiColumn_main = zooUI.MelColumnLayout(parent)
            cgmUI.add_Header('Setup Hotkey')
            cgmUI.add_TextBlock(self.mi_cgmHotkeyer._d_kws['name'])

            #>>>Modifier row ------------------------------------------------------------------------------------
            self.uiRow_Modifier = zooUI.MelHSingleStretchLayout(
                uiColumn_main, ut='cgmUISubTemplate', padding=2)
            #zooUI.MelSpacer(self.uiRow_Modifier,w=5)
            #zooUI.MelLabel(self.uiRow_Modifier, label = 'Modifier: ',align='right')
            self.uiRow_Modifier.setStretchWidget(
                zooUI.MelSeparator(self.uiRow_Modifier))
            self.uiRow_Modifier.layout()

            self.uiRadioCollection_modifier = zooUI.MelRadioCollection()
            self.uiOptions_modifier = []

            for i, item in enumerate(cgmHotkeyer._l_modifierOptions):
                self.uiOptions_modifier.append(
                    self.uiRadioCollection_modifier.createButton(
                        self.uiRow_Modifier, label=item))
            self.uiRow_Modifier.layout()
            mc.radioCollection(self.uiRadioCollection_modifier,
                               edit=True,
                               sl=self.uiOptions_modifier[0])

            #>>>Text row ------------------------------------------------------------------------------------

            uiRow_key = zooUI.MelHLayout(uiColumn_main,
                                         ut='cgmUISubTemplate',
                                         padding=15)
            self.uiText_key = zooUI.MelTextField(
                uiRow_key,
                backgroundColor=[1, 1, 1],
                h=20,
                text=self.mi_cgmHotkeyer._defaultKey,
                ut='cgmUITemplate',
                #ec = lambda *a:self._UTILS.puppet_doChangeName(self),
                annotation="Hotkey to use")
            uiRow_key.layout()

            #>>> Button row
            mc.setParent(uiColumn_main)
            cgmUI.add_LineSubBreak()
            uiRow_buttons = zooUI.MelHLayout(uiColumn_main,
                                             ut='cgmUISubTemplate',
                                             padding=5)
            cgmUI.add_Button(uiRow_buttons,
                             'Go',
                             commandText=lambda *a: self.buttonPress_go(),
                             annotationText="Set it up")
            cgmUI.add_Button(
                uiRow_buttons,
                'Reset',
                commandText=lambda *a: self.buttonPress_reset(),
                en=False,
                annotationText="Reset given key to the default maya setting")
            uiRow_buttons.layout()
Ejemplo n.º 3
0
    def uiUpdate_commits(self):
        self.uiScroll_commits.clear()
        #_d_ui_annotations = {}

        _sidePadding = 25
        _parent = self.uiScroll_commits
        _branch = self.var_branchMode.value
        _dat = cgmUpdate.get_dat(_branch, _commit_limit, True)

        uiRC = mUI.MelRadioCollection()
        self.uiRC_commits = uiRC
        self.dat_commits = _dat

        for i, d in enumerate(_dat):
            _hash = d['hash']
            _msg = d['msg']
            _date = d['date']
            _url = d['url']

            _ann = '\n {0} commit {1} | {2} | {3} \n {4} \n {5}'.format(
                _branch, i, _hash, _date, _msg, _url)
            _report = '{0} | {1}'.format(_hash, _msg[:50])
            _label = "{0} - {1} | {3}...".format(i, _date, _hash[:8],
                                                 _msg[:40])
            #log.debug(_report)
            #cgmUI.mUI.MelLabel(_parent, l = _msg,
            #                   annotation = d['msg'])

            #mc.separator(parent = _parent, height = 5,
            #ut='cgmUISubTemplate'
            #             )
            cgmUI.mUI.MelSpacer(_parent, h=5)
            uiRC.createButton(
                _parent,
                label=_label,
                annotation=_ann,
                onCommand=cgmGEN.Callback(log.info, _ann),
                #ut='cgmUIHeader',
                #onCommand = lambda*a:(log.info("{0} | {1} | {2}".format(uiRC.getSelectedIndex(), _branch, self.dat_commits[uiRC.getSelectedIndex()]['hash'])))
                #sl=_rb,
                #onCommand = cgmGEN.Callback(_var.setValue,i)
            )
            mc.setParent(_parent)
            cgmUI.add_LineSubBreak()
Ejemplo n.º 4
0
def uiFunc_build_post_process_column(self, parentColumn):
    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()

    # Post Process Action
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)
    self._post_row_aimDirection = _row

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Action:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    actions = ['Dragger', 'Spring', 'Trajectory Aim', 'Keys to Motion Curve']

    self.post_actionMenu = mUI.MelOptionMenu(_row,
                                             useTemplate='cgmUITemplate',
                                             changeCommand=cgmGEN.Callback(
                                                 uiFunc_setPostAction, self))
    for dir in actions:
        self.post_actionMenu.append(dir)

    self.post_actionMenu.setValue(actions[0])

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Post Process Action

    # Post Process Options Frame
    #
    self._postProcessOptionsColumn = mUI.MelColumnLayout(
        parentColumn, useTemplate='cgmUISubTemplate')
    #
    # Post Process Options Frame

    uiFunc_setPostAction(self)
Ejemplo n.º 5
0
        def build_layoutWrapper(self,parent):
            uiColumn_main = zooUI.MelColumnLayout(parent)
            cgmUI.add_Header('Setup Hotkey')
            cgmUI.add_TextBlock(self.mi_cgmHotkeyer._d_kws['name'])
            
            #>>>Modifier row ------------------------------------------------------------------------------------
            self.uiRow_Modifier = zooUI.MelHSingleStretchLayout(uiColumn_main,ut='cgmUISubTemplate',padding = 2)
            #zooUI.MelSpacer(self.uiRow_Modifier,w=5)
            #zooUI.MelLabel(self.uiRow_Modifier, label = 'Modifier: ',align='right')
            self.uiRow_Modifier.setStretchWidget( zooUI.MelSeparator(self.uiRow_Modifier) )		
            self.uiRow_Modifier.layout()

            self.uiRadioCollection_modifier = zooUI.MelRadioCollection()
            self.uiOptions_modifier = []		

            for i,item in enumerate(cgmHotkeyer._l_modifierOptions):
                self.uiOptions_modifier.append(self.uiRadioCollection_modifier.createButton(self.uiRow_Modifier,label=item))
            self.uiRow_Modifier.layout()
            mc.radioCollection(self.uiRadioCollection_modifier,edit=True, sl=self.uiOptions_modifier[0])
            
            #>>>Text row ------------------------------------------------------------------------------------
            
            
            uiRow_key = zooUI.MelHLayout(uiColumn_main,ut='cgmUISubTemplate',padding = 15)            
            self.uiText_key = zooUI.MelTextField(uiRow_key,backgroundColor = [1,1,1],h=20,
                                                 text = self.mi_cgmHotkeyer._defaultKey,
                                                 ut = 'cgmUITemplate',
                                                 #ec = lambda *a:self._UTILS.puppet_doChangeName(self),
                                                 annotation = "Hotkey to use")   
            uiRow_key.layout()
            
            #>>> Button row
            mc.setParent(uiColumn_main)
            cgmUI.add_LineSubBreak()                                             
            uiRow_buttons = zooUI.MelHLayout(uiColumn_main,ut='cgmUISubTemplate',padding = 5)  
            cgmUI.add_Button(uiRow_buttons,'Go',commandText = lambda *a:self.buttonPress_go(),
                             annotationText="Set it up")
            cgmUI.add_Button(uiRow_buttons,'Reset',commandText = lambda *a:self.buttonPress_reset(),en = False,
                                         annotationText="Reset given key to the default maya setting")   
            uiRow_buttons.layout()
Ejemplo n.º 6
0
def uiFunc_update_details(self):
    if not self._mDynFK:
        return

    self.detailsFrame.clear()

    dat = self._mDynFK.get_dat()

    self.detailsFrame(edit=True, collapse=False)

    _details = mUI.MelColumnLayout(self.detailsFrame,
                                   useTemplate='cgmUIHeaderTemplate')

    cgmUI.add_LineSubBreak()

    # Base Name
    uiFunc_make_display_line(_details,
                             label='Base Name:',
                             text=self._mDynFK.baseName,
                             button=False)

    # Direction Info
    _row = mUI.MelHSingleStretchLayout(_details,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l="Direction:")

    _row.setStretchWidget(mUI.MelSeparator(_row))

    mUI.MelLabel(_row, l="Fwd:")

    uiTF = mUI.MelLabel(_row,
                        ut='cgmUISubTemplate',
                        l=self._mDynFK.fwd,
                        en=True)

    mUI.MelLabel(_row, l="Up:")

    uiTF = mUI.MelLabel(_row,
                        ut='cgmUISubTemplate',
                        l=self._mDynFK.up,
                        en=True)

    mUI.MelSpacer(_row, w=10)
    _row.layout()

    # Nucleus
    uiFunc_make_display_line(_details,
                             label='Nucleus:',
                             text=self._mDynFK.mNucleus[0],
                             button=True,
                             buttonLabel=">>",
                             buttonCommand=cgmGEN.Callback(
                                 uiFunc_select_item, self._mDynFK.mNucleus[0]),
                             buttonInfo="Select nucleus transform.",
                             presetOptions=True,
                             presetObj=self._mDynFK.mNucleus[0])

    uiFunc_make_display_line(_details,
                             label='Hair System:',
                             text=dat['mHairSysShape'].p_nameBase,
                             button=True,
                             buttonLabel=">>",
                             buttonCommand=cgmGEN.Callback(
                                 uiFunc_select_item,
                                 dat['mHairSysShape'].p_nameBase),
                             buttonInfo="Select hair system transform.",
                             presetOptions=True,
                             presetObj=dat['mHairSysShape'].p_nameBase)

    _row = mUI.MelHSingleStretchLayout(_details,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l='Enabled:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    self.nucleusEnabledCB = mUI.MelCheckBox(_row,
                                            en=True,
                                            v=True,
                                            label='',
                                            ann='Enable Nucleus')
    self.nucleusEnabledCB(edit=True,
                          changeCommand=cgmGEN.Callback(
                              uiFunc_set_nucleus_enabled, self))

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()

    # Start Times

    _row = mUI.MelHSingleStretchLayout(_details,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l='Start Time:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    self.startTimeIF = mUI.MelIntField(_row, v=dat['mNucleus'].startFrame)
    self.startTimeIF(edit=True,
                     changeCommand=cgmGEN.Callback(uiFunc_set_start_time,
                                                   self,
                                                   mode='refresh'))

    cgmUI.add_Button(
        _row, '<<',
        cgmGEN.Callback(uiFunc_set_start_time, self, mode='beginning'),
        "Set Start To Beginning of Slider.")

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()

    # TimeInput Row ----------------------------------------------------------------------------------
    _row = mUI.MelHSingleStretchLayout(_details, ut='cgmUISubTemplate')
    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l='Bake Time:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    mUI.MelLabel(_row, l='Start:')

    self.uiFieldInt_start = mUI.MelIntField(_row,
                                            'cgmLocWinStartFrameField',
                                            width=40)

    mUI.MelLabel(_row, l='End:')

    self.uiFieldInt_end = mUI.MelIntField(_row,
                                          'cgmLocWinEndFrameField',
                                          width=40)

    cgmUI.add_Button(_row, '<<',
                     cgmGEN.Callback(uiFunc_updateTimeRange, self, 'min'),
                     "Set Start To Beginning of Slider.")
    cgmUI.add_Button(_row, '[   ]',
                     cgmGEN.Callback(uiFunc_updateTimeRange, self, 'slider'),
                     "Set Time to Slider.")
    cgmUI.add_Button(_row, '>>',
                     cgmGEN.Callback(uiFunc_updateTimeRange, self, 'max'),
                     "Set End To End of Slider.")

    uiFunc_updateTimeRange(self, mode='slider')

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()

    mc.setParent(_details)
    cgmUI.add_LineSubBreak()

    allChains = []
    for idx in dat['chains']:
        allChains += dat['chains'][idx]['mObjJointChain']
    allTargets = []
    for idx in dat['chains']:
        allTargets += dat['chains'][idx]['mTargets']

    _row = mUI.MelHLayout(_details,
                          ut='cgmUISubTemplate',
                          padding=_padding * 2)

    cgmUI.add_Button(
        _row,
        'Bake All Joints',
        cgmGEN.Callback(uiFunc_bake, self, 'chain', allChains),
        #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
        'Bake All Joints')
    cgmUI.add_Button(_row, 'Bake All Targets',
                     cgmGEN.Callback(uiFunc_bake, self, 'target', allTargets),
                     'Bake All Targets')

    _row.layout()

    _row = mUI.MelHLayout(_details,
                          ut='cgmUISubTemplate',
                          padding=_padding * 2)

    cgmUI.add_Button(
        _row,
        'Connect All Targets',
        cgmGEN.Callback(uiFunc_connect_targets, self),
        #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
        'Connect All Targets')
    cgmUI.add_Button(_row, 'Disconnect All Targets',
                     cgmGEN.Callback(uiFunc_disconnect_targets, self),
                     'Disconnect All Targets')

    _row.layout()

    # Chains
    for i, chain in enumerate(self._mDynFK.msgList_get('chain')):
        _row = mUI.MelHSingleStretchLayout(_details,
                                           ut='cgmUISubTemplate',
                                           padding=_padding)

        mUI.MelSpacer(_row, w=_padding)

        _subChainColumn = mUI.MelColumnLayout(
            _row, useTemplate='cgmUIHeaderTemplate')

        chainFrame = mUI.MelFrameLayout(_subChainColumn,
                                        label=chain.p_nameBase,
                                        collapsable=True,
                                        collapse=True,
                                        useTemplate='cgmUIHeaderTemplate')

        _chainColumn = mUI.MelColumnLayout(chainFrame,
                                           useTemplate='cgmUIHeaderTemplate')

        _row.setStretchWidget(_subChainColumn)

        #mUI.MelSpacer(_row,w=_padding)
        _row.layout()

        mc.setParent(_chainColumn)
        cgmUI.add_LineSubBreak()

        uiFunc_make_display_line(
            _chainColumn,
            label='Follicle:',
            text=cgmMeta.asMeta(chain.mFollicle[0]).p_nameBase,
            button=True,
            buttonLabel=">>",
            buttonCommand=cgmGEN.Callback(uiFunc_select_item,
                                          chain.mFollicle[0]),
            buttonInfo="Select follicle transform.",
            presetOptions=True,
            presetObj=chain.mFollicle[0])

        mc.setParent(_chainColumn)
        cgmUI.add_LineSubBreak()

        uiFunc_make_display_line(_chainColumn,
                                 label='Group:',
                                 text=chain.p_nameShort,
                                 button=True,
                                 buttonLabel=">>",
                                 buttonCommand=cgmGEN.Callback(
                                     uiFunc_select_item, chain.p_nameBase),
                                 buttonInfo="Select group transform.")

        mc.setParent(_chainColumn)
        cgmUI.add_LineSubBreak()

        _row = mUI.MelHSingleStretchLayout(_chainColumn,
                                           ut='cgmUISubTemplate',
                                           padding=5)

        mUI.MelSpacer(_row, w=_padding)
        mUI.MelLabel(_row, l='Orient Up:')

        _row.setStretchWidget(mUI.MelSeparator(_row))

        chainDirections = []
        for dir in ['x+', 'x-', 'y+', 'y-', 'z+', 'z-']:
            if chain.fwd[0] != dir[0]:
                chainDirections.append(dir)
        chainDirections.append('None')

        upMenu = mUI.MelOptionMenu(_row, useTemplate='cgmUITemplate')
        for dir in chainDirections:
            upMenu.append(dir)

        upMenu.setValue(chain.up)

        upMenu(edit=True,
               changeCommand=cgmGEN.Callback(uiFunc_set_chain_up, self, i,
                                             upMenu))

        mUI.MelSpacer(_row, w=_padding)

        _row.layout()

        _row = mUI.MelHLayout(_chainColumn,
                              ut='cgmUISubTemplate',
                              padding=_padding * 2)
        cgmUI.add_Button(
            _row,
            'Bake Joints',
            cgmGEN.Callback(uiFunc_bake, self, 'chain',
                            chain.msgList_get('mObjJointChain')),
            #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
            'Bake All Joints')
        cgmUI.add_Button(
            _row, 'Bake Targets',
            cgmGEN.Callback(uiFunc_bake, self, 'target',
                            chain.msgList_get('mTargets')), 'Bake All Targets')

        _row.layout()

        _row = mUI.MelHLayout(_chainColumn,
                              ut='cgmUISubTemplate',
                              padding=_padding * 2)

        cgmUI.add_Button(
            _row,
            'Connect Targets',
            cgmGEN.Callback(uiFunc_connect_targets, self, i),
            #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
            'Connect All Targets')
        cgmUI.add_Button(_row, 'Disconnect Targets',
                         cgmGEN.Callback(uiFunc_disconnect_targets, self, i),
                         'Disconnect All Targets')

        _row.layout()

        _row = mUI.MelHLayout(_chainColumn,
                              ut='cgmUISubTemplate',
                              padding=_padding * 2)
        cgmUI.add_Button(
            _row,
            'Delete Chain',
            cgmGEN.Callback(uiFunc_delete_chain, self, i),
            #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
            'Bake All Joints')
        _row.layout()

        frameDat = [['Targets', 'mTargets'], ['Locators', 'mLocs'],
                    ['Joint Chain', 'mObjJointChain'], ['Aims', 'mAims'],
                    ['Parents', 'mParents']]

        for dat in frameDat:
            frame = mUI.MelFrameLayout(_chainColumn,
                                       label=dat[0],
                                       collapsable=True,
                                       collapse=True,
                                       useTemplate='cgmUIHeaderTemplate')
            column = mUI.MelColumnLayout(frame,
                                         useTemplate='cgmUITemplate',
                                         height=75)
            row = mUI.MelHSingleStretchLayout(column,
                                              ut='cgmUIHeaderTemplate',
                                              padding=_padding)

            mUI.MelSpacer(row, w=_padding)

            itemList = uiFunc_create_selection_list(
                row, [x.p_nameShort for x in chain.msgList_get(dat[1])])

            mUI.MelSpacer(row, w=_padding)

            row.setStretchWidget(itemList)

            row.layout()

    # End Chains

    mc.setParent(_details)
    cgmUI.add_LineSubBreak()
Ejemplo n.º 7
0
def buildColumn_main(self, parent, asScroll=False):
    """
    Trying to put all this in here so it's insertable in other uis
    
    """
    if asScroll:
        _inside = mUI.MelScrollLayout(parent,
                                      useTemplate='cgmUIHeaderTemplate')
    else:
        _inside = mUI.MelColumnLayout(parent,
                                      useTemplate='cgmUIHeaderTemplate')

    #>>>Objects Load Row ---------------------------------------------------------------------------------------

    mUI.MelSeparator(_inside, ut='cgmUISubTemplate', h=3)

    _row = mUI.MelHSingleStretchLayout(_inside,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l='Dynamic Chain System:')

    uiTF_objLoad = mUI.MelLabel(_row,
                                ut='cgmUIInstructionsTemplate',
                                l='',
                                en=True)

    self.uiTF_objLoad = uiTF_objLoad
    cgmUI.add_Button(_row, '<<', cgmGEN.Callback(uiFunc_load_selected, self),
                     "Load first selected object.")
    _row.setStretchWidget(uiTF_objLoad)
    mUI.MelSpacer(_row, w=_padding)

    _row.layout()

    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()

    self.detailsFrame = mUI.MelFrameLayout(_inside,
                                           label="Details",
                                           collapsable=True,
                                           collapse=True,
                                           useTemplate='cgmUIHeaderTemplate')

    uiFunc_update_details(self)

    # Create Frame

    self.createFrame = mUI.MelFrameLayout(_inside,
                                          label="Create",
                                          collapsable=True,
                                          collapse=False,
                                          useTemplate='cgmUIHeaderTemplate')

    _create = mUI.MelColumnLayout(self.createFrame,
                                  useTemplate='cgmUIHeaderTemplate')

    cgmUI.add_LineSubBreak()

    _row = mUI.MelHSingleStretchLayout(_create,
                                       ut='cgmUISubTemplate',
                                       padding=_padding)

    mUI.MelSpacer(_row, w=_padding)

    _subRow = mUI.MelColumnLayout(_row, useTemplate='cgmUIHeaderTemplate')
    self.itemList = cgmUI.cgmScrollList(_subRow, numberOfRows=8, height=100)
    self.itemList(edit=True, allowMultiSelection=True)

    mUI.MelSpacer(_row, w=_padding)

    _row.setStretchWidget(_subRow)

    _row.layout()

    mUI.MelSeparator(_create, ut='cgmUISubTemplate', h=5)

    _row = mUI.MelHSingleStretchLayout(_create,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)

    addBtn = cgmUI.add_Button(
        _row, 'Add Selected',
        cgmGEN.Callback(uiFunc_list_function, self.itemList, 'add selected'),
        "Load selected objects.")

    cgmUI.add_Button(
        _row, 'Remove Selected',
        cgmGEN.Callback(uiFunc_list_function, self.itemList,
                        'remove selected'), "Remove selected objects.")

    cgmUI.add_Button(
        _row, 'Clear',
        cgmGEN.Callback(uiFunc_list_function, self.itemList, 'clear'),
        "Clear all objects.")

    _row.setStretchWidget(addBtn)

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()

    cgmUI.add_LineSubBreak()

    _row = mUI.MelHSingleStretchLayout(_create,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)

    _row.setStretchWidget(
        cgmUI.add_Button(_row, 'Make Dynamic Chain',
                         cgmGEN.Callback(uiFunc_make_dynamic_chain, self),
                         "Make Dynamic Chain."))

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()

    cgmUI.add_LineSubBreak()

    self.optionsFrame = mUI.MelFrameLayout(_create,
                                           label="Options",
                                           collapsable=True,
                                           collapse=True,
                                           useTemplate='cgmUIHeaderTemplate')

    _options = mUI.MelColumnLayout(self.optionsFrame,
                                   useTemplate='cgmUISubTemplate')

    mUI.MelSeparator(_options, ut='cgmUISubTemplate', h=5)

    _row = mUI.MelHSingleStretchLayout(_options,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Base Name: ')

    self.options_baseName = mUI.MelTextField(_row,
                                             ann='Name',
                                             text='DynamicChain')

    _row.setStretchWidget(self.options_baseName)

    mUI.MelSpacer(_row, w=_padding)
    _row.layout()

    _row = mUI.MelHSingleStretchLayout(_options,
                                       ut='cgmUISubTemplate',
                                       padding=5)
    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Name: ')

    self.options_name = mUI.MelTextField(_row, ann='Name', text='')

    _row.setStretchWidget(self.options_name)

    mUI.MelSpacer(_row, w=_padding)
    _row.layout()

    mUI.MelSeparator(_options, ut='cgmUISubTemplate', h=5)

    _row = mUI.MelHSingleStretchLayout(_options,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Direction:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    directions = ['x+', 'x-', 'y+', 'y-', 'z+', 'z-']

    mUI.MelLabel(_row, l='Fwd:')

    self.fwdMenu = mUI.MelOptionMenu(_row, useTemplate='cgmUITemplate')
    for dir in directions:
        self.fwdMenu.append(dir)

    self.fwdMenu.setValue('z+')

    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l='Up:')

    self.upMenu = mUI.MelOptionMenu(_row, useTemplate='cgmUITemplate')
    for dir in directions:
        self.upMenu.append(dir)

    self.upMenu.setValue('y+')

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    """
    _row.layout()

    #>>>Report ---------------------------------------------------------------------------------------
    _row_report = mUI.MelHLayout(_inside ,ut='cgmUIInstructionsTemplate',h=20)
    self.uiField_report = mUI.MelLabel(_row_report,
                                       bgc = SHARED._d_gui_state_colors.get('help'),
                                       label = '...',
                                       h=20)
    _row_report.layout() """

    return _inside
Ejemplo n.º 8
0
    def buildOptions(self,parent, asScroll = False):
 
        if asScroll:
            _inside = mUI.MelScrollLayout(parent,useTemplate = 'cgmUISubTemplate') 
        else:
            _inside = mUI.MelColumnLayout(parent,useTemplate = 'cgmUISubTemplate') 
        
        #>>>Objects Load Row ---------------------------------------------------------------------------------------
        
        mc.setParent(_inside)
        cgmUI.add_LineSubBreak()

        _row = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate',padding = 5,bgc=_subLineBGC)
        mUI.MelSpacer(_row,w=5)
        mUI.MelLabel(_row,l='Auto Link by')
        _row.setStretchWidget( mUI.MelSeparator(_row) )
    
        cgmUI.add_Button(_row,'Name',
                 cgmGEN.Callback(self.uiFunc_link_by_name,self),
                 _d_annotations.get('linkName','fix'), bgc=_buttonBGC) 
        cgmUI.add_Button(_row,'Distance',
                 cgmGEN.Callback(self.uiFunc_link_by_distance,self),
                 _d_annotations.get('linkDistance','fix'), bgc=_buttonBGC) 
        mUI.MelSpacer(_row,w=5)
        _row.layout()

        _row = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate',padding = 1,bgc=_subLineBGC)
        mUI.MelSpacer(_row,w=9)
        mUI.MelLabel(_row,l='Set Target Constraint to')
        _row.setStretchWidget( mUI.MelSeparator(_row) )

        cgmUI.add_Button(_row,'Point/Orient',
                 cgmGEN.Callback(self.uiFunc_set_constraint_type,1,True,self),
                 _d_annotations.get('setPointOrient','fix'), bgc=_buttonBGC) 
        cgmUI.add_Button(_row,'A',
                 cgmGEN.Callback(self.uiFunc_set_constraint_type,1,False,self),
                 _d_annotations.get('setPointOrientAll','fix'), bgc=_buttonBGC) 
        mUI.MelSpacer(_row,w=4)
        cgmUI.add_Button(_row,'Orient',
                 cgmGEN.Callback(self.uiFunc_set_constraint_type,0,True,self),
                 _d_annotations.get('setOrient','fix'), bgc=_buttonBGC) 
        cgmUI.add_Button(_row,'A',
                 cgmGEN.Callback(self.uiFunc_set_constraint_type,1,False,self),
                 _d_annotations.get('setOrientAll','fix'), bgc=_buttonBGC) 
        mUI.MelSpacer(_row,w=9)

        _row.layout()


        _row = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate',padding = 5,bgc=_subLineBGC)
        mUI.MelSpacer(_row,w=5)
        mUI.MelLabel(_row,l='Set Connection Pose')
        _row.setStretchWidget( mUI.MelSeparator(_row) )
        self.cb_set_connection_at_bake = mUI.MelCheckBox(_row,
                           v = self.var_mocap_set_connection_at_bake.value,
                           onCommand = lambda *a: self.var_mocap_set_connection_at_bake.setValue(1),
                           offCommand = lambda *a: self.var_mocap_set_connection_at_bake.setValue(0),
                           label="Set On Bake")
        cgmUI.add_Button(_row,'Manual Set',
                 cgmGEN.Callback(self.uiFunc_set_connection_pose,1,self),
                 _d_annotations.get('setConnectionPose','fix'), bgc = [.5,.2,0.2]) 
        mUI.MelSpacer(_row,w=5)

        _row.layout()

        # Bake Options

        timelineInfo = SEARCH.get_time('slider')

        mc.setParent(_inside)
        cgmUI.add_Header("Bake Options", overrideUpper = True)

        cgmUI.add_LineSubBreak()


        _row = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate',padding = 5,bgc=_subLineBGC)
        #self.timeSubMenu.append( _row )
        mUI.MelSpacer(_row,w=5)
        mUI.MelLabel(_row,l='Set Timeline Range')
        _row.setStretchWidget( mUI.MelSeparator(_row) )

        cgmUI.add_Button(_row,'Slider',
                 cgmGEN.Callback(self.uiFunc_updateTimeRange,'slider'),
                 _d_annotations.get('sliderRange','fix'), bgc=_buttonBGC) 
        cgmUI.add_Button(_row,'Sel',
                 cgmGEN.Callback(self.uiFunc_updateTimeRange,'selected'),
                 _d_annotations.get('selectedRange','fix'), bgc=_buttonBGC) 
        cgmUI.add_Button(_row,'Scene',
                 cgmGEN.Callback(self.uiFunc_updateTimeRange,'scene'),
                 _d_annotations.get('sceneRange','fix'), bgc=_buttonBGC) 
        mUI.MelSpacer(_row,w=5)
        _row.layout()


        _row = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate', padding=5,bgc=_subLineBGC)
        mUI.MelSpacer(_row,w=5)
        mUI.MelLabel(_row,l='Bake Range')
        _row.setStretchWidget( mUI.MelSeparator(_row) )

        mUI.MelLabel(_row,l='start')

        self.startFrameField = mUI.MelIntField(_row,'cgmLocWinStartFrameField',
                                           width = 40,
                                           value= timelineInfo[0])

        mUI.MelLabel(_row,l='end')

        self.endFrameField = mUI.MelIntField(_row,'cgmLocWinEndFrameField',
                                         width = 40,
                                         value= timelineInfo[1])

        cgmUI.add_Button(_row,' <<',
                         cgmGEN.Callback(self.uiFunc_bake,'back'),                         
                         #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
                         _d_annotations.get('<<<','fix'), bgc=_buttonBGC)
    
        cgmUI.add_Button(_row,'Bake',
                         cgmGEN.Callback(self.uiFunc_bake,'all'),                         
                         _d_annotations.get('All','fix'), bgc=_buttonBGC)
        
        
        cgmUI.add_Button(_row,'>>',
                         cgmGEN.Callback(self.uiFunc_bake,'forward'),                         
                         _d_annotations.get('>>>','fix'), bgc=_buttonBGC)

        mUI.MelSpacer(_row,w=5)
        _row.layout()

        mc.setParent(_inside)
        cgmUI.add_LineSubBreak()

        return _inside
Ejemplo n.º 9
0
def buildColumn_main(self, parent, asScroll=False):
    """
    Trying to put all this in here so it's insertable in other uis
    
    """
    if asScroll:
        _inside = mUI.MelScrollLayout(parent, useTemplate='cgmUISubTemplate')
    else:
        _inside = mUI.MelColumnLayout(parent, useTemplate='cgmUISubTemplate')

    self.var_contextTD = cgmMeta.cgmOptionVar('cgmVar_contextTD',
                                              defaultValue='selection')
    self.var_jointAimAxis = cgmMeta.cgmOptionVar('cgmVar_jointDefaultAimAxis',
                                                 defaultValue=2)
    self.var_jointUpAxis = cgmMeta.cgmOptionVar('cgmVar_jointDefaultUpAxis',
                                                defaultValue=1)

    self.uiPB_cgmJointTools = mc.progressBar(vis=False)

    mc.setParent(_inside)
    cgmUI.add_Header('Orient')
    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()
    #Orient ==================================================================================================

    #>>>Tweak -------------------------------------------------------------------------------------
    _row = mUI.MelHSingleStretchLayout(_inside,
                                       ut='cgmUISubTemplate',
                                       padding=5)
    mUI.MelSpacer(_row, w=5)

    mUI.MelLabel(_row, l='Tweak:')
    _row.setStretchWidget(mUI.MelSeparator(_row))
    _base_str = 'uiFF_orientTweak'

    #self._d_transformAttrFields[label] = {}
    #self._d_transformRows[label] = _row

    for a in list('xyz'):
        mUI.MelLabel(_row, l=a)
        _field = mUI.MelFloatField(_row, ut='cgmUISubTemplate', w=50)
        self.__dict__['{0}{1}'.format(_base_str, a.capitalize())] = _field

    mc.button(parent=_row,
              ut='cgmUITemplate',
              l=' + ',
              c=cgmGEN.Callback(uiFunc_tweak, self, '+'),
              ann="Adds value relatively to current")
    mc.button(parent=_row,
              ut='cgmUITemplate',
              l=' - ',
              c=cgmGEN.Callback(uiFunc_tweak, self, '-'),
              ann="Subracts value relatively to current")
    mc.button(parent=_row,
              ut='cgmUITemplate',
              l='Zero',
              c=cgmGEN.Callback(uiFunc_tweak, self, 'zero'),
              ann="Zero out the fields.")

    mUI.MelSpacer(_row, w=5)
    _row.layout()

    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()
    #mUI.MelSeparator(_inside)

    buildRow_worldUp(self, _inside)
    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()
    buildRow_getVector(self, _inside)

    #>>>Aim mode -------------------------------------------------------------------------------------
    _d = {'aim': self.var_jointAimAxis, 'up': self.var_jointUpAxis}

    for k in _d.keys():
        _var = _d[k]

        _row = mUI.MelHSingleStretchLayout(_inside,
                                           ut='cgmUISubTemplate',
                                           padding=5)

        mUI.MelSpacer(_row, w=5)
        mUI.MelLabel(_row, l='{0}:'.format(k))
        _row.setStretchWidget(mUI.MelSeparator(_row))

        uiRC = mUI.MelRadioCollection()
        _on = _var.value

        for i, item in enumerate(SHARED._l_axis_by_string):
            if i == _on:
                _rb = True
            else:
                _rb = False

            uiRC.createButton(_row,
                              label=item,
                              sl=_rb,
                              onCommand=cgmGEN.Callback(_var.setValue, i))

            mUI.MelSpacer(_row, w=2)
        _row.layout()

    #mUI.MelSeparator(_inside)

    #>>Orient Row -------------------------------------------------------------------------------
    _row_orient = mUI.MelHLayout(_inside, ut='cgmUISubTemplate', padding=5)
    mc.button(parent=_row_orient,
              ut='cgmUITemplate',
              l='Orient Selected',
              c=cgmGEN.Callback(orientJoints, self),
              ann="Orient selected joints")

    mc.button(
        parent=_row_orient,
        ut='cgmUITemplate',
        l='Plane Up',
        c=cgmGEN.Callback(orientPlane, self, 'up'),
        ann=
        "Orient selected joints along up plane of joints. Most useful for fingers and things like that"
    )
    mc.button(
        parent=_row_orient,
        ut='cgmUITemplate',
        l='Plane Out',
        c=cgmGEN.Callback(orientPlane, self, 'out'),
        ann=
        "Orient selected joints along out plane of joints. Most useful for fingers and things like that"
    )

    mc.button(
        parent=_row_orient,
        ut='cgmUITemplate',
        l='Freeze',
        ann=
        "Freeze selected joint's orientation - our method as we don't like Maya's",
        c=cgmGEN.Callback(MMCONTEXT.func_process, JOINTS.freezeOrientation,
                          None, 'each', 'freezeOrientation', False, **{}),
    )
    _row_orient.layout()
    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()

    #Create ==================================================================================================
    mc.setParent(_inside)
    cgmUI.add_Header('Create')

    #>>>Options Row ---------------------------------------------------------------------------------------
    _row_createOptions = mUI.MelHSingleStretchLayout(_inside,
                                                     ut='cgmUISubTemplate',
                                                     padding=5)
    mUI.MelSpacer(_row_createOptions, w=2)
    mUI.MelLabel(_row_createOptions, l='Resplit:')

    self.create_guiOptionVar('splitMode', defaultValue=0)

    uiRC = mUI.MelRadioCollection()
    _on = self.var_splitMode.value

    for i, item in enumerate(['none', 'linear', 'curve', 'sub']):
        if i == _on:
            _rb = True
        else:
            _rb = False

        uiRC.createButton(_row_createOptions,
                          label=item,
                          sl=_rb,
                          onCommand=cgmGEN.Callback(
                              self.var_splitMode.setValue, i))

        #mUI.MelSpacer(_row_createOptions,w=2)
    _row_createOptions.setStretchWidget(mUI.MelSeparator(_row_createOptions))

    self.uiIF_cnt = mUI.MelIntField(_row_createOptions,
                                    value=3,
                                    ut='cgmUISubTemplate',
                                    w=30)
    mUI.MelLabel(_row_createOptions, l='#')

    mUI.MelSpacer(_row_createOptions, w=2)

    _row_createOptions.layout()

    #>>>Create Buttons Row ---------------------------------------------------------------------------------------
    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()
    _row_create = mUI.MelHSingleStretchLayout(_inside,
                                              ut='cgmUISubTemplate',
                                              padding=5)
    mUI.MelSpacer(_row_create, w=2)

    self.uiCB_orient = mUI.MelCheckBox(_row_create,
                                       en=True,
                                       l='Orient',
                                       value=True,
                                       ann='Orient created joints')

    self.uiCB_chain = mUI.MelCheckBox(_row_create,
                                      en=True,
                                      l='Chain',
                                      value=True,
                                      ann='Parent created joints as a chain')

    self.uiCB_relative = mUI.MelCheckBox(
        _row_create,
        en=True,
        l='Relative',
        value=False,
        ann=
        'Relative orient where the chain orientation is relative to the parent'
    )

    _row_create.setStretchWidget(mUI.MelSeparator(_row_create))

    #mUI.MelLabel(_row_create,l='From Selected:')
    mc.button(
        parent=_row_create,
        ut='cgmUITemplate',
        l='From Selected',
        c=cgmGEN.Callback(createJoints, self, 'each'),
        #ann = "Show the joint axis by current context",
        #c= lambda *a:MMCONTEXT.set_attrs(self,'displayLocalAxis',1,self.var_contextTD.value,'joint',select=False),
    )
    mc.button(
        parent=_row_create,
        ut='cgmUITemplate',
        l='Mid',
        c=cgmGEN.Callback(MMCONTEXT.func_process, RIGGING.create_at, None,
                          'all', 'Create Joint at mid', **{
                              'create': 'joint',
                              'midPoint': 'True'
                          }),
        ann='Create a joint at the mid point of selected',
    )
    mc.button(
        parent=_row_create,
        ut='cgmUITemplate',
        l='Curve',
        c=cgmGEN.Callback(createJoints, self, 'curve'),
        #ann = "Show the joint axis by current context",
        #c= lambda *a:MMCONTEXT.set_attrs(self,'displayLocalAxis',1,self.var_contextTD.value,'joint',select=False),
    )

    mUI.MelSpacer(_row_create, w=2)
    _row_create.layout()

    if asScroll:
        #Axis ==================================================================================================
        mc.setParent(_inside)
        cgmUI.add_Header('Raycast')
        mc.setParent(_inside)
        cgmUI.add_LineSubBreak()

        UICHUNKS.uiChunk_rayCast(self, _inside)

    #Axis ==================================================================================================
    mc.setParent(_inside)
    cgmUI.add_Header('Axis')
    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()

    #>>>Axis Show Row ---------------------------------------------------------------------------------------
    _row_axis = mUI.MelHLayout(_inside, ut='cgmUISubTemplate', padding=5)
    mc.button(
        parent=_row_axis,
        ut='cgmUITemplate',
        l='* Show',
        ann="Show the joint axis by current context",
        c=lambda *a: MMCONTEXT.set_attrs(self,
                                         'displayLocalAxis',
                                         1,
                                         self.var_contextTD.value,
                                         'joint',
                                         select=False),
    )

    mc.button(
        parent=_row_axis,
        ut='cgmUITemplate',
        l='* Hide',
        ann="Hide the joint axis by current context",
        c=lambda *a: MMCONTEXT.set_attrs(self,
                                         'displayLocalAxis',
                                         0,
                                         self.var_contextTD.value,
                                         'joint',
                                         select=False),
    )

    _row_axis.layout()

    #Axis ==================================================================================================
    mc.setParent(_inside)
    cgmUI.add_Header('Radius')
    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()
    _row_radius = mUI.MelHLayout(_inside, ut='cgmUISubTemplate', padding=5)
    mc.button(parent=_row_radius,
              ut='cgmUITemplate',
              l=' / 2 ',
              c=lambda *a: radius_modify(self, '/', 2),
              ann="Contextual radius editing")
    mc.button(parent=_row_radius,
              ut='cgmUITemplate',
              l=' - 10',
              c=lambda *a: radius_modify(self, '-', 10),
              ann="Contextual radius editing")
    mc.button(parent=_row_radius,
              ut='cgmUITemplate',
              l='- 1',
              c=lambda *a: radius_modify(self, '-', 1),
              ann="Contextual radius editing")
    mc.button(parent=_row_radius,
              ut='cgmUITemplate',
              l='+ 1',
              c=lambda *a: radius_modify(self, '+', 1),
              ann="Contextual radius editing")
    mc.button(parent=_row_radius,
              ut='cgmUITemplate',
              l='+10',
              c=lambda *a: radius_modify(self, '+', 10),
              ann="Contextual radius editing")
    mc.button(parent=_row_radius,
              ut='cgmUITemplate',
              l='*2',
              c=lambda *a: radius_modify(self, '*', 2),
              ann="Contextual radius editing")
    _row_radius.layout()

    #Utilities ==================================================================================================
    mc.setParent(_inside)
    cgmUI.add_Header('Utilities')
    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()

    #Buttons ----------------------------------------------------------------------------------------------
    _row_utils = mUI.MelHLayout(_inside, ut='cgmUISubTemplate', padding=5)

    mc.button(parent=_row_utils,
              ut='cgmUITemplate',
              l='cometJO',
              c=lambda *a: mel.eval('cometJointOrient'),
              ann="General Joint orientation tool  by Michael Comet")
    mc.button(parent=_row_utils,
              ut='cgmUITemplate',
              l='* Select',
              c=lambda *a: contextual_select(self),
              ann="Contextual joint selection")
    mc.button(
        parent=_row_utils,
        ut='cgmUITemplate',
        l='seShapeTaper',
        ann=
        "Fantastic blendtaper like tool for sdk poses by our pal - Scott Englert",
        c=lambda *a: mel.eval('seShapeTaper'),
    )
    _row_utils.layout()

    return _inside
Ejemplo n.º 10
0
def uiFunc_build_post_keyframe_to_motion_curve_column(self):
    parentColumn = self._postProcessOptionsColumn

    parentColumn.clear()

    # Debug
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l='Additional Options:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    mUI.MelLabel(_row, l='Debug:')

    self.uiCB_post_debug = mUI.MelCheckBox(
        _row,
        en=True,
        v=False,
        label='',
        ann='Debug locators will not be deleted so you could see what happened'
    )

    mUI.MelLabel(_row, l='Show Bake:')

    self.uiCB_post_show_bake = mUI.MelCheckBox(_row,
                                               en=True,
                                               v=False,
                                               label='',
                                               ann='Show the bake process')

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Debug

    # Bake Trajectory Aim Button
    #
    _row = mUI.MelHLayout(parentColumn,
                          ut='cgmUISubTemplate',
                          padding=_padding * 2)

    cgmUI.add_Button(
        _row,
        'Bake Keyframes to Motion Curve',
        cgmGEN.Callback(uiFunc_bake_keyframe_to_motion_curve, self),
        #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
        'Bake Keyframes to Motion Curve',
        h=30)

    _row.layout()
    #
    # End Bake Dragger Button

    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()
Ejemplo n.º 11
0
def uiFunc_build_post_trajectory_aim_column(self):
    parentColumn = self._postProcessOptionsColumn

    parentColumn.clear()

    # Aim
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)
    self._post_row_aimDirection = _row

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Aim:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    directions = ['x+', 'x-', 'y+', 'y-', 'z+', 'z-']

    mUI.MelLabel(_row, l='Fwd:')

    self.post_fwdMenu = mUI.MelOptionMenu(_row,
                                          useTemplate='cgmUITemplate',
                                          changeCommand=cgmGEN.Callback(
                                              uiFunc_setPostAim, self))
    for dir in directions:
        self.post_fwdMenu.append(dir)

    self.post_fwdMenu.setValue(self._optionDict['aimFwd'])

    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l='Up:')

    self.post_upMenu = mUI.MelOptionMenu(_row,
                                         useTemplate='cgmUITemplate',
                                         changeCommand=cgmGEN.Callback(
                                             uiFunc_setPostAim, self))
    for dir in directions:
        self.post_upMenu.append(dir)

    self.post_upMenu.setValue(self._optionDict['aimUp'])

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Aim

    # Post Damp
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Damp:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    self.uiFF_post_damp = mUI.MelFloatField(_row,
                                            ut='cgmUISubTemplate',
                                            w=50,
                                            v=15)

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Damp

    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()

    # Debug
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Show Bake:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    self.uiCB_post_show_bake = mUI.MelCheckBox(_row,
                                               en=True,
                                               v=False,
                                               label='',
                                               ann='Show the bake process')

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Debug

    # Bake Trajectory Aim Button
    #
    _row = mUI.MelHLayout(parentColumn,
                          ut='cgmUISubTemplate',
                          padding=_padding * 2)

    cgmUI.add_Button(
        _row,
        'Bake Trajectory Aim',
        cgmGEN.Callback(uiFunc_bake_trajectory_aim, self),
        #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
        'Bake Trajectory Aim',
        h=30)

    _row.layout()
    #
    # End Bake Dragger Button

    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()
Ejemplo n.º 12
0
def uiFunc_build_post_spring_column(self):
    parentColumn = self._postProcessOptionsColumn

    parentColumn.clear()

    # Aim
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)
    self._post_row_aimDirection = _row

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Aim:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    directions = ['x+', 'x-', 'y+', 'y-', 'z+', 'z-']

    mUI.MelLabel(_row, l='Fwd:')

    self.post_fwdMenu = mUI.MelOptionMenu(_row,
                                          useTemplate='cgmUITemplate',
                                          changeCommand=cgmGEN.Callback(
                                              uiFunc_setPostAim, self))
    for dir in directions:
        self.post_fwdMenu.append(dir)

    self.post_fwdMenu.setValue(self._optionDict['aimFwd'])

    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l='Up:')

    self.post_upMenu = mUI.MelOptionMenu(_row,
                                         useTemplate='cgmUITemplate',
                                         changeCommand=cgmGEN.Callback(
                                             uiFunc_setPostAim, self))
    for dir in directions:
        self.post_upMenu.append(dir)

    self.post_upMenu.setValue(self._optionDict['aimUp'])

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Aim

    # Spring
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Spring Force:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    self.uiFF_post_spring = mUI.MelFloatField(_row,
                                              ut='cgmUISubTemplate',
                                              w=50,
                                              v=1.0)

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Spring

    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()

    # Post Damp
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Damp:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    self.uiFF_post_damp = mUI.MelFloatField(_row,
                                            ut='cgmUISubTemplate',
                                            w=50,
                                            v=.1)

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Damp

    # Spring
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Angular Spring Force:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    self.uiFF_post_angularSpring = mUI.MelFloatField(_row,
                                                     ut='cgmUISubTemplate',
                                                     w=50,
                                                     v=1.0)

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Spring

    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()

    # Post Damp
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Angular Damp:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    self.uiFF_post_angularDamp = mUI.MelFloatField(_row,
                                                   ut='cgmUISubTemplate',
                                                   w=50,
                                                   v=.1)

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Damp

    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()

    # Post Object Scale
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)
    mUI.MelLabel(_row, l='Object Scale:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    self.uiFF_post_object_scale = mUI.MelFloatField(_row,
                                                    ut='cgmUISubTemplate',
                                                    w=50,
                                                    v=10.0)

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Object Scale

    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()

    # Debug
    #
    _row = mUI.MelHSingleStretchLayout(parentColumn,
                                       ut='cgmUISubTemplate',
                                       padding=5)

    mUI.MelSpacer(_row, w=_padding)

    mUI.MelLabel(_row, l='Additional Options:')

    _row.setStretchWidget(mUI.MelSeparator(_row))

    mUI.MelLabel(_row, l='Debug:')

    self.uiCB_post_debug = mUI.MelCheckBox(
        _row,
        en=True,
        v=False,
        label='',
        ann='Debug locators will not be deleted so you could see what happened'
    )

    mUI.MelLabel(_row, l='Show Bake:')

    self.uiCB_post_show_bake = mUI.MelCheckBox(_row,
                                               en=True,
                                               v=False,
                                               label='',
                                               ann='Show the bake process')

    mUI.MelSpacer(_row, w=_padding)

    _row.layout()
    #
    # End Debug

    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()

    # Bake Spring Button
    #
    _row = mUI.MelHLayout(parentColumn,
                          ut='cgmUISubTemplate',
                          padding=_padding * 2)

    cgmUI.add_Button(
        _row,
        'Bake Spring',
        cgmGEN.Callback(uiFunc_bake_spring, self),
        #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
        'Bake Spring',
        h=30)

    _row.layout()
    #
    # End Bake Spring Button

    mc.setParent(parentColumn)
    cgmUI.add_LineSubBreak()
Ejemplo n.º 13
0
def buildColumn_create_mapping(self):
    """
    Trying to put all this in here so it's insertable in other uis
    
    """   
    self.mappingColumn.clear()

    # if asScroll:
    #     _inside = mUI.MelScrollLayout(parent,useTemplate = 'cgmUISubTemplate') 
    # else:
    #     _inside = mUI.MelColumnLayout(parent,useTemplate = 'cgmUISubTemplate') 
    
    #>>>Objects Load Row ---------------------------------------------------------------------------------------
    _inside = self.mappingColumn

    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()

    _row = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate',padding = _padding)        
    
    mUI.MelSpacer(_row,w=_padding)

    mUI.MelLabel(_row,l='Name:')

    self.nameTF = mUI.MelTextField(_row, text=self.connectionDict['name'], editable = True, bgc=[0,0,0], cc=cgmGEN.Callback(uiFunc_update_connectionDict_name,self))

    _row.setStretchWidget(self.nameTF)

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()

    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()
    
    controllerConnections = [ ['Left Stick Horizontal', 'LStickHorizontal'], ['Left Stick Vertical', 'LStickVertical'], ['Right Stick Horizontal', 'RStickHorizontal'], ['Right Stick Vertical', 'RStickVertical'], ['Left Trigger', 'LTrigger'], ['Right Trigger', 'RTrigger'] ]

    for con in controllerConnections:
        _row = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate',padding = _padding)

        mUI.MelSpacer(_row,w=_padding)

        _subColumn = mUI.MelColumnLayout(_row,useTemplate = 'cgmUIHeaderTemplate') 

        _conFrame = mUI.MelFrameLayout(_subColumn, label=con[0], collapsable=True, collapse=True,useTemplate = 'cgmUIHeaderTemplate')
        
        _conColumn = mUI.MelColumnLayout(_conFrame,useTemplate = 'cgmUIHeaderTemplate') 

        uiFunc_build_controller_connection_column(self, _conColumn, con[1])

        _row.setStretchWidget(_subColumn)

        mUI.MelSpacer(_row,w=_padding)

        _row.layout()

        mc.setParent(_inside)
        cgmUI.add_LineSubBreak()

    # Add/Clear Mapping Buttons
    #
    _row = mUI.MelHLayout(_inside,ut='cgmUISubTemplate',padding = _padding*2)
    
    cgmUI.add_Button(_row,'Add Mapping',
        cgmGEN.Callback(uiFunc_add_mapping_to_list,self),                         
        'Add Mapping Button',h=30)

    cgmUI.add_Button(_row,'Clear Mapping',
        cgmGEN.Callback(uiFunc_clear_connection_dict,self),                         
        'Add Mapping Button',h=30)

    _row.layout()
    #
    # End Add/Clear Mapping Buttons

    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()

    return _inside
Ejemplo n.º 14
0
    def build_layoutWrapper(self,parent):
        _str_func = 'build_layoutWrapper'
        #self._d_uiCheckBoxes = {}
    
        #_MainForm = mUI.MelFormLayout(parent,ut='cgmUISubTemplate')
        _MainForm = mUI.MelFormLayout(self,ut='cgmUITemplate')
        _mainScroll = mUI.MelScrollLayout(_MainForm,useTemplate = 'cgmUIHeaderTemplate') 

        _mappingFrame = mUI.MelFrameLayout(_mainScroll, label='Create Mapping', collapsable=True, collapse=False,useTemplate = 'cgmUIHeaderTemplate')
        
        self.mappingColumn = mUI.MelColumnLayout(_mappingFrame,useTemplate = 'cgmUISubTemplate') 

        buildColumn_create_mapping(self)

        _loadMappingFrame = mUI.MelFrameLayout(_mainScroll, label='Load Mappings', collapsable=True, collapse=False,useTemplate = 'cgmUIHeaderTemplate')
        
        self.loadMappingColumn = mUI.MelColumnLayout(_loadMappingFrame,useTemplate = 'cgmUISubTemplate') 

        _row = mUI.MelHSingleStretchLayout(self.loadMappingColumn,ut='cgmUISubTemplate',padding = _padding, height=75+_padding)

        mUI.MelSpacer(_row,w=_padding)

        _colorColumn = mUI.MelColumnLayout(_row,useTemplate = 'cgmUIHeaderTemplate', height=75 )
        self.mappingListTSL = cgmUI.cgmScrollList(_colorColumn, numberOfRows = 4, height=75)

        mUI.MelSpacer(_row,w=_padding)

        _row.setStretchWidget(_colorColumn)

        _row.layout()

        mc.setParent(self.loadMappingColumn)
        cgmUI.add_LineSubBreak()

        _row = mUI.MelHLayout(self.loadMappingColumn,ut='cgmUISubTemplate',padding = _padding*2)
        cgmUI.add_Button(_row,'Load From File',
            cgmGEN.Callback(uiFunc_load,self),
            #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
            'Load a mapping from file',h=30)
        cgmUI.add_Button(_row,'Remove Mapping',
            cgmGEN.Callback(uiFunc_remove_mapping,self),
            'Remove selected mapping',h=30) 

        _row.layout() 

        mc.setParent(self.loadMappingColumn)
        cgmUI.add_LineSubBreak()

        # Start GamePad Button
        #
        #_row = mUI.MelHLayout(_mainScroll,ut='cgmUISubTemplate',padding = _padding*2)
        
        self.animDrawBtn = cgmUI.add_Button(_mainScroll,'Start GamePad',
            cgmGEN.Callback(start_controller,self),                         
            #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
            'Start Gamepad Button',h=50)

        #_row.layout()    
        #
        # End Recording Button

        _row_cgm = cgmUI.add_cgmFooter(_MainForm)            
        _MainForm(edit = True,
                  af = [(_mainScroll,"top",0),
                        (_mainScroll,"left",0),
                        (_mainScroll,"right",0),                        
                        (_row_cgm,"left",0),
                        (_row_cgm,"right",0),                        
                        (_row_cgm,"bottom",0),
    
                        ],
                  ac = [(_mainScroll,"bottom",2,_row_cgm),
                        ],
                  attachNone = [(_row_cgm,"top")])          
Ejemplo n.º 15
0
def uiFunc_build_options_column(self):
    mc.setParent(self._optionColumn)
    cgmUI.add_LineSubBreak()

    # Mode
    #
    _row = mUI.MelHSingleStretchLayout(self._optionColumn,ut='cgmUISubTemplate',padding = 5)

    mUI.MelSpacer(_row,w=_padding)                      
    mUI.MelLabel(_row,l='Mode:')
    _row.setStretchWidget( mUI.MelSeparator(_row) )

    uiRC = mUI.MelRadioCollection()

    _on = self._optionDict['mode']

    for i,item in enumerate(['position','aim']):
        if item == _on:
            _rb = True
        else:_rb = False

        uiRC.createButton(_row,label=item,sl=_rb,
                          onCommand = cgmGEN.Callback(uiFunc_setModeOption,self,'mode', item))

        mUI.MelSpacer(_row,w=_padding)       

    _row.layout()  
    #
    # End Mode

    mc.setParent(self._optionColumn)
    cgmUI.add_LineSubBreak()    

    # Plane
    #
    _row = mUI.MelHSingleStretchLayout(self._optionColumn,ut='cgmUISubTemplate',padding = 5)

    mUI.MelSpacer(_row,w=_padding)                          
    mUI.MelLabel(_row,l='Plane:')

    _row.setStretchWidget( mUI.MelSeparator(_row) )
   
    self.planeMenu = mUI.MelOptionMenu(_row,useTemplate = 'cgmUITemplate')
    for option in _planeOptionsPosition:
        self.planeMenu.append(option)

    self.planeMenu.setValue( self._optionDict['plane'] )

    self.planeMenu(edit=True, changeCommand=cgmGEN.Callback(uiFunc_set_plane,self))

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()
    #
    # End Plane

    # Aim
    #
    _row = mUI.MelHSingleStretchLayout(self._optionColumn,ut='cgmUISubTemplate',padding = 5, vis=False)
    self._row_aimDirection = _row

    mUI.MelSpacer(_row,w=_padding)                          
    mUI.MelLabel(_row,l='Aim:')  

    _row.setStretchWidget( mUI.MelSeparator(_row) )

    directions = ['x+', 'x-', 'y+', 'y-', 'z+', 'z-']

    mUI.MelLabel(_row,l='Fwd:') 

    self.fwdMenu = mUI.MelOptionMenu(_row,useTemplate = 'cgmUITemplate', changeCommand=cgmGEN.Callback(uiFunc_setAim,self))
    for dir in directions:
        self.fwdMenu.append(dir)
    
    self.fwdMenu.setValue(self._optionDict['aimFwd'])

    mUI.MelSpacer(_row,w=_padding)
    
    mUI.MelLabel(_row,l='Up:')

    self.upMenu = mUI.MelOptionMenu(_row,useTemplate = 'cgmUITemplate', changeCommand=cgmGEN.Callback(uiFunc_setAim,self))
    for dir in directions:
        self.upMenu.append(dir)

    self.upMenu.setValue(self._optionDict['aimUp'])

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()
    #
    # End Aim

    # mc.setParent(self._optionColumn)
    # cgmUI.add_LineSubBreak()    

    # Plane Object
    #
    _row = mUI.MelHSingleStretchLayout(self._optionColumn,ut='cgmUISubTemplate',padding = 5)
    self._row_planeObject = _row

    mUI.MelSpacer(_row,w=_padding)
    mUI.MelLabel(_row,l='Plane Object:')

    self.uiTF_planeObject = mUI.MelLabel(_row,ut='cgmUIInstructionsTemplate',l='',en=False)

    _row.setStretchWidget( self.uiTF_planeObject )

    cgmUI.add_Button(_row,'<<',
                     cgmGEN.Callback(uiFunc_load_planeObject,self),
                     "Load first selected object.")  

    cgmUI.add_Button(_row,'Create',
                     cgmGEN.Callback(uiFunc_create_planeObject,self),
                     "Load first selected object.") 

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()

    self._row_planeObject(edit=True, vis=False)
    #
    # End Plane Object

    # Record Mode
    #
    _row = mUI.MelHSingleStretchLayout(self._optionColumn,ut='cgmUISubTemplate',padding = 5)

    mUI.MelSpacer(_row,w=_padding)                          
    mUI.MelLabel(_row,l='Record Mode:')

    _row.setStretchWidget( mUI.MelSeparator(_row) )
   
    self.recordMenu = mUI.MelOptionMenu(_row,useTemplate = 'cgmUITemplate')
    for option in ['replace', 'combine']:
        self.recordMenu.append(option)

    self.recordMenu.setValue( self._optionDict['recordMode'] )

    self.recordMenu(edit=True, changeCommand=cgmGEN.Callback(uiFunc_set_record_mode,self))

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()
    #
    # End Record Mode

    # Loop Time
    #
    _row = mUI.MelHSingleStretchLayout(self._optionColumn,ut='cgmUISubTemplate',padding = 5)

    mUI.MelSpacer(_row,w=_padding)
    mUI.MelLabel(_row,l='Loop Time:')

    _row.setStretchWidget( mUI.MelSeparator(_row) )

    self.uiCB_loopTime = mUI.MelCheckBox(_row,en=True,
                               v = self._optionDict['loopTime'],
                               label = '',
                               ann='Should time loop to start after reaching the end',
                               cc=cgmGEN.Callback(uiFunc_set_loop_time,self))

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()
    #
    # End Loop Time

    # Post Blend Frames
    #
    _row = mUI.MelHSingleStretchLayout(self._optionColumn,ut='cgmUISubTemplate',padding = 5)

    mUI.MelSpacer(_row,w=_padding)
    mUI.MelLabel(_row,l='Post Blend Frames:')

    _row.setStretchWidget( mUI.MelSeparator(_row) )

    self.uiIF_postBlendFrames = mUI.MelIntField(_row, ut='cgmUISubTemplate', w= 50, v=self._optionDict['postBlendFrames'], cc=cgmGEN.Callback(uiFunc_set_post_blend_frames,self))

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()
    #
    # End Post Blend Frames

    # Debug
    #
    _row = mUI.MelHSingleStretchLayout(self._optionColumn,ut='cgmUISubTemplate',padding = 5)

    mUI.MelSpacer(_row,w=_padding)
    mUI.MelLabel(_row,l='Debug:')

    _row.setStretchWidget( mUI.MelSeparator(_row) )

    self.uiCB_debug = mUI.MelCheckBox(_row,en=True,
                               v = self._optionDict['loopTime'],
                               label = '',
                               ann='Various debug junk might stick around after recording',
                               cc=cgmGEN.Callback(uiFunc_set_debug,self))

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()
    #
    # End Debug

    mc.setParent(self._optionColumn)
    cgmUI.add_LineSubBreak()   
Ejemplo n.º 16
0
def buildColumn_main(self,parent, asScroll = False):
    """
    Trying to put all this in here so it's insertable in other uis
    
    """   
    if asScroll:
        _inside = mUI.MelScrollLayout(parent,useTemplate = 'cgmUISubTemplate') 
    else:
        _inside = mUI.MelColumnLayout(parent,useTemplate = 'cgmUISubTemplate') 
    
    #>>>Objects Load Row ---------------------------------------------------------------------------------------
    _row_objLoad = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate',padding = _padding)        

    mUI.MelSpacer(_row_objLoad,w=_padding)
    mUI.MelLabel(_row_objLoad, 
                 l='Target:')

    self.uiTF_objLoad = mUI.MelLabel(_row_objLoad,ut='cgmUIInstructionsTemplate',l='',en=True)

    _row_objLoad.setStretchWidget(self.uiTF_objLoad)
    mUI.MelSpacer(_row_objLoad,w=_padding)

    _row_objLoad.layout()

    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()

    # Options Frame
    #
    _row = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate',padding = _padding)        

    mUI.MelSpacer(_row,w=_padding)

    _subColumn = mUI.MelColumnLayout(_row,useTemplate = 'cgmUIHeaderTemplate') 

    _optionFrame = mUI.MelFrameLayout(_subColumn, label='Options', collapsable=True, collapse=True,useTemplate = 'cgmUIHeaderTemplate')
    
    self._optionColumn = mUI.MelColumnLayout(_optionFrame,useTemplate = 'cgmUIHeaderTemplate') 

    uiFunc_build_options_column(self)

    _row.setStretchWidget(_subColumn)

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()
    #
    # End Options Frame

    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()

    # Recording Button
    #
    _row = mUI.MelHLayout(_inside,ut='cgmUISubTemplate',padding = _padding*2)
    
    self.animDrawBtn = cgmUI.add_Button(_row,'Start Recording Context',
        cgmGEN.Callback(uiFunc_toggleContext,self),                         
        #lambda *a: attrToolsLib.doAddAttributesToSelected(self),
        'Start Live Record',h=50)

    _row.layout()    
    #
    # End Recording Button

    mc.setParent(_inside)
    cgmUI.add_LineSubBreak()

    # Instructions Label
    #
    _row = mUI.MelHLayout(_inside,ut='cgmUISubTemplate',padding = _padding*2)
    self._infoLayout = _row

    self._infoLayout(edit=True, vis=False)

    mUI.MelLabel(_row,ut='cgmUIInstructionsTemplate',l='Left Drag: Draw  -  Ctrl Left Drag: Reposition  -  Right Click: Cache Data',en=True)

    _row.layout()
    #
    # End Instructions

    # Post Process Frame
    #
    _row = mUI.MelHSingleStretchLayout(_inside,ut='cgmUISubTemplate',padding = _padding)        

    mUI.MelSpacer(_row,w=_padding)

    _subColumn = mUI.MelColumnLayout(_row,useTemplate = 'cgmUIHeaderTemplate') 

    _postProcessFrame = mUI.MelFrameLayout(_subColumn, label='Post Process Animation', collapsable=True, collapse=True,useTemplate = 'cgmUIHeaderTemplate')
    
    self._postProcessColumn = mUI.MelColumnLayout(_postProcessFrame,useTemplate = 'cgmUIHeaderTemplate') 

    AFT.uiFunc_build_post_process_column(self, self._postProcessColumn)

    _row.setStretchWidget(_subColumn)

    mUI.MelSpacer(_row,w=_padding)

    _row.layout()
    #
    # End Post Process Frame

    return _inside