]> git.tdb.fi Git - libs/gl.git/blob - source/core/clipping.h
Rearrange soucre files into subdirectories
[libs/gl.git] / source / core / clipping.h
1 #ifndef MSP_GL_CLIPPING_H_
2 #define MSP_GL_CLIPPING_H_
3
4 #include <vector>
5 #include "bindable.h"
6
7 namespace Msp {
8 namespace GL {
9
10 class ClipPlane;
11 class Matrix;
12 class ProgramData;
13
14 class Clipping: public Bindable<Clipping>
15 {
16 private:
17         std::vector<const ClipPlane *> planes;
18
19 public:
20         static unsigned get_n_attach_points();
21
22         void attach(unsigned, const ClipPlane &);
23         void detach(unsigned);
24
25         void update_shader_data(ProgramData &, const Matrix &) const;
26
27         void bind() const;
28
29         static void unbind();
30 };
31
32 } // namespace GL
33 } // namespace Msp
34
35 #endif