I’m having problems using 32 bits floating point textures in GLSL. All values stored in the texture reduce to zero in the shader. I’m using a GForce7800GTX so it shouldn’t be a problem with lack of support for these textures.
In my program I create a texture with:
GLfloat tex[32*32][3] = {
#include “texture.txt”
};
where texture is a texfile which holds floating point numbers such on the form:
{ 0.54432f, 0.02342f, 0.01144f},
{ 0.52627f, 0.12613f, 0.12532f},
{ 0.32445f, 0.13551f, 0.23420f}, …
then I try
glTexImage2D( GL_TEXTURE_2D, 0, GL_FLOAT_RGB32_NV, 32, 32, 0, GL_RGB, GL_FLOAT, tex );
But my shader never recieves any floating point numbers, only zeros. I have tried the same thing with normal 8 bit per channel textures and that works fine. Any suggestions what I might forget?