C# Class Sharpex2D.Rendering.OpenGL.OpenGLRenderer

Inheritance: IRenderer, IDisposable
Afficher le fichier Open project: ThuCommix/Sharpex2D

Méthodes publiques

Méthode Description
Begin ( ) : void

Begins the draw operation.

CreateResource ( string fontFamily, float size, TextAccessoire accessoire ) : IFont

Creates a new Resource.

CreateResource ( int width, int height ) : ITexture

Creates a new Resource.

CreateResource ( string path ) : ITexture

Creates a new Resource.

Dispose ( ) : void

Disposes the object.

DrawString ( string text, IFont font, Rectangle rectangle, Color color ) : void

Draws a string.

DrawString ( string text, IFont font, Vector2 position, Color color ) : void

Draws a string.

DrawTexture ( ITexture texture, Rectangle rectangle, Color color, float opacity = 1 ) : void

Draws a Texture.

DrawTexture ( ITexture texture, Rectangle source, Rectangle destination, Color color, float opacity = 1 ) : void

Draws a Texture.

DrawTexture ( ITexture texture, SpriteSheet spriteSheet, Rectangle rectangle, Color color, float opacity = 1 ) : void

Draws a Texture.

DrawTexture ( ITexture texture, SpriteSheet spriteSheet, Vector2 position, Color color, float opacity = 1 ) : void

Draws a Texture.

DrawTexture ( ITexture texture, Vector2 position, Color color, float opacity = 1 ) : void

Draws a Texture.

End ( ) : void

Ends the draw operation.

Initialize ( ) : void

Initializes the renderer.

MeasureString ( string text, IFont font ) : Vector2

Measures the string.

OpenGLRenderer ( ) : System

Initializes a new OpenGLRenderer class.

ResetTransform ( ) : void

Resets the Transform.

SetTransform ( Matrix2x3 matrix ) : void

Sets the Transform.

Méthodes protégées

Méthode Description
Dispose ( bool disposing ) : void

Disposes the object.

Private Methods

Méthode Description
GraphicsDeviceClearColorChanged ( object sender, EventArgs e ) : void

Triggered if the clear color changed.

WindowScreenSizeChanged ( object sender, EventArgs e ) : void

Triggered if the screen size changed.

Method Details

Begin() public méthode

Begins the draw operation.
public Begin ( ) : void
Résultat void

CreateResource() public méthode

Creates a new Resource.
public CreateResource ( string fontFamily, float size, TextAccessoire accessoire ) : IFont
fontFamily string The FontFamily.
size float The Size.
accessoire TextAccessoire The TextAccessoire.
Résultat IFont

CreateResource() public méthode

Creates a new Resource.
public CreateResource ( int width, int height ) : ITexture
width int The Width.
height int The Height.
Résultat ITexture

CreateResource() public méthode

Creates a new Resource.
public CreateResource ( string path ) : ITexture
path string The Path.
Résultat ITexture

Dispose() public méthode

Disposes the object.
public Dispose ( ) : void
Résultat void

Dispose() protected méthode

Disposes the object.
protected Dispose ( bool disposing ) : void
disposing bool The disposing state.
Résultat void

DrawString() public méthode

Draws a string.
public DrawString ( string text, IFont font, Rectangle rectangle, Color color ) : void
text string The Text.
font IFont The Font.
rectangle Sharpex2D.Math.Rectangle The Rectangle.
color Color The Color.
Résultat void

DrawString() public méthode

Draws a string.
public DrawString ( string text, IFont font, Vector2 position, Color color ) : void
text string The Text.
font IFont The Font.
position Vector2 The Position.
color Color The Color.
Résultat void

DrawTexture() public méthode

Draws a Texture.
public DrawTexture ( ITexture texture, Rectangle rectangle, Color color, float opacity = 1 ) : void
texture ITexture The Texture.
rectangle Sharpex2D.Math.Rectangle The Rectangle.
color Color The Color.
opacity float The Opacity.
Résultat void

DrawTexture() public méthode

Draws a Texture.
public DrawTexture ( ITexture texture, Rectangle source, Rectangle destination, Color color, float opacity = 1 ) : void
texture ITexture The Texture.
source Sharpex2D.Math.Rectangle The SourceRectangle.
destination Sharpex2D.Math.Rectangle The DestinationRectangle.
color Color The Color.
opacity float The Opacity.
Résultat void

DrawTexture() public méthode

Draws a Texture.
public DrawTexture ( ITexture texture, SpriteSheet spriteSheet, Rectangle rectangle, Color color, float opacity = 1 ) : void
texture ITexture The Texture.
spriteSheet SpriteSheet The SpriteSheet.
rectangle Sharpex2D.Math.Rectangle The Rectangle.
color Color The Color.
opacity float The Opacity.
Résultat void

DrawTexture() public méthode

Draws a Texture.
public DrawTexture ( ITexture texture, SpriteSheet spriteSheet, Vector2 position, Color color, float opacity = 1 ) : void
texture ITexture The Texture.
spriteSheet SpriteSheet The SpriteSheet.
position Vector2 The Position.
color Color The Color.
opacity float The Opacity.
Résultat void

DrawTexture() public méthode

Draws a Texture.
public DrawTexture ( ITexture texture, Vector2 position, Color color, float opacity = 1 ) : void
texture ITexture The Texture.
position Vector2 The Position.
color Color The Color.
opacity float The Opacity.
Résultat void

End() public méthode

Ends the draw operation.
public End ( ) : void
Résultat void

Initialize() public méthode

Initializes the renderer.
public Initialize ( ) : void
Résultat void

MeasureString() public méthode

Measures the string.
public MeasureString ( string text, IFont font ) : Vector2
text string The String.
font IFont The Font.
Résultat Vector2

OpenGLRenderer() public méthode

Initializes a new OpenGLRenderer class.
public OpenGLRenderer ( ) : System
Résultat System

ResetTransform() public méthode

Resets the Transform.
public ResetTransform ( ) : void
Résultat void

SetTransform() public méthode

Sets the Transform.
public SetTransform ( Matrix2x3 matrix ) : void
matrix Sharpex2D.Math.Matrix2x3 The Matrix.
Résultat void