Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

renqilin

have you met this kind of problem?

This topic is 5558 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

when I drawed vertices in my Render() function, I found that if the plane is entirely in the screen, it wouldn''t be showed, however if I moved my camera and so let the plane is partly in the screen, it would be showed. why did this kind of problem occur ? PS(some of my codes): typedef struct tagNormalVertex { FLOAT x, y, z; FLOAT nx, ny, nz; FLOAT tu, tv; } NormalVertex; VOID Render() { // sorry I can''t remember the parameters g_lpD3DDevice->BeginScene(..); g_lpD3DDevice->Clear(...); g_lpD3DDevice->SetStreamSource(....); g_lpD3DDevice->SetVertexShader(...); g_lpD3DDevice->SetIndices(...); // Control camare ,set view and projection matrix ...... // Now drawing. g_lpD3DDevice->DrawIndexedPrimitive(D3DPT_TRIANGLELIST, 0, dwNumOfVerices, 0, dwNumOfPolygons); g_lpD3DDevice->EndScene(..); g_lpD3DDevice->Present(NULL, NULL, NULL, NULL); }

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
how can you not remember the parameters... those would be wy it doesn''t work...

Share this post


Link to post
Share on other sites
the plane would only be showed when it is partly in the screen, that means if any part of the plane is out of screen, it would be drawed by D3D.So I think if those parameters are wrong, maybe the plane would never be drawed.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

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

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!