summaryrefslogtreecommitdiff
path: root/src/gfxinit.cpp
diff options
context:
space:
mode:
authorMichael Lutz <michi@icosahedron.de>2021-01-16 16:43:25 +0100
committerMichael Lutz <michi@icosahedron.de>2021-02-22 22:16:07 +0100
commite8fc050b6eebddaadf10563c3764ee455687559d (patch)
treed55490546e66f56ac85fcc7ce64842d8c93b9def /src/gfxinit.cpp
parent320072c8dc03d651f8278a41fc09346c8ed5a174 (diff)
downloadopenttd-e8fc050b6eebddaadf10563c3764ee455687559d.tar.xz
Add: [OpenGL] Support for 8bpp blitters.
Diffstat (limited to 'src/gfxinit.cpp')
-rw-r--r--src/gfxinit.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gfxinit.cpp b/src/gfxinit.cpp
index 7c4b49cdf..441f18863 100644
--- a/src/gfxinit.cpp
+++ b/src/gfxinit.cpp
@@ -263,7 +263,7 @@ static bool SwitchNewGRFBlitter()
* between multiple 32bpp blitters, which perform differently with 8bpp sprites.
*/
uint depth_wanted_by_base = BaseGraphics::GetUsedSet()->blitter == BLT_32BPP ? 32 : 8;
- uint depth_wanted_by_grf = _support8bpp == S8BPP_NONE ? 32 : 8;
+ uint depth_wanted_by_grf = _support8bpp != S8BPP_NONE || VideoDriver::GetInstance()->HasEfficient8Bpp() ? 8 : 32;
for (GRFConfig *c = _grfconfig; c != nullptr; c = c->next) {
if (c->status == GCS_DISABLED || c->status == GCS_NOT_FOUND || HasBit(c->flags, GCF_INIT_ONLY)) continue;
if (c->palette & GRFP_BLT_32BPP) depth_wanted_by_grf = 32;