3#ifndef GDK_GFX_WEBGL1ES2_SCREEN_CAMERA_H
4#define GDK_GFX_WEBGL1ES2_SCREEN_CAMERA_H
7#include <gdk/graphics_types.h>
8#include <gdk/screen_camera.h>
9#include <gdk/webgl1es2_camera.h>
10#include <gdk/webgl1es2_texture.h>
11#include <jfc/unique_handle.h>
29 const float aHeight)
override;
33 const float aNearClippingPlane,
34 const float aFarClippingPlane,
35 const float aViewportAspectRatio)
override;
40 const float aNearClippingPlane,
41 const float aFarClippingPlane,
42 const float aViewportAspectRatio)
override;
46 const gdk::graphics_quaternion_type &aRotation)
override;
47 virtual void set_transform(
const gdk::graphics_matrix4x4_type &aMatrix)
override;
60 void activate(
const gdk::graphics_intvector2_type& aFrameBufferSize)
const;
79 graphics_vector2_type m_ViewportPosition = graphics_vector2_type::Zero;
80 graphics_vector2_type m_ViewportSize = graphics_vector2_type(1, 1);
clear_mode
controls which buffers in the active frame buffer object to clear
Definition camera.h:13
represents an observable 3d object.
Definition entity.h:13
Position, orientation and perspective from which entity(s) are drawn.
Definition screen_camera.h:15
webgl1es2_camera(const webgl1es2_camera &a)=default
copy semantics
virtual void set_clear_mode(const gdk::camera::clear_mode aClearMode) override
clear mode decides which buffers to clear. see enum
void activate(const gdk::graphics_intvector2_type &aFrameBufferSize) const
activates this camera; mutates gl according to this camera's state
webgl1es2_screen_camera & operator=(webgl1es2_screen_camera &&a)=default
move semantics
webgl1es2_screen_camera()
constructs with reasonable default values
virtual void set_transform(const gdk::graphics_vector3_type &aWorldPos, const gdk::graphics_quaternion_type &aRotation) override
rebuilds the view matrix from a 3d position and rotation
webgl1es2_screen_camera & operator=(const webgl1es2_screen_camera &a)=default
copy semantics
webgl1es2_screen_camera(const webgl1es2_screen_camera &a)=default
copy semantics
virtual void set_perspective_projection(const float aFieldOfView, const float aNearClippingPlane, const float aFarClippingPlane, const float aViewportAspectRatio) override
sets the projection matrix to a perspective projection
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 of the window
virtual void set_orthographic_projection(const float aWidth, const float aHeight, const float aNearClippingPlane, const float aFarClippingPlane, const float aViewportAspectRatio) override
sets the projection matrix to an orthographic projection
webgl1es2_screen_camera(webgl1es2_screen_camera &&)=default
move semantics
virtual void set_clear_color(const gdk::color &acolor) override
sets the clear color, used to fill color buffer after it is cleared.
Represents a 4 channel color: {Red, Green, Blue, Alpha}. TODO: channel values should be limited to th...
Definition color.h:11