Sign in to follow this  
spiffycrony

Z-Buffer for Quad wireframe mesh directx8

Recommended Posts

I am trying to draw the quad wireframe mesh using directx. I want to make use of the zbuffer for this. I can do this when it is a tri wireframe mesh as follows m_d3d.Device.SetRenderState D3DRS_COLORWRITEENABLE, 0 m_d3d.Device.SetRenderState D3DRS_FILLMODE, D3DFILL_SOLID m_d3d.Device.SetStreamSource 0, m_VertexBuffer, sizeOfVertex m_d3d.Device.DrawPrimitive D3DPT_TRIANGLELIST, 0, m_NumTriangles m_d3d.Device.SetRenderState D3DRS_COLORWRITEENABLE, D3DCOLORWRITEENABLE_ALPHA Or D3DCOLORWRITEENABLE_BLUE Or D3DCOLORWRITEENABLE_GREEN Or D3DCOLORWRITEENABLE_RED m_d3d.Device.SetRenderState D3DRS_FILLMODE, D3DFILL_WIREFRAME m_d3d.Device.DrawPrimitive D3DPT_TRIANGLELIST, 0, m_NumTriangles But for the quad mesh, i can only draw it as 4 lines(each quad). How to make use of the zbuffer for a quad wireframe mesh?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this