#include <boost/shared_ptr.hpp>
-#include <Moof/Resource.hh>
#include <Moof/OpenGL.hh>
+#include <Moof/Resource.hh>
namespace Mf {
public:
Texture(const std::string& name);
- void bind();
- GLuint getObject();
+ void bind() const;
+ GLuint getObject() const;
- unsigned getWidth();
- unsigned getHeight();
+ static void resetBind();
- void setMinFilter(GLuint filter);
- void setMaxFilter(GLuint filter);
- void setWrapU(GLuint wrap);
- void setWrapV(GLuint wrap);
+ unsigned getWidth() const;
+ unsigned getHeight() const;
- void applyChanges();
+ void setMinFilter(GLuint filter);
+ void setMagFilter(GLuint filter);
+ void setWrapS(GLuint wrap);
+ void setWrapT(GLuint wrap);
- static std::string getPathToResource(const std::string& name);
+ static std::string getPath(const std::string& name);
struct Exception : std::runtime_error
{
};
private:
- class TextureImpl;
- boost::shared_ptr<TextureImpl> impl_;
+ class Impl;
+ boost::shared_ptr<Impl> impl_;
};