#pragma once #include "Array.h" namespace Framework { class Bild; class Animation2DData; class Textur2D : public virtual ReferenceCounter { private: struct Animation { Animation2DData* data; int jetzt; double ausgleich; }; bool circularAnimation; int animationIndex; Bild* txt; Array* animData; public: //! Constructor DLLEXPORT Textur2D(); //! Destructor DLLEXPORT ~Textur2D(); //! Sets whether the animation should repeat automatically //! \param ca 1 if the animation should repeat automatically DLLEXPORT void setCircularAnimation(bool ca); //! Sets a pointer to the texture (if not animated) //! \param textur The pointer to the image DLLEXPORT void setTexturZ(Bild* textur); //! Adds an animation //! \param textur The pointer to the animation data DLLEXPORT void addAnimationZ(Animation2DData* textur); //! Sets the current animation //! \param index The index of the animation DLLEXPORT void setAnimation(int index); //! Activates the next animation DLLEXPORT void nextAnimation(); //! Sets the elapsed time since the last call //! \param t The elapsed time in seconds DLLEXPORT bool tick(double t); //! Returns the current texture DLLEXPORT Bild* zTextur() const; }; } // namespace Framework