Floating Point Textures

Started by
7 comments, last by MARS_999 18 years, 3 months ago
How do I create floating point textures?
Advertisement
Nobody is entirely sure.

The Valve guys mentioned something about having to do each skybox 4 times, which suggests that each channel of the sky is a seperate image which is then assembled into an FP format at runtime. I don't know of any tools that allow you to edit floating point textures directly, which is unfortunate.
SlimDX | Ventspace Blog | Twitter | Diverse teams make better games. I am currently hiring capable C++ engine developers in Baltimore, MD.
tried HDRShop?
Nooo, how do I create them in OpenGL, so I could render the HDR portions of the image on them?

[EDIT]

I think it can be done using 'glTexImage2D', 'glCopyTexImage2D' and 'GL_RGB16F_ARB'.
I'm trying to figure it out right now.
use an FBO. remember to tone map. RGBA16F.
float *data = new float[Width * Height * 4];glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA32F_ARB, Width, Height, 0, GL_RGBA, GL_FLOAT, data);


That should work
isn't 32f overkill?
Quote:Original post by Code-R
isn't 32f overkill?
No. (Hint: Read about High Dynamic Range (HDR) rendering.)

If you mean he could use 16F instead of 32F, then I guess it's all just down to your needs.
SlimDX | Ventspace Blog | Twitter | Diverse teams make better games. I am currently hiring capable C++ engine developers in Baltimore, MD.
Quote:Original post by Promit
Quote:Original post by Code-R
isn't 32f overkill?
No. (Hint: Read about High Dynamic Range (HDR) rendering.)

If you mean he could use 16F instead of 32F, then I guess it's all just down to your needs.


Ditto :)

This topic is closed to new replies.

Advertisement