stereo rendering and modeling units

MrPixel

25-11-2008 07:35:50

I need to know the units that scenes are built in. We are dealing with very accurate stereo rendering, and the scale of the scene/model matters (unlike mono 3D). We used Collada and OgreMax before graduating to oFusion. Both Collada and OgreMax pass along modeling units information. But I can't find a way to get this info with oFusion.

I don't mind doing the conversion when loading into Ogre - but I need the units info in the export file. Or setting a "scale scene" value in the exporter would work also. I found a thread from Feb 06 that said "The scale scene feature will be in the next updates".

http://www.ogre3d.org/phpBB2addons/viewtopic.php?t=434&highlight=export+units

Is scene scale in there and I'm just missing it? I'm using the Pro version. TIA

Evak

25-11-2008 17:12:27

I am on the wrong computer with no 3ds max installed the mo, but if you want 1 unit in max to equal 1 unit in Ogre. You have to go to unit setup in 3dsmax.

I have mine set at generic, and the system unit setting as 1 unit = 1 meter. I think the default setting is 10 units - 1 meter or something.

If you set it to 1:1 thet the units between Ogre and Max will match and you can create say a spherical physics body of 1.0 in your source code and create a 1 unit sphere in 3dsmax and they will match.

Don't know if that helps

MrPixel

25-11-2008 23:00:10

Thanks for the reply Evak. We started out like that - setting System Units in Max to 1 Unit = 1.0 Meters. And that worked fine except when we are constructing small objects (on the cm scale). Several things break down in Max when you try to work at a scale /100 or 1/1000 of your System Units (near clipping, navigation speeds, minimum object size, etc.). Max User Reference even says:
Make sure no significant detail in the scene is smaller than one generic 3ds Max unit.

So the ideal situation is to have oFusion export in System Units (like it already does) but also include what those units are in the export file. Then artists can build stuff at whatever System Units make the most sense and we can adjust for System Units when importing.

But like I said in the original post, a scene scale factor would be another (less desirable) solution.

Thanks,
-pixel

Evak

26-11-2008 06:31:52

Your best bet if you have the pro version is probably to log into your support page and post a ticket. Lioric is usualy quite quick at responding there.

I believe he said Ofusion 2.0 release date was on the 27th. Should be some new goodies in there for shoggoth.

Lioric

08-01-2009 23:46:01

This feature has been added and will be provided with the next update (as always, if need it earlier just contact support)

All the needed unit data as scene unit type, scene version, master scale type, number of units per master scale ref (as the number of scene units per meter or other master scale ref that you need) is included in the scene and can be used in your application calling the "getSceneHeader" method of the OSMScene loader object

MrPixel

08-01-2010 08:03:57

Sorry to resurrect this thread - but since I started it... :)

We finally upgraded to a version of oFusion that has "unitsPerMasterRef" being exported. That gives us the info we need - thanks for getting it in. I was kinda hoping that something like "unitsPerMeter" would be output so we could just read a single consistent value for the scaling. As it is now, we need to also parse the "masterScaleRef" string and compensate if it's not "meters". This requires us to have all the potential string values for "masterScaleRef" in our conversion code and if Max adds to or modifies any of those strings (master scale types), the code will break. With "unitsPerMeter" exported, scale conversions are a no-brainer and robust.

Anyway, I'm probably crying over spilt milk. I looked at the oFusion Knowledgebase to find the possible values for "masterScaleRef". ArticleID 000068 lists the new header data types added for the scene unit info, but doesn't list the potential values. Should we assume the strings (and capitalization) match the values that appear in the Max menus?