PHP + STL Files

Illustrates a bounding box of a pyramidA while back, I had the need to interpret an STL file (stereolithography), which is the general filetype of choice when dealing with rapid prototyping / 3D printing. My side business at the time had released a free 3D model viewer for the iPad, and we wanted to give estimates on prototyping costs whenever someone uploaded one of their own models. I couldn’t find any reasonable STL parsers that would work server-side, so I decided to make my own. The process of doing that, and the resulting files, are described below.