sdl_glimp: make ARB_separate_shader_objects an explicit hard requirement#1899
sdl_glimp: make ARB_separate_shader_objects an explicit hard requirement#1899
Conversation
|
This makes the engine display a proper warning instead of aborting with cryptic errors later like discussed in that issue: With this branch the engine catches the missing requirement and reports it properly: |
|
I don't think we use anything from that extension. The extension is about compiling a vertex shader by itself, or compiling a fragment shader by itself. The idea is to allow any (vertex shader, fragment shader) pair without having to recompile each possible combination. But we do it the old-fashioned way of compiling vertex + fragment together each time. It's true that GLES has a limitation of only allowing one compilation unit per shader, according to https://stackoverflow.com/a/33622131. But the multiple compilation units feature is part of basic desktop OpenGL and doesn't require an extension. |
Our code require
ARB_separate_shader_objects, so we should test for it explicitly.The
ARB_separate_shader_objectsextension is made required in OpenGL 4., but it only requires OpenGL 2.0 or ARB_shader_objects.Mesa provides it with all known desktop OpenGL drivers, including GL 2.1 ones.
GL4ES doesn't provide it despite providing OpenGL 2.1 over OpenGL ES because as far as I know GL ES doesn't provide such feature and then it doesn't translate.