w23 / OpenSource

Load Source games maps as combined meshes correctly positioned relative to each other
Do What The F*ck You Want To Public License
157 stars 16 forks source link

Severe Z-fighting on geometry that is "too close" #24

Open w23 opened 7 years ago

w23 commented 7 years ago

I don't mean coplanar surfaces from different maps. Should either tweak z-buffer params, or completely change z buffer approach to something less naive and more contemporary.

w23 commented 6 years ago

Reversed-z would be ideal. However, OpenGL is crap (for its -1 to 1 mapping which destroys precision for no good reason), and OpenGL < 4.5 (which also implies ES) is double crap, because it doesn't have a way around that (glClipControl is either ext or gl 4.5).

So, according to this: https://developer.nvidia.com/content/depth-precision-visualized my best option seems to be to try separating projection matrix from model-view.

w23 commented 6 years ago

Separating projection matrix from model-view matrix doesn't lead to image improvement.