Hi, For a project I work on I try to build a visualizer for a flight simulator.
When trying to build all the stuff I need to I run into strange behavior when using osg with huge units. For example compare the two code https://gist.github.com/anonymous/5662271 Only the lines 21 and 22 are changing. To sum here I only want to put a sphere (1m radius) very far from the origin (something like the earth radius in fact). In the first case I created the sphere directly far from the origin and in the second case I create it at the origin and then move it away using a MatrixTransform. While the two way should give the them result I get very different result. The first case don't work well and here is why I got: [Image: http://t.imgbox.com/abgajZ7H.jpg ] (http://imgbox.com/abgajZ7H) The second case work way better and here is my result: [Image: http://t.imgbox.com/acyiv91j.jpg ] (http://imgbox.com/acyiv91j) So could you explain what I get this difference ? Is it because OpenGL uses float under the hood and so the value I use are too big? Similarly, I saw that even using the technique described in the second case this stop to work when I use bigger numbers. For example try with 1e+10 and none of the code above will work. So can you provide tips for building a visualizer which should handle planetary size value with both small and big assets ? Thank you! Cheers, codec ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=54249#54249 _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org