🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Direct3D 11 Depth Testing

Started by
1 comment, last by peter1745 4 years, 3 months ago

So, I'm wondering how you enable depth testing in Direct3D 11?

Basically “glEnable(GL_DEPTH_TEST)” for Direct3D 11. I've been messing about with depth buffers for an hour now and I can't figure it out. What I'm trying to achieve is preventing say, the back vertices of a cube rendering on top of the front vertices.

Advertisement

Nevermind! I figured it out. Turns out I didn't need to mess with the depth buffer, I just needed to create and set a Rasterizer state and set the cull mode to fix the issue.

This topic is closed to new replies.

Advertisement