MCPcopy Create free account
hub / github.com/PyMesh/PyMesh / create_box

Function create_box

tools/Wires/Inflator/PeriodicInflator3D.cpp:28–52  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

26
27namespace PeriodicInflator3DHelper {
28 void create_box(const VectorF& bbox_min, const VectorF& bbox_max,
29 MatrixFr& box_vertices, MatrixIr& box_faces) {
30 box_vertices.resize(8, 3);
31 box_faces.resize(12, 3);
32 box_vertices << bbox_min[0], bbox_min[1], bbox_min[2],
33 bbox_max[0], bbox_min[1], bbox_min[2],
34 bbox_max[0], bbox_max[1], bbox_min[2],
35 bbox_min[0], bbox_max[1], bbox_min[2],
36 bbox_min[0], bbox_min[1], bbox_max[2],
37 bbox_max[0], bbox_min[1], bbox_max[2],
38 bbox_max[0], bbox_max[1], bbox_max[2],
39 bbox_min[0], bbox_max[1], bbox_max[2];
40 box_faces << 1, 2, 5,
41 5, 2, 6,
42 3, 4, 7,
43 3, 0, 4,
44 2, 3, 6,
45 3, 7, 6,
46 0, 1, 5,
47 0, 5, 4,
48 4, 5, 6,
49 4, 6, 7,
50 0, 3, 2,
51 0, 2, 1;
52 }
53}
54
55using namespace PeriodicInflator3DHelper;

Callers 1

clip_phantom_meshMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected