Skip to content

Commit 191efe2

Browse files
committed
Merge pull request #109778 from BlueCube3310/gles3-astc-detect
Compatibility: Improve ASTC extension detecting
2 parents 8265bb8 + d481a23 commit 191efe2

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

drivers/gles3/storage/config.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,10 @@ Config::Config() {
7878
#endif
7979

8080
bptc_supported = extensions.has("GL_ARB_texture_compression_bptc") || extensions.has("GL_EXT_texture_compression_bptc");
81-
astc_hdr_supported = extensions.has("GL_KHR_texture_compression_astc_hdr");
82-
astc_supported = astc_hdr_supported || extensions.has("GL_KHR_texture_compression_astc") || extensions.has("GL_OES_texture_compression_astc") || extensions.has("GL_KHR_texture_compression_astc_ldr") || extensions.has("WEBGL_compressed_texture_astc");
83-
astc_layered_supported = extensions.has("GL_KHR_texture_compression_astc_sliced_3d");
81+
astc_3d_supported = extensions.has("GL_OES_texture_compression_astc");
82+
astc_hdr_supported = astc_3d_supported || extensions.has("GL_KHR_texture_compression_astc_hdr");
83+
astc_layered_supported = astc_hdr_supported || extensions.has("GL_KHR_texture_compression_astc_sliced_3d");
84+
astc_supported = astc_layered_supported || extensions.has("GL_KHR_texture_compression_astc_ldr") || extensions.has("WEBGL_compressed_texture_astc");
8485

8586
if (RasterizerGLES3::is_gles_over_gl()) {
8687
float_texture_supported = true;

drivers/gles3/storage/config.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ class Config {
8080
bool astc_supported = false;
8181
bool astc_hdr_supported = false;
8282
bool astc_layered_supported = false;
83+
bool astc_3d_supported = false;
8384
bool srgb_framebuffer_supported = false;
8485

8586
bool force_vertex_shading = false;

0 commit comments

Comments
 (0)