|
Muto 0.0.1
|
Component that holds sub-texture data for sprites. More...
#include <Components.h>
Public Member Functions | |
| Ref< SubTexture2D > & | GetSubTexture () |
| operator const Ref< SubTexture2D > & () const | |
| operator Ref< SubTexture2D > & () | |
| void | SetOffset (const glm::vec2 &offset) |
| Sets the offset for the sub-texture. | |
| void | SetTexture (const Ref< Texture2D > &texture) |
| Copy constructor. | |
| void | SetTilingFactor (const glm::vec2 &tiling) |
| Sets the tiling factor for the sub-texture. | |
| SubTextureComponent ()=default | |
| SubTextureComponent (const Ref< SubTexture2D > &subTexture) | |
| Constructor that initializes the sub-texture directly. | |
| SubTextureComponent (const Ref< Texture2D > &texture) | |
| Constructor that initializes the sub-texture from a full texture. | |
Public Attributes | |
| glm::vec2 | Offset = { 0.0f, 0.0f } |
| Offset for the sub-texture. | |
| Ref< SubTexture2D > | SubTexture |
| The sub-texture reference. | |
| glm::vec2 | TilingFactor = { 1.0f, 1.0f } |
| Tiling factor for the sub-texture. | |
Component that holds sub-texture data for sprites.
|
default |
Constructor that initializes the sub-texture from a full texture.
References SubTextureComponent().
Referenced by SubTextureComponent(), and SubTextureComponent().
|
inline |
|
inline |
|
inline |
|
inline |
Sets the offset for the sub-texture.
Copy constructor.
Sets the tiling factor for the sub-texture.
| glm::vec2 Muto::SubTextureComponent::Offset = { 0.0f, 0.0f } |
Offset for the sub-texture.
| Ref<SubTexture2D> Muto::SubTextureComponent::SubTexture |
The sub-texture reference.
| glm::vec2 Muto::SubTextureComponent::TilingFactor = { 1.0f, 1.0f } |
Tiling factor for the sub-texture.