3DRadSpace 0.1.0Alpha
3DRadSpace is a free, simple to use, rapid application development game engine.
Loading...
Searching...
No Matches
Engine3DRadSpace.Graphics.Viewport Struct Reference

Represents a screen viewport for rendering. More...

#include <Viewport.hpp>

Public Member Functions

 Viewport (Internal.RectangleF r, float mind, float maxd)
 Viewport ()=default
 Viewport (Math::RectangleF r, float mind, float maxd)
Math::Vector3 Unproject (const Math::Vector3 &source, const Math::Matrix4x4 &projection, const Math::Matrix4x4 &view, const Math::Matrix4x4 &world) const
 Unprojects a screen space point to world space using the given projection, view and world matrices.

Public Attributes

Internal.RectangleF ScreenRectangle
float MinDepth = 0.0f
 Minimal depth value of this viewport. Default is 0.0f.
float MaxDepth = 1.0f
 Maximum depth value of this viewport. Default is 1.0f.
Math::RectangleF ScreenRectangle
 Screen coordinates of this viewport.

Detailed Description

Represents a screen viewport for rendering.

Constructor & Destructor Documentation

◆ Viewport() [1/3]

Engine3DRadSpace.Graphics.Viewport.Viewport ( Internal.RectangleF r,
float mind,
float maxd )
inline

◆ Viewport() [2/3]

◆ Viewport() [3/3]

Member Function Documentation

◆ Unproject()

Vector3 Viewport::Unproject ( const Math::Vector3 & source,
const Math::Matrix4x4 & projection,
const Math::Matrix4x4 & view,
const Math::Matrix4x4 & world ) const

Unprojects a screen space point to world space using the given projection, view and world matrices.

Parameters
sourceThe screen space point to unproject.
projectionThe projection matrix.
viewThe view matrix.
worldThe world matrix.
Returns
The unprojected world space point.

Member Data Documentation

◆ MaxDepth

float Engine3DRadSpace.Graphics.Viewport.MaxDepth = 1.0f

Maximum depth value of this viewport. Default is 1.0f.

◆ MinDepth

float Engine3DRadSpace.Graphics.Viewport.MinDepth = 0.0f

Minimal depth value of this viewport. Default is 0.0f.

◆ ScreenRectangle [1/2]

Internal.RectangleF Engine3DRadSpace.Graphics.Viewport.ScreenRectangle

◆ ScreenRectangle [2/2]


The documentation for this struct was generated from the following files: