C# Class WaveEngine.Components.Graphics2D.Sprite

Represents a 2D Image.
Inheritance: Component
Afficher le fichier Open project: WaveEngine/Components Class Usage Examples

Protected Properties

Свойство Type Description
disposed bool
texture Texture

Private Properties

Свойство Type Description
InitMaterial void
LoadTexture void
RefreshMaterialFromPath void
RefreshTexture void
UnloadTexture void

Méthodes publiques

Méthode Description
Dispose ( ) : void

Releases unmanaged and - optionally - managed resources.

Sprite ( ) : System

Initializes a new instance of the Sprite class based on a content file.

Sprite ( Material material ) : System

Initializes a new instance of the Sprite class based on a content file.

Sprite ( Texture texture ) : System

Initializes a new instance of the Sprite class based on a texture. See Texture for more information.

Sprite ( string texturePath ) : System

Initializes a new instance of the Sprite class based on a content file.

Méthodes protégées

Méthode Description
DefaultValues ( ) : void

The default values

Dispose ( bool disposing ) : void

Releases unmanaged and - optionally - managed resources

Initialize ( ) : void

Performs further custom initialization for this instance.

UpdateSourceRectangle ( ) : void

The update source rectangle.

Private Methods

Méthode Description
InitMaterial ( ) : void

Init material

LoadTexture ( ) : void

Load texture

RefreshMaterialFromPath ( ) : void

Init material

RefreshTexture ( ) : void

Refresh the sprite texture

UnloadTexture ( ) : void

Unload texture

Method Details

DefaultValues() protected méthode

The default values
protected DefaultValues ( ) : void
Résultat void

Dispose() public méthode

Releases unmanaged and - optionally - managed resources.
public Dispose ( ) : void
Résultat void

Dispose() protected méthode

Releases unmanaged and - optionally - managed resources
protected Dispose ( bool disposing ) : void
disposing bool /// true to release both managed and unmanaged resources; false to release only unmanaged resources. ///
Résultat void

Initialize() protected méthode

Performs further custom initialization for this instance.
protected Initialize ( ) : void
Résultat void

Sprite() public méthode

Initializes a new instance of the Sprite class based on a content file.
public Sprite ( ) : System
Résultat System

Sprite() public méthode

Initializes a new instance of the Sprite class based on a content file.
Material can not be null.
public Sprite ( Material material ) : System
material Material The material used to render the sprite.
Résultat System

Sprite() public méthode

Initializes a new instance of the Sprite class based on a texture. See Texture for more information.
Texture can not be null.
public Sprite ( Texture texture ) : System
texture Texture The texture.
Résultat System

Sprite() public méthode

Initializes a new instance of the Sprite class based on a content file.
TexturePath can not be null.
public Sprite ( string texturePath ) : System
texturePath string The texture path to the content file.
Résultat System

UpdateSourceRectangle() protected méthode

The update source rectangle.
Sprite has been disposed.
protected UpdateSourceRectangle ( ) : void
Résultat void

Property Details

disposed protected_oe property

The disposed
protected bool disposed
Résultat bool

texture protected_oe property

The sprite texture
protected Texture texture
Résultat Texture