I used 3D graphics extension, so most of the 3d rendering routines comes from it, but camera control and mouse control are made by myself with a bit of stack overflow :)