/* Initializes graphics subsystem */ int gInit(GContext *context) { glEnable(GL_BLEND); glBlendFunc(GL_SRC_ALPHA,GL_ONE_MINUS_SRC_ALPHA); //glEnable(GL_TEXTURE_2D); glPixelStorei(GL_UNPACK_ALIGNMENT, 1); glClearColor(0,0,0,0); glClear(GL_COLOR_BUFFER_BIT); loadShaders(&(context->shaders)); loadPrograms(&(context->programs),&(context->shaders)); loadBuffers(&(context->buffers)); setModelview(context,1,0,0,1); setTranslation(context,0,0); //printInfo("initGraphics()\n"); #ifdef DEBUG checkError(); #endif if(context->callback != NULL) context->callback(context->callback_data); return 0; }
void TransitionTriangulation::init() { loadTables(); loadBuffers(); loadPrograms(); }