summaryrefslogtreecommitdiffhomepage
path: root/src/rlgl.h
diff options
context:
space:
mode:
authorRay <[email protected]>2021-08-16 19:23:06 +0200
committerRay <[email protected]>2021-08-16 19:23:06 +0200
commit92a13878dce2962fa0c701ff69ea2de3cbeeaeab (patch)
treec6dc290501180d3b4b4b3c5f1d10f50ace9334c4 /src/rlgl.h
parent1b4c58b66f670b521d2f707b3fa1be860738b33a (diff)
downloadraylib-92a13878dce2962fa0c701ff69ea2de3cbeeaeab.tar.gz
raylib-92a13878dce2962fa0c701ff69ea2de3cbeeaeab.zip
Add some comments
Diffstat (limited to 'src/rlgl.h')
-rw-r--r--src/rlgl.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/rlgl.h b/src/rlgl.h
index 3c995c79..45d44b16 100644
--- a/src/rlgl.h
+++ b/src/rlgl.h
@@ -3431,6 +3431,10 @@ unsigned int rlLoadShaderCode(const char *vsCode, const char *fsCode)
if (vsCode != NULL) vertexShaderId = rlCompileShader(vsCode, GL_VERTEX_SHADER);
if (fsCode != NULL) fragmentShaderId = rlCompileShader(fsCode, GL_FRAGMENT_SHADER);
+
+ // Get the size of compiled shaders (not available on OpenGL ES 2.0)
+ //GLint binarySize = 0;
+ //glGetProgramiv(programId, GL_PROGRAM_BINARY_LENGTH, &binarySize);
if ((vertexShaderId == RLGL.State.defaultVShaderId) && (fragmentShaderId == RLGL.State.defaultFShaderId)) id = RLGL.State.defaultShaderId;
else
@@ -3467,7 +3471,7 @@ unsigned int rlLoadShaderCode(const char *vsCode, const char *fsCode)
{
int namelen = -1;
int num = -1;
- char name[256]; // Assume no variable names longer than 256
+ char name[256] = { 0 }; // Assume no variable names longer than 256
GLenum type = GL_ZERO;
// Get the name of the uniforms