PDA

View Full Version : [py] show Polygons only in viewport


Sorath
08-07-2012, 03:17 PM
Hey,

I am trying to do show Polygons only from the show menu inside the viewport.
But I can't find a proper command,
I got it working using this - filtered on polys only.

mc.modelEditor (viewport, edit=True, vs=1)

but due to our pipeline this doesn't work, so what I need is not a isolate selected but rather a show polygons only.

anyone a Idea how to access this menu entries?

cheers

NaughtyNathan
08-07-2012, 04:21 PM
the modelEditor command has several different flags to turn on/off the display of all those various node types, for example:
mc.modelEditor(viewport, e=1, polyMeshes=1)you can also turn all objects off using the -alo -allObjects flag. doesn't turning "Echo All Commands" on in the script editor help here?

Sorath
08-07-2012, 04:34 PM
ups.
ok, aparently I tried last time with echo all commands and didn't got feedback.
but yeah, it works now.
thanks anyway for pointing me out!

djx
08-08-2012, 12:41 AM
You can get a list of all the modelEditor keywords with the current viewport state like this (with python)...

pm.modelEditor('modelPanel4', q=True, sts=True)

but as you will discover, this is one of those cases where maya reveals its mel origins... and so doing it in mel formats the result better (with mel)...

modelEditor -q -sts "modelPanel4";

David

CGTalk Moderation
08-08-2012, 12:41 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.