Sphere Draws Wrong?

Mikey0727

Newcomer
Joined
Mar 26, 2005
Messages
5
In my code I tried to make a sphere mesh and render it. The mesh draws almost, but you can see through it into the background color, and the pattern I see on it changes every time. (Which I find even more strange) Can someone help? (Code Attached)

Also, When I add References, I have several versions of the Directx libraries on my system. (1.02902) , (1.0900), ect. What do these mean?

Thanks!
 
Last edited by a moderator:
You are not clearing your depth buffer, which is essential to draw the right pixels on your screen.
Use these clear flags in your Device.Clear() method call:
Code:
ClearFlags.Target | ClearFlags.ZBuffer
 
Back
Top