diff options
author | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2022-05-11 00:12:37 +0200 |
---|---|---|
committer | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2022-05-11 00:26:26 +0200 |
commit | d2bb5b88cc6215f8312f24bec29f8ddc0d75d9a5 (patch) | |
tree | 726c882598fafc8cd85c63198455eddbeda8e9ae | |
parent | 9bdb853eecd56bc905e5a766731a64034b54c96c (diff) |
[GL] Fix HTML5 builds.
Safer guards for debug functions.
GL_FRAMEBUFFER_INCOMPLETE_* functions seem to be OpenGL 4.
-rw-r--r-- | drivers/gles3/rasterizer_storage_gles3.h | 2 | ||||
-rw-r--r-- | drivers/gles3/storage/texture_storage.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gles3/rasterizer_storage_gles3.h b/drivers/gles3/rasterizer_storage_gles3.h index 6401771abb..d22db198c8 100644 --- a/drivers/gles3/rasterizer_storage_gles3.h +++ b/drivers/gles3/rasterizer_storage_gles3.h @@ -302,7 +302,7 @@ inline void RasterizerStorageGLES3::buffer_orphan_and_upload(unsigned int p_buff } inline String RasterizerStorageGLES3::get_framebuffer_error(GLenum p_status) { -#ifdef DEBUG_ENABLED +#if defined(DEBUG_ENABLED) && defined(GLES_OVER_GL) if (p_status == GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT) { return "GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT"; } else if (p_status == GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT) { diff --git a/drivers/gles3/storage/texture_storage.h b/drivers/gles3/storage/texture_storage.h index 1e1cd3f9bf..a841ff8f46 100644 --- a/drivers/gles3/storage/texture_storage.h +++ b/drivers/gles3/storage/texture_storage.h @@ -574,7 +574,7 @@ public: }; inline String TextureStorage::get_framebuffer_error(GLenum p_status) { -#ifdef DEBUG_ENABLED +#if defined(DEBUG_ENABLED) && defined(GLES_OVER_GL) if (p_status == GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT) { return "GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT"; } else if (p_status == GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT) { |