I just looked at your projection formula, and it seems really weird, especially when DEPTH is set to higher values. Notice the concave face of the cube on the left. I use X'=X/Z*ZOOM Y'=Y/Z*ZOOM Where ZOOM controls perspective distortion. I usually set it to 256.