Original Post
I've just enabled AutoDepthStencilBuffer, as I've been trying to fix a problem with my heightmap. The problem is that the farthest part of my terrain is rendering over the closest part. seemed to me that the z-order was off, but when I enable any z functions (ZFUNC) I get holes in my terrain (or no terrain at all). also tried changing the CULLMODE to D3DCULL_CW, but I lose more geometry that way. I can really figure it out, I was wondering if it was something to do with raw file loaded terrain, or if there's something I'm missing. Just in case you wondered, I'm testing the Buffer Format's compatibility, and it's D3DFMT_D24X8.