Library for 3.2'' uLcd Picaso Display4D system Picaso Serial Environment Command Set web: http://www.4dsystems.com.au/product/20/67/Processors_Graphics/PICASO/
Isocele.h@1:a74e42cf52b2, 2015-04-05 (annotated)
- Committer:
- adelino
- Date:
- Sun Apr 05 13:54:48 2015 +0000
- Revision:
- 1:a74e42cf52b2
PicasoLib version 2
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
adelino | 1:a74e42cf52b2 | 1 | #ifndef ISOCELE_H |
adelino | 1:a74e42cf52b2 | 2 | #define ISOCELE_H |
adelino | 1:a74e42cf52b2 | 3 | |
adelino | 1:a74e42cf52b2 | 4 | #include "Screen.h" |
adelino | 1:a74e42cf52b2 | 5 | #include "Sprite.h" |
adelino | 1:a74e42cf52b2 | 6 | |
adelino | 1:a74e42cf52b2 | 7 | class Isocele:public Sprite |
adelino | 1:a74e42cf52b2 | 8 | { |
adelino | 1:a74e42cf52b2 | 9 | public: |
adelino | 1:a74e42cf52b2 | 10 | Isocele(Screen* mScreen,UINT16 xc,UINT16 yc,UINT16 radius,int orientation,float _speed,Color color); |
adelino | 1:a74e42cf52b2 | 11 | // |
adelino | 1:a74e42cf52b2 | 12 | virtual void draw(void); |
adelino | 1:a74e42cf52b2 | 13 | // |
adelino | 1:a74e42cf52b2 | 14 | virtual ~Isocele(void); |
adelino | 1:a74e42cf52b2 | 15 | // |
adelino | 1:a74e42cf52b2 | 16 | void setOrientation(int _orientation); |
adelino | 1:a74e42cf52b2 | 17 | // |
adelino | 1:a74e42cf52b2 | 18 | void turnLeft(void); |
adelino | 1:a74e42cf52b2 | 19 | // |
adelino | 1:a74e42cf52b2 | 20 | void turnRight(void); |
adelino | 1:a74e42cf52b2 | 21 | // |
adelino | 1:a74e42cf52b2 | 22 | void setInvisible(bool _state); |
adelino | 1:a74e42cf52b2 | 23 | // |
adelino | 1:a74e42cf52b2 | 24 | void setNewPosition(INT16 _xcnew,INT16 _ycnew); |
adelino | 1:a74e42cf52b2 | 25 | // |
adelino | 1:a74e42cf52b2 | 26 | void setNewPosition(INT16 _xcnew,INT16 _ycnew,bool isScreenLimits); |
adelino | 1:a74e42cf52b2 | 27 | // |
adelino | 1:a74e42cf52b2 | 28 | void update(float delta); |
adelino | 1:a74e42cf52b2 | 29 | // |
adelino | 1:a74e42cf52b2 | 30 | int getOrientation(void) const; |
adelino | 1:a74e42cf52b2 | 31 | // |
adelino | 1:a74e42cf52b2 | 32 | UINT16 getXcenter(void) const; |
adelino | 1:a74e42cf52b2 | 33 | // |
adelino | 1:a74e42cf52b2 | 34 | UINT16 getYcenter(void) const; |
adelino | 1:a74e42cf52b2 | 35 | |
adelino | 1:a74e42cf52b2 | 36 | static const int ORIENTATION_UP=0; |
adelino | 1:a74e42cf52b2 | 37 | static const int ORIENTATION_LEFT=1; |
adelino | 1:a74e42cf52b2 | 38 | static const int ORIENTATION_DOWN=2; |
adelino | 1:a74e42cf52b2 | 39 | static const int ORIENTATION_RIGHT=3; |
adelino | 1:a74e42cf52b2 | 40 | |
adelino | 1:a74e42cf52b2 | 41 | protected: |
adelino | 1:a74e42cf52b2 | 42 | UINT16 myXcenter; |
adelino | 1:a74e42cf52b2 | 43 | UINT16 myYcenter; |
adelino | 1:a74e42cf52b2 | 44 | UINT16 myRadius; |
adelino | 1:a74e42cf52b2 | 45 | int myOrientation; |
adelino | 1:a74e42cf52b2 | 46 | |
adelino | 1:a74e42cf52b2 | 47 | UINT16 myX1,myY1; |
adelino | 1:a74e42cf52b2 | 48 | UINT16 myX2,myY2; |
adelino | 1:a74e42cf52b2 | 49 | UINT16 myX3,myY3; |
adelino | 1:a74e42cf52b2 | 50 | float mySpeed; |
adelino | 1:a74e42cf52b2 | 51 | |
adelino | 1:a74e42cf52b2 | 52 | void updateOrientation(void); |
adelino | 1:a74e42cf52b2 | 53 | void myElementUpdate(void); |
adelino | 1:a74e42cf52b2 | 54 | }; |
adelino | 1:a74e42cf52b2 | 55 | #endif |