Texure.cpp 537 B

12345678910111213141516171819202122232425262728293031
  1. #include "Texture.h"
  2. #include "utility/Rect.h"
  3. #include <cstdint>
  4. using WalrusRPG::Graphics::Texture;
  5. using WalrusRPG::Utils::Rect;
  6. namespace {
  7. /*texture_type_t*/ char* loadPNG(char *data) {
  8. // stuff
  9. return nullptr;
  10. }
  11. }
  12. Texture::Texture(char *data)
  13. {
  14. // TODO
  15. // load data from texture
  16. // texture = loadPNG(data);
  17. }
  18. Texture::~Texture()
  19. {
  20. // destroy(texture);
  21. }
  22. WalrusRPG::Utils::Rect Texture::get_dimensions()
  23. {
  24. // return Rect(0, 0, texture[0], texture[1]);
  25. return Rect(0, 0, 0, 0);
  26. }