Hello Michael, On 11/08/2010 05:09 AM, Michael Raab wrote: > I'm trying to render a height map of some of our 3D scenarios. > So I'm rendering from the top center of the worlds bounding volume using a > orthograhic camera. I thought I could try to use a FBOViewport for that > purpose but until now I get no reasonanble result (the resulting image is > empty). > I've attached my source code, maybe someone can have a look?
> // get camera position > Vec3f camPos( > vol.getMin().x() + (vol.getMax().x() - vol.getMin().x())/2.0f, > vol.getMin().y() + (vol.getMax().y() - vol.getMin().y())/2.0f, > vol.getMax().z() > ); I don't see where you make the camera look down. This only places it at the top center of the bounding box, but it's still looks along the negative z axis, so probably does not see your scene at all. Also, I'm afraid the FBOViewport currently misses code to actually read back anything but the color buffers. Can you render with a shader that writes (linear) depth to a texture instead? Cheers, Carsten ------------------------------------------------------------------------------ The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book "Blueprint to a Billion" shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev _______________________________________________ Opensg-users mailing list Opensg-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/opensg-users