textures.h 643 B

12345678910111213141516171819202122232425
  1. #pragma once
  2. #ifdef _arch_dreamcast
  3. #include "GL/glkos.h"
  4. #include "GL/glu.h"
  5. #include "GL/glext.h"
  6. #include "kos.h"
  7. #else
  8. #include "GL/gl.h"
  9. #endif
  10. #include "../include/base.h"
  11. typedef struct {
  12. GLuint id;
  13. GLuint list_id;
  14. int width;
  15. int height;
  16. int channels;
  17. } Texture;
  18. void DrawTexture(Texture texture, float x, float y, float scale, Color color);
  19. Texture LoadTexture(const char* filename);
  20. Texture LoadTextureFromMemory(const unsigned char* data, size_t data_size);
  21. void UnloadTexture(Texture texture);
  22. void DrawTexturePro(Texture texture, Rectangle source, Rectangle dest, Vector2 origin, float rotation, Color tint);