Re: [AD] depth buffer API

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On 2012-05-13, at 2:50 PM, Elias Pschernig wrote:
> I also want a way to make the depth buffer work when drawing to an
> off-screen bitmap, but I'm not really sure yet what is needed for that.
> With OpenGL, we probably need to attach a depth buffer to each FBO we
> create or something.

This is important for D3D. Firstly, you can create a depth surface and use it with any texture surface so you might only need one. But the important part is, if the depth buffer is enabled, it has to be at least as big as the bound texture. Otherwise, nothing will render. That's a little known fact I think, and it screwed me up really good once. Something to keep in mind and maybe document.

Trent





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/