C# Class MeshRenderer.Core.Zoom

Manages the current world to screen transformation
Mostrar archivo Open project: RegrowthStudios/VoxelRTS Class Usage Examples

Private Properties

Property Type Description

Public Methods

Method Description
Initialize ( Rectangle screen ) : void
Initialize ( Rectangle screen, BoundingBox world ) : void
ScreenToWorld ( float x, float y ) : PointF
Update ( BoundingBox world ) : void
ViewportContains ( float x, float y ) : bool
WorldToScreen ( float x, float y ) : PointF
Zoom ( ) : System
Zoom ( bool invertY ) : System
ZoomReset ( ) : void
ZoomUpdate ( int amount, float focusX, float focusY ) : bool

Zoom in or out of the viewport.

Method Details

Initialize() public method

public Initialize ( Rectangle screen ) : void
screen System.Drawing.Rectangle
return void

Initialize() public method

public Initialize ( Rectangle screen, BoundingBox world ) : void
screen System.Drawing.Rectangle
world BoundingBox
return void

ScreenToWorld() public method

public ScreenToWorld ( float x, float y ) : PointF
x float
y float
return System.Drawing.PointF

Update() public method

public Update ( BoundingBox world ) : void
world BoundingBox
return void

ViewportContains() public method

public ViewportContains ( float x, float y ) : bool
x float
y float
return bool

WorldToScreen() public method

public WorldToScreen ( float x, float y ) : PointF
x float
y float
return System.Drawing.PointF

Zoom() public method

public Zoom ( ) : System
return System

Zoom() public method

public Zoom ( bool invertY ) : System
invertY bool
return System

ZoomReset() public method

public ZoomReset ( ) : void
return void

ZoomUpdate() public method

Zoom in or out of the viewport.
public ZoomUpdate ( int amount, float focusX, float focusY ) : bool
amount int Zoom amount
focusX float Relative x point position
focusY float Relative y point position
return bool