C# Class Myre.Graphics.Quad

显示文件 Open project: TomGillen/Myre Class Usage Examples

Public Methods

Method Description
Draw ( ) : void

Draws this instance.

Draw ( Effect effect ) : void
Draw ( Myre.Graphics.Materials.Material material, BoxedValueStore parameters ) : void
Quad ( Microsoft.Xna.Framework.Graphics.GraphicsDevice device ) : System

Initializes a new instance of the Quad class.

SetPosition ( Rectangle screenCoordinates, float depth ) : void
SetPosition ( System.Numerics.Vector2 topLeft, System.Numerics.Vector2 bottomRight, float depth ) : void

Sets the poisition of this quad.

SetPosition ( float topLeftX = -1, float topLeftY = 1, float bottomRightX = 1, float bottomRightY = -1, float depth ) : void

Private Methods

Method Description
ToDeviceCoordinate ( float x, float y, System.Numerics.Vector2 resolution ) : System.Numerics.Vector2

Method Details

Draw() public method

Draws this instance.
public Draw ( ) : void
return void

Draw() public method

public Draw ( Effect effect ) : void
effect Microsoft.Xna.Framework.Graphics.Effect
return void

Draw() public method

public Draw ( Myre.Graphics.Materials.Material material, BoxedValueStore parameters ) : void
material Myre.Graphics.Materials.Material
parameters BoxedValueStore
return void

Quad() public method

Initializes a new instance of the Quad class.
public Quad ( Microsoft.Xna.Framework.Graphics.GraphicsDevice device ) : System
device Microsoft.Xna.Framework.Graphics.GraphicsDevice The graphics device.
return System

SetPosition() public method

public SetPosition ( Rectangle screenCoordinates, float depth ) : void
screenCoordinates Rectangle
depth float
return void

SetPosition() public method

Sets the poisition of this quad.
public SetPosition ( System.Numerics.Vector2 topLeft, System.Numerics.Vector2 bottomRight, float depth ) : void
topLeft System.Numerics.Vector2 The top left corner, in normalised device coordinates.
bottomRight System.Numerics.Vector2 The bottom right corner, in normalised device coordinates.
depth float The depth.
return void

SetPosition() public method

public SetPosition ( float topLeftX = -1, float topLeftY = 1, float bottomRightX = 1, float bottomRightY = -1, float depth ) : void
topLeftX float
topLeftY float
bottomRightX float
bottomRightY float
depth float
return void