/* * opengl interface (only mesa supported yet) */ #ifndef GL_INT_H #define GL_INT_H #if HAVE_OPENGL #include #include "attr.h" #include "matrix.h" using namespace std; class gl_int : public gfx_int { Display *dpy; XVisualInfo *vi; XSetWindowAttributes swa; Window win; GLXContext cx; bool in_begin; int fb_depth; // bytes of framebuffer, right now int fb_format; // GL_RGB or GL_RGBA // vec last_pos; double x1, y1, z1, x2, y2, z2; void clip (const vec &v) t_no; void check_attrs (const attribute_set &attr) t_err; public: gl_int () t_no; ~gl_int () t_no; void begin_fig () t_no; void end_fig () t_no; void segment (const point &a, const point &b) t_err; void object (const points &v) t_err; }; #endif #endif