This mainly targets OpenGL ES 2.0 but it also supports compiling GLSL as
ESSL 3.00. It's missing support for framebuffer objects which should be
possible on ES 2. (Though using renderbuffers instead of textures.)
opengl1 cvars that are not supported will display a message and disable
the cvar. This has not been reviewed for new opengl2 cvars. Enabling
cvars may cause rendering issues. Some of the broken cvars may be
possible to support using OpenGL ES 3 features.
The game displays okay with the default cvars.
Don't draw the world scene to a separate FBO from the rest of the
screen.
This fixes the world scene having HOM instead of seeing through to the
previously drawn content. World of Padman uses this to have a separate
3D scene for the sky and world in wop_padship for dynamic skybox.
This also makes r_ext_framebuffer_multisample apply to HUD models
instead of depending on r_ext_multisample (which doesn't work on Linux
with some Intel graphics).
GL_DEPTH_TEXTURE_MODE defaults to GL_LUMINANCE. Code sets it here as
part of a workaround old nvidia drivers (apparently? the URL in comment
is dead). GL_DEPTH_TEXTURE_MODE was removed in OpenGL 3.0 / 3.2 Core
contexts and may be treated as an error.
Using LUMINANCE with OpenGL 3.2 Core contex results in all images being
solid black (in the menu, world, and the console). In the end the whole
screen was solid black except the intro video.
Store images in RGB and RGBA instead. This doesn't affect r_grayscale
visually. If there is issues with it now possibly using compressed
formats, then it would already be an issue for r_grayscale 0.9.
Models don't have a surface limit; skins shouldn't either. Some player
models require more than 32 surfaces since vanilla Quake 3 did not
enforce the limit.
Skins are now limited to 256 surfaces because having no limit would
require parsing the skin file twice. The skin surfaces are dynamically
allocated so it doesn't increase memory usage when less surfaces
are used.
GL1's R_CreateImage sets GL texture to 0 before it ends, so border color is not
applied to the fog image. GL_CLAMP is not used for fog image (in either renderer),
so it would presumably not be used even if applied to the fog image.