Number of vertices in object ?


#1

Hi ,

OK, guys, a beginner’s question - is there a MEL command that returns the number of vertices for an object? I’m trawling through the library, but I haven’t found anything yet.

Cheers

Bob


#2

the polyEvaluate command can tell you a lot of attrs of a polymesh

int $numberOfVertex=’ polyEvaluate -vertex`;


#3

Alternatively:

proc int mhNumVerts(string $obj)
{
select -r $obj;
PolySelectConvert 3;
string $selected[] = ls -sl -fl;
int $numVerts = size($selected);
return $numVerts;
}


#4

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.