I am trying to use a FBO to render a scene to a depth texture and a color texture. Then I want to be able to display each of the textures on a quad. Basically what I do is something like this:
Loop {
Render To FBO
Bind Depth Texture
Display Quad Textured with Depth Texture
Bind Color Texture
Display Quad Textured with Color Texture
}
What I want to end up with would be a rectangle with one halfe textured with the depth texture and the other have texture with the color texture, like this....
The depth part works fine... but the color texture doesn't.... Before I post any code or get too involved in this, my first question would be:Code :----------------------------- | | | | | | | Depth | Color | | Texture | Texture | | | | | | | | | | -----------------------------
Can I create a FBO and attach both a depth and color texture, then render the scene to the bound FBO and expect both textures to be rendered to?
Ed



