News for hackers. Stuff that matters.
Re:Show HN: 3D Renderer Built using 2D HTML Canvas by arnioxux on Saturday July 15, 2017 @11:39PM (#14780351)
I didn't look at the code, but canvas only supports 3x3 transforms and you need 4x4 to do perspective: https://developer.mozilla.org/en-US/docs/Web/API/CanvasRende...

So if those cubes are textured, you'd need to subdivide the texture and approximate each with affine transforms. Here's an example of this hack (which was only necessary years ago before webgl existed): https://acko.net/blog/projective-texturing-with-canvas/

Re:Show HN: 3D Renderer Built using 2D HTML Canvas by Matheus28 on Monday July 17, 2017 @07:01AM (#14787319)
For wireframe objects like the one in the OP (which actually does use a perspective projection it seems), that's not really a problem. Just have your own code that does all the matrix multiplication, and you get a point you can plug right into moveTo/lineTo