mirror of
https://github.com/raysan5/raylib.git
synced 2026-06-28 21:01:23 +08:00
rlgl.h: glint64 did not exist before OpenGL 3.2 (#4284)
Some checks are pending
Android / build (arm64) (push) Waiting to run
Android / build (x86_64) (push) Waiting to run
CMakeBuilds / Windows Build (push) Waiting to run
CMakeBuilds / Linux Build (push) Waiting to run
Linux / build (i386, i386, /user/bin, 32) (push) Waiting to run
Linux / build (x86_64, amd64, /user/bin, 64) (push) Waiting to run
Linux Examples / build (push) Waiting to run
macOS / build (push) Waiting to run
Parse raylib_api / build (push) Waiting to run
WebAssembly / build (push) Waiting to run
Windows / build (i686, pe-i386, 32, mingw-w64) (push) Waiting to run
Windows / build (x64, x64, 64, msvc16) (push) Waiting to run
Windows / build (x86, Win32, 32, msvc16) (push) Waiting to run
Windows / build (x86_64, pe-x86-64, 64, mingw-w64) (push) Waiting to run
Windows Examples / build (push) Waiting to run
Some checks are pending
Android / build (arm64) (push) Waiting to run
Android / build (x86_64) (push) Waiting to run
CMakeBuilds / Windows Build (push) Waiting to run
CMakeBuilds / Linux Build (push) Waiting to run
Linux / build (i386, i386, /user/bin, 32) (push) Waiting to run
Linux / build (x86_64, amd64, /user/bin, 64) (push) Waiting to run
Linux Examples / build (push) Waiting to run
macOS / build (push) Waiting to run
Parse raylib_api / build (push) Waiting to run
WebAssembly / build (push) Waiting to run
Windows / build (i686, pe-i386, 32, mingw-w64) (push) Waiting to run
Windows / build (x64, x64, 64, msvc16) (push) Waiting to run
Windows / build (x86, Win32, 32, msvc16) (push) Waiting to run
Windows / build (x86_64, pe-x86-64, 64, mingw-w64) (push) Waiting to run
Windows Examples / build (push) Waiting to run
Compilation breaks on rlgl.h for early OpenGL versions. Glint64 did not exist on those versions (< OpenGL 3.2)
This commit is contained in:
parent
0c06a08e07
commit
d314afc451
@ -4414,14 +4414,14 @@ void rlUpdateShaderBuffer(unsigned int id, const void *data, unsigned int dataSi
|
||||
// Get SSBO buffer size
|
||||
unsigned int rlGetShaderBufferSize(unsigned int id)
|
||||
{
|
||||
GLint64 size = 0;
|
||||
|
||||
#if defined(GRAPHICS_API_OPENGL_43)
|
||||
GLint64 size = 0;
|
||||
glBindBuffer(GL_SHADER_STORAGE_BUFFER, id);
|
||||
glGetBufferParameteri64v(GL_SHADER_STORAGE_BUFFER, GL_BUFFER_SIZE, &size);
|
||||
#endif
|
||||
|
||||
return (size > 0)? (unsigned int)size : 0;
|
||||
#else
|
||||
return 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
// Read SSBO buffer data (GPU->CPU)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user