I've been writing a 3D software renderer for the first time and really enjoying getting an understanding of how rendering APIs are roughly working behind the scenes.

I visualized the depth buffer and noticed something was off (left). Turns out I was computing the barycentric coordinates incorrectly! Fixed that and now it's all smooth (right).