15 lines
535 B
OpenSCAD
15 lines
535 B
OpenSCAD
module prism(l, w, h) {
|
|
polyhedron(// pt 0 1 2 3 4 5
|
|
points=[[0,0,0], [0,w,h], [l,w,h], [l,0,0], [0,w,0], [l,w,0]],
|
|
// top sloping face (A)
|
|
faces=[[0,1,2,3],
|
|
// vertical rectangular face (B)
|
|
[2,1,4,5],
|
|
// bottom face (C)
|
|
[0,3,5,4],
|
|
// rear triangular face (D)
|
|
[0,4,1],
|
|
// front triangular face (E)
|
|
[3,2,5]]
|
|
);}
|