Archived

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

Camera problem ?

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

Hello people. I got a kinda weird problem with my engine. I made a 3D area consisting of an island and some water around it. The thing is that when viewed from altitude, the water and the island intersections are messed. You can see 2 screen there : http://artillerie.vdc4.org/screen1.jpg http://artillerie.vdc4.org/screen2.jpg The first one is quite ok (not seen from too height and not looking too down) but the second is clearly messed. Did anyone already encounter this problem? I suspect it comes from ent camera settings but I cannot find exactly where I do something false. Thanks

Share this post


Link to post
Share on other sites
This problem is known as Z-fighting. I know of two ways to solve it. The first one is to increase the size of your Z buffer during creation. I suspect you are using a 16 bit Z buffer so change D3DFMT_D16 to D3DFMT_D24S8 (or test to see if you have D3DFMT_D32).

The second thing to try is messing around with your near and far clip planes when creating the projection matrix.

Hope that helps.

Share this post


Link to post
Share on other sites
hi,
the problem is your Z-Buffer. I suppose you use 16 bit - this works quite unprecisely. Try to use a 32 bit Z-Buffer...

Edit:
@ __Daedalus__: Damn, half a minute too late ;-)

[edited by - Christoph on May 31, 2004 5:14:17 AM]

Share this post


Link to post
Share on other sites