GPU: make using the glsl basic-shader a flag
This allows for it to be more easily tested.
This commit is contained in:
@@ -51,8 +51,6 @@
|
||||
|
||||
/* State */
|
||||
|
||||
static const bool USE_GLSL = false;
|
||||
|
||||
static struct {
|
||||
GPUShader *cached_shaders[GPU_SHADER_OPTION_COMBINATIONS];
|
||||
bool failed_shaders[GPU_SHADER_OPTION_COMBINATIONS];
|
||||
@@ -269,6 +267,24 @@ const GLubyte stipple_hexagon[128] = {
|
||||
0x22, 0x22, 0x22, 0x22, 0x22, 0x22, 0x22, 0x22};
|
||||
/* ********************************************* */
|
||||
|
||||
/* GLSL State */
|
||||
|
||||
static bool USE_GLSL = false;
|
||||
|
||||
/**
|
||||
* \note this isn't part of the basic shader API,
|
||||
* only set from the command line once on startup.
|
||||
*/
|
||||
void GPU_basic_shader_use_glsl_set(bool enabled)
|
||||
{
|
||||
USE_GLSL = enabled;
|
||||
}
|
||||
|
||||
bool GPU_basic_shader_use_glsl_get(void)
|
||||
{
|
||||
return USE_GLSL;
|
||||
}
|
||||
|
||||
/* Init / exit */
|
||||
|
||||
void GPU_basic_shaders_init(void)
|
||||
|
Reference in New Issue
Block a user