Toggle navigation
Polycount
News
Forums
Patreon
Challenges
Quarterly Character Art Challenge
Bi-Monthly Environment Art Challenge
Wiki
Moar
Recent
Activity
Badges
Drafts
Store
Sign In
·
Register
Author:
praesidenter
Home
›
Technical Talk
MEL script, selected faces and edges at the same time stored in separate variables is it possible?
malcolm
polycount sponsor
Offline /
Send Message
malcolm
polycount sponsor
Aug 2018
Hi, like the title says, is it possible to enter multi select mode, then select some edges and some faces in the viewport, then in MEL somehow store the selected edges in variable1 and store the faces in variable2.
0
·
Share on Facebook
Share on Twitter
Replies
Offline /
Send Message
throttlekitty
ngon master
Aug 2018
These two lines will do this. I'm using
filterExpand
as a selection mask for the active selection in this case.
string $faceSel[] = `filterExpand -ex 1 -sm 34`;
string $edgeSel[] = `filterExpand -ex 1 -sm 32`;
0
·
Share on Facebook
Share on Twitter
Offline /
Send Message
Klaudio2U
polycounter lvl 8
Aug 2018
Check the filterExpand command. For example:
filterExpand -sm 32; // gets only edges
filterExpand -sm 34; // gets only faces
And then store only faces selection like this (can’t test it because I’m not on my PC):
string $faces[] = ‘filterExpand -sm 34’;
0
·
Share on Facebook
Share on Twitter
Offline /
Send Message
malcolm
polycount sponsor
Aug 2018
This is exactly what I need to improve my script. Thanks a lot guys.
0
·
Share on Facebook
Share on Twitter
Sign In
or
Register
to comment.
Replies
filterExpand -sm 32; // gets only edges
filterExpand -sm 34; // gets only faces
And then store only faces selection like this (can’t test it because I’m not on my PC):
string $faces[] = ‘filterExpand -sm 34’;