Hi
does anyone know how to force a texture ( to which i rendered to using pbuffers ) into a specific mipmap level? I have set the following texparameters so far:
glTexParameteri( GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_LINEAR);
glTexParameteri( GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
glTexParameteri( GL_TEXTURE_2D,GL_TEXTURE_WRAP_S,GL_CLAMP_TO_EDGE);
glTexParameteri( GL_TEXTURE_2D,GL_TEXTURE_WRAP_T,GL_CLAMP_TO_EDGE);
glTexParameteri(GL_TEXTURE_2D,GL_GENERATE_MIPMAP_SGIS,GL_TRUE);
I think that it can only work if i actually upload the mipmaps via gluBuild2dMipMaps for example. The problem is that i cant use this function since the texture is not load from a file or something but generated at runtime. I actually need to pass 3 mipmaplevels of this texture to a pixelshader. Anyone have an idea how to do this?