X-Git-Url: https://git.dogcows.com/gitweb?p=chaz%2Fyoink;a=blobdiff_plain;f=src%2FMoof%2FAnimation.hh;h=38a055d8834c56fa9fa6f309057aadb4afd89af0;hp=cfda19beff3cd2b0de2686ea457d299d0fc15c79;hb=f72400af4fa3e7b54dab154b5a2b6503a6f9af18;hpb=bfa6212d09d8735d8fd5e2638188e4a99f21ada4 diff --git a/src/Moof/Animation.hh b/src/Moof/Animation.hh index cfda19b..38a055d 100644 --- a/src/Moof/Animation.hh +++ b/src/Moof/Animation.hh @@ -45,6 +45,9 @@ namespace Mf { +class Animation; +typedef boost::shared_ptr AnimationP; + /** * A class to manage frame-based animation. Animation sequences can be loaded * from file, then named sequences are started. The animation is updated @@ -55,7 +58,16 @@ namespace Mf { class Animation : public Resource { + class Impl; + boost::shared_ptr impl_; + public: + + static AnimationP alloc(const std::string& name) + { + return AnimationP(new Animation(name)); + } + Animation(const std::string& name); void startSequence(const std::string& name); @@ -64,10 +76,6 @@ public: unsigned getFrame() const; static std::string getPath(const std::string& name); - -private: - class Impl; - boost::shared_ptr impl_; };