To pull all the work so far together, I’ve added a simple user interface:
With panels to allow you to set the output dimensions and quality, view the monochrome 2D brightness reference image, view and zoom around the generated lithophane and Drag & Drop images from you computer.
You can set:
- Max Size – the largest X or Y dimension of the output lithophane.
- Thickness – the maximum Z dimension of the output lithophane.
- Border – the thickness of the border around the edge
- Thinnest layer – This is the layer thickness for the brightest pixels in the image
- Vectors per pixel – each of the pixels in the image is translated into a number of 3D points on the surface of the lithophane, the larger this number, the more detailed the output (and the larger the STL file/slower the processing) 2 is a good value for this you can go up to 5, but it will take time and use memory…
- Base/Stand depth – I added this for RichRap, he likes to have a small stand on the base when printing vertically. I haven’t used it as all the test prints I performed all stood on their edges quite happily without a stand.
Once you click on an image that you have dropped on the lower panel, the progress bar is updated to show you the conversion progress and once it has displayed the 3D view, the software converts the data into an STL file and initialises a download.
The steps are:
- 2D processing – converting the image to a brightness monochrome image
- Processing Vectors – adding each of the points to the 3D mesh
- Processing Faces – adding each of the triangles (2 per square)
- Processing Surface – adding the features that allow light to reflect off the surface
- Adding to scene – putting it into the three.js scene for viewiing
- Creating STL file – Arranging the Vectors and Faces onto a binary STL format
- Downloading – initialising a download of the STL Blob.
All of this happens on your machine with nothing being transferred over the internet, so it’s quick and private with no cloud access or spam emails to worry about.
My daughter is happy with the first tool I’ve made for her and I have received some external feedback that is positive as well, which is very nice to get 🙂
Use it here
The source is available here if you’re interested in the details.
Oh, and here’s a picture of a printed Lithophane:
People are having some trouble with the parameters the program will only accept the values shown below, if you enter another value, it will be shown in red and ignored:
Output Dimension – between 1 mm and 1000 mm
Thickness – between 1 mm and 100 mm
Border Thickness – between 0 mm and Output Dimension / 2
Thinnest layer – between 0.1 mm and Thickness In MM
Vectors per pixel – between 1 and 5
Base/Stand depth between -50 mm and 50 mm (negative sticks out the back)
The Stand will be the same thickness as the border, unless the border is 0 in which case it will be 2mm thick.