gdk-graphics 0a0aef92e917cfbac53dffbc32c295e4de914093
Loading...
Searching...
No Matches
screen_camera.h
1// © Joseph Cameron - MIT License
2
3#ifndef GDK_GRAPHICS_SCREEN_CAMERA_H
4#define GDK_GRAPHICS_SCREEN_CAMERA_H
5
6#include <gdk/graphics/camera.h>
7#include <gdk/graphics/color.h>
8#include <gdk/graphics/types.h>
9
10namespace gdk::graphics {
12 class screen_camera : public camera {
13 public:
17 virtual void set_viewport(const float aX,
18 const float aY,
19 const float aWidth,
20 const float aHeight) = 0;
21
23 virtual void set_scissor(const float aX,
24 const float aY,
25 const float aWidth,
26 const float aHeight) = 0;
27
28 virtual void clear_scissor() = 0;
29
30 virtual ~screen_camera() = default;
31 };
32}
33
34#endif
35
a point of view a scene is drawn from. A camera starts at the origin looking down -Z,...
Definition camera.h:12
Position, orientation and perspective from which entity(s) are drawn.
Definition screen_camera.h:12
virtual void set_viewport(const float aX, const float aY, const float aWidth, const float aHeight)=0
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)=0
clip this camera to a rectangle of the window without moving what it draws