namespace Mf {
+class Texture;
+typedef boost::shared_ptr<Texture> TextureP;
+
+
class Texture : public Resource
{
+ class Impl;
+ boost::shared_ptr<Impl> impl_;
+
public:
+
+ static TextureP alloc(const std::string& name)
+ {
+ return TextureP(new Texture(name));
+ }
+
Texture(const std::string& name);
void bind() const;
static std::string getPath(const std::string& name);
+
struct Exception : public Mf::Exception
{
enum
switch (code)
{
case BAD_IMAGE_FORMAT:
- return "inappropriate image format";
+ return "unknown image format";
}
return Mf::Exception::what();
}
};
-
-private:
- class Impl;
- boost::shared_ptr<Impl> impl_;
};