dd_image.h 361 B

1234567891011121314151617181920
  1. #ifndef DD_IMAGE_H
  2. #define DD_IMAGE_H
  3. #include "dd_opengl.h"
  4. struct dd_image {
  5. GLuint tex;
  6. int width, height;
  7. float *pixels;
  8. GLubyte *pixelsb;
  9. };
  10. void dd_image_load_bmp(struct dd_image *img, const char *filename);
  11. void dd_image_to_opengl(struct dd_image *img);
  12. void dd_image_free(struct dd_image *img);
  13. void dd_image_draw(struct dd_image *img);
  14. #endif