python - FrameSelected isn't working -


I have this problem where I'm unable to get the function frame select () In my view, I have a camera called TT_CAM, and there is a list of models with label labeled 'model' (this is called pebble / sphere etc.) called

My aim is to The user executes the script,

I tried to use the code given below but This failed for the frame.

Here's what I have tried:

  Import cmas cmlook.lookThru ("TT_CAM") as CMD cm mAssets = cmds.select ('Model *' ) # Cmds.viewFit (mAssets) cmds.FrameSelected (MAssets)    

I call it a I will not post it as an answer. I did not know that Pimail actually had such a task, but you have to import it explicitly to use it (it is a problem from here that you get it from CMDS How are you calling ). Due to the size of your code, I just rewrite it using just the piemail.

  Import pymel.core to import from pmym.core.runtime import from frame frames related to pm.lookThru (" TT_CAM ") mAssets = Pm.select ('Model *') Framesocated () # No logic required to pass, works with selected objects   

However this is just ViewFit () , which accepts other arguments, such as how many viewport you want fit, this can be fixed To, whether you how you can pass a float.

Comments

Popular posts from this blog

wpf - ControlTemplate with changes for every class -

sonata admin - how to add ManyToOne property field in configureListfield in sonataAdmin -

sql - Return Function using Cursor -