- disabled palette emulation for the GLES backend.

Right now the shader does not support it and will require significant redesign to work well with the target hardware.
This commit is contained in:
Christoph Oelckers 2021-10-13 00:09:18 +02:00
parent a358cf8516
commit 8d9d3d5f8f
2 changed files with 4 additions and 2 deletions

View file

@ -53,6 +53,7 @@
#include "gamehud.h"
EXTERN_CVAR(Bool, cl_capfps)
EXTERN_CVAR(Int, vid_preferbackend)
PalEntry GlobalMapFog;
float GlobalFogDensity = 350.f;
@ -118,7 +119,7 @@ void RenderViewpoint(FRenderViewpoint& mainvp, IntRect* bounds, float fov, float
auto vrmode = VRMode::GetVRMode(mainview && toscreen);
const int eyeCount = vrmode->mEyeCount;
screen->FirstEye();
hw_int_useindexedcolortextures = eyeCount > 1? false : *hw_useindexedcolortextures;
hw_int_useindexedcolortextures = eyeCount > 1 || vid_preferbackend == 3? false : *hw_useindexedcolortextures;
for (int eye_ix = 0; eye_ix < eyeCount; ++eye_ix)
{

View file

@ -54,6 +54,7 @@
#include "gamehud.h"
CVARD(Bool, hw_hightile, true, CVAR_ARCHIVE | CVAR_GLOBALCONFIG, "enable/disable hightile texture rendering")
EXTERN_CVAR(Int, vid_preferbackend)
bool hw_int_useindexedcolortextures;
CUSTOM_CVARD(Bool, hw_useindexedcolortextures, false, CVAR_ARCHIVE | CVAR_GLOBALCONFIG, "enable/disable indexed color texture rendering")
{
@ -98,7 +99,7 @@ void GLInstance::DoDraw()
if (rendercommands.Size() > 0)
{
if (!useMapFog) hw_int_useindexedcolortextures = hw_useindexedcolortextures;
if (!useMapFog && vid_preferbackend != 3) hw_int_useindexedcolortextures = hw_useindexedcolortextures;
lastState.Flags = ~rendercommands[0].StateFlags; // Force ALL flags to be considered 'changed'.
lastState.DepthFunc = INT_MIN; // Something totally invalid.