tongs.frink

View or download tongs.frink in plain text format


/** This makes a tongs holder for 3-D printing. */

// The model resolution
r = 254/in

//width = 18.8 mm
//depth = 24.4 mm
//height = 1 inch

width = 17 mm
depth = 26.0 mm
height = 1 inch

thickness = 2 mm

// Outer wall
outer = callJava["frink.graphics.VoxelArray", "construct", [-thickness r, (width+thickness) r, -thickness r, (depth+thickness) r, 0 mm r, height r, true]]

// Inner wall
inner = callJava["frink.graphics.VoxelArray", "construct", [0 mm r, width r, 0 mm r, depth r, 0 mm r, height r, true]]

outer.remove[inner]

outer.projectX[undef].show["X"]
outer.projectY[undef].show["Y"]
outer.projectZ[undef].show["Z"]

w = new Writer["tongs" + (width->mm) + "x" + (depth->mm) + ".obj"]
w.println[outer.toObjFormat["tongs", 1/(r mm)]]
w.close[]


View or download tongs.frink in plain text format


This is a program written in the programming language Frink.
For more information, view the Frink Documentation or see More Sample Frink Programs.

Alan Eliasen was born 19100 days, 8 hours, 57 minutes ago.