PolyResource.h 920 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /*
  2. * PolyResource.h
  3. * Poly
  4. *
  5. * Created by Ivan Safrin on 9/19/08.
  6. * Copyright 2008 __MyCompanyName__. All rights reserved.
  7. *
  8. */
  9. // @package BasicTypes
  10. #pragma once
  11. #include "PolyString.h"
  12. #include "PolyGlobals.h"
  13. #include <vector>
  14. #include <string>
  15. using std::vector;
  16. using std::string;
  17. namespace Polycode {
  18. class _PolyExport Resource {
  19. public:
  20. Resource(int type);
  21. virtual ~Resource();
  22. String getResourceName();
  23. int getResourceType();
  24. void setResourceName(String newName);
  25. void setResourcePath(String path);
  26. String getResourcePath();
  27. static const int RESOURCE_TEXTURE = 0;
  28. static const int RESOURCE_MATERIAL = 1;
  29. static const int RESOURCE_SHADER = 2;
  30. static const int RESOURCE_PROGRAM = 3;
  31. static const int RESOURCE_MESH = 5;
  32. static const int RESOURCE_CUBEMAP = 6;
  33. protected:
  34. int type;
  35. String resourcePath;
  36. String name;
  37. };
  38. }