#pragma once

#include "Transition.hpp"

/*
   Class: ScaleTransition

     Implements a transition that scales the specified data element by the given amount along the X and Y axes.

     *Inherits* from <>.
*/
class ScaleTransition: public Transition {
  public:
    /*
       Constructor: ScaleTransition

         Initializes the object.

       Parameters:

         pDataElement - Pointer to the data element to be altered.
         fDeltaX - Total horizontal scaling value.
         fDeltaY - Total vertical scaling value.
         iTotalSteps - Duration of the transition in steps.
    */
    ScaleTransition(DataElement* pDataElement, float fDeltaX, float fDeltaY, int iTotalSteps);

    /*
       Destructor: ~ScaleTransition

         Releases all allocated resources.
    */
    ~ScaleTransition();


    /*
       Function: Update

         Updates the transition by executing one scaling step. *Inherited* from <Transition>.
    */
    void Update();

    /*
       Function: Complete

         Checks if the transition is completed. *Inherited* from <Transition>.

       Returns:

         A boolean value indicating if the transition is completed.
    */
    bool Complete();

  private:
    DataElement* pDataElement;
    float fScalingStepX;
    float fScalingStepY;
    int iTotalSteps;
    int iStepsDone;
};