Moderator: Paul Tuersley
urbanspaceman wrote:I've uploaded a small update...this is v. 1.06.
Okay, I had a chance this evening to test the script in CS3 and on a PC, as well as double check some things in Max and Maya. After a few bug fixes, everything seems to be okay. I think I'll be using it on another project very soon, using AE and Lightwave.
urbanspaceman wrote:I believe I know what's happening. It's not quite a bug, but a change in my decision making.
The code in exportcam 1.1 and AE3D 1.06 for the camera is almost identical, except that exportcam scaled down things by 100. If you are mixing the 2 plug ins during one project there will be a mismatch of units multiplied by 100.
Would be interested to hear the opinion of Maya users, to see what is the best decision to make. It's a program I'm still learning about.
Agrapha expressed the need to preserve the pixel values in case one wanted to go back to AE at some point. So I decided to to make 1 AE pixel = 1 cm, and give the option to switch off the shifting of 0,0,0 (which would change all position values and not match AE anymore). This worked fine, but I had to scale up the locators by 100 times to see them.
My goal is to create a simple plug-in that is uncluttered with unnecessary options...so I'm seeing if I can avoid adding a 'change units' button.
At the moment, 1 AE pixel = 1 cm in all three 3D packages...I kind of like the simplicity and consistency of that.
But it may be slightly awkward to work in these dimensions in Maya...I may switch to 1 AE pixel = 1 m instead.
Lightwave is the 3D program I'm most familiar with. In that app there is a button that allows you to scale the grid (and cameras, lights, nulls) by 10 times by clicking a button. This doesn't alter the keyframes, it just allows you to view things at a comfortable size. I have not found the equivalent of this in Maya, so I'm a bit stuck in deciding which units to use, because things are looking too small or too big. Some more advice from Maya experts would help.
No idea why the .ma file wouldn't work from a new project, Russ, especially if it worked the first time. I've been testing with Maya 7 it hasn't complained yet.
Shayder wrote:How many pixels are there in a cm?
Shayder wrote:Anyways this script is already awesome!
urbanspaceman wrote:A new update, v. 1.08. (same link as above)
http://www.urbanspaceman.net/shared/AEs ... Export.jsxShayder wrote:How many pixels are there in a cm?
That's the thing, pixels are relative units. It's a bit like asking "how many cm wide are 100 apples?". Since apples come in all shapes and sizes, just like pixels, there is no answer. Think of your computer monitor resolution: you can set your monitor to 1280 pixels wide, but you may have a 15', a 17', or a 21' monitor. So in each case a pixel would be a different size in inches.
So when going from AE (pixels) to 3D software (cm), the choice is arbitrary. Making 1 pixel = 1 cm is as good a convention as any.Shayder wrote:Anyways this script is already awesome!
Glad you like it. It was a labour of love, that's for sure.
I spent some more time playing with Maya and I think I was right to divide AE's position values by 100 in the first place, and Russ was right that it was better before. It appears Maya likes to work with small numbers and is stubborn about changing this. If I'm going to have 1 pixel = 1 cm, Maya would prefer I call it 0.01 meters, and not 1 cm. So now I have set the world units to meters.
I also added a perspective camera in a comfortable position that should allow you to see the whole AE scene when you open up the .ma file. I also increased the size of the grid so it will not get lost so easily. Now the camera and the locators look normal sized as well.
Since this is an export script, the more I think about it the more it makes sense to pick a method that makes it comfortable to work in the 3D package, and assume that the camera isn't going to be sent back to AE again (since you already have a copy of it in AE, anyway). If there is a need to go check back with AE for the position of something, all you have to do is move a decimal point (eg. if something is at X=1.00 in Maya, it's at X=100 in AE).
If anyone here completes a project with it, make sure you tell me how it went, and even some links of videos online. Cheers!