-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSprite.h
More file actions
36 lines (26 loc) · 703 Bytes
/
Sprite.h
File metadata and controls
36 lines (26 loc) · 703 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
/*
* Sprite.h
*
* Created on: 5 maj 2010
* Author: meros
*/
#ifndef SPRITEDRAWABLE_H_
#define SPRITEDRAWABLE_H_
#include <SFML/Graphics.hpp>
class Sprite {
public:
Sprite();
virtual ~Sprite();
bool LoadTGA(const char* aTgaFile);
void Mirror();
void DrawGroundCenterRelative(sf::RenderTarget& aTarget, float aXCenter,
float aYGround, float aHeight, float aRotation);
void DrawTiling(sf::RenderTarget& aTarget, float aXStart, float aYStart,
float aXEnd, float aYEnd);
void DrawStretchRotation(sf::RenderTarget& aTarget, float aXCenter,
float aYCenter, float aNonRotHeight, float aAngleRad);
private:
sf::Texture myBMP;
sf::Sprite mySprite;
};
#endif /* Sprite_H_ */