1 #include <msp/gl/extensions/msp_clipping.h>
12 vector<ClipUnit> ClipUnit::units;
19 bool ClipUnit::set_plane(const ClipPlane *p)
21 bool result = (p!=plane);
26 unsigned ClipUnit::get_n_units()
28 static Require _req(MSP_clipping);
29 static int count = get_i(GL_MAX_CLIP_PLANES);
33 ClipUnit &ClipUnit::get_unit(unsigned i)
36 throw out_of_range("ClipUnit::get_unit");
40 unsigned j = units.size();
41 units.resize(i+1, ClipUnit());
42 for(; j<units.size(); ++j)
49 ClipUnit *ClipUnit::find_unit(const ClipPlane *p)
51 for(vector<ClipUnit>::iterator i=units.begin(); i!=units.end(); ++i)