rayzor
diff src/min3d.h @ 6:a68dbf80d547
finally showing something ... :)
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Mon, 07 Apr 2014 06:04:11 +0300 |
parents | 5fcf72837b69 |
children | 70e332156d02 |
line diff
1.1 --- a/src/min3d.h Sun Apr 06 02:43:24 2014 +0300 1.2 +++ b/src/min3d.h Mon Apr 07 06:04:11 2014 +0300 1.3 @@ -43,7 +43,11 @@ 1.4 extern "C" { 1.5 #endif 1.6 1.7 +int m3d_init(void); 1.8 +void m3d_shutdown(void); 1.9 + 1.10 void m3d_set_buffers(struct m3d_image *cbuf, uint16_t *zbuf); 1.11 +void m3d_clear_color(float r, float g, float b); 1.12 void m3d_clear(unsigned int bmask); 1.13 1.14 void m3d_enable(int bit); 1.15 @@ -51,6 +55,8 @@ 1.16 1.17 /* matrix stack */ 1.18 void m3d_matrix_mode(int mode); 1.19 +void m3d_push_matrix(void); 1.20 +void m3d_pop_matrix(void); 1.21 void m3d_load_identity(void); 1.22 void m3d_load_matrix(const float *m); 1.23 void m3d_mult_matrix(const float *m); 1.24 @@ -69,7 +75,13 @@ 1.25 void m3d_draw(int prim, int vcount); 1.26 void m3d_draw_indexed(int prim, const int *idxarr, int icount); 1.27 1.28 -/* TODO immediate mode */ 1.29 +/* immediate mode interface */ 1.30 +void m3d_begin(int prim); 1.31 +void m3d_end(void); 1.32 +void m3d_vertex(float x, float y, float z); 1.33 +void m3d_normal(float x, float y, float z); 1.34 +void m3d_color(float x, float y, float z); 1.35 +void m3d_texcoord(float x, float y); 1.36 1.37 #ifdef __cplusplus 1.38 }