Hi Harash, Are you really using floatToRGB or it is not in use anywhere? This will never give you exact results because this will have quantization errors if you use normalized textures (so just GL_RGB). Try to use float textures directly. In your case GL_RGB32F_ARB (for three channels: min, max, and mean).
Another point which one has to check: when doing mipmapping if texture coordinates to grab from the previous level are correct. This might introduce errors either because wrong pixels are grabbed or interpolation is in between (so pixels are not grabbed at their center). I must admit it was a long time ago, that I have tested the shaders if they use correct pixel coordinates. It might happen that there is still a mistake. You can see it in the code, where there is a comment "(TODO check why -1 seems to be correct)". Because to the time I wrote the shader, I was pretty sure it should be +halfTexel and not -halfTexel there. However the results seems to be correct. The shader was original taken from my other application. I have to sit down and just to recheck all that mipmap stuff, but unfortunately I have not so much time for that :( Cheers, Art ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=20840#20840 _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org