Diff
Modified: trunk/Source/WebCore/bindings/js/JSDOMConvertWebGL.cpp (295108 => 295109)
--- trunk/Source/WebCore/bindings/js/JSDOMConvertWebGL.cpp 2022-06-01 22:30:34 UTC (rev 295108)
+++ trunk/Source/WebCore/bindings/js/JSDOMConvertWebGL.cpp 2022-06-02 00:15:58 UTC (rev 295109)
@@ -161,77 +161,46 @@
JSValue convertToJSValue(JSGlobalObject& lexicalGlobalObject, JSDOMGlobalObject& globalObject, WebGLExtension& extension)
{
+#define TO_JS(EXT) \
+ case WebGLExtension::EXT ## Name: \
+ return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXT&>(extension));
+
switch (extension.getName()) {
- case WebGLExtension::WebGLLoseContextName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLLoseContext&>(extension));
- case WebGLExtension::EXTShaderTextureLODName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTShaderTextureLOD&>(extension));
- case WebGLExtension::EXTTextureCompressionBPTCName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTTextureCompressionBPTC&>(extension));
- case WebGLExtension::EXTTextureCompressionRGTCName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTTextureCompressionRGTC&>(extension));
- case WebGLExtension::EXTTextureFilterAnisotropicName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTTextureFilterAnisotropic&>(extension));
- case WebGLExtension::EXTTextureNorm16Name:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTTextureNorm16&>(extension));
- case WebGLExtension::EXTsRGBName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTsRGB&>(extension));
- case WebGLExtension::EXTFragDepthName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTFragDepth&>(extension));
- case WebGLExtension::EXTBlendMinMaxName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTBlendMinMax&>(extension));
- case WebGLExtension::KHRParallelShaderCompileName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<KHRParallelShaderCompile&>(extension));
- case WebGLExtension::OESStandardDerivativesName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<OESStandardDerivatives&>(extension));
- case WebGLExtension::OESTextureFloatName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<OESTextureFloat&>(extension));
- case WebGLExtension::OESTextureFloatLinearName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<OESTextureFloatLinear&>(extension));
- case WebGLExtension::OESTextureHalfFloatName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<OESTextureHalfFloat&>(extension));
- case WebGLExtension::OESTextureHalfFloatLinearName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<OESTextureHalfFloatLinear&>(extension));
- case WebGLExtension::OESVertexArrayObjectName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<OESVertexArrayObject&>(extension));
- case WebGLExtension::OESElementIndexUintName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<OESElementIndexUint&>(extension));
- case WebGLExtension::OESFBORenderMipmapName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<OESFBORenderMipmap&>(extension));
- case WebGLExtension::WebGLDebugRendererInfoName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLDebugRendererInfo&>(extension));
- case WebGLExtension::WebGLDebugShadersName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLDebugShaders&>(extension));
- case WebGLExtension::WebGLCompressedTextureATCName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLCompressedTextureATC&>(extension));
- case WebGLExtension::WebGLCompressedTextureETCName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLCompressedTextureETC&>(extension));
- case WebGLExtension::WebGLCompressedTextureETC1Name:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLCompressedTextureETC1&>(extension));
- case WebGLExtension::WebGLCompressedTexturePVRTCName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLCompressedTexturePVRTC&>(extension));
- case WebGLExtension::WebGLCompressedTextureS3TCName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLCompressedTextureS3TC&>(extension));
- case WebGLExtension::WebGLCompressedTextureS3TCsRGBName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLCompressedTextureS3TCsRGB&>(extension));
- case WebGLExtension::WebGLCompressedTextureASTCName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLCompressedTextureASTC&>(extension));
- case WebGLExtension::WebGLDepthTextureName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLDepthTexture&>(extension));
- case WebGLExtension::WebGLDrawBuffersName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLDrawBuffers&>(extension));
- case WebGLExtension::ANGLEInstancedArraysName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<ANGLEInstancedArrays&>(extension));
- case WebGLExtension::EXTColorBufferHalfFloatName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTColorBufferHalfFloat&>(extension));
- case WebGLExtension::EXTFloatBlendName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTFloatBlend&>(extension));
- case WebGLExtension::WebGLColorBufferFloatName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLColorBufferFloat&>(extension));
- case WebGLExtension::EXTColorBufferFloatName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<EXTColorBufferFloat&>(extension));
- case WebGLExtension::WebGLMultiDrawName:
- return toJS(&lexicalGlobalObject, &globalObject, static_cast<WebGLMultiDraw&>(extension));
+ TO_JS(ANGLEInstancedArrays)
+ TO_JS(EXTBlendMinMax)
+ TO_JS(EXTColorBufferFloat)
+ TO_JS(EXTColorBufferHalfFloat)
+ TO_JS(EXTFloatBlend)
+ TO_JS(EXTFragDepth)
+ TO_JS(EXTShaderTextureLOD)
+ TO_JS(EXTTextureCompressionBPTC)
+ TO_JS(EXTTextureCompressionRGTC)
+ TO_JS(EXTTextureFilterAnisotropic)
+ TO_JS(EXTTextureNorm16)
+ TO_JS(EXTsRGB)
+ TO_JS(KHRParallelShaderCompile)
+ TO_JS(OESElementIndexUint)
+ TO_JS(OESFBORenderMipmap)
+ TO_JS(OESStandardDerivatives)
+ TO_JS(OESTextureFloat)
+ TO_JS(OESTextureFloatLinear)
+ TO_JS(OESTextureHalfFloat)
+ TO_JS(OESTextureHalfFloatLinear)
+ TO_JS(OESVertexArrayObject)
+ TO_JS(WebGLColorBufferFloat)
+ TO_JS(WebGLCompressedTextureASTC)
+ TO_JS(WebGLCompressedTextureATC)
+ TO_JS(WebGLCompressedTextureETC)
+ TO_JS(WebGLCompressedTextureETC1)
+ TO_JS(WebGLCompressedTexturePVRTC)
+ TO_JS(WebGLCompressedTextureS3TC)
+ TO_JS(WebGLCompressedTextureS3TCsRGB)
+ TO_JS(WebGLDebugRendererInfo)
+ TO_JS(WebGLDebugShaders)
+ TO_JS(WebGLDepthTexture)
+ TO_JS(WebGLDrawBuffers)
+ TO_JS(WebGLLoseContext)
+ TO_JS(WebGLMultiDraw)
}
ASSERT_NOT_REACHED();
return jsNull();
Modified: trunk/Source/WebCore/html/canvas/WebGL2RenderingContext.cpp (295108 => 295109)
--- trunk/Source/WebCore/html/canvas/WebGL2RenderingContext.cpp 2022-06-01 22:30:34 UTC (rev 295108)
+++ trunk/Source/WebCore/html/canvas/WebGL2RenderingContext.cpp 2022-06-02 00:15:58 UTC (rev 295109)
@@ -2712,26 +2712,26 @@
return variable.get(); \
}
+ ENABLE_IF_REQUESTED(EXTColorBufferFloat, m_extColorBufferFloat, "EXT_color_buffer_float"_s, EXTColorBufferFloat::supported(*m_context));
+ ENABLE_IF_REQUESTED(EXTColorBufferHalfFloat, m_extColorBufferHalfFloat, "EXT_color_buffer_half_float"_s, EXTColorBufferHalfFloat::supported(*m_context));
+ ENABLE_IF_REQUESTED(EXTFloatBlend, m_extFloatBlend, "EXT_float_blend"_s, EXTFloatBlend::supported(*m_context));
ENABLE_IF_REQUESTED(EXTTextureCompressionBPTC, m_extTextureCompressionBPTC, "EXT_texture_compression_bptc"_s, EXTTextureCompressionBPTC::supported(*m_context));
ENABLE_IF_REQUESTED(EXTTextureCompressionRGTC, m_extTextureCompressionRGTC, "EXT_texture_compression_rgtc"_s, EXTTextureCompressionRGTC::supported(*m_context));
ENABLE_IF_REQUESTED(EXTTextureFilterAnisotropic, m_extTextureFilterAnisotropic, "EXT_texture_filter_anisotropic"_s, enableSupportedExtension("GL_EXT_texture_filter_anisotropic"_s));
ENABLE_IF_REQUESTED(EXTTextureNorm16, m_extTextureNorm16, "EXT_texture_norm16"_s, EXTTextureNorm16::supported(*m_context));
+ ENABLE_IF_REQUESTED(KHRParallelShaderCompile, m_khrParallelShaderCompile, "KHR_parallel_shader_compile"_s, KHRParallelShaderCompile::supported(*m_context));
ENABLE_IF_REQUESTED(OESTextureFloatLinear, m_oesTextureFloatLinear, "OES_texture_float_linear"_s, enableSupportedExtension("GL_OES_texture_float_linear"_s));
- ENABLE_IF_REQUESTED(WebGLLoseContext, m_webglLoseContext, "WEBGL_lose_context"_s, true);
ENABLE_IF_REQUESTED(WebGLCompressedTextureASTC, m_webglCompressedTextureASTC, "WEBGL_compressed_texture_astc"_s, WebGLCompressedTextureASTC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureATC, m_webglCompressedTextureATC, "WEBKIT_WEBGL_compressed_texture_atc"_s, WebGLCompressedTextureATC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureETC, m_webglCompressedTextureETC, "WEBGL_compressed_texture_etc"_s, WebGLCompressedTextureETC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureETC1, m_webglCompressedTextureETC1, "WEBGL_compressed_texture_etc1"_s, WebGLCompressedTextureETC1::supported(*m_context));
+ ENABLE_IF_REQUESTED(WebGLCompressedTexturePVRTC, m_webglCompressedTexturePVRTC, "WEBGL_compressed_texture_pvrtc"_s, WebGLCompressedTexturePVRTC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTexturePVRTC, m_webglCompressedTexturePVRTC, "WEBKIT_WEBGL_compressed_texture_pvrtc"_s, WebGLCompressedTexturePVRTC::supported(*m_context));
- ENABLE_IF_REQUESTED(WebGLCompressedTexturePVRTC, m_webglCompressedTexturePVRTC, "WEBGL_compressed_texture_pvrtc"_s, WebGLCompressedTexturePVRTC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureS3TC, m_webglCompressedTextureS3TC, "WEBGL_compressed_texture_s3tc"_s, WebGLCompressedTextureS3TC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureS3TCsRGB, m_webglCompressedTextureS3TCsRGB, "WEBGL_compressed_texture_s3tc_srgb"_s, WebGLCompressedTextureS3TCsRGB::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLDebugRendererInfo, m_webglDebugRendererInfo, "WEBGL_debug_renderer_info"_s, true);
ENABLE_IF_REQUESTED(WebGLDebugShaders, m_webglDebugShaders, "WEBGL_debug_shaders"_s, m_context->supportsExtension("GL_ANGLE_translated_shader_source"_s));
- ENABLE_IF_REQUESTED(EXTColorBufferFloat, m_extColorBufferFloat, "EXT_color_buffer_float"_s, EXTColorBufferFloat::supported(*m_context));
- ENABLE_IF_REQUESTED(EXTColorBufferHalfFloat, m_extColorBufferHalfFloat, "EXT_color_buffer_half_float"_s, EXTColorBufferHalfFloat::supported(*m_context));
- ENABLE_IF_REQUESTED(EXTFloatBlend, m_extFloatBlend, "EXT_float_blend"_s, EXTFloatBlend::supported(*m_context));
- ENABLE_IF_REQUESTED(KHRParallelShaderCompile, m_khrParallelShaderCompile, "KHR_parallel_shader_compile"_s, KHRParallelShaderCompile::supported(*m_context));
+ ENABLE_IF_REQUESTED(WebGLLoseContext, m_webglLoseContext, "WEBGL_lose_context"_s, true);
ENABLE_IF_REQUESTED(WebGLMultiDraw, m_webglMultiDraw, "WEBGL_multi_draw"_s, true);
return nullptr;
}
@@ -2746,47 +2746,32 @@
if (m_isPendingPolicyResolution)
return result;
- if (m_context->supportsExtension("GL_OES_texture_float_linear"_s))
- result.append("OES_texture_float_linear"_s);
- if (EXTTextureCompressionBPTC::supported(*m_context))
- result.append("EXT_texture_compression_bptc"_s);
- if (EXTTextureCompressionRGTC::supported(*m_context))
- result.append("EXT_texture_compression_rgtc"_s);
- if (m_context->supportsExtension("GL_EXT_texture_filter_anisotropic"_s))
- result.append("EXT_texture_filter_anisotropic"_s);
- if (EXTTextureNorm16::supported(*m_context))
- result.append("EXT_texture_norm16"_s);
- if (WebGLCompressedTextureASTC::supported(*m_context))
- result.append("WEBGL_compressed_texture_astc"_s);
- if (WebGLCompressedTextureATC::supported(*m_context))
- result.append("WEBKIT_WEBGL_compressed_texture_atc"_s);
- if (WebGLCompressedTextureETC::supported(*m_context))
- result.append("WEBGL_compressed_texture_etc"_s);
- if (WebGLCompressedTextureETC1::supported(*m_context))
- result.append("WEBGL_compressed_texture_etc1"_s);
- if (WebGLCompressedTexturePVRTC::supported(*m_context)) {
- result.append("WEBKIT_WEBGL_compressed_texture_pvrtc"_s);
- result.append("WEBGL_compressed_texture_pvrtc"_s);
- }
- if (WebGLCompressedTextureS3TC::supported(*m_context))
- result.append("WEBGL_compressed_texture_s3tc"_s);
- if (WebGLCompressedTextureS3TCsRGB::supported(*m_context))
- result.append("WEBGL_compressed_texture_s3tc_srgb"_s);
- result.append("WEBGL_lose_context"_s);
- if (m_context->supportsExtension("GL_ANGLE_translated_shader_source"_s))
- result.append("WEBGL_debug_shaders"_s);
- result.append("WEBGL_debug_renderer_info"_s);
- if (EXTColorBufferFloat::supported(*m_context))
- result.append("EXT_color_buffer_float"_s);
- if (EXTColorBufferHalfFloat::supported(*m_context))
- result.append("EXT_color_buffer_half_float"_s);
- if (EXTFloatBlend::supported(*m_context))
- result.append("EXT_float_blend"_s);
- if (KHRParallelShaderCompile::supported(*m_context))
- result.append("KHR_parallel_shader_compile"_s);
- if (WebGLMultiDraw::supported(*m_context))
- result.append("WEBGL_multi_draw"_s);
+#define APPEND_IF_SUPPORTED(nameLiteral, condition) \
+ if (condition) \
+ result.append(nameLiteral ## _s);
+ APPEND_IF_SUPPORTED("EXT_color_buffer_float", EXTColorBufferFloat::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_color_buffer_half_float", EXTColorBufferHalfFloat::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_float_blend", EXTFloatBlend::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_texture_compression_bptc", EXTTextureCompressionBPTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_texture_compression_rgtc", EXTTextureCompressionRGTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_texture_filter_anisotropic", m_context->supportsExtension("GL_EXT_texture_filter_anisotropic"_s))
+ APPEND_IF_SUPPORTED("EXT_texture_norm16", EXTTextureNorm16::supported(*m_context))
+ APPEND_IF_SUPPORTED("KHR_parallel_shader_compile", KHRParallelShaderCompile::supported(*m_context))
+ APPEND_IF_SUPPORTED("OES_texture_float_linear", m_context->supportsExtension("GL_OES_texture_float_linear"_s))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_astc", WebGLCompressedTextureASTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBKIT_WEBGL_compressed_texture_atc", WebGLCompressedTextureATC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_etc", WebGLCompressedTextureETC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_etc1", WebGLCompressedTextureETC1::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_pvrtc", WebGLCompressedTexturePVRTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBKIT_WEBGL_compressed_texture_pvrtc", WebGLCompressedTexturePVRTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_s3tc", WebGLCompressedTextureS3TC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_s3tc_srgb", WebGLCompressedTextureS3TCsRGB::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_debug_renderer_info", true)
+ APPEND_IF_SUPPORTED("WEBGL_debug_shaders", m_context->supportsExtension("GL_ANGLE_translated_shader_source"_s))
+ APPEND_IF_SUPPORTED("WEBGL_lose_context", true)
+ APPEND_IF_SUPPORTED("WEBGL_multi_draw", WebGLMultiDraw::supported(*m_context))
+
return result;
}
Modified: trunk/Source/WebCore/html/canvas/WebGLExtension.h (295108 => 295109)
--- trunk/Source/WebCore/html/canvas/WebGLExtension.h 2022-06-01 22:30:34 UTC (rev 295108)
+++ trunk/Source/WebCore/html/canvas/WebGLExtension.h 2022-06-02 00:15:58 UTC (rev 295109)
@@ -37,8 +37,11 @@
public:
// Extension names are needed to properly wrap instances in _javascript_ objects.
enum ExtensionName {
- WebGLLoseContextName,
+ ANGLEInstancedArraysName,
EXTBlendMinMaxName,
+ EXTColorBufferFloatName,
+ EXTColorBufferHalfFloatName,
+ EXTFloatBlendName,
EXTFragDepthName,
EXTShaderTextureLODName,
EXTTextureCompressionBPTCName,
@@ -47,30 +50,27 @@
EXTTextureNorm16Name,
EXTsRGBName,
KHRParallelShaderCompileName,
+ OESElementIndexUintName,
+ OESFBORenderMipmapName,
+ OESStandardDerivativesName,
OESTextureFloatName,
OESTextureFloatLinearName,
OESTextureHalfFloatName,
OESTextureHalfFloatLinearName,
- OESStandardDerivativesName,
OESVertexArrayObjectName,
+ WebGLColorBufferFloatName,
+ WebGLCompressedTextureASTCName,
+ WebGLCompressedTextureATCName,
+ WebGLCompressedTextureETCName,
+ WebGLCompressedTextureETC1Name,
+ WebGLCompressedTexturePVRTCName,
+ WebGLCompressedTextureS3TCName,
+ WebGLCompressedTextureS3TCsRGBName,
WebGLDebugRendererInfoName,
WebGLDebugShadersName,
- WebGLCompressedTextureS3TCName,
- WebGLCompressedTextureS3TCsRGBName,
WebGLDepthTextureName,
WebGLDrawBuffersName,
- OESElementIndexUintName,
- OESFBORenderMipmapName,
- WebGLCompressedTextureATCName,
- WebGLCompressedTextureETCName,
- WebGLCompressedTextureETC1Name,
- WebGLCompressedTexturePVRTCName,
- WebGLCompressedTextureASTCName,
- ANGLEInstancedArraysName,
- EXTColorBufferHalfFloatName,
- EXTFloatBlendName,
- WebGLColorBufferFloatName,
- EXTColorBufferFloatName,
+ WebGLLoseContextName,
WebGLMultiDrawName,
};
Modified: trunk/Source/WebCore/html/canvas/WebGLRenderingContext.cpp (295108 => 295109)
--- trunk/Source/WebCore/html/canvas/WebGLRenderingContext.cpp 2022-06-01 22:30:34 UTC (rev 295108)
+++ trunk/Source/WebCore/html/canvas/WebGLRenderingContext.cpp 2022-06-02 00:15:58 UTC (rev 295109)
@@ -148,8 +148,21 @@
return variable.get(); \
}
+ if (equalIgnoringASCIICase(name, "ANGLE_instanced_arrays"_s)) {
+ if (!m_angleInstancedArrays) {
+ if (!ANGLEInstancedArrays::supported(*m_context))
+ m_angleInstancedArrays = nullptr;
+ else {
+ m_context->ensureExtensionEnabled("GL_ANGLE_instanced_arrays"_s);
+ m_angleInstancedArrays = adoptRef(new ANGLEInstancedArrays(*this));
+ InspectorInstrumentation::didEnableExtension(*this, name);
+ }
+ }
+ return m_angleInstancedArrays.get();
+ }
ENABLE_IF_REQUESTED(EXTBlendMinMax, m_extBlendMinMax, "EXT_blend_minmax", enableSupportedExtension("GL_EXT_blend_minmax"_s));
- ENABLE_IF_REQUESTED(EXTsRGB, m_extsRGB, "EXT_sRGB", enableSupportedExtension("GL_EXT_sRGB"_s));
+ ENABLE_IF_REQUESTED(EXTColorBufferHalfFloat, m_extColorBufferHalfFloat, "EXT_color_buffer_half_float", EXTColorBufferHalfFloat::supported(*m_context));
+ ENABLE_IF_REQUESTED(EXTFloatBlend, m_extFloatBlend, "EXT_float_blend", EXTFloatBlend::supported(*m_context));
ENABLE_IF_REQUESTED(EXTFragDepth, m_extFragDepth, "EXT_frag_depth", enableSupportedExtension("GL_EXT_frag_depth"_s));
if (equalIgnoringASCIICase(name, "EXT_shader_texture_lod"_s)) {
if (!m_extShaderTextureLOD) {
@@ -163,10 +176,13 @@
}
return m_extShaderTextureLOD.get();
}
- ENABLE_IF_REQUESTED(EXTTextureFilterAnisotropic, m_extTextureFilterAnisotropic, "EXT_texture_filter_anisotropic", enableSupportedExtension("GL_EXT_texture_filter_anisotropic"_s));
ENABLE_IF_REQUESTED(EXTTextureCompressionBPTC, m_extTextureCompressionBPTC, "EXT_texture_compression_bptc", EXTTextureCompressionBPTC::supported(*m_context));
ENABLE_IF_REQUESTED(EXTTextureCompressionRGTC, m_extTextureCompressionRGTC, "EXT_texture_compression_rgtc", EXTTextureCompressionRGTC::supported(*m_context));
+ ENABLE_IF_REQUESTED(EXTTextureFilterAnisotropic, m_extTextureFilterAnisotropic, "EXT_texture_filter_anisotropic", enableSupportedExtension("GL_EXT_texture_filter_anisotropic"_s));
+ ENABLE_IF_REQUESTED(EXTsRGB, m_extsRGB, "EXT_sRGB", enableSupportedExtension("GL_EXT_sRGB"_s));
ENABLE_IF_REQUESTED(KHRParallelShaderCompile, m_khrParallelShaderCompile, "KHR_parallel_shader_compile", KHRParallelShaderCompile::supported(*m_context));
+ ENABLE_IF_REQUESTED(OESElementIndexUint, m_oesElementIndexUint, "OES_element_index_uint", enableSupportedExtension("GL_OES_element_index_uint"_s));
+ ENABLE_IF_REQUESTED(OESFBORenderMipmap, m_oesFBORenderMipmap, "OES_fbo_render_mipmap", enableSupportedExtension("GL_OES_fbo_render_mipmap"_s));
ENABLE_IF_REQUESTED(OESStandardDerivatives, m_oesStandardDerivatives, "OES_standard_derivatives", enableSupportedExtension("GL_OES_standard_derivatives"_s));
ENABLE_IF_REQUESTED(OESTextureFloat, m_oesTextureFloat, "OES_texture_float", OESTextureFloat::supported(*m_context));
ENABLE_IF_REQUESTED(OESTextureFloatLinear, m_oesTextureFloatLinear, "OES_texture_float_linear", enableSupportedExtension("GL_OES_texture_float_linear"_s));
@@ -173,17 +189,17 @@
ENABLE_IF_REQUESTED(OESTextureHalfFloat, m_oesTextureHalfFloat, "OES_texture_half_float", OESTextureHalfFloat::supported(*m_context));
ENABLE_IF_REQUESTED(OESTextureHalfFloatLinear, m_oesTextureHalfFloatLinear, "OES_texture_half_float_linear", enableSupportedExtension("GL_OES_texture_half_float_linear"_s));
ENABLE_IF_REQUESTED(OESVertexArrayObject, m_oesVertexArrayObject, "OES_vertex_array_object", enableSupportedExtension("GL_OES_vertex_array_object"_s));
- ENABLE_IF_REQUESTED(OESElementIndexUint, m_oesElementIndexUint, "OES_element_index_uint", enableSupportedExtension("GL_OES_element_index_uint"_s));
- ENABLE_IF_REQUESTED(OESFBORenderMipmap, m_oesFBORenderMipmap, "OES_fbo_render_mipmap", enableSupportedExtension("GL_OES_fbo_render_mipmap"_s));
- ENABLE_IF_REQUESTED(WebGLLoseContext, m_webglLoseContext, "WEBGL_lose_context", true);
+ ENABLE_IF_REQUESTED(WebGLColorBufferFloat, m_webglColorBufferFloat, "WEBGL_color_buffer_float", WebGLColorBufferFloat::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureASTC, m_webglCompressedTextureASTC, "WEBGL_compressed_texture_astc", WebGLCompressedTextureASTC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureATC, m_webglCompressedTextureATC, "WEBKIT_WEBGL_compressed_texture_atc", WebGLCompressedTextureATC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureETC, m_webglCompressedTextureETC, "WEBGL_compressed_texture_etc", WebGLCompressedTextureETC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureETC1, m_webglCompressedTextureETC1, "WEBGL_compressed_texture_etc1", WebGLCompressedTextureETC1::supported(*m_context));
+ ENABLE_IF_REQUESTED(WebGLCompressedTexturePVRTC, m_webglCompressedTexturePVRTC, "WEBGL_compressed_texture_pvrtc", WebGLCompressedTexturePVRTC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTexturePVRTC, m_webglCompressedTexturePVRTC, "WEBKIT_WEBGL_compressed_texture_pvrtc", WebGLCompressedTexturePVRTC::supported(*m_context));
- ENABLE_IF_REQUESTED(WebGLCompressedTexturePVRTC, m_webglCompressedTexturePVRTC, "WEBGL_compressed_texture_pvrtc", WebGLCompressedTexturePVRTC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureS3TC, m_webglCompressedTextureS3TC, "WEBGL_compressed_texture_s3tc", WebGLCompressedTextureS3TC::supported(*m_context));
ENABLE_IF_REQUESTED(WebGLCompressedTextureS3TCsRGB, m_webglCompressedTextureS3TCsRGB, "WEBGL_compressed_texture_s3tc_srgb", WebGLCompressedTextureS3TCsRGB::supported(*m_context));
+ ENABLE_IF_REQUESTED(WebGLDebugRendererInfo, m_webglDebugRendererInfo, "WEBGL_debug_renderer_info", true);
+ ENABLE_IF_REQUESTED(WebGLDebugShaders, m_webglDebugShaders, "WEBGL_debug_shaders", m_context->supportsExtension("GL_ANGLE_translated_shader_source"_s));
ENABLE_IF_REQUESTED(WebGLDepthTexture, m_webglDepthTexture, "WEBGL_depth_texture", WebGLDepthTexture::supported(*m_context));
if (equalIgnoringASCIICase(name, "WEBGL_draw_buffers"_s)) {
if (!m_webglDrawBuffers) {
@@ -197,23 +213,7 @@
}
return m_webglDrawBuffers.get();
}
- if (equalIgnoringASCIICase(name, "ANGLE_instanced_arrays"_s)) {
- if (!m_angleInstancedArrays) {
- if (!ANGLEInstancedArrays::supported(*m_context))
- m_angleInstancedArrays = nullptr;
- else {
- m_context->ensureExtensionEnabled("GL_ANGLE_instanced_arrays"_s);
- m_angleInstancedArrays = adoptRef(new ANGLEInstancedArrays(*this));
- InspectorInstrumentation::didEnableExtension(*this, name);
- }
- }
- return m_angleInstancedArrays.get();
- }
- ENABLE_IF_REQUESTED(WebGLDebugRendererInfo, m_webglDebugRendererInfo, "WEBGL_debug_renderer_info", true);
- ENABLE_IF_REQUESTED(WebGLDebugShaders, m_webglDebugShaders, "WEBGL_debug_shaders", m_context->supportsExtension("GL_ANGLE_translated_shader_source"_s));
- ENABLE_IF_REQUESTED(EXTColorBufferHalfFloat, m_extColorBufferHalfFloat, "EXT_color_buffer_half_float", EXTColorBufferHalfFloat::supported(*m_context));
- ENABLE_IF_REQUESTED(EXTFloatBlend, m_extFloatBlend, "EXT_float_blend", EXTFloatBlend::supported(*m_context));
- ENABLE_IF_REQUESTED(WebGLColorBufferFloat, m_webglColorBufferFloat, "WEBGL_color_buffer_float", WebGLColorBufferFloat::supported(*m_context));
+ ENABLE_IF_REQUESTED(WebGLLoseContext, m_webglLoseContext, "WEBGL_lose_context", true);
ENABLE_IF_REQUESTED(WebGLMultiDraw, m_webglMultiDraw, "WEBGL_multi_draw", WebGLMultiDraw::supported(*m_context));
return nullptr;
}
@@ -228,73 +228,45 @@
if (m_isPendingPolicyResolution)
return result;
- if (m_context->supportsExtension("GL_EXT_blend_minmax"_s))
- result.append("EXT_blend_minmax"_s);
- if (m_context->supportsExtension("GL_EXT_sRGB"_s))
- result.append("EXT_sRGB"_s);
- if (m_context->supportsExtension("GL_EXT_frag_depth"_s))
- result.append("EXT_frag_depth"_s);
- if (m_context->supportsExtension("GL_OES_texture_float"_s))
- result.append("OES_texture_float"_s);
- if (m_context->supportsExtension("GL_OES_texture_float_linear"_s))
- result.append("OES_texture_float_linear"_s);
- if (m_context->supportsExtension("GL_OES_texture_half_float"_s))
- result.append("OES_texture_half_float"_s);
- if (m_context->supportsExtension("GL_OES_texture_half_float_linear"_s))
- result.append("OES_texture_half_float_linear"_s);
- if (m_context->supportsExtension("GL_OES_standard_derivatives"_s))
- result.append("OES_standard_derivatives"_s);
- if (m_context->supportsExtension("GL_EXT_shader_texture_lod"_s) || m_context->supportsExtension("GL_ARB_shader_texture_lod"_s))
- result.append("EXT_shader_texture_lod"_s);
- if (EXTTextureCompressionBPTC::supported(*m_context))
- result.append("EXT_texture_compression_bptc"_s);
- if (EXTTextureCompressionRGTC::supported(*m_context))
- result.append("EXT_texture_compression_rgtc"_s);
- if (m_context->supportsExtension("GL_EXT_texture_filter_anisotropic"_s))
- result.append("EXT_texture_filter_anisotropic"_s);
- if (m_context->supportsExtension("GL_OES_vertex_array_object"_s))
- result.append("OES_vertex_array_object"_s);
- if (m_context->supportsExtension("GL_OES_element_index_uint"_s))
- result.append("OES_element_index_uint"_s);
- if (m_context->supportsExtension("GL_OES_fbo_render_mipmap"_s))
- result.append("OES_fbo_render_mipmap"_s);
- result.append("WEBGL_lose_context"_s);
- if (WebGLCompressedTextureASTC::supported(*m_context))
- result.append("WEBGL_compressed_texture_astc"_s);
- if (WebGLCompressedTextureATC::supported(*m_context))
- result.append("WEBKIT_WEBGL_compressed_texture_atc"_s);
- if (WebGLCompressedTextureETC::supported(*m_context))
- result.append("WEBGL_compressed_texture_etc"_s);
- if (WebGLCompressedTextureETC1::supported(*m_context))
- result.append("WEBGL_compressed_texture_etc1"_s);
- if (WebGLCompressedTexturePVRTC::supported(*m_context)) {
- result.append("WEBKIT_WEBGL_compressed_texture_pvrtc"_s);
- result.append("WEBGL_compressed_texture_pvrtc"_s);
- }
- if (WebGLCompressedTextureS3TC::supported(*m_context))
- result.append("WEBGL_compressed_texture_s3tc"_s);
- if (WebGLCompressedTextureS3TCsRGB::supported(*m_context))
- result.append("WEBGL_compressed_texture_s3tc_srgb"_s);
- if (WebGLDepthTexture::supported(*m_context))
- result.append("WEBGL_depth_texture"_s);
- if (supportsDrawBuffers())
- result.append("WEBGL_draw_buffers"_s);
- if (ANGLEInstancedArrays::supported(*m_context))
- result.append("ANGLE_instanced_arrays"_s);
- if (m_context->supportsExtension("GL_ANGLE_translated_shader_source"_s))
- result.append("WEBGL_debug_shaders"_s);
- result.append("WEBGL_debug_renderer_info"_s);
- if (EXTColorBufferHalfFloat::supported(*m_context))
- result.append("EXT_color_buffer_half_float"_s);
- if (EXTFloatBlend::supported(*m_context))
- result.append("EXT_float_blend"_s);
- if (WebGLColorBufferFloat::supported(*m_context))
- result.append("WEBGL_color_buffer_float"_s);
- if (KHRParallelShaderCompile::supported(*m_context))
- result.append("KHR_parallel_shader_compile"_s);
- if (WebGLMultiDraw::supported(*m_context))
- result.append("WEBGL_multi_draw"_s);
+#define APPEND_IF_SUPPORTED(nameLiteral, condition) \
+ if (condition) \
+ result.append(nameLiteral ## _s);
+ APPEND_IF_SUPPORTED("ANGLE_instanced_arrays", ANGLEInstancedArrays::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_blend_minmax", m_context->supportsExtension("GL_EXT_blend_minmax"_s))
+ APPEND_IF_SUPPORTED("EXT_color_buffer_half_float", EXTColorBufferHalfFloat::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_float_blend", EXTFloatBlend::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_frag_depth", m_context->supportsExtension("GL_EXT_frag_depth"_s))
+ APPEND_IF_SUPPORTED("EXT_shader_texture_lod", m_context->supportsExtension("GL_EXT_shader_texture_lod"_s) || m_context->supportsExtension("GL_ARB_shader_texture_lod"_s))
+ APPEND_IF_SUPPORTED("EXT_texture_compression_bptc", EXTTextureCompressionBPTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_texture_compression_rgtc", EXTTextureCompressionRGTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("EXT_texture_filter_anisotropic", m_context->supportsExtension("GL_EXT_texture_filter_anisotropic"_s))
+ APPEND_IF_SUPPORTED("EXT_sRGB", m_context->supportsExtension("GL_EXT_sRGB"_s))
+ APPEND_IF_SUPPORTED("KHR_parallel_shader_compile", KHRParallelShaderCompile::supported(*m_context))
+ APPEND_IF_SUPPORTED("OES_element_index_uint", m_context->supportsExtension("GL_OES_element_index_uint"_s))
+ APPEND_IF_SUPPORTED("OES_fbo_render_mipmap", m_context->supportsExtension("GL_OES_fbo_render_mipmap"_s))
+ APPEND_IF_SUPPORTED("OES_standard_derivatives", m_context->supportsExtension("GL_OES_standard_derivatives"_s))
+ APPEND_IF_SUPPORTED("OES_texture_float", m_context->supportsExtension("GL_OES_texture_float"_s))
+ APPEND_IF_SUPPORTED("OES_texture_float_linear", m_context->supportsExtension("GL_OES_texture_float_linear"_s))
+ APPEND_IF_SUPPORTED("OES_texture_half_float", m_context->supportsExtension("GL_OES_texture_half_float"_s))
+ APPEND_IF_SUPPORTED("OES_texture_half_float_linear", m_context->supportsExtension("GL_OES_texture_half_float_linear"_s))
+ APPEND_IF_SUPPORTED("OES_vertex_array_object", m_context->supportsExtension("GL_OES_vertex_array_object"_s))
+ APPEND_IF_SUPPORTED("WEBGL_color_buffer_float", WebGLColorBufferFloat::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_astc", WebGLCompressedTextureASTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBKIT_WEBGL_compressed_texture_atc", WebGLCompressedTextureATC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_etc", WebGLCompressedTextureETC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_etc1", WebGLCompressedTextureETC1::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_pvrtc", WebGLCompressedTexturePVRTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBKIT_WEBGL_compressed_texture_pvrtc", WebGLCompressedTexturePVRTC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_s3tc", WebGLCompressedTextureS3TC::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_compressed_texture_s3tc_srgb", WebGLCompressedTextureS3TCsRGB::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_debug_renderer_info", true)
+ APPEND_IF_SUPPORTED("WEBGL_debug_shaders", m_context->supportsExtension("GL_ANGLE_translated_shader_source"_s))
+ APPEND_IF_SUPPORTED("WEBGL_depth_texture", WebGLDepthTexture::supported(*m_context))
+ APPEND_IF_SUPPORTED("WEBGL_draw_buffers", supportsDrawBuffers())
+ APPEND_IF_SUPPORTED("WEBGL_lose_context", true)
+ APPEND_IF_SUPPORTED("WEBGL_multi_draw", WebGLMultiDraw::supported(*m_context))
+
return result;
}
Modified: trunk/Source/WebCore/html/canvas/WebGLRenderingContextBase.cpp (295108 => 295109)
--- trunk/Source/WebCore/html/canvas/WebGLRenderingContextBase.cpp 2022-06-01 22:30:34 UTC (rev 295108)
+++ trunk/Source/WebCore/html/canvas/WebGLRenderingContextBase.cpp 2022-06-02 00:15:58 UTC (rev 295109)
@@ -3999,41 +3999,41 @@
if (equalIgnoringASCIICase(name, nameLiteral ## _s)) \
return variable != nullptr;
+ CHECK_EXTENSION(m_angleInstancedArrays, "ANGLE_instanced_arrays");
+ CHECK_EXTENSION(m_extBlendMinMax, "EXT_blend_minmax");
+ CHECK_EXTENSION(m_extColorBufferFloat, "EXT_color_buffer_float");
+ CHECK_EXTENSION(m_extColorBufferHalfFloat, "EXT_color_buffer_half_float");
+ CHECK_EXTENSION(m_extFloatBlend, "EXT_float_blend");
CHECK_EXTENSION(m_extFragDepth, "EXT_frag_depth");
- CHECK_EXTENSION(m_extBlendMinMax, "EXT_blend_minmax");
- CHECK_EXTENSION(m_extsRGB, "EXT_sRGB");
+ CHECK_EXTENSION(m_extShaderTextureLOD, "EXT_shader_texture_lod");
CHECK_EXTENSION(m_extTextureCompressionBPTC, "EXT_texture_compression_bptc");
CHECK_EXTENSION(m_extTextureCompressionRGTC, "EXT_texture_compression_rgtc");
CHECK_EXTENSION(m_extTextureFilterAnisotropic, "EXT_texture_filter_anisotropic");
- CHECK_EXTENSION(m_extTextureFilterAnisotropic, "WEBKIT_EXT_texture_filter_anisotropic");
CHECK_EXTENSION(m_extTextureNorm16, "EXT_texture_norm16");
- CHECK_EXTENSION(m_extShaderTextureLOD, "EXT_shader_texture_lod");
+ CHECK_EXTENSION(m_extsRGB, "EXT_sRGB");
CHECK_EXTENSION(m_khrParallelShaderCompile, "KHR_parallel_shader_compile");
+ CHECK_EXTENSION(m_oesElementIndexUint, "OES_element_index_uint");
+ CHECK_EXTENSION(m_oesFBORenderMipmap, "OES_fbo_render_mipmap");
+ CHECK_EXTENSION(m_oesStandardDerivatives, "OES_standard_derivatives");
CHECK_EXTENSION(m_oesTextureFloat, "OES_texture_float");
CHECK_EXTENSION(m_oesTextureFloatLinear, "OES_texture_float_linear");
CHECK_EXTENSION(m_oesTextureHalfFloat, "OES_texture_half_float");
CHECK_EXTENSION(m_oesTextureHalfFloatLinear, "OES_texture_half_float_linear");
- CHECK_EXTENSION(m_oesStandardDerivatives, "OES_standard_derivatives");
CHECK_EXTENSION(m_oesVertexArrayObject, "OES_vertex_array_object");
- CHECK_EXTENSION(m_oesElementIndexUint, "OES_element_index_uint");
- CHECK_EXTENSION(m_oesFBORenderMipmap, "OES_fbo_render_mipmap");
- CHECK_EXTENSION(m_webglLoseContext, "WEBGL_lose_context");
- CHECK_EXTENSION(m_webglDebugRendererInfo, "WEBGL_debug_renderer_info");
- CHECK_EXTENSION(m_webglDebugShaders, "WEBGL_debug_shaders");
+ CHECK_EXTENSION(m_webglColorBufferFloat, "WEBGL_color_buffer_float");
CHECK_EXTENSION(m_webglCompressedTextureASTC, "WEBGL_compressed_texture_astc");
CHECK_EXTENSION(m_webglCompressedTextureATC, "WEBKIT_WEBGL_compressed_texture_atc");
CHECK_EXTENSION(m_webglCompressedTextureETC, "WEBGL_compressed_texture_etc");
CHECK_EXTENSION(m_webglCompressedTextureETC1, "WEBGL_compressed_texture_etc1");
+ CHECK_EXTENSION(m_webglCompressedTexturePVRTC, "WEBGL_compressed_texture_pvrtc");
CHECK_EXTENSION(m_webglCompressedTexturePVRTC, "WEBKIT_WEBGL_compressed_texture_pvrtc");
CHECK_EXTENSION(m_webglCompressedTextureS3TC, "WEBGL_compressed_texture_s3tc");
CHECK_EXTENSION(m_webglCompressedTextureS3TCsRGB, "WEBGL_compressed_texture_s3tc_srgb");
+ CHECK_EXTENSION(m_webglDebugRendererInfo, "WEBGL_debug_renderer_info");
+ CHECK_EXTENSION(m_webglDebugShaders, "WEBGL_debug_shaders");
CHECK_EXTENSION(m_webglDepthTexture, "WEBGL_depth_texture");
CHECK_EXTENSION(m_webglDrawBuffers, "WEBGL_draw_buffers");
- CHECK_EXTENSION(m_angleInstancedArrays, "ANGLE_instanced_arrays");
- CHECK_EXTENSION(m_extColorBufferHalfFloat, "EXT_color_buffer_half_float");
- CHECK_EXTENSION(m_extFloatBlend, "EXT_float_blend");
- CHECK_EXTENSION(m_webglColorBufferFloat, "WEBGL_color_buffer_float");
- CHECK_EXTENSION(m_extColorBufferFloat, "EXT_color_buffer_float");
+ CHECK_EXTENSION(m_webglLoseContext, "WEBGL_lose_context");
CHECK_EXTENSION(m_webglMultiDraw, "WEBGL_multi_draw");
return false;
}
@@ -8106,26 +8106,28 @@
(void) variable.releaseNonNull(); \
}
+ LOSE_EXTENSION(m_angleInstancedArrays);
+ LOSE_EXTENSION(m_extBlendMinMax);
+ LOSE_EXTENSION(m_extColorBufferFloat);
+ LOSE_EXTENSION(m_extColorBufferHalfFloat);
+ LOSE_EXTENSION(m_extFloatBlend);
LOSE_EXTENSION(m_extFragDepth);
- LOSE_EXTENSION(m_extBlendMinMax);
- LOSE_EXTENSION(m_extsRGB);
+ LOSE_EXTENSION(m_extShaderTextureLOD);
LOSE_EXTENSION(m_extTextureCompressionBPTC);
LOSE_EXTENSION(m_extTextureCompressionRGTC);
LOSE_EXTENSION(m_extTextureFilterAnisotropic);
LOSE_EXTENSION(m_extTextureNorm16);
- LOSE_EXTENSION(m_extShaderTextureLOD);
+ LOSE_EXTENSION(m_extsRGB);
LOSE_EXTENSION(m_khrParallelShaderCompile);
+ LOSE_EXTENSION(m_oesElementIndexUint);
+ LOSE_EXTENSION(m_oesFBORenderMipmap);
+ LOSE_EXTENSION(m_oesStandardDerivatives);
LOSE_EXTENSION(m_oesTextureFloat);
LOSE_EXTENSION(m_oesTextureFloatLinear);
LOSE_EXTENSION(m_oesTextureHalfFloat);
LOSE_EXTENSION(m_oesTextureHalfFloatLinear);
- LOSE_EXTENSION(m_oesStandardDerivatives);
LOSE_EXTENSION(m_oesVertexArrayObject);
- LOSE_EXTENSION(m_oesElementIndexUint);
- LOSE_EXTENSION(m_oesFBORenderMipmap);
- LOSE_EXTENSION(m_webglLoseContext);
- LOSE_EXTENSION(m_webglDebugRendererInfo);
- LOSE_EXTENSION(m_webglDebugShaders);
+ LOSE_EXTENSION(m_webglColorBufferFloat);
LOSE_EXTENSION(m_webglCompressedTextureASTC);
LOSE_EXTENSION(m_webglCompressedTextureATC);
LOSE_EXTENSION(m_webglCompressedTextureETC);
@@ -8132,13 +8134,13 @@
LOSE_EXTENSION(m_webglCompressedTextureETC1);
LOSE_EXTENSION(m_webglCompressedTexturePVRTC);
LOSE_EXTENSION(m_webglCompressedTextureS3TC);
+ LOSE_EXTENSION(m_webglCompressedTextureS3TCsRGB);
+ LOSE_EXTENSION(m_webglDebugRendererInfo);
+ LOSE_EXTENSION(m_webglDebugShaders);
LOSE_EXTENSION(m_webglDepthTexture);
LOSE_EXTENSION(m_webglDrawBuffers);
- LOSE_EXTENSION(m_angleInstancedArrays);
- LOSE_EXTENSION(m_extColorBufferHalfFloat);
- LOSE_EXTENSION(m_extFloatBlend);
- LOSE_EXTENSION(m_webglColorBufferFloat);
- LOSE_EXTENSION(m_extColorBufferFloat);
+ LOSE_EXTENSION(m_webglLoseContext);
+ LOSE_EXTENSION(m_webglMultiDraw);
}
void WebGLRenderingContextBase::activityStateDidChange(OptionSet<ActivityState::Flag> oldActivityState, OptionSet<ActivityState::Flag> newActivityState)
Modified: trunk/Source/WebCore/html/canvas/WebGLRenderingContextBase.h (295108 => 295109)
--- trunk/Source/WebCore/html/canvas/WebGLRenderingContextBase.h 2022-06-01 22:30:34 UTC (rev 295108)
+++ trunk/Source/WebCore/html/canvas/WebGLRenderingContextBase.h 2022-06-02 00:15:58 UTC (rev 295109)
@@ -76,17 +76,19 @@
class EXTColorBufferFloat;
class EXTColorBufferHalfFloat;
class EXTFloatBlend;
+class EXTFragDepth;
+class EXTShaderTextureLOD;
class EXTTextureCompressionBPTC;
class EXTTextureCompressionRGTC;
class EXTTextureFilterAnisotropic;
class EXTTextureNorm16;
-class EXTShaderTextureLOD;
class EXTsRGB;
-class EXTFragDepth;
class HTMLImageElement;
class ImageData;
class IntSize;
class KHRParallelShaderCompile;
+class OESElementIndexUint;
+class OESFBORenderMipmap;
class OESStandardDerivatives;
class OESTextureFloat;
class OESTextureFloatLinear;
@@ -93,8 +95,6 @@
class OESTextureHalfFloat;
class OESTextureHalfFloatLinear;
class OESVertexArrayObject;
-class OESElementIndexUint;
-class OESFBORenderMipmap;
#if ENABLE(OFFSCREEN_CANVAS)
class OffscreenCanvas;
#endif
@@ -119,8 +119,8 @@
class WebGLMultiDraw;
class WebGLObject;
class WebGLShader;
+class WebGLShaderPrecisionFormat;
class WebGLSharedObject;
-class WebGLShaderPrecisionFormat;
class WebGLUniformLocation;
#if ENABLE(VIDEO)
@@ -445,11 +445,7 @@
friend class EXTTextureCompressionBPTC;
friend class EXTTextureCompressionRGTC;
- friend class WebGLDrawBuffers;
- friend class WebGLFramebuffer;
- friend class WebGLObject;
friend class OESVertexArrayObject;
- friend class WebGLDebugShaders;
friend class WebGLCompressedTextureASTC;
friend class WebGLCompressedTextureATC;
friend class WebGLCompressedTextureETC;
@@ -457,12 +453,17 @@
friend class WebGLCompressedTexturePVRTC;
friend class WebGLCompressedTextureS3TC;
friend class WebGLCompressedTextureS3TCsRGB;
+ friend class WebGLDebugShaders;
+ friend class WebGLDrawBuffers;
friend class WebGLMultiDraw;
+
+ friend class WebGLFramebuffer;
+ friend class WebGLObject;
friend class WebGLRenderingContextErrorMessageCallback;
- friend class WebGLVertexArrayObjectOES;
+ friend class WebGLSync;
friend class WebGLVertexArrayObject;
friend class WebGLVertexArrayObjectBase;
- friend class WebGLSync;
+ friend class WebGLVertexArrayObjectOES;
// Implementation helpers.
friend class ScopedUnpackParametersResetRestore;
@@ -706,26 +707,28 @@
// Enabled extension objects.
// FIXME: Move some of these to WebGLRenderingContext, the ones not needed for WebGL2
+ RefPtr<ANGLEInstancedArrays> m_angleInstancedArrays;
+ RefPtr<EXTBlendMinMax> m_extBlendMinMax;
+ RefPtr<EXTColorBufferFloat> m_extColorBufferFloat;
+ RefPtr<EXTColorBufferHalfFloat> m_extColorBufferHalfFloat;
+ RefPtr<EXTFloatBlend> m_extFloatBlend;
RefPtr<EXTFragDepth> m_extFragDepth;
- RefPtr<EXTBlendMinMax> m_extBlendMinMax;
- RefPtr<EXTsRGB> m_extsRGB;
+ RefPtr<EXTShaderTextureLOD> m_extShaderTextureLOD;
RefPtr<EXTTextureCompressionBPTC> m_extTextureCompressionBPTC;
RefPtr<EXTTextureCompressionRGTC> m_extTextureCompressionRGTC;
RefPtr<EXTTextureFilterAnisotropic> m_extTextureFilterAnisotropic;
RefPtr<EXTTextureNorm16> m_extTextureNorm16;
- RefPtr<EXTShaderTextureLOD> m_extShaderTextureLOD;
+ RefPtr<EXTsRGB> m_extsRGB;
RefPtr<KHRParallelShaderCompile> m_khrParallelShaderCompile;
+ RefPtr<OESElementIndexUint> m_oesElementIndexUint;
+ RefPtr<OESFBORenderMipmap> m_oesFBORenderMipmap;
+ RefPtr<OESStandardDerivatives> m_oesStandardDerivatives;
RefPtr<OESTextureFloat> m_oesTextureFloat;
RefPtr<OESTextureFloatLinear> m_oesTextureFloatLinear;
RefPtr<OESTextureHalfFloat> m_oesTextureHalfFloat;
RefPtr<OESTextureHalfFloatLinear> m_oesTextureHalfFloatLinear;
- RefPtr<OESStandardDerivatives> m_oesStandardDerivatives;
RefPtr<OESVertexArrayObject> m_oesVertexArrayObject;
- RefPtr<OESElementIndexUint> m_oesElementIndexUint;
- RefPtr<OESFBORenderMipmap> m_oesFBORenderMipmap;
- RefPtr<WebGLLoseContext> m_webglLoseContext;
- RefPtr<WebGLDebugRendererInfo> m_webglDebugRendererInfo;
- RefPtr<WebGLDebugShaders> m_webglDebugShaders;
+ RefPtr<WebGLColorBufferFloat> m_webglColorBufferFloat;
RefPtr<WebGLCompressedTextureASTC> m_webglCompressedTextureASTC;
RefPtr<WebGLCompressedTextureATC> m_webglCompressedTextureATC;
RefPtr<WebGLCompressedTextureETC> m_webglCompressedTextureETC;
@@ -733,13 +736,11 @@
RefPtr<WebGLCompressedTexturePVRTC> m_webglCompressedTexturePVRTC;
RefPtr<WebGLCompressedTextureS3TC> m_webglCompressedTextureS3TC;
RefPtr<WebGLCompressedTextureS3TCsRGB> m_webglCompressedTextureS3TCsRGB;
+ RefPtr<WebGLDebugRendererInfo> m_webglDebugRendererInfo;
+ RefPtr<WebGLDebugShaders> m_webglDebugShaders;
RefPtr<WebGLDepthTexture> m_webglDepthTexture;
RefPtr<WebGLDrawBuffers> m_webglDrawBuffers;
- RefPtr<ANGLEInstancedArrays> m_angleInstancedArrays;
- RefPtr<EXTColorBufferHalfFloat> m_extColorBufferHalfFloat;
- RefPtr<EXTFloatBlend> m_extFloatBlend;
- RefPtr<WebGLColorBufferFloat> m_webglColorBufferFloat;
- RefPtr<EXTColorBufferFloat> m_extColorBufferFloat;
+ RefPtr<WebGLLoseContext> m_webglLoseContext;
RefPtr<WebGLMultiDraw> m_webglMultiDraw;
bool m_areWebGL2TexImageSourceFormatsAndTypesAdded { false };