gdk-graphics 0a0aef92e917cfbac53dffbc32c295e4de914093
Loading...
Searching...
No Matches
gdk::graphics::null_camera Class Referencefinal
Inheritance diagram for gdk::graphics::null_camera:
Collaboration diagram for gdk::graphics::null_camera:

Public Member Functions

virtual void set_perspective_projection (const floating_point_type aFieldOfView, const floating_point_type aNear, const floating_point_type aFar, const floating_point_type aAspectRatio) override
 use a perspective projection with the given view volume
virtual void set_perspective_projection (const floating_point_type aFieldOfView, const floating_point_type aNear, const floating_point_type aFar, const floating_point_type aAspectRatio, const vector2_type &aShift) override
 use a perspective projection whose window is off the view's axis: an asymmetric frustum, as an eye of a stereo pair sees a screen both eyes converge on, or a panel of a tiled display sees its share
virtual void set_orthographic_projection (const vector2_type &aOrthographicSize, const floating_point_type aNear, const floating_point_type aFar, const floating_point_type aAspectRatio) override
 use an orthographic projection with the given view volume aOrthographicSize is the full extent of the volume, not its half extents
virtual void set_transform (const matrix4x4_type &aTransform) override
 sets the camera's world and view matrix
virtual void set_transform (const vector3_type &aWorldPos, const quaternion_type &aRotation) override
virtual void set_clear_color (const color &aColor) override
 sets the clear color, used to fill color buffer after it is cleared.
virtual void set_clear_mode (const clear_mode aClearMode) override
 clear mode decides which buffers to clear. see enum
virtual void set_viewport (const float aX, const float aY, const float aWidth, const float aHeight) override
 sets the normalized size and position of the viewport within the window
virtual void set_scissor (const float aX, const float aY, const float aWidth, const float aHeight) override
 clip this camera to a rectangle of the window without moving what it draws
virtual void clear_scissor () override
std::array< float, 4 > scissor () const
const vector3_type & position () const
const quaternion_type & rotation () const
const matrix4x4_type & transform () const
const color & clear_color () const
clear_mode mode () const
floating_point_type field_of_view () const
floating_point_type aspect_ratio () const
floating_point_type near_clip () const
floating_point_type far_clip () const

Additional Inherited Members

Public Types inherited from gdk::graphics::camera
enum class  clear_mode { nothing , color_and_depth , depth_only }
 controls which buffers in the active frame buffer object to clear More...

Member Function Documentation

◆ clear_scissor()

virtual void gdk::graphics::null_camera::clear_scissor ( )
overridevirtual

◆ set_clear_color()

virtual void gdk::graphics::null_camera::set_clear_color ( const color & acolor)
overridevirtual

sets the clear color, used to fill color buffer after it is cleared.

Implements gdk::graphics::camera.

◆ set_clear_mode()

virtual void gdk::graphics::null_camera::set_clear_mode ( const clear_mode aClearMode)
overridevirtual

clear mode decides which buffers to clear. see enum

Implements gdk::graphics::camera.

◆ set_orthographic_projection()

virtual void gdk::graphics::null_camera::set_orthographic_projection ( const vector2_type & aOrthographicSize,
const floating_point_type aNearClippingPlane,
const floating_point_type aFarClippingPlane,
const floating_point_type aViewportAspectRatio )
overridevirtual

use an orthographic projection with the given view volume aOrthographicSize is the full extent of the volume, not its half extents

Implements gdk::graphics::camera.

◆ set_perspective_projection() [1/2]

virtual void gdk::graphics::null_camera::set_perspective_projection ( const floating_point_type aFieldOfView,
const floating_point_type aNearClippingPlane,
const floating_point_type aFarClippingPlane,
const floating_point_type aViewportAspectRatio )
overridevirtual

use a perspective projection with the given view volume

Parameters
aFieldOfViewvertical field of view, in radians
aNearClippingPlanedistance to the near plane; must be > 0
aFarClippingPlanedistance to the far plane; must be > aNearClippingPlane
aViewportAspectRatiowidth divided by height

Implements gdk::graphics::camera.

◆ set_perspective_projection() [2/2]

virtual void gdk::graphics::null_camera::set_perspective_projection ( const floating_point_type aFieldOfView,
const floating_point_type aNearClippingPlane,
const floating_point_type aFarClippingPlane,
const floating_point_type aViewportAspectRatio,
const vector2_type & aShift )
overridevirtual

use a perspective projection whose window is off the view's axis: an asymmetric frustum, as an eye of a stereo pair sees a screen both eyes converge on, or a panel of a tiled display sees its share

Parameters
aShifthow far the window's centre is from the axis, as a share of the window's half extents: {0, 0} is the symmetric projection above; {0.25, 0} moves the window a quarter of its half width to the right, so what is on the axis is drawn that far left of the centre

Implements gdk::graphics::camera.

◆ set_scissor()

virtual void gdk::graphics::null_camera::set_scissor ( const float aX,
const float aY,
const float aWidth,
const float aHeight )
overridevirtual

clip this camera to a rectangle of the window without moving what it draws

Implements gdk::graphics::screen_camera.

◆ set_transform() [1/2]

virtual void gdk::graphics::null_camera::set_transform ( const matrix4x4_type & aMatrix)
overridevirtual

sets the camera's world and view matrix

Implements gdk::graphics::camera.

◆ set_transform() [2/2]

virtual void gdk::graphics::null_camera::set_transform ( const vector3_type & aWorldPos,
const quaternion_type & aRotation )
overridevirtual

Implements gdk::graphics::camera.

◆ set_viewport()

virtual void gdk::graphics::null_camera::set_viewport ( const float aX,
const float aY,
const float aWidth,
const float aHeight )
overridevirtual

sets the normalized size and position of the viewport within the window

Viewports that meet share their edge exactly: a pixel is drawn by one of them, never by neither

Implements gdk::graphics::screen_camera.


The documentation for this class was generated from the following file: