Antiprism 0.23
|
Make a snub-antiprism. More...
#include <polygons.h>
Public Member Functions | |
snub_antiprism (int N, int D=1) | |
Constructor. | |
snub_antiprism (polygon &pgon) | |
Constructor. | |
bool | set_edge2 (double e2, char *msg=0) |
Set the edge length of the non-polygon edges. | |
bool | set_height (double, char *msg=0) |
Set the height. | |
void | make_poly_part (geom_if &geom) |
Make a part of (or a complete) polygon-based polyhedron. |
Make a snub-antiprism.
snub_antiprism::snub_antiprism | ( | int | N, |
int | D = 1 |
||
) | [inline] |
Constructor.
Base polygon in form {N/D} (with N/D not necessarily in lowest form.)
N | number of sides to the (compound) polygon. |
D | the number of vertices stepped by an edge (default 1) |
snub_antiprism::snub_antiprism | ( | polygon & | pgon | ) | [inline] |
Constructor.
pgon | polygon to base the polyhedron on. |
void snub_antiprism::make_poly_part | ( | geom_if & | geom | ) | [virtual] |
Make a part of (or a complete) polygon-based polyhedron.
Make a non-compound polyhedron, using num_sides
and step
for {n/d}. If parts
is greater than 1
then polygon::make_poly will make a compound by repeating this polyhedron parts
times.
geom | a geometry to return the polyhedron. |
Reimplemented from polygon.
bool snub_antiprism::set_edge2 | ( | double | len2, |
char * | msg = 0 |
||
) | [virtual] |
Set the edge length of the non-polygon edges.
These are the vertical edges of a prism, the slanting edges of a pyramid, etc.
len2 | the edge length of the non-polygon edges. |
msg | a string with length at least MSG_SZ to hold the error message if the edge length was not valid. |
true
if the edge length was valid, otherwise false
and msg
contains the error messge. Reimplemented from polygon.
bool snub_antiprism::set_height | ( | double | ht, |
char * | msg = 0 |
||
) | [virtual] |
Set the height.
ht | the height. |
msg | a string with length at least MSG_SZ to hold the error message if the height was not valid. |
true
if the height was valid, otherwise false
and msg
contains the error messge. Reimplemented from polygon.