]> Dogcows Code - chaz/yoink/blobdiff - src/Moof/Texture.hh
minor refactoring and state progress
[chaz/yoink] / src / Moof / Texture.hh
index d55f6f7309c71fe05765ac86c02abfbd53599959..5aa38e1dc85e04ea70aa5f910c6c91992b688a0f 100644 (file)
 namespace Mf {
 
 
+class Texture;
+typedef boost::shared_ptr<Texture> TextureP;
+
+
 class Texture : public Resource
 {
+       class Impl;
+       boost::shared_ptr<Impl> mImpl;
+
 public:
+
+       static TextureP alloc(const std::string& name)
+       {
+               return TextureP(new Texture(name));
+       }
+
        Texture(const std::string& name);
 
        void bind() const;
@@ -66,6 +79,7 @@ public:
 
        static std::string getPath(const std::string& name);
 
+
        struct Exception : public Mf::Exception
        {
                enum
@@ -86,15 +100,11 @@ public:
                        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_;
 };
 
 
This page took 0.020066 seconds and 4 git commands to generate.