Doh Scene units was what I thought I was typing, just bad typing and
spelling ;) thanks for the tip on get units out, 
 
But I would argue that loader should have the option to scale the file to
the scene units if the format being loaded supports a unit size, its very
rare that you would have a scene in say meters and want a model created in
say milimeters to come in the size of a small country ;), 
 
Its sort of the same thing that we do in our with our imagery and elevation
software, you have a projection then we mosaic or re-project every thing
passed to the required projection no matter what the source projection is of
each component..
 
 
BTW I not i'm not suggesting you to do this, just that for me and my 20k+
users this would be a good thing some time down the road, 
 
 
  _____  

From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Roger James
Sent: Friday, November 23, 2007 12:33 PM
To: 'OpenSceneGraph Users'
Subject: Re: [osg-users] Proposal to change the way the
Colladapluginhandlesthe DAE object



Gordon

 

I don't quite know what you mean by screen units, I suspect it is something
like "the same units as the rest of the scene graph". I think this function
is best done outside the plugin. In the current SVN you can do this using
the DAE object and document name returned by the plugin.

 

You need to get hold of the correct domCOLLADA object and then call getAsset
on it to get hold of the domAsset object and then call getUnit in that to
get the information you need.

 

If you do put any scaling transforms above the model then remember to
rescale the normals back to unity as well!

 

stateset->setMode(GL_NORMALIZE, StateAttribute::ON);

 

 

Roger

 

  _____  

From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Gordon
Tomlinson
Sent: 23 November 2007 15:24
To: 'OpenSceneGraph Users'
Subject: Re: [osg-users] Proposal to change the way the Collada
pluginhandlesthe DAE object

 

Need to add scaling the loaded model to correct screen units ;)  ( worth a
try ;) )

 

 

_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to