PolyResource.h 896 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  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 "PolyGlobals.h"
  12. #include <vector>
  13. #include <string>
  14. using std::vector;
  15. using std::string;
  16. namespace Polycode {
  17. class _PolyExport Resource {
  18. public:
  19. Resource(int type);
  20. virtual ~Resource();
  21. string getResourceName();
  22. int getResourceType();
  23. void setResourceName(string newName);
  24. void setResourcePath(string path);
  25. string getResourcePath();
  26. static const int RESOURCE_TEXTURE = 0;
  27. static const int RESOURCE_MATERIAL = 1;
  28. static const int RESOURCE_SHADER = 2;
  29. static const int RESOURCE_PROGRAM = 3;
  30. static const int RESOURCE_MESH = 5;
  31. static const int RESOURCE_CUBEMAP = 6;
  32. protected:
  33. int type;
  34. string resourcePath;
  35. string name;
  36. };
  37. }