meta data for this page
  •  

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
en:design_guide_polyhedron [2020/12/08 06:47]
JSCAD Editor
en:design_guide_polyhedron [2022/04/13 06:57] (current)
rozek included "require" statement
Line 12: Line 12:
  
 <code javascript> <code javascript>
 +const { polyhedron } = require('@jscad/modeling').primitives
 +
 const points = [ [10, 10, 0], [10, -10, 0], [-10, -10, 0], [-10, 10, 0], [0, 0, 10] ] const points = [ [10, 10, 0], [10, -10, 0], [-10, -10, 0], [-10, 10, 0], [0, 0, 10] ]
 const faces = [ [0, 1, 4], [1, 2, 4], [2, 3, 4], [3, 0, 4], [1, 0, 3], [2, 1, 3] ] const faces = [ [0, 1, 4], [1, 2, 4], [2, 3, 4], [3, 0, 4], [1, 0, 3], [2, 1, 3] ]