]> git.tdb.fi Git - libs/gl.git/blob - source/grid.h
Drop Id tags and copyright notices from files
[libs/gl.git] / source / grid.h
1 #ifndef MSP_GL_GRID_H_
2 #define MSP_GL_GRID_H_
3
4 #include "geometrybuilder.h"
5 #include "vector.h"
6
7 namespace Msp {
8 namespace GL {
9
10 class GridBuilder: public GeometryBuilder
11 {
12 private:
13         Vector3 origin;
14         Vector3 side1;
15         Vector3 side2;
16         Vector3 norm;
17         Vector3 binorm;
18         unsigned u_div;
19         unsigned v_div;
20         float u_origin;
21         float y_origin;
22
23 public:
24         GridBuilder(float, float, unsigned = 4, unsigned = 4);
25         GridBuilder(const Vector3 &, const Vector3 &, unsigned = 4, unsigned = 4);
26         GridBuilder(const Vector3 &, const Vector3 &, const Vector3 &, unsigned = 4, unsigned = 4);
27 private:
28         void init(bool);
29
30 public:
31         virtual void build(PrimitiveBuilder &) const;
32 };
33
34 } // namespace GL
35 } // namespace Msp
36
37 #endif