TextureResource.h 535 B

123456789101112131415161718192021222324252627
  1. #ifndef ANKI_RESOURCE_TEXTURE_RESOURCE_H
  2. #define ANKI_RESOURCE_TEXTURE_RESOURCE_H
  3. #include "anki/gl/Texture.h"
  4. namespace anki {
  5. class Image;
  6. /// Texture resource class
  7. ///
  8. /// It loads or creates an image and then loads it in the GPU. It supports
  9. /// compressed and uncompressed TGAs and some of the formats of PNG
  10. /// (PNG loading uses libpng)
  11. class TextureResource: public Texture
  12. {
  13. public:
  14. /// Load a texture
  15. void load(const char* filename);
  16. /// Load a texture
  17. void load(const Image& img);
  18. };
  19. } // end namespace
  20. #endif