Mercurial > pidgin.yaz
comparison gtk/plugins/crazychat/face.h @ 14191:009db0b357b5
This is a hand-crafted commit to migrate across subversion revisions
16854:16861, due to some vagaries of the way the original renames were
done. Witness that monotone can do in one revision what svn had to
spread across several.
author | Ethan Blanton <elb@pidgin.im> |
---|---|
date | Sat, 16 Dec 2006 04:59:55 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
14190:366be2ce35a7 | 14191:009db0b357b5 |
---|---|
1 #ifndef __FACE_H__ | |
2 #define __FACE_H__ | |
3 | |
4 #include <GL/gl.h> | |
5 #include <GL/glu.h> | |
6 #include "glm.h" | |
7 | |
8 #define NUM_PARTS 10 | |
9 #define DOG_SHARK_CHANGE 5 | |
10 #define CRAZY_COUNT 12 | |
11 #define MAX_EYE_POP 1.3 | |
12 #define EYE_TIME 120 | |
13 #define MAX_FILE_LEN 64 | |
14 #define ANGLE_INC 60 | |
15 | |
16 typedef enum {DOG, SHARK} KIND; | |
17 typedef int BOOL; | |
18 typedef enum {UP, DOWN, CONST} DIRECTION; | |
19 typedef enum {NORMAL, CRAZY1, CRAZY2, CRAZY3} OUTPUT_MODE; | |
20 | |
21 struct face_struct { | |
22 char* name; | |
23 KIND my_kind; | |
24 void* char_struct; | |
25 GLint* mat_indeces; | |
26 GLMmat_str* materials; | |
27 OUTPUT_MODE my_mode; | |
28 int eye_count, crazy_count; | |
29 void (*draw_func)(struct face_struct*, GLfloat, GLfloat, BOOL, BOOL, GLfloat, DIRECTION, OUTPUT_MODE); | |
30 float curr_z_angle, curr_eye_pop; | |
31 }; | |
32 | |
33 typedef struct face_struct* FACE; | |
34 typedef enum {APPENDAGE, HEAD, LIDS, LEFT_IRIS, RIGHT_IRIS, EYES, PUPIL, EXTRA1, EXTRA2, EXTRA3} PART; | |
35 | |
36 FACE init_face(KIND kind); | |
37 | |
38 FACE copy_face(FACE f); | |
39 | |
40 void draw_face(FACE face, GLfloat zrot, GLfloat yrot, BOOL left_eye, BOOL right_eye, GLfloat mouth_open, DIRECTION dir, OUTPUT_MODE mode); | |
41 | |
42 void change_materials(FACE face, int* mats, int num_change); | |
43 | |
44 #endif |