JNGL
Easy to use cross-platform 2D game library
|
Fragment or vertex GLSL shader. More...
#include <jngl/Shader.hpp>
Public Types | |
enum class | Type : uint8_t { VERTEX , FRAGMENT } |
Type of a Shader. To link a ShaderProgram, one shader of each type is needed. More... | |
Public Member Functions | |
Shader (const char *source, Type, const char *gles20Source=nullptr) | |
Creates a vertex or fragment shader by compiling it. | |
Shader (const std::istream &source, Type) | |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. | |
Shader (const std::istream &source, Type, const std::istream &gles20Source) | |
Shader (const Shader &)=delete | |
Shader (Shader &&)=delete | |
Shader & | operator= (const Shader &)=delete |
Shader & | operator= (Shader &&)=delete |
Friends | |
class | ShaderProgram |
Fragment or vertex GLSL shader.
Definition at line 12 of file Shader.hpp.
|
strong |
Type of a Shader. To link a ShaderProgram, one shader of each type is needed.
Definition at line 15 of file Shader.hpp.
Creates a vertex or fragment shader by compiling it.
source | Source code using either GLSL v3.30 or GLSL ES v3.00. |
gles20Source | Source code using GLSL v1.00 for OpenGL ES 2.0 |
Shader | ( | const std::istream & | source, |
Type | ) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
|
friend |
Definition at line 43 of file Shader.hpp.