# ifndef _SGL_LINKS # include "sgl_links.h" # endif # define _SGL_CLASS /******************************************************* * class: sgl * * Class which encompasses many of the glut basic * initialization, closing, functions, and object * creation and painting * If necessary this class should be instansiated * and several functions may be overloaded. * However, this class should work as is in * conjunction with the sgl_shapes class. *******************************************************/ class sgl : public Link { // static? What does that mean? public: // should be protected static GLfloat time; static GLfloat distance; static GLfloat aperture; static GLfloat focus; static GLfloat view_ratio; static GLfloat view_rotx; static GLfloat view_roty; static GLfloat view_rotz; public: sgl() : Link(NO_ACTION) {}; // default empty constructor sgl(int argc, char *argv[]): Link(NO_ACTION) { init(argc, argv);}; ~sgl() {}; // default empty destructor // calls ~Link automatically void init(int argc, char * argv[], int,int,int,int); void init(int argc, char * argv[]); void init(int,int,int,int); void init(); static void setProjection(); static void setProjection(GLfloat); static void advance(); static void advance(GLfloat); static void idle(); static void downarrow(int,int,int); static void downkey(unsigned char,int,int); static void visible(int); static void reshape(int, int); void paint(); void print(); GLfloat gettime() { return time; } };