double precision
-
- Gnoblar
- Posts: 1
- Joined: Tue Apr 12, 2005 1:12 am
double precision
Quick newbie question: does OGRE have (or is it possible for OGRE to have) double precision position information in a scenegraph?
-
- Hobgoblin
- Posts: 508
- Joined: Tue Feb 03, 2004 6:39 am
-
- Goblin
- Posts: 220
- Joined: Mon May 31, 2004 5:54 am
- Location: Canada
-
- OGRE Retired Team Member
- Posts: 3067
- Joined: Tue Feb 10, 2004 12:53 pm
- Location: The Netherlands
- x 1
-
- Hobgoblin
- Posts: 512
- Joined: Fri Nov 19, 2004 3:56 am
We use double precision in our application. The frame hit was very minimal (like two tp five fps) - not even noticeable.
You have to change a #define flag in your OgreConfig.h file and recompile the Ogre library. Word of caution though, if you plan on using any other libraries make sure they support doubles and some of the ogreaddons require lots of modifications to support double. For some reason some of those authors used a float declaration instead of using Ogre::Real.
BTW, we also use the Newton Physics engine which also supports a double precision. Newton here: http://www.physicsengine.com
You have to change a #define flag in your OgreConfig.h file and recompile the Ogre library. Word of caution though, if you plan on using any other libraries make sure they support doubles and some of the ogreaddons require lots of modifications to support double. For some reason some of those authors used a float declaration instead of using Ogre::Real.
BTW, we also use the Newton Physics engine which also supports a double precision. Newton here: http://www.physicsengine.com
-
- OGRE Retired Team Member
- Posts: 19269
- Joined: Sun Oct 06, 2002 11:19 pm
- Location: Guernsey, Channel Islands
- x 66
-
- Gnoblar
- Posts: 9
- Joined: Mon Oct 29, 2012 3:03 pm
- Location: Russia, Moscow
Re: double precision
1) Is Ogre SDK builded in single precision?
2)If yes, how can I set double precision without recompiling?
Just set in OgreConfig.h, isn't it:
Thank you.
2)If yes, how can I set double precision without recompiling?
Just set in OgreConfig.h, isn't it:
Code: Select all
#ifndef OGRE_DOUBLE_PRECISION
#define OGRE_DOUBLE_PRECISION 1
#endif
-
- OGRE Expert User
- Posts: 1920
- Joined: Sun Feb 19, 2012 9:24 pm
- Location: Russia
- x 201
Re: double precision
You have to recompile it.
-
- OGRE Team Member
- Posts: 4304
- Joined: Mon Feb 04, 2008 2:02 pm
- Location: Germany
- x 136
Re: double precision
And you can also set that pre-compilation macro via CMake I think.
Ogre Admin [Admin, Dev, PR, Finance, Wiki, etc.] | BasicOgreFramework | AdvancedOgreFramework
Don't know what to do in your spare time? Help the Ogre wiki grow! Or squash a bug...
Don't know what to do in your spare time? Help the Ogre wiki grow! Or squash a bug...