Open infapi00 opened 4 years ago
Confirmed this issue when compiling and running on Raspberry Pi 4 with Vulkan drivers on Manjaro Linux. Applied patch to source, recompiled, and issue was resolved. Confirmed fix.
Thanks for the bug report. I do not think OpenGL2 is the main focus of this project. After all there are alternatives ports (such as Quake3e) that has much better support for OpenGL2 renderer. IMHO vkQuake3 should remove OpenGL2 renderer
Not sure if the glrenderer2 is maintained, but just in case.
When testing with a opengl2 driver it fails during shader compilation due this error:
0:253(14): error: no function with name 'textureCubeLod'
That function has been changing names through glsl versions, and there is some code at GLSL_GetHeader to handle that:
For our case, it goes through the second else, as on opengl 2.1, it was using GLSL 1.20 so the name was textureCubeLod. But the problem is that on GLSL 1.20 core that function is available but only for vertex shaders. To be used on fragment shaders, it is needed the extension GL_ARB_shader_texture_lod. So a quick workaround (tested and working) would be the following one:
But again, that is a workaround, as we need to check if that extension is available (skimming I see some extension-handling code at tr_extensions.c), and probably something else that Im missing. Also again, not sure if there is a real interest to maintain the non-vulkan renderers.
The specific device tested was the rpi4, which Mesa OpenGL driver exposes 2.1 (as a embedded device, it is more focused on GLES).