summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAntonio Jose Ramos Marquez <[email protected]>2021-05-08 18:24:14 +0200
committerGitHub <[email protected]>2021-05-08 18:24:14 +0200
commit2565c011580fda074e0f3dceacd5e6a1476b3284 (patch)
tree852dab8ea709f95bb91603679a112e53f72beaed
parent133e6f097d9c088c36100cc1cd1d0773daf8e19b (diff)
downloadraylib-2565c011580fda074e0f3dceacd5e6a1476b3284.tar.gz
raylib-2565c011580fda074e0f3dceacd5e6a1476b3284.zip
check for vao extension (#1757)
-rw-r--r--src/rlgl.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/rlgl.h b/src/rlgl.h
index b3eddf0c..c60a2a70 100644
--- a/src/rlgl.h
+++ b/src/rlgl.h
@@ -3141,7 +3141,10 @@ unsigned int rlLoadVertexArray(void)
{
unsigned int vaoId = 0;
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
- glGenVertexArrays(1, &vaoId);
+ if (RLGL.ExtSupported.vao)
+ {
+ glGenVertexArrays(1, &vaoId);
+ }
#endif
return vaoId;
}