/
points.hpp
47 lines (34 loc) · 1.12 KB
/
points.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#ifndef VPYTHON_PYTYHON_POINTS_HPP
#define VPYTHON_PYTYHON_POINTS_HPP
#include "renderable.hpp"
#include "python/num_util.hpp"
#include "python/arrayprim.hpp"
namespace cvisual { namespace python {
class points : public arrayprim_color
{
private:
// Specifies whether or not the size of the points should scale with the
// world or with the screen.
enum { WORLD, PIXELS } size_units;
// Specifies the shape of the point. Future candidates are triangles,
// diamonds, etc.
enum { ROUND, SQUARE } points_shape;
// The size of the points
float size;
bool degenerate() const;
virtual void outer_render( const view&);
virtual void gl_render( const view&);
virtual vector get_center() const;
virtual void gl_pick_render( const view&);
virtual void grow_extent( extent&);
public:
points();
void set_points_shape( const std::string& n_type);
std::string get_points_shape( void);
void set_size( float r);
inline float get_size( void) { return size; }
void set_size_units( const std::string& n_type);
std::string get_size_units( void);
};
} } // !namespace cvisual::python
#endif /*VPYTHON_PYTYHON_POINTS_HPP*/