glvtable.h

00001 #ifndef ALLEGRO_GL_WINDOWS_VTABLE_H
00002 #define ALLEGRO_GL_WINDOWS_VTABLE_H
00003 
00004 #include <allegro.h>
00005 
00006 
00007 /* Special structure for holding video bitmaps. This piggy-backs
00008  * over the regular BITMAP structure to provide AllegroGL with the
00009  * necessary information for maintaining video bitmap over OpenGL
00010  */
00011 typedef struct AGL_VIDEO_BITMAP {
00012     GLenum target;         /* GL_TEXTURE_2D, GL_TEXTURE_RECTANGLE_NV, etc */
00013     BITMAP *memory_copy;   /* Memory copy for reading -> subbitmap */
00014     GLuint tex;            /* Associated texture number */
00015     GLuint fbo;            /* Associated FBO number. */
00016     int x_ofs, y_ofs;      /* Offsets of this block */
00017     int width, height;     /* Size of the bitmap block */
00018     struct AGL_VIDEO_BITMAP *next; /* Next block, if bitmap is too large to fit in one texture */
00019     GLenum format;         /* Pixel data format of the memory copy bitmap. */
00020     GLenum type;           /* Pixel data type of the memory copy bitmap. */
00021 } AGL_VIDEO_BITMAP;
00022 
00023 
00024 void __allegro_gl__glvtable_update_vtable (GFX_VTABLE **vtable);
00025 BITMAP *allegro_gl_create_video_bitmap(int w, int h);
00026 void allegro_gl_drawing_mode(void);
00027 void allegro_gl_set_blender_mode(int mode, int r, int g, int b, int a);
00028 void allegro_gl_destroy_video_bitmap(BITMAP *bmp);
00029 void allegro_gl_created_sub_bitmap(BITMAP *bmp, BITMAP *parent);
00030 void split_color(int color, GLubyte *r, GLubyte *g, GLubyte *b, GLubyte *a,
00031         int color_depth);
00032 void allegro_gl_screen_blit_to_self (struct BITMAP *source, struct BITMAP *dest,
00033         int source_x, int source_y, int dest_x, int dest_y, int width,
00034         int height);
00035 void allegro_gl_video_blit_from_memory(struct BITMAP *source,
00036         struct BITMAP *dest, int source_x, int source_y, int dest_x,
00037         int dest_y, int width, int height);
00038 void allegro_gl_video_blit_to_memory(struct BITMAP *source, struct BITMAP *dest,
00039         int source_x, int source_y, int dest_x, int dest_y, int width,
00040         int height);
00041 void do_masked_blit_screen(struct BITMAP *source, struct BITMAP *dest,
00042         int source_x, int source_y, int dest_x, int dest_y, int width, int height,
00043         int flip_dir, int blit_type);
00044 void allegro_gl_video_blit_to_self(struct BITMAP *source, struct BITMAP *dest,
00045         int source_x, int source_y, int dest_x, int dest_y, int width, int height);
00046 void allegro_gl_screen_clear_to_color(struct BITMAP *bmp, int color);
00047 void allegro_gl_upload_and_display_texture(struct BITMAP *source,
00048         int source_x, int source_y, int dest_x, int dest_y, int width, int height,
00049         int flip_dir, GLint format, GLint type);
00050 void allegro_gl_screen_draw_glyph_ex(struct BITMAP *bmp,
00051         AL_CONST struct FONT_GLYPH *glyph, int x, int y,
00052         int color, int bg, int flip);
00053 void allegro_gl_screen_draw_color_glyph_ex(struct BITMAP *bmp,
00054         struct BITMAP *sprite, int x, int y, int color, int bg, int flip);
00055 void allegro_gl_screen_polygon3d_f(struct BITMAP *bmp, int type,
00056                                    struct BITMAP *texture, int vc,
00057                                    V3D_f *vtx[]);
00058 #endif
00059 

Generated on Sun Nov 11 15:52:55 2007 for AllegroGL by  doxygen 1.5.2