Jump to content
  • Advertisement
Sign in to follow this  
Buck Fush

Vertexshader in Screenspace

This topic is 5113 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm trying to draw screenquads with the help of a vertexshader 1.1 in Directx8.1. But I don't see anything. Other shaders with transformation matrix work just fine. The culling mode is correct. I stripped most of this from my fixed function code. DWORD dwDecl[] = { D3DVSD_STREAM(0), D3DVSD_REG(0, D3DVSDT_FLOAT3), // position (I've also tried D3DVSDT_FLOAT4) D3DVSD_REG(1, D3DVSDT_FLOAT2), // texture coord D3DVSD_END() }; // shadercode: vs.1.1 mov oPos,v0 mov oT0, v1 That's how I fill the VB: float w=512.0f; // I've also tried 1.0f for w&h float h=512.0f; float *vb from vertexbuffer lock vb[0] = 0.0f; vb[1] = 0.0f; vb[2] = 0.0f; vb[3] = 0.0f; // u,v vb[4] = 0.0f; vb+=5; vb[0] = w; vb[1] = 0.0f; vb[2] = 0.0f; vb[3] = 1.0f; // u,v vb[4] = 0.0f; vb+=5; vb[0] = w; vb[1] = h; vb[2] = 0.0f; vb[3] = 1.0f; // u,v vb[4] = 1.0f; vb+=5; vb[0] = 0.0f; vb[1] = h; vb[2] = 0.0f; vb[3] = 0.0f; // u,v vb[4] = 1.0f; Thankx in advance

Share this post


Link to post
Share on other sites
Advertisement
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!