PDA

View Full Version : Moving beyond the limits of 32-bit float precision



JoshKlint
11-30-2010, 07:03 PM
How would you suggest rendering very large worlds that extend beyond the practical limitations of 32-bit float precision? Does OpenGL 3.3 support 64-bit floats? I would like to support extremely large worlds in the future, beyond 20 kilometers wide.

Dark Photon
11-30-2010, 07:35 PM
Does OpenGL 3.3 support 64-bit floats?
No, not AFAIK. You need OpenGL 4.0 and/or ARB_gpu_shader_fp64 (which I believe is only supported on GL4 HW).


How would you suggest rendering very large worlds that extend beyond the practical limitations of 32-bit float precision? ... I would like to support extremely large worlds in the future, beyond 20 kilometers wide.
This has come up before. Check out this thread (http://www.opengl.org/discussion_boards/ubbthreads.php?ubb=showflat&Number=273226). I'd start at the bottom and read backwards.

A key requirement you need to decide is: what accuracy do you require for the coordinates (e.g. cm, mm, um, nm, etc.). This determines the maximum size of your entities (local coordinate systems, each with their own MODELING transform - think chunk of terrain) at some precision (say, fp32).