diff options
Diffstat (limited to 'engines/sword25/gfx/animation.h')
-rw-r--r-- | engines/sword25/gfx/animation.h | 69 |
1 files changed, 34 insertions, 35 deletions
diff --git a/engines/sword25/gfx/animation.h b/engines/sword25/gfx/animation.h index 2d6c9c95fd..de684ce395 100644 --- a/engines/sword25/gfx/animation.h +++ b/engines/sword25/gfx/animation.h @@ -43,7 +43,6 @@ namespace Sword25 { // Forward declarations class Kernel; -class BS_PackageManager; class AnimationResource; class AnimationTemplate; class AnimationDescription; @@ -53,9 +52,9 @@ class Animation : public TimedRenderObject { friend class RenderObject; private: - Animation(RenderObjectPtr<RenderObject> ParentPtr, const Common::String &FileName); - Animation(RenderObjectPtr<RenderObject> ParentPtr, const AnimationTemplate &Template); - Animation(InputPersistenceBlock &Reader, RenderObjectPtr<RenderObject> ParentPtr, uint Handle); + Animation(RenderObjectPtr<RenderObject> parentPtr, const Common::String &fileName); + Animation(RenderObjectPtr<RenderObject> parentPtr, const AnimationTemplate &template_); + Animation(InputPersistenceBlock &reader, RenderObjectPtr<RenderObject> parentPtr, uint handle); public: enum ANIMATION_TYPES { @@ -71,77 +70,77 @@ public: void Stop(); void SetFrame(uint Nr); - virtual void SetPos(int X, int Y); - virtual void SetX(int X); - virtual void SetY(int Y); + virtual void setPos(int x, int y); + virtual void setX(int x); + virtual void setY(int y); - virtual int GetX() const; - virtual int GetY() const; - virtual int GetAbsoluteX() const; - virtual int GetAbsoluteY() const; + virtual int getX() const; + virtual int getY() const; + virtual int getAbsoluteX() const; + virtual int getAbsoluteY() const; /** @brief Setzt den Alphawert der Animation. @param Alpha der neue Alphawert der Animation (0 = keine Deckung, 255 = volle Deckung). @remark Diese Methode darf nur aufgerufen werden, wenn die Methode IsAlphaAllowed() true zurückgibt. */ - void SetAlpha(int Alpha); + void setAlpha(int alpha); /** @brief Setzt die Modulationfarbe der Animation. @param Color eine 24-Bit Farbe, die die Modulationsfarbe der Animation festlegt. @remark Diese Methode darf nur aufgerufen werden, wenn die Methode IsColorModulationAllowed() true zurückgibt. */ - void SetModulationColor(uint ModulationColor); + void setModulationColor(uint modulationColor); /** @brief Setzt den Skalierungsfaktor der Animation. @param ScaleFactor der Faktor um den die Animation in beide Richtungen gestreckt werden soll. @remark Diese Methode darf nur aufgerufen werden, wenn die Methode IsScalingAllowed() true zurückgibt. */ - void SetScaleFactor(float ScaleFactor); + void setScaleFactor(float scaleFactor); /** @brief Setzt den Skalierungsfaktor der Animation auf der X-Achse. @param ScaleFactor der Faktor um den die Animation in Richtungen der X-Achse gestreckt werden soll. @remark Diese Methode darf nur aufgerufen werden, wenn die Methode IsScalingAllowed() true zurückgibt. */ - void SetScaleFactorX(float ScaleFactorX); + void setScaleFactorX(float scaleFactorX); /** @brief Setzt den Skalierungsfaktor der Animation auf der Y-Achse. @param ScaleFactor der Faktor um den die Animation in Richtungen der Y-Achse gestreckt werden soll. @remark Diese Methode darf nur aufgerufen werden, wenn die Methode IsScalingAllowed() true zurückgibt. */ - void SetScaleFactorY(float ScaleFactorY); + void setScaleFactorY(float scaleFactorY); /** @brief Gibt den Skalierungsfakter der Animation auf der X-Achse zurück. @remark Diese Methode darf nur aufgerufen werden, wenn die Methode IsScalingAllowed() true zurückgibt. */ - float GetScaleFactorX() const { - return m_ScaleFactorX; + float getScaleFactorX() const { + return _scaleFactorX; } /** @brief Gibt den Skalierungsfakter der Animation auf der Y-Achse zurück. @remark Diese Methode darf nur aufgerufen werden, wenn die Methode IsScalingAllowed() true zurückgibt. */ - float GetScaleFactorY() const { - return m_ScaleFactorY; + float getScaleFactorY() const { + return _scaleFactorY; } - virtual bool Persist(OutputPersistenceBlock &Writer); - virtual bool Unpersist(InputPersistenceBlock &Reader); + virtual bool persist(OutputPersistenceBlock &writer); + virtual bool unpersist(InputPersistenceBlock &reader); - virtual void FrameNotification(int TimeElapsed); + virtual void frameNotification(int timeElapsed); - ANIMATION_TYPES GetAnimationType() const; - int GetFPS() const; - int GetFrameCount() const; - bool IsScalingAllowed() const; - bool IsAlphaAllowed() const; - bool IsColorModulationAllowed() const; + ANIMATION_TYPES getAnimationType() const; + int getFPS() const; + int getFrameCount() const; + bool isScalingAllowed() const; + bool isAlphaAllowed() const; + bool isColorModulationAllowed() const; uint GetCurrentFrame() const { return m_CurrentFrame; } @@ -157,7 +156,7 @@ public: void RegisterDeleteCallback(ANIMATION_CALLBACK Callback, uint Data = 0); protected: - virtual bool DoRender(); + virtual bool doRender(); private: enum DIRECTION { @@ -165,11 +164,11 @@ private: BACKWARD }; - int m_RelX; - int m_RelY; - float m_ScaleFactorX; - float m_ScaleFactorY; - uint m_ModulationColor; + int _relX; + int _relY; + float _scaleFactorX; + float _scaleFactorY; + uint _modulationColor; uint m_CurrentFrame; int m_CurrentFrameTime; bool m_Running; |