Basic 3D
Z-Buffer Depth
Resolve two overlapping triangles by keeping the smaller depth at each covered pixel.
z-buffer-depth
A z-buffer stores the nearest depth seen so far at each pixel, so a later fragment only wins when its z value is smaller.