11.07.2015 Views

Download document (10.35 MB) - Escuela Superior de Informática ...

Download document (10.35 MB) - Escuela Superior de Informática ...

Download document (10.35 MB) - Escuela Superior de Informática ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

D.2. Código fuente <strong>de</strong> los módulos más relevantes. 151173 GSList *Nodo;174 TPunto3D *punto3D;175 GLUquadricObj *qobj;176177 glMatrixMo<strong>de</strong>(GL_MODELVIEW);178 glPushMatrix();179180 if(posicion3D == VISTA_BRAZOS)181 {182 Nodo = (g_slist_nth ( mo<strong>de</strong>lo3D[marca].lista, frame));183184 if (Nodo != NULL){185 punto3D = Nodo->data;186 glTranslatef(punto3D->x,punto3D->y,punto3D->z);187188 qobj = gluNewQuadric ();189190 /* Dibujamos el esfera */191 glDisable(GL_LIGHTING); //Comentar si queremos <strong>de</strong>tallado192 gluQuadricDrawStyle (qobj, GLU_FILL);193 gluSphere (qobj, tamano, 10, 10);194 glEnable(GL_LIGHTING); //Comentar si queremos <strong>de</strong>tallado195 }196 }197 else if(posicion3D == VISTA_CARA)198 {199 Nodo = (g_slist_nth ( mo<strong>de</strong>lo3DGestos[marca].gestos_lista, frame));200201 if (Nodo != NULL){202 punto3D = Nodo->data;203 glTranslatef(punto3D->x,punto3D->y,punto3D->z);204205 qobj = gluNewQuadric ();206207 /* Dibujamos el esfera */208 glDisable(GL_LIGHTING); //Comentar si queremos <strong>de</strong>tallado209 gluQuadricDrawStyle (qobj, GLU_FILL);210 gluSphere (qobj, tamano, 10, 10);211 glEnable(GL_LIGHTING); //Comentar si queremos <strong>de</strong>tallado212 }213 }214215 glMatrixMo<strong>de</strong>(GL_MODELVIEW);216 glPopMatrix();217 }218219 /********************************************************************220 * Funcion: ren<strong>de</strong>rFrame221 * Descripcion: Calcula y dibuja en pantalla el frame actual222 * Entradas: Ninguna.223 * Salidas: Ninguna.224 ********************************************************************/225 void ren<strong>de</strong>rFrame(void)226 {227228 GtkWidget *hscale_frame;229230 double tamano_marca = 8;231 double tamano_huesos = 2;232

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!