/** Program to 3-D Print Enzo Mari's "16 Pesci" Original image used for extracting: https://frinklang.org/frinksamp/16PesciOrig.jpg Cleaned-up image: (you will need this to run this program) https://frinklang.org/frinksamp/16PesciBW.png */ r = 254/in depth = 1 mm // The image file to extract can be loaded from: // https://frinklang.org/frinksamp/16PesciBW.png img = new image["file:16PesciBW.png"] v = callJava["frink.graphics.VoxelArray", "extrudeZ", [img, round[depth r]]] v.projectZ[undef].show["Z"] filename = "16Pesci.obj" print["Writing $filename..."] w = new Writer[filename] w.println[v.toObjFormat["16Pesci", 1/(r mm)]] w.close[] println["done."]