home *** CD-ROM | disk | FTP | other *** search
- #ifndef ANIMATION2D_H
- #define ANIMATION2D_H
- #include "Object2D.h"
- class Sequences;
- class String;
- class Scene2D;
-
- class Animation2D : public Object2D
- {
- public:
- Animation2D(Scene2D * scene, int layer, const String & name);
- virtual ~Animation2D();
-
- virtual void render();
-
- void start(int seq, bool is_loop);
- bool life_cycle(float delta_time);
- bool is_finished()const;
- void set_transparency(int alpha);
-
- void render_frame(int seq, int fr, int alpha)const;
-
- int get_height()const;
- int get_height(int seq, int fr)const;
- int get_width()const;
- int get_width(int seq, int fr )const;
- int get_sequence_count()const;
- int get_frame_count(int seq)const;
- private:
- int alpha;
- int current_seq;
- int current_fr;
- float time;
- bool loop_current;
- bool finished;
-
- /**
- * @supplierCardinality 1
- */
- const Sequences * sequences;
- };
- #endif //ANIMATION2D_H