“The Vertex Size…” command/option (found under Display > Polygons) uses a function called setVertexSize()
, at least that is what is printed in the script editor.
I have tried to find the Mel source file for this function in the Maya installation directory with no luck. Also no luck with whatIs
and runTimeCommand -query -command
and the Mel reference does not list it.
Is anyone familiar with this function? How can I find its source code? or learn more about it?
I need to find out the underlying Mel command its using the change the sizes of polygon vertices, I have tried setVertexSize(<some number>)
but I get an error, I dont think the function has any built in parameters.
Running whatIs on setVertexSize, gives you this:
whatIs setVertexSize;
If you look in that script, and search for setVertexSize, you’ll end up here:
So, this procedure just queries value from
vertexSizeSlider (slider in
Vertex Size pop-up window), and calls
polyOptions command, passing that value as an argument to
sizeVertex flag.
Meaning, you could just do the following, to change size of polygonal vertices:
polyOptions -activeObjects -sizeVertex 4; // changes vertex size on selected (active) objects only
polyOptions -global -sizeVertex 11; // changes vertex size on all objects
1 Like
man you are amazing, thank you once again for you kindr help. That is the mel command I was looking for indeed.
If I may ask what editor/IDE are you using there with Maya? It seems to even support Mel console ouput!
First image is from Zubrigg’s Charcoal Editor - I use that one in Maya.
Outside of Maya, PyCharm for Python, and Visual Studio for C++.
If you’re asking about second image (these 2 images are not from the same editor), it’s just plain old Notepad++ in dark mode (which has colorful feelings towards MEL, I guess - not my doing).
I don’t use it as an IDE, rather it’s default “text” files viewer/editor, and happened to be used to open this MEL script (apologies for vividness of above code snippet - just realized it; hopefully it’s not causing any strain/pain to sensitive people).
1 Like