PDA

View Full Version : mel - linear unit change?


Drewid
10-20-2011, 11:47 AM
I've got a whole bunch of files, hundreds of 'em, where the linear units setup is inconsistent.
We've got meters, centimeters, and feet, and probably chains, poles, and furlongs as well knowing my luck.

So anyhow I've got to batch them all into centimeters by loading the file, changing the setting and resaving.
Is there a mel command to change the linear units setting? The script editor echo doesn't show anything particularly useful.

Drewid
10-20-2011, 11:57 AM
Ah - found it

currentUnit -linear "cm";

NaughtyNathan
10-20-2011, 12:04 PM
oh dear God... you are going to regret doing this! ;) Maya's unit setup is the most god-awful mess I've ever had to workaround in Maya and is probably the one thing that causes us the most issues across studios/projects...

Anyway, to switch units use the currentUnit command. (or, the "changeLinearUnit" script if you also want to reset the grid like Maya does when you manually switch)
:nathaN

CGTalk Moderation
10-20-2011, 12:04 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.