Antiprism 0.23
|
Class for a geometry in a scene. More...
#include <scene.h>
Public Member Functions | |
scene_geom (const geom_if &geo=col_geom_v()) | |
Constructor. | |
scene_geom (const scene_geom &sc_geo) | |
Copy constructor. | |
scene_geom & | operator= (const scene_geom &sc_geo) |
Assignment operator. | |
~scene_geom () | |
Destructor. | |
void | set_geom (const geom_if &geo=col_geom_v()) |
Set the geometry. | |
const geom_if & | get_geom () const |
Get the geometry. | |
col_geom_v & | get_geom () |
Get the geometry. | |
void | geom_changed () |
Indicate that the geometry has changed. | |
double | get_v_ball_rad () const |
Get the vertex ball radius (the maximum without overlap.) | |
double | min_rad () const |
Get the minimum display radius. | |
const bound_sphere & | get_bound_sph () const |
Get a sphere that bounds the geometry. | |
void | set_width (double wdth) |
Set the width of the geometry. | |
double | get_width () const |
Get the width of the geometry. | |
void | set_centre (vec3d cent) |
Set the centre of the geometry. | |
vec3d | get_centre () const |
Get the centre of the geometry. | |
void | add_disp (geom_disp &disp) |
Add a new display. | |
bool | delete_disp (int idx) |
Delete a display. | |
const vector< geom_disp * > & | get_disps () const |
Get the displays. | |
vector< geom_disp * > & | get_disps () |
Get the displays. | |
geom_disp_label * | get_label () const |
Get the geometry label display. | |
void | set_label (const geom_disp_label &lab) |
Set the geometry label display. | |
vec3d | get_v_label_pos (int idx) const |
Position of a vertex label. | |
vec3d | get_e_label_pos (int idx) const |
Position of an edge label. | |
vec3d | get_f_label_pos (int idx) const |
Position of a face label. | |
geom_disp * | get_sym () const |
Get the symmetry element display. | |
void | set_sym (const geom_disp &sym) |
Set the symmetry element display. | |
int | animate () |
Update animated displays. |
Class for a geometry in a scene.
scene_geom::scene_geom | ( | const geom_if & | geo = col_geom_v() | ) |
Constructor.
geo | the geometry to display in a scene. |
scene_geom::scene_geom | ( | const scene_geom & | sc_geo | ) |
Copy constructor.
sc_geo | the scene geometry to copy from. |
void scene_geom::add_disp | ( | geom_disp & | disp | ) |
Add a new display.
disp | display to add. |
int scene_geom::animate | ( | ) |
Update animated displays.
0
if no changes). bool scene_geom::delete_disp | ( | int | idx | ) |
Delete a display.
idx | index number of the display to delete. |
void scene_geom::geom_changed | ( | ) |
Indicate that the geometry has changed.
Call this if the disply geometry has been changed through a reference to the data member.
const bound_sphere& scene_geom::get_bound_sph | ( | ) | const [inline] |
Get a sphere that bounds the geometry.
vec3d scene_geom::get_centre | ( | ) | const [inline] |
Get the centre of the geometry.
vector<geom_disp *>& scene_geom::get_disps | ( | ) | [inline] |
Get the displays.
const vector<geom_disp *>& scene_geom::get_disps | ( | ) | const [inline] |
Get the displays.
vec3d scene_geom::get_e_label_pos | ( | int | idx | ) | const |
Position of an edge label.
idx | edge index number. |
vec3d scene_geom::get_f_label_pos | ( | int | idx | ) | const |
Position of a face label.
idx | face index number. |
col_geom_v& scene_geom::get_geom | ( | ) | [inline] |
Get the geometry.
const geom_if& scene_geom::get_geom | ( | ) | const [inline] |
Get the geometry.
geom_disp_label * scene_geom::get_label | ( | ) | const |
Get the geometry label display.
geom_disp * scene_geom::get_sym | ( | ) | const |
Get the symmetry element display.
double scene_geom::get_v_ball_rad | ( | ) | const [inline] |
Get the vertex ball radius (the maximum without overlap.)
vec3d scene_geom::get_v_label_pos | ( | int | idx | ) | const |
Position of a vertex label.
idx | vertex index number. |
double scene_geom::get_width | ( | ) | const [inline] |
Get the width of the geometry.
double scene_geom::min_rad | ( | ) | const [inline] |
Get the minimum display radius.
scene_geom & scene_geom::operator= | ( | const scene_geom & | sc_geo | ) |
Assignment operator.
sc_geo | the scene geometry to assign from. |
void scene_geom::set_centre | ( | vec3d | cent | ) | [inline] |
Set the centre of the geometry.
cent | the centre to set |
void scene_geom::set_geom | ( | const geom_if & | geo = col_geom_v() | ) |
Set the geometry.
geo | the geometry to display. |
void scene_geom::set_label | ( | const geom_disp_label & | lab | ) |
Set the geometry label display.
lab | the geometry label display to set. |
void scene_geom::set_sym | ( | const geom_disp & | sym | ) |
Set the symmetry element display.
sym | the symmetry element display to set. |
void scene_geom::set_width | ( | double | wdth | ) | [inline] |
Set the width of the geometry.
wdth | the width to set |