From 0e5a826935cd1e5ef1e3061d029e2aafea038f47 Mon Sep 17 00:00:00 2001 From: Yann Herklotz Date: Tue, 26 Sep 2017 14:18:22 +0100 Subject: Adding --- camera2d_8h_source.html | 99 ++++++++++--------------------------------------- 1 file changed, 20 insertions(+), 79 deletions(-) (limited to 'camera2d_8h_source.html') diff --git a/camera2d_8h_source.html b/camera2d_8h_source.html index 4f4c0f8a..f78054a5 100644 --- a/camera2d_8h_source.html +++ b/camera2d_8h_source.html @@ -3,23 +3,22 @@ - + + YAGE: yage/base/camera2d.h Source File + + - @@ -28,7 +27,7 @@ -
+
YAGE  v0.1.1
@@ -39,40 +38,19 @@
- + - - + + + +
+
@@ -107,45 +85,7 @@ $(document).ready(function(){initNavTree('camera2d_8h_source.html','');});
camera2d.h
-Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
-
2  * camera2d.h
-
3  *
-
4  * Copyright (c) 2017 Yann Herklotz Grave <ymherklotz@gmail.com>
-
5  * MIT License, see LICENSE file for more details.
-
6  * ----------------------------------------------------------------------------
-
7  */
-
8 
-
9 #ifndef YAGE_CAMERA2D_H
-
10 #define YAGE_CAMERA2D_H
-
11 
-
12 #include "glslprogram.h"
-
13 
-
14 #include <glm/glm.hpp>
-
15 #include <glm/gtc/matrix_transform.hpp>
-
16 
-
17 namespace yage
-
18 {
-
19 
-
20 class Camera2D
-
21 {
-
22 private:
-
23  bool update_matrix_ = true;
-
24  float scale_ = 1;
-
25  glm::vec2 position_;
-
26  glm::mat4 camera_matrix_;
-
27  glm::mat4 ortho_matrix_;
-
28 
-
29 public:
-
30  Camera2D(int screen_width = 1280, int screen_height = 720);
-
31 
-
32  void update(GlslProgram &program);
-
33  void move(const glm::vec2 &direction);
-
34 };
-
35 
-
36 } // namespace yage
-
37 
-
38 #endif
-
glm::mat4 ortho_matrix_
Definition: camera2d.h:27
+Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
2  * camera2d.h
3  *
4  * Copyright (c) 2017 Yann Herklotz Grave <ymherklotz@gmail.com>
5  * MIT License, see LICENSE file for more details.
6  * ----------------------------------------------------------------------------
7  */
8 
9 #ifndef YAGE_CAMERA2D_H
10 #define YAGE_CAMERA2D_H
11 
12 #include "glslprogram.h"
13 
14 #include <glm/glm.hpp>
15 #include <glm/gtc/matrix_transform.hpp>
16 
17 namespace yage
18 {
19 
20 class Camera2D
21 {
22 private:
23  bool update_matrix_ = true;
24  float scale_ = 1;
25  glm::vec2 position_;
26  glm::mat4 camera_matrix_;
27  glm::mat4 ortho_matrix_;
28 
29 public:
30  Camera2D(int screen_width = 1280, int screen_height = 720);
31 
32  void update(GlslProgram &program);
33  void move(const glm::vec2 &direction);
34 };
35 
36 } // namespace yage
37 
38 #endif
glm::mat4 ortho_matrix_
Definition: camera2d.h:27
float scale_
Definition: camera2d.h:24
glm::mat4 camera_matrix_
Definition: camera2d.h:26
void update(GlslProgram &program)
Definition: camera2d.cpp:23
@@ -154,6 +94,7 @@ $(document).ready(function(){initNavTree('camera2d_8h_source.html','');});
glm::vec2 position_
Definition: camera2d.h:25
Definition: camera2d.h:20
+
Project namespace.
Definition: camera2d.cpp:13
void move(const glm::vec2 &direction)
Definition: camera2d.cpp:39
Camera2D(int screen_width=1280, int screen_height=720)
Definition: camera2d.cpp:16
@@ -162,9 +103,9 @@ $(document).ready(function(){initNavTree('camera2d_8h_source.html','');}); -- cgit