Jump to content
  • Advertisement
Sign in to follow this  

Problem with disapearing vertices...

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

Hi Folkz! Its been a while since ive last coded some DX stuff, so i decided to see if there is anything left what i knew ... I tried some basic stuff, and now i have a strange problem which i cant explain to me, so i need to ask for ya help. This is the problem: Ive made a vertexbuffer, an indexbuffer, a rendred some triangles. this is like i fill my vertexbuffer: int pos=0; for(int i=0;i<Vertices_High;i++) for(int j=0;j<Vertices_Width;j++) { Vertices[pos].x = (-1)+i*0.05f; Vertices[pos].z = 0.0f; Vertices[pos].y =(-1)+j*0.05f; Vertices[pos].Diffuse = 0x4500ff00; pos++; } Everything worked well, until i wantet to put in some hight. If i set the z value to everything higher than 0.000000001, the vertice isnt visible! I really dont know why or what to do. I think its cut out for some for or near plane stuff but i dont have set any projection matrix or viewmatrix, there should be standard values for them. If i set any view or projectionmatrix, my mesh dissapears complete. Anyone any idea??

Share this post


Link to post
Share on other sites
Advertisement
You need to init the World, View, and Projection matrices before using them. Leaving them at their default values will, I think, result in undefined behaviour.

Hope this helps.

Share this post


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

  • 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!