aboutsummaryrefslogtreecommitdiff
path: root/src/libjin/graphics/shaders/je_shader.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/libjin/graphics/shaders/je_shader.h')
-rw-r--r--src/libjin/graphics/shaders/je_shader.h30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/libjin/graphics/shaders/je_shader.h b/src/libjin/graphics/shaders/je_shader.h
index 6a2db9c..92e1c4c 100644
--- a/src/libjin/graphics/shaders/je_shader.h
+++ b/src/libjin/graphics/shaders/je_shader.h
@@ -52,7 +52,7 @@ namespace JinEngine
/// @param name Name of the uniform variable to be assigned.
/// @param number Value of uniform variable to be sent.
///
- void sendFloat(const char* name, float number);
+ Shader& sendFloat(const char* name, float number);
///
/// Send texture to shader.
@@ -60,7 +60,7 @@ namespace JinEngine
/// @param name Name of the uniform variable to be assigned.
/// @param texture Texture to be sent.
///
- void sendTexture(const char* name, const Texture* texture);
+ Shader& sendTexture(const char* name, const Texture* texture);
///
/// Send integer value to shader
@@ -68,7 +68,7 @@ namespace JinEngine
/// @param name Name of the uniform variable to be assigned.
/// @param value Value to be sent.
///
- void sendInt(const char* name, int value);
+ Shader& sendInt(const char* name, int value);
///
/// Send 2D vector to shader.
@@ -77,7 +77,7 @@ namespace JinEngine
/// @param x X value of the vector to be sent.
/// @param y Y value of the vector to be sent.
///
- void sendVec2(const char* name, float x, float y);
+ Shader& sendVec2(const char* name, float x, float y);
///
/// Send 3D vector to shader.
@@ -87,7 +87,7 @@ namespace JinEngine
/// @param y Y value of the vector to be sent.
/// @param z Z value of the vector to be sent.
///
- void sendVec3(const char* name, float x, float y, float z);
+ Shader& sendVec3(const char* name, float x, float y, float z);
///
/// Send 4D vector to shader.
@@ -98,7 +98,7 @@ namespace JinEngine
/// @param z Z value of the vector to be sent.
/// @param w W value of the vector to be sent.
///
- void sendVec4(const char* name, float x, float y, float z, float w);
+ Shader& sendVec4(const char* name, float x, float y, float z, float w);
///
/// Send canvas to shader.
@@ -106,7 +106,7 @@ namespace JinEngine
/// @param name Name of the uniform variable to be assigned.
/// @param canvas Canvas to be sent.
///
- void sendCanvas(const char* name, const Canvas* canvas);
+ Shader& sendCanvas(const char* name, const Canvas* canvas);
///
/// Send color to shader.
@@ -114,7 +114,7 @@ namespace JinEngine
/// @param name Name of the uniform variable to be assigned.
/// @param color Color to be sent.
///
- void sendColor(const char* name, const Color* color);
+ Shader& sendColor(const char* name, const Color* color);
///
/// Send 4 by 4 matrix to shader.
@@ -122,7 +122,7 @@ namespace JinEngine
/// @param name Name of the uniform variable to be assigned.
/// @param mat4 Matrix to be sent.
///
- void sendMatrix4(const char* name, const Math::Matrix* mat4);
+ Shader& sendMatrix4(const char* name, const Math::Matrix* mat4);
///
/// Set vertices value.
@@ -132,7 +132,7 @@ namespace JinEngine
/// @param stride Byte offset between consecutive generic vertex attributes.
/// @param pointers Pointer to the first component of the first generic vertex attribute in the array.
///
- void uploadVertices(int n, GLenum type, GLsizei stride, const GLvoid * pointers, GLboolean normalized = GL_FALSE);
+ Shader& uploadVertices(int n, GLenum type, GLsizei stride, const GLvoid * pointers, GLboolean normalized = GL_FALSE);
///
/// Set texture UV coordinates.
@@ -142,27 +142,27 @@ namespace JinEngine
/// @param stride Byte offset between consecutive generic vertex attributes.
/// @param pointers Pointer to the first component of the first generic vertex attribute in the array.
///
- void uploadUV(int n, GLenum type, GLsizei stride, const GLvoid * pointers, GLboolean normalized = GL_FALSE);
+ Shader& uploadUV(int n, GLenum type, GLsizei stride, const GLvoid * pointers, GLboolean normalized = GL_FALSE);
///
/// Upload vertex color array.
///
- void uploadColor(int n, GLenum type, GLsizei stride, const GLvoid * pointers, GLboolean normalized = GL_FALSE);
+ Shader& uploadColor(int n, GLenum type, GLsizei stride, const GLvoid * pointers, GLboolean normalized = GL_FALSE);
///
/// Set attribute.
///
- void uploadAttribute(const String& name, int n, GLenum type, GLsizei stride, const GLvoid * pointers, GLboolean normalized = GL_FALSE);
+ Shader& uploadAttribute(const String& name, int n, GLenum type, GLsizei stride, const GLvoid * pointers, GLboolean normalized = GL_FALSE);
///
/// Reset attribute index.
///
- void beginUploadAttributes();
+ Shader& beginUploadAttributes();
///
/// Reset attribute index.
///
- void endUploadAttributes();
+ Shader& endUploadAttributes();
///
/// Program ID.