Anonymous object supports. Initial implementation provides for a box of arbitrary size.
This commit is contained in:
parent
e93cc13698
commit
33f489bba9
3 changed files with 146 additions and 1 deletions
|
@ -27,6 +27,14 @@ sub mesh {
|
|||
$facets = [
|
||||
[0,1,2], [0,2,3], [4,5,6], [4,6,7], [0,4,7], [0,7,1], [1,7,6], [1,6,2], [2,6,5], [2,5,3], [4,0,3], [4,3,5],
|
||||
],
|
||||
} elsif ($name eq 'box') {
|
||||
my ($x, $y, $z) = @{ $params{"dim"} };
|
||||
$vertices = [
|
||||
[$x,$y,0], [$x,0,0], [0,0,0], [0,$y,0], [$x,$y,$z], [0,$y,$z], [0,0,$z], [$x,0,$z],
|
||||
];
|
||||
$facets = [
|
||||
[0,1,2], [0,2,3], [4,5,6], [4,6,7], [0,4,7], [0,7,1], [1,7,6], [1,6,2], [2,6,5], [2,5,3], [4,0,3], [4,3,5],
|
||||
],
|
||||
} elsif ($name eq 'cube_with_hole') {
|
||||
$vertices = [
|
||||
[0,0,0],[0,0,10],[0,20,0],[0,20,10],[20,0,0],[20,0,10],[5,5,0],[15,5,0],[5,15,0],[20,20,0],[15,15,0],[20,20,10],[5,5,10],[5,15,10],[15,5,10],[15,15,10]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue