PDA

View Full Version : Filter selection for vertices?


EightBit
02-17-2011, 05:37 AM
Is there a way?
TIA

efecto
02-17-2011, 07:18 AM
filterExpand?

ewerybody
02-18-2011, 08:10 AM
"Know-it-All" ^^

sm=31 (http://download.autodesk.com/us/maya/2009help/CommandsPython/filterExpand.html)!

EightBit
02-18-2011, 03:13 PM
That actually works better than what I was thinking of, but can a vertex be detected from a selection list?sel = cmds.ls (sl=1)
for tmp in sel:
Is tmp a vertex? Thanks.

ewerybody
02-18-2011, 03:57 PM
Hm... don't know. objectType just returns mesh. But you could look if mc.filterExpand results in anything at all: for x in mc.ls(sl=1):
if mc.filterExpand(x,sm=31) is not None:
print (x + ' is a vertex')You can additionally get rid of the bundles via fl=1 but actually ... I can't imagine a case where I ever had to do this! What you need is just:vsel = mc.filterExpand(sm=31)

EightBit
05-29-2011, 05:25 PM
Back around to needing this. Very helpful.
Thanks.

CGTalk Moderation
05-29-2011, 05:25 PM
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.