Maya Working Units

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

THREAD CLOSED
 
Thread Tools Search this Thread Display Modes
Old 06 June 2013   #1
Maya Working Units

Just want to know how everyone deals with Maya's working units. I have been reading a bit and it seems using anything but the default of centimeters is going to cause problems. I have a bunch of questions regarding scene scale and units:

How does changing the units/scale affect rendering and light falloff? I assume different render engines would handle scale differently. I seem to recall someone mentioning in a tutorial that you want the scale to be correct to get the best results (with mental ray).

Does scale and units matter for dynamics, like nCloth, particles, etc? I saw someone mention that they use 1:1 scale with the default of cm, but scale things down to bake out any simulations.

So from what I understand scale is certainly going to be important if you are creating assets for a game engine, or to be used on another project with specific units, but what exactly is affected by units and scene scale within Maya itself?

I have only come across one issue so far, and that is a car model I am currently working on. My working units were left at the default of centimeters, and my grid settings are default of a grid line every 5 units. My car is 14 grid spaces long, so therefore 70cm or about 2.3 feet long. The issue I have run into is the camera sensitivity, and clipping. If I try to frame in on any tiny details, they are clipped off by the near clipping plane. When dollying with the scroll wheel, the movement is way too much, so I have been using alt+rmb drag a lot.

Now I am trying to decide whether it is necessary for me to adjust the scale. Should I just group everything and scale up to the correct size? I have read that mental ray doesn't handle scaled cameras well, though I am not sure why.

I am really just hoping to get some input on how others deal with scene scale and units. Do you just work with the default of centimeters, or is it really project dependent? I have heard some people say they work as though 1cm = 1m. Sorry for the long post, just trying to wrap my head around this, so I can avoid any problems on future projects. I should also note that I am using 2014 primarily and sometimes 2013, but I don't know if there has been any fixes or improvements made to using non-cm units between the two.
 
Old 06 June 2013   #2
Although I stick to real world scale and leave units as cm's 99.7% of the time, I've not noticed too many issues working with arbitrary scale. Some things like n dynamics use units in meters, but there is a space scale attribute on the nucleus that you can change to allow for that.

David

Oh... yeah...you do know you can adjust the camera near and far clipping don't you? And scaling cameras in groups is fine, as long as you don't try non-proportional scaling, and are aware of the affect that the scale is having on the clipping distances.
__________________
http://www.djx.com.au
 
Old 06 June 2013   #3
Thanks for the insight David. I have been looking into it a bit more and I think I will just stick with centimeters and 1:1 scale. I wasn't aware of the nucleus' space scale attribute, but I'll keep that in mind as well.

As for the clipping, I did actually adjust the near clipping to help the problem, but then I was getting things I did want clipped showing up. Obviously this can be circumvented by just hiding stuff that I'm not working on. The clipping wasn't really as an issue as much as the very sensitive dollying. So for the car, I will try scaling everything up as a group to proper scale, and adjust the clipping values as needed.

One other thing I have been thinking about is attribute values. Say I were to merge verts, and was adjusting the snap distance, is that measured in the scene's units (cm's)? That was one other 'issue' I have been having with the car, when merging verts I was to the point where maya wouldn't even allow enough decimal places for me to merge the right verts without getting some I didn't want. I was hitting .0001, and if you try going to 5 decimal places it seems to auto round to 4. I'd imagine this has something to do with my scene scale being much smaller than real world.

At this point I will assume everything uses cm's/the scene scale with some exceptions like nDynamics using meters as you mentioned. I also read somewhere some of the physically accurate mental ray shaders have values in mm's. I guess it doesn't really matter as long as things seem to be working correctly and look right.
 
Old 06 June 2013   #4
In channel box, go to Edit, Settings, Change Precision...
You can go up to 15 decimal places. I'm pretty sure its not changing the precision, just the display.

Oh, forgot... your polyMergeVert input node will display with higher precision there.

Last edited by fleabay : 06 June 2013 at 04:37 PM.
 
Old 06 June 2013   #5
Thanks for the tip, I had no idea that existed. Unfortunately I am not home for a few days so I will be unable to test this, but if I scale my entire model up will I not require such a small value when merging verts? I guess that would be the case if that distance value is in fact based on the working units.
 
Old 06 June 2013   #6
When it comes to lighting, if you're rendering with mental ray, there are no "centimeters" but rather the scale needs to be 1 unit = 1 cm for proper light falloff. Here's a thread where we discussed scale in mental ray, and as Bitter pointed out (among others) if you're not modeling in cm, you need to do the conversion. Thus, since I model in inches and feet (silly Americans), I have to rescale everything upon import into Maya by .394, .394, .394. I need 1 inch to equal 1 cm for proper lighting.

Someday I'll just write a little script that sets the pivot point to 0,0,0 and then rescales the imported group, maybe have it flip on Visible in Reflection/Refractions as well, since I use .obj files. Someday.
__________________
Commodore 64 @ 1MHz
64KB RAM
1541 Floppy Drive


"Like stone we battle the wind... Beat down and strangle the rains..."
 
Old 06 June 2013   #7
For all intents and purposes, the notion of a real centimeter and meter as such in maya is afaik pointless. Afaik, and I am not an expert on this, the only thing that has relevance, is how the "scale" is linked to the time node.

Heh, this is from the back of my head. Maybe I am wholly wrong here.
__________________
Are you warm, are you real, Mona Lisa?
 
Old 06 June 2013   #8
Originally Posted by InfernalDarkness: When it comes to lighting, if you're rendering with mental ray, there are no "centimeters" but rather the scale needs to be 1 unit = 1 cm for proper light falloff.


While there are some exceptions, most renderers are "unitless" in the sense they don't care what size your scene is. Light falloff itself is influenced by the intensity and distance of the light relative to the surface.

If you scale the scene you will have to scale the intensity (and scale if using area lights) of your lights appropiately to match the new size of the scene.

As to the original question. Which unit to use often comes down to precision, once you start getting scenes which are the size of cities then centimetres starts to become difficult to work in - especially if your animating away from the origin. Decimetres are generally a good compromise between doing small and large scale scenes.
 
Old 06 June 2013   #9
Quote: While there are some exceptions, most renderers are "unitless" in the sense they don't care what size your scene is. Light falloff itself is influenced by the intensity and distance of the light relative to the surface.

If you scale the scene you will have to scale the intensity (and scale if using area lights) of your lights appropiately to match the new size of the scene.


Correct for the most part. However, in mental ray, if you model to centimeters then Maya spits out 1 unit for 1 cm in its mental ray export. mental ray doesn't internally use centimeters but since that's how Maya exports the geometry, you'll want to use centimeters generally to achieve predictable, natural-looking light and preserve quadratic falloff. Thus, any other conversion would break the quadratic falloff, as tested in the thread I linked to previously.

That is to say, since I'm modeling in inches, if I don't do the scale conversion to centimeters, then quadratic falloff won't work in mental ray. Adjusting the intensity won't help, nor the scale of the lighting mechanism (for example, the scale in Final Gather or photon GI settings.) And that's why I was having so much trouble with scene scale initially, and was using various workarounds to make the lighting look right. Once the scale is proper, none of those workarounds were necessary any longer.
__________________
Commodore 64 @ 1MHz
64KB RAM
1541 Floppy Drive


"Like stone we battle the wind... Beat down and strangle the rains..."
 
Old 06 June 2013   #10
Originally Posted by InfernalDarkness: if you're not modeling in cm, you need to do the conversion. Thus, since I model in inches and feet (silly Americans), I have to rescale everything upon import into Maya by .394, .394, .394. I need 1 inch to equal 1 cm for proper lighting.


Interesting. Coincidentally, I was thinking the only reason they would implement imperial units is for adherence to schematics or reference in imperial units

PowerAnimator was aimed at the film industry and it turns out some "older lenses" are measured in inches...it doesn't elaborate.
http://en.wikipedia.org/wiki/Camera_lens

Is the improper lighting a result of rounding numbers? If precision is high enough would this become negligible? One would think Maya would handle conversion properly.
__________________

gibby3d.com
 
Old 06 June 2013   #11
Sorry Infernal, I cant let that slide past...
Originally Posted by InfernalDarkness: Here's a thread where we discussed scale in mental ray, and as Bitter pointed out (among others) if you're not modeling in cm, you need to do the conversion.
I think most people on that thread came to different conclusions. In fact Bitter actually said:

Originally Posted by Bitter: To be honest (and possibly muddy things) mental ray is units agnostic.

1 = 1 of whatever.

Working in correct scale makes other things inside Maya more intuitive. But when translated to mental ray, the numbers are 1 to 1 translation and don't really mean 1 meter = 100 cm. 1 unit (of anything) in Maya will get sent to mental ray as 1 not 100. Changing the default units (and nothing else) results in an identical .mi file.


So I think he's saying: work at any scale you like because mentalray doesn't care. I would also dispute your quadratic falloff example. In most of your tests you chose a light intensity of 1. In maya what are the units of light intensity? The standard lights are certainly not calibrated to real world.

And in your final post...
Originally Posted by InfernalDarkness: ... "Light energy decays at a rate of 1/r^2 where r = radial distance away from the source." The scene's scale certainly affects this, as the radial distance gets warped if you're doing it wrong.
What do you mean by the "radial distance gets warped"? Warped how? In maya there is no distance warping that I am aware of.

So, bringing things back on track, I'd reiterate by quoting a few snippets from Bitter: "Working in correct scale makes other things inside Maya more intuitive.", "Scale conversion is convenience.","I would just say consistency is key for your pipeline", "...scale conventions being set at the beginning of a show."

My own summary...
When you start a project, choose a scale that makes things convenient and intuitive, then be consistent.

David
__________________
http://www.djx.com.au
 
Old 06 June 2013   #12
I sit corrected, DJX, and apologize to anyone else for any misleading information. The error wasn't in the scene scale, but in my light amplification (intensity) math itself. To test this and prove myself wrong, I made a simple gridwork scene using the most basic measurements possible, at units of 4. Quadratic falloff occured properly on lights, rendering intensities of 1, 4, 16, and on up. Scaling the scene up by 4x yielded similar results - the lights need to be 4x as bright.

I think what threw me off was the scale conversion from centimeters to inches itself; it's not math I can do on the fly, so the light intensities were always a conundrum. Instead of doubling a light's power to achieve conformity, I should have been multiplying it by factors of 2.54, for example, so the math got far less intuitive as I struggled with factors of 2, 4, or 10, and even worse error the higher the lights' intensity.

Thanks for calling me out, DJX! Sometimes you just gotta break it all down, I appreciate the lesson. If anyone wants to see these rendertests for scale, I'll post them in another thread for cross-analysis.
__________________
Commodore 64 @ 1MHz
64KB RAM
1541 Floppy Drive


"Like stone we battle the wind... Beat down and strangle the rains..."
 
Old 06 June 2013   #13
If you want to do a simple test to see whether Mental Ray cares about what scale you model in...

Create a simple polyplane 1 unit big and then position a point light 1 unit above it - set the falloff to quadratic and hit render. Now scale the plane up or down however you like. Does the intensity of the light hitting the polyplane change? The answer is no because the distance from the surface to the light is always the same.

However if you scale your scene (lights, cameras, everything), the distance between the light and surface does change so you'll have to adjust the intensity of your lights accordingly (I haven't had to work this out, but I'd say it's exponential scaling of the light intensity).
 
Old 06 June 2013   #14
Thread automatically closed

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.
__________________
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
 
Thread Closed share thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 03:17 AM.


Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.