From 8ad8165816929301a87e90bbb32c3df6b69030ee Mon Sep 17 00:00:00 2001 From: Yann Herklotz Date: Sat, 2 Sep 2017 12:28:11 +0100 Subject: Updating docs --- glslprogram_8hpp_source.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'glslprogram_8hpp_source.html') diff --git a/glslprogram_8hpp_source.html b/glslprogram_8hpp_source.html index fddbe2a0..d042cf8a 100644 --- a/glslprogram_8hpp_source.html +++ b/glslprogram_8hpp_source.html @@ -29,7 +29,7 @@
YAGE -  0.02 +  v0.1.1
Yet Another Game Engine
@@ -85,7 +85,7 @@ $(document).ready(function(){initNavTree('glslprogram_8hpp_source.html','');});
glslprogram.hpp
-Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
2  * glslprogram.hpp
3  *
4  * Copyright (c) 2017 Yann Herklotz Grave <ymherklotz@gmail.com> -- MIT License
5  * See file LICENSE for more details
6  * ----------------------------------------------------------------------------
7  */
8 
9 #ifndef GLSL_PROGRAM_HPP
10 #define GLSL_PROGRAM_HPP
11 
12 #include <GL/glew.h>
13 
14 #include <string>
15 
16 namespace yage
17 {
18 
20 {
21 private:
23  GLuint program_id_ = 0;
24  GLuint vertex_shader_id_ = 0;
25  GLuint fragment_shader_id_ = 0;
27 
29  void compileShader(const GLuint &shader, const std::string &file_path);
30 
31 public:
32  GlslProgram() = default;
33  GlslProgram(const GlslProgram &) = delete;
34  GlslProgram(GlslProgram &&) = delete;
35  ~GlslProgram();
36 
37  GlslProgram &operator=(const GlslProgram &) = delete;
38  GlslProgram &operator=(GlslProgram &&) = delete;
39 
41  void compileShaders(const std::string &vertex_shader_path,
42  const std::string &fragment_shader_path);
43  void linkShaders();
44  void addAttribute(const std::string &attribute_name);
45  GLint getUniformLocation(const std::string &uniform_name);
46  void use();
47  void unuse();
48 };
49 
50 } // yage
51 
52 #endif
void unuse()
Definition: glslprogram.cpp:154
+Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
2  * glslprogram.hpp
3  *
4  * Copyright (c) 2017 Yann Herklotz Grave <ymherklotz@gmail.com> -- MIT License
5  * See file LICENSE for more details
6  * ----------------------------------------------------------------------------
7  */
8 
9 #ifndef GLSL_PROGRAM_HPP
10 #define GLSL_PROGRAM_HPP
11 
12 #include <GL/glew.h>
13 
14 #include <string>
15 
16 namespace yage
17 {
18 
20 {
21 private:
23  GLuint program_id_ = 0;
24  GLuint vertex_shader_id_ = 0;
25  GLuint fragment_shader_id_ = 0;
27 
29  void compileShader(const GLuint &shader, const std::string &file_path);
30 
31 public:
32  GlslProgram() = default;
33  GlslProgram(const GlslProgram &) = delete;
34  GlslProgram(GlslProgram &&) = delete;
35  ~GlslProgram();
36 
37  GlslProgram &operator=(const GlslProgram &) = delete;
38  GlslProgram &operator=(GlslProgram &&) = delete;
39 
41  void compileShaders(const std::string &vertex_shader_path,
42  const std::string &fragment_shader_path);
43  void linkShaders();
44  void addAttribute(const std::string &attribute_name);
45  GLint getUniformLocation(const std::string &uniform_name);
46  void use();
47  void unuse();
48 };
49 
50 } // namespace yage
51 
52 #endif
void unuse()
Definition: glslprogram.cpp:154
int attribute_index_
Definition: glslprogram.hpp:26
Definition: glslprogram.hpp:19
void compileShaders(const std::string &vertex_shader_path, const std::string &fragment_shader_path)
compiles vertex and fragment shader
Definition: glslprogram.cpp:75
@@ -97,7 +97,7 @@ $(document).ready(function(){initNavTree('glslprogram_8hpp_source.html','');});
void addAttribute(const std::string &attribute_name)
Definition: glslprogram.cpp:131
void compileShader(const GLuint &shader, const std::string &file_path)
compiles one shader
Definition: glslprogram.cpp:34
void use()
Definition: glslprogram.cpp:146
-
Templated matrix class.
Definition: camera2d.hpp:17
+
Project namespace.
Definition: body.cpp:13
GLuint vertex_shader_id_
Definition: glslprogram.hpp:24
GlslProgram & operator=(const GlslProgram &)=delete
GLint getUniformLocation(const std::string &uniform_name)
Definition: glslprogram.cpp:137
@@ -107,7 +107,7 @@ $(document).ready(function(){initNavTree('glslprogram_8hpp_source.html','');});