Replacing chess pieces (more tutorial than just stls, and this works for anything mostly rotationally symmetrical)
by jamesglanville, published
I lost some of my chess pieces a while back, and wanted to print matching replacements. These won't be of any use to people, but I was surprised by how well my method worked to create the replacements, so i'll list it here.
Firstly, you'll need a camera, a chess piece of the type you want to copy (eg I lost a black rook, I used a white one to copy, you just need the shape), inkscape, and openscad.
1) Take a picture of the chess piece as horizontally as you can, from quite far away. The aim is to get a good outline, that isn't skewed by camera angle. For an example of what I used, there's a picture of a black bishop.
2) Import this into inkscape. You want to align it so it's completely vertical, and so the bottom of the chess piece is touching the bottom of the page, and the centre of the chess piece is aligned with the left side of the page. There's a picture attached to show you what I mean.
3) You then want to trace the outline, as best you can. You want to use the left and bottom sides of the page, then trace the rest, so that when you're done you have the outline of half a chess piece. When you're done, you want to add a bunch of nodes to the line, then convert to straight lines. This has the effect of forming an almost-smooth line, but composed of just straight lines (important for the next step).
4) Then you want to delete the original image, and export the lines to dxf format.
5)Then you need to use openscad to convert the 2d outline to a 3d object:
Hit F5 to see if it looks ok. Then you can do any edits you need (eg I used difference() to subtract the cutout part of the bishop). You then need to scale the object to the right size. To do this I get openscad to draw a cuboid until I find the height, then use scale() to get the correct height.
Export to stl, then print.
You can see the picture of some of my real chess pieces (a white rook and black bishop and black pawn, and the rest are printed replacements). I was amazed at how well this method works :)