#include <SlySprite.h>
|
typedef std::string | ImageKey |
| Defines an alias representing the image key. More...
|
|
◆ ImageKey
Defines an alias representing the image key.
◆ SlySprite() [1/5]
◆ SlySprite() [2/5]
◆ SlySprite() [3/5]
◆ ~SlySprite()
SlySprite::~SlySprite |
( |
| ) |
|
|
virtual |
◆ SlySprite() [4/5]
Specialized Constructor.
- Parameters
-
The creation of a SlySprite requires an image. This is the normal way to setup a Sly Sprite. Image must be loaded in prior to calling creating a sprite.
◆ SlySprite() [5/5]
SlySprite::SlySprite |
( |
Image * |
inputImage | ) |
|
◆ GetAngle()
float SlySprite::GetAngle |
( |
| ) |
|
Gets the angle.
- Returns
- The sprite's angle.
◆ GetHeight()
float SlySprite::GetHeight |
( |
| ) |
|
Gets the sprite height.
- Returns
- The height.
◆ GetWidth()
float SlySprite::GetWidth |
( |
| ) |
|
Gets the sprite's width.
- Returns
- The width.
◆ operator=() [1/2]
◆ operator=() [2/2]
Move assignment operator.
◆ Render() [1/2]
void SlySprite::Render |
( |
| ) |
|
Renders the sprite with the current 2D Camera.
The CameraManager loads in a default 2D Camera to be used for sprite rendering. This camera may be changed at the scene level if a different camera is desired.
- See also
- Scene::SetCurrent2DCamera
◆ Render() [2/2]
void SlySprite::Render |
( |
Camera * |
renderCam | ) |
|
Renders the sprite to the given renderCam.
- Parameters
-
[in,out] | renderCam | If non-null, the render camera. |
This render operation should be avoided unless the user specifically wishes to render to a different camera other than the current 2D one associated with the scene.
◆ SetAngle()
void SlySprite::SetAngle |
( |
float |
a | ) |
|
Sets the sprite angle.
- Parameters
-
◆ SetCenter()
void SlySprite::SetCenter |
( |
float |
offsetX, |
|
|
float |
offsetY |
|
) |
| |
Sets the center of the sprite.
- Parameters
-
offsetX | The offset x coordinate. |
offsetY | The offset y coordinate. |
◆ SetPosition()
void SlySprite::SetPosition |
( |
float |
x, |
|
|
float |
y |
|
) |
| |
Sets the sprite position.
- Parameters
-
x | The x coordinate. |
y | The y coordinate. |
◆ SetScaleFactor()
void SlySprite::SetScaleFactor |
( |
float |
scalex, |
|
|
float |
scaley |
|
) |
| |
Sets scale factor.
- Parameters
-
scalex | The x scale. |
scaley | The y scale. |
◆ SetScalePixel()
void SlySprite::SetScalePixel |
( |
float |
width, |
|
|
float |
height |
|
) |
| |
Sets scale pixel.
- Parameters
-
width | The width. |
height | The height. |
◆ SetWorld()
void SlySprite::SetWorld |
( |
| ) |
|
◆ angle
◆ centerX
◆ centerY
◆ height
◆ inputRectangle
Rect* SlySprite::inputRectangle |
|
private |
◆ pGOSprite
GraphicsObject_Sprite* SlySprite::pGOSprite |
|
private |
◆ scaleX
◆ scaleY
◆ width
The documentation for this class was generated from the following files: