Sign in to follow this  
vbms

Z Buffer

Recommended Posts

i have a problem with my z buffer ... working on a terrain class lib, running it on a geforce4 mx 440 ... im getting realy jagged edges along the water line... the further i go out the worse it gets (duuu) etc. PIXELFORMATDESCRIPTOR dosnt seem to do anything 4 me :( GRRRrr this is my therd (small) terrain engine and unless i find a solution i will proccess the waterLine/terrain geometry so that its all one surface (power ROAR). what do edge flags döo could i use them to reduce this problem, my ^idea^ is it a good 1?? :p -x love u x- [Edited by - vbms on May 23, 2006 1:49:00 AM]

Share this post


Link to post
Share on other sites
Yeah, that has happened to me too. It's called z-fighting and is due to z-buffer precision. First of all, try to "push" the front plane as far as you think is acceptable for your game, and see if it fixes it. If not, provided that your camera is always over the water plane, and you don't want to "see" the surface under the water(with blending and such), you can just:

Disable the depth mask
Render a solid water plane
Enable the depth mask
Render the terrain

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this