I use osgdem with the --no-interpolate-imagery and --no-mipmap optiosn to wrap 
geotiff imagery onto my terrain complex.  However, the unsigned int rgb 
channels contain index values to be used in lookup tables in the shader, not 
real imagery.  Because of this, it is important that the color values contained 
in the input geotiffs be carried all the way through the osgdem process without 
any interpolation.

I modified the src for VPB to force NEAREST for the textures, and use the 
--no-interpolate-imagery and --no-mipmap options to try to keep any 
interpolation from happening.  For the most part, everything works and I am 
able to get the correct index values in my shader.  The exception is at tile 
boundaries of the osgdem-generated terrain complex.  

To test this, I used a geotiff that only had values of 13 and 15 in it and 
generated an osgdem terrain.  In my shader, I decode those index values and 
color the terrain grees in the value is either 13 or 15, and red if it's 14.  
The entire terrain is green except at the tile boundaries where spots of red 
show up.  This leads me to believe that interpolation is happening at the tile 
boundaries.  Am I correct in this assumption?  Any thoughts on how I might 
prevent this from happening?  Thanks.

-Ethan

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=54312#54312





_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to