File: gridVisualisation.h

package info (click to toggle)
ball 1.4.3~beta1-3
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 318,984 kB
  • sloc: cpp: 346,579; ansic: 4,097; python: 2,664; yacc: 1,778; lex: 1,099; xml: 964; sh: 688; sql: 316; awk: 118; makefile: 108
file content (106 lines) | stat: -rw-r--r-- 1,908 bytes parent folder | download | duplicates (9)
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
// -*- Mode: C++; tab-width: 2; -*-
// vi: set ts=2:
//
// $Id: gridVisualisation.h,v 1.1.4.1 2007-03-25 21:26:08 oliver Exp $
//

#ifndef  BALL_VIEW_PRIMITIV_GRIDSLICE_H
#define  BALL_VIEW_PRIMITIV_GRIDSLICE_H

#ifndef BALL_VIEW_KERNEL_GEOMETRICOBJECT_H
# include <BALL/VIEW/KERNEL/geometricObject.h>
#endif

#ifndef BALL_DATATYPE_REGULARDATA3D_H
# include <BALL/DATATYPE/regularData3D.h>
#endif

namespace BALL
{
	namespace VIEW
	{
		/** GridVisualisation 
				\ingroup ViewPrimitives
		*/
		class BALL_VIEW_EXPORT GridVisualisation
			: public GeometricObject
		{
			public:

			enum Type
			{
				///
				PLANE,

				///
				SLICES,

				///
				DOTS
			};

			BALL_CREATE(GridVisualisation)

			///
			GridVisualisation();

			///
			GridVisualisation(const GridVisualisation& plane);

			/** Destructor
			*/
			virtual ~GridVisualisation(){};

			///
			const GridVisualisation& operator = (const GridVisualisation& plane);
			
			///
			const Vector3& getNormal() const { return normal_;}

			///
			void setNormal(const Vector3& normal) { normal_ = normal;}

			///
			const Vector3& getPoint() const { return point_;}

			///
			void setPoint(const Vector3& v) { point_ = v;}

			///
			void setGrid(const RegularData3D* grid) { grid_ = grid;}

			///
			const RegularData3D* getGrid() const { return grid_;}

			///
			Position getTexture() const { return texture_;}

			///
			void setTexture(Position texture) { texture_ = texture;}

			///
			void setDotSize(Size dot_size) { dot_size_ = dot_size;}

			///
			Size getDotSize() const { return dot_size_;}

			Vector3 origin, x,y,z;
			float max_dim;
			Size slices;
			vector<Vector3> points;
			Type type;
			bool draw_box;

			protected:

			Vector3 normal_;
			Vector3 point_;
			Position texture_;
			const RegularData3D* grid_;
			Size dot_size_;
		};

	} // namespace VIEW
} // namespace BALL

#endif // BALL_VIEW_KERNEL_CLIPPING_PLANE_H