The LARC Game Engine
A Simple Game Engine from the Laboratory for Recreational Computing
Public Member Functions | Public Attributes | List of all members
LSpriteDesc Class Reference

The base sprite descriptor. More...

#include <SpriteDesc.h>

Inheritance diagram for LSpriteDesc:
LSpriteDesc2D LSpriteDesc3D LBaseObject

Public Member Functions

 LSpriteDesc ()
 Constructor. More...
 
 LSpriteDesc (UINT)
 Constructor. More...
 

Public Attributes

UINT m_nSpriteIndex = 0
 Sprite index.
 
UINT m_nCurrentFrame = 0
 Current animation frame.
 
float m_fXScale = 1.0f
 Horizontal scale.
 
float m_fYScale = 1.0f
 Vertical scale.
 
float m_fRoll = 0.0f
 Z-axis rotation.
 
XMFLOAT4 m_f4Tint = XMFLOAT4(1.0f, 1.0f, 1.0f, 1.0f)
 Color tint.
 
float m_fAlpha = 1.0f
 Alpha channel, 0.0f for transparent, 1.0f for opaque.
 

Detailed Description

Describes the sprite draw parameters shared by 2D and 3D sprites, even the obscure ones that aren't used very often (such as alpha and tint).

Constructor & Destructor Documentation

◆ LSpriteDesc() [1/2]

LSpriteDesc::LSpriteDesc ( )

Default constructor.

◆ LSpriteDesc() [2/2]

LSpriteDesc::LSpriteDesc ( UINT  n)

Constructor.

Parameters
nSprite index.