/******* FUNCTIONS ***********************************/ void drawSomething() { glPushMatrix(); glMatrixMode(GL_MODELVIEW); glLoadIdentity(); //TRANSLUCENT glTranslatef(0,0,modelZ); glScalef(800,800,800); model.draw(); glPopMatrix(); }
void drawBuddha() { model.load("../../cncsvision/data/objmodels/happyBuddha.obj"); glPushMatrix(); glMatrixMode(GL_MODELVIEW); glLoadIdentity(); //TRANSLUCENT glTranslatef(0,0,factors["AbsDepth"]); glScalef(800,800,800); model.draw(); glPopMatrix(); }
/******* FUNCTIONS ***********************************/ void drawSomething() { //WHITELIGHT glPushMatrix(); glLoadIdentity(); glMultMatrixd( rigidAux.getFullTransformation().data() ); glTranslated(5.5/100,0,7.5/100); glScalef(1,1,scaleZ); model.draw(); glPopMatrix(); }
void drawOcclusion() { double holeRadius=25; double maxSlant=M_PI/4; double tanMaxSlant = tan(maxSlant); glColor3fv(glBlack); glPushMatrix(); glLoadIdentity(); glTranslated(fixationPoint.x(),fixationPoint.y(),focalDistance+100+holeRadius/tanMaxSlant ); glScalef(10,10,2000); //diameter of inner hole is 5 cm @ focalDistance glRotated(90,1,0,0); model.draw(); glPopMatrix(); }
/** * @brief drawScene */ void drawScene() { glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); glShadeModel(GL_SMOOTH); glEnable(GL_DEPTH_TEST); glMatrixMode(GL_MODELVIEW); glLoadIdentity(); glPushMatrix(); glTranslated(0,0,-10+eyeZ); //glScaled(0.01,0.01,0.01); arcball.applyRotationMatrix(); obj.draw(GL_POINT); glPopMatrix(); glutSwapBuffers(); }