From 26a029d407be480d791972afb5975cf62c9360a6 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 02:47:55 +0200 Subject: Adding upstream version 124.0.1. Signed-off-by: Daniel Baumann --- gfx/angle/checkout/LICENSE | 32 + gfx/angle/checkout/include/EGL/egl.h | 342 + gfx/angle/checkout/include/EGL/eglext.h | 1486 + gfx/angle/checkout/include/EGL/eglext_angle.h | 412 + gfx/angle/checkout/include/EGL/eglplatform.h | 175 + gfx/angle/checkout/include/GLES/gl.h | 743 + gfx/angle/checkout/include/GLES/glext.h | 962 + gfx/angle/checkout/include/GLES/glplatform.h | 38 + gfx/angle/checkout/include/GLES2/gl2.h | 656 + gfx/angle/checkout/include/GLES2/gl2ext.h | 3949 +++ gfx/angle/checkout/include/GLES2/gl2ext_angle.h | 667 + gfx/angle/checkout/include/GLES2/gl2platform.h | 27 + gfx/angle/checkout/include/GLES3/gl3.h | 1192 + gfx/angle/checkout/include/GLES3/gl31.h | 1507 + gfx/angle/checkout/include/GLES3/gl32.h | 1808 ++ gfx/angle/checkout/include/GLES3/gl3platform.h | 27 + gfx/angle/checkout/include/GLSLANG/ShaderLang.h | 1001 + gfx/angle/checkout/include/GLSLANG/ShaderVars.h | 331 + gfx/angle/checkout/include/GLX/glxext.h | 954 + gfx/angle/checkout/include/KHR/khrplatform.h | 290 + gfx/angle/checkout/include/WGL/wgl.h | 946 + gfx/angle/checkout/include/angle_gl.h | 27 + gfx/angle/checkout/include/export.h | 40 + gfx/angle/checkout/include/platform/Feature.h | 196 + .../include/platform/FeaturesD3D_autogen.h | 198 + .../checkout/include/platform/FeaturesGL_autogen.h | 501 + .../include/platform/FeaturesMtl_autogen.h | 242 + .../checkout/include/platform/FeaturesVk_autogen.h | 786 + .../include/platform/FrontendFeatures_autogen.h | 115 + .../checkout/include/platform/PlatformMethods.h | 334 + .../checkout/include/vulkan/vulkan_fuchsia_ext.h | 31 + gfx/angle/checkout/out/gen/angle/angle_commit.h | 5 + gfx/angle/checkout/src/common/CircularBuffer.h | 175 + gfx/angle/checkout/src/common/Color.h | 104 + gfx/angle/checkout/src/common/Color.inc | 69 + gfx/angle/checkout/src/common/FastVector.h | 891 + gfx/angle/checkout/src/common/FixedVector.h | 353 + gfx/angle/checkout/src/common/Float16ToFloat32.cpp | 300 + gfx/angle/checkout/src/common/MemoryBuffer.cpp | 179 + gfx/angle/checkout/src/common/MemoryBuffer.h | 93 + gfx/angle/checkout/src/common/Optional.h | 74 + .../checkout/src/common/PackedEGLEnums_autogen.cpp | 452 + .../checkout/src/common/PackedEGLEnums_autogen.h | 144 + gfx/angle/checkout/src/common/PackedEnums.cpp | 673 + gfx/angle/checkout/src/common/PackedEnums.h | 859 + .../checkout/src/common/PackedGLEnums_autogen.cpp | 2449 ++ .../checkout/src/common/PackedGLEnums_autogen.h | 610 + gfx/angle/checkout/src/common/PoolAlloc.cpp | 487 + gfx/angle/checkout/src/common/PoolAlloc.h | 181 + gfx/angle/checkout/src/common/Spinlock.h | 71 + gfx/angle/checkout/src/common/SynchronizedValue.h | 540 + gfx/angle/checkout/src/common/aligned_memory.cpp | 64 + gfx/angle/checkout/src/common/aligned_memory.h | 23 + gfx/angle/checkout/src/common/android_util.cpp | 424 + gfx/angle/checkout/src/common/android_util.h | 59 + gfx/angle/checkout/src/common/angle_version.h | 28 + .../checkout/src/common/angle_version_info.cpp | 40 + gfx/angle/checkout/src/common/angle_version_info.h | 20 + gfx/angle/checkout/src/common/angleutils.cpp | 156 + gfx/angle/checkout/src/common/angleutils.h | 601 + .../checkout/src/common/apple_platform_utils.h | 90 + gfx/angle/checkout/src/common/bitset_utils.h | 1106 + gfx/angle/checkout/src/common/debug.cpp | 349 + gfx/angle/checkout/src/common/debug.h | 468 + .../src/common/entry_points_enum_autogen.cpp | 3454 +++ .../src/common/entry_points_enum_autogen.h | 1736 ++ gfx/angle/checkout/src/common/event_tracer.cpp | 53 + gfx/angle/checkout/src/common/event_tracer.h | 26 + gfx/angle/checkout/src/common/hash_utils.h | 39 + gfx/angle/checkout/src/common/mathutil.cpp | 83 + gfx/angle/checkout/src/common/mathutil.h | 1482 + gfx/angle/checkout/src/common/matrix_utils.cpp | 285 + gfx/angle/checkout/src/common/matrix_utils.h | 424 + gfx/angle/checkout/src/common/platform.h | 209 + gfx/angle/checkout/src/common/spirv/spirv_types.h | 133 + gfx/angle/checkout/src/common/string_utils.cpp | 357 + gfx/angle/checkout/src/common/string_utils.h | 125 + gfx/angle/checkout/src/common/system_utils.cpp | 267 + gfx/angle/checkout/src/common/system_utils.h | 224 + .../checkout/src/common/system_utils_apple.cpp | 59 + .../checkout/src/common/system_utils_linux.cpp | 55 + gfx/angle/checkout/src/common/system_utils_mac.cpp | 28 + .../checkout/src/common/system_utils_posix.cpp | 470 + gfx/angle/checkout/src/common/system_utils_win.cpp | 264 + .../checkout/src/common/system_utils_win32.cpp | 235 + .../third_party/base/anglebase/base_export.h | 13 + .../base/anglebase/containers/mru_cache.h | 275 + .../common/third_party/base/anglebase/logging.h | 26 + .../src/common/third_party/base/anglebase/macros.h | 17 + .../third_party/base/anglebase/no_destructor.h | 106 + .../base/anglebase/numerics/checked_math.h | 384 + .../base/anglebase/numerics/checked_math_impl.h | 641 + .../base/anglebase/numerics/clamped_math.h | 270 + .../base/anglebase/numerics/clamped_math_impl.h | 368 + .../base/anglebase/numerics/math_constants.h | 20 + .../third_party/base/anglebase/numerics/ranges.h | 39 + .../base/anglebase/numerics/safe_conversions.h | 403 + .../anglebase/numerics/safe_conversions_arm_impl.h | 60 + .../anglebase/numerics/safe_conversions_impl.h | 893 + .../base/anglebase/numerics/safe_math.h | 12 + .../base/anglebase/numerics/safe_math_arm_impl.h | 131 + .../anglebase/numerics/safe_math_clang_gcc_impl.h | 182 + .../anglebase/numerics/safe_math_shared_impl.h | 227 + .../src/common/third_party/base/anglebase/sha1.cc | 245 + .../src/common/third_party/base/anglebase/sha1.h | 36 + .../third_party/base/anglebase/sys_byteorder.h | 49 + .../common/third_party/smhasher/src/PMurHash.cpp | 339 + .../src/common/third_party/smhasher/src/PMurHash.h | 57 + .../src/common/third_party/xxhash/xxhash.c | 1030 + .../src/common/third_party/xxhash/xxhash.h | 341 + gfx/angle/checkout/src/common/tls.cpp | 156 + gfx/angle/checkout/src/common/tls.h | 54 + .../src/common/uniform_type_info_autogen.cpp | 378 + gfx/angle/checkout/src/common/utilities.cpp | 1509 + gfx/angle/checkout/src/common/utilities.h | 336 + gfx/angle/checkout/src/common/vector_utils.h | 523 + .../src/common/vulkan/libvulkan_loader.cpp | 57 + .../checkout/src/common/vulkan/libvulkan_loader.h | 23 + .../common/vulkan/vk_google_filtering_precision.h | 57 + gfx/angle/checkout/src/common/vulkan/vk_headers.h | 163 + .../checkout/src/common/vulkan/vulkan_icd.cpp | 349 + gfx/angle/checkout/src/common/vulkan/vulkan_icd.h | 72 + .../src/compiler/preprocessor/DiagnosticsBase.cpp | 148 + .../src/compiler/preprocessor/DiagnosticsBase.h | 102 + .../compiler/preprocessor/DirectiveHandlerBase.cpp | 19 + .../compiler/preprocessor/DirectiveHandlerBase.h | 49 + .../src/compiler/preprocessor/DirectiveParser.cpp | 981 + .../src/compiler/preprocessor/DirectiveParser.h | 88 + .../src/compiler/preprocessor/ExpressionParser.h | 48 + .../checkout/src/compiler/preprocessor/Input.cpp | 130 + .../checkout/src/compiler/preprocessor/Input.h | 59 + .../checkout/src/compiler/preprocessor/Lexer.cpp | 19 + .../checkout/src/compiler/preprocessor/Lexer.h | 32 + .../checkout/src/compiler/preprocessor/Macro.cpp | 45 + .../checkout/src/compiler/preprocessor/Macro.h | 55 + .../src/compiler/preprocessor/MacroExpander.cpp | 531 + .../src/compiler/preprocessor/MacroExpander.h | 91 + .../src/compiler/preprocessor/Preprocessor.cpp | 107 + .../src/compiler/preprocessor/Preprocessor.h | 72 + .../src/compiler/preprocessor/SourceLocation.h | 44 + .../checkout/src/compiler/preprocessor/Token.cpp | 79 + .../checkout/src/compiler/preprocessor/Token.h | 115 + .../checkout/src/compiler/preprocessor/Tokenizer.h | 63 + .../src/compiler/preprocessor/numeric_lex.h | 54 + .../preprocessor/preprocessor_lex_autogen.cpp | 2626 ++ .../preprocessor/preprocessor_tab_autogen.cpp | 1773 ++ .../src/compiler/translator/ASTMetadataHLSL.cpp | 445 + .../src/compiler/translator/ASTMetadataHLSL.h | 62 + .../translator/AtomicCounterFunctionHLSL.cpp | 112 + .../translator/AtomicCounterFunctionHLSL.h | 50 + .../checkout/src/compiler/translator/BaseTypes.cpp | 64 + .../checkout/src/compiler/translator/BaseTypes.h | 1782 ++ .../translator/BuiltInFunctionEmulator.cpp | 161 + .../compiler/translator/BuiltInFunctionEmulator.h | 80 + .../translator/BuiltInFunctionEmulatorGLSL.cpp | 284 + .../translator/BuiltInFunctionEmulatorGLSL.h | 40 + .../translator/BuiltInFunctionEmulatorHLSL.cpp | 173 + .../translator/BuiltInFunctionEmulatorHLSL.h | 27 + .../compiler/translator/BuiltinsWorkaroundGLSL.cpp | 109 + .../compiler/translator/BuiltinsWorkaroundGLSL.h | 24 + .../checkout/src/compiler/translator/CallDAG.cpp | 316 + .../checkout/src/compiler/translator/CallDAG.h | 77 + .../checkout/src/compiler/translator/CodeGen.cpp | 96 + .../src/compiler/translator/CollectVariables.cpp | 1288 + .../src/compiler/translator/CollectVariables.h | 38 + .../checkout/src/compiler/translator/Common.h | 256 + .../checkout/src/compiler/translator/Compiler.cpp | 1746 ++ .../checkout/src/compiler/translator/Compiler.h | 397 + .../src/compiler/translator/ConstantUnion.cpp | 803 + .../src/compiler/translator/ConstantUnion.h | 122 + .../src/compiler/translator/Declarator.cpp | 33 + .../checkout/src/compiler/translator/Declarator.h | 49 + .../src/compiler/translator/Diagnostics.cpp | 106 + .../checkout/src/compiler/translator/Diagnostics.h | 67 + .../src/compiler/translator/DirectiveHandler.cpp | 304 + .../src/compiler/translator/DirectiveHandler.h | 57 + .../src/compiler/translator/DriverUniformMetal.h | 33 + .../src/compiler/translator/ExtensionBehavior.cpp | 125 + .../src/compiler/translator/ExtensionBehavior.h | 93 + .../src/compiler/translator/ExtensionGLSL.cpp | 118 + .../src/compiler/translator/ExtensionGLSL.h | 44 + .../src/compiler/translator/FlagStd140Structs.cpp | 76 + .../src/compiler/translator/FlagStd140Structs.h | 30 + .../src/compiler/translator/FunctionLookup.cpp | 179 + .../src/compiler/translator/FunctionLookup.h | 60 + .../checkout/src/compiler/translator/HashNames.cpp | 99 + .../checkout/src/compiler/translator/HashNames.h | 33 + .../src/compiler/translator/ImageFunctionHLSL.cpp | 401 + .../src/compiler/translator/ImageFunctionHLSL.h | 96 + .../src/compiler/translator/ImmutableString.h | 143 + .../compiler/translator/ImmutableStringBuilder.cpp | 63 + .../compiler/translator/ImmutableStringBuilder.h | 80 + .../translator/ImmutableString_ESSL_autogen.cpp | 345 + .../checkout/src/compiler/translator/InfoSink.cpp | 124 + .../checkout/src/compiler/translator/InfoSink.h | 152 + .../src/compiler/translator/Initialize.cpp | 223 + .../checkout/src/compiler/translator/Initialize.h | 30 + .../src/compiler/translator/InitializeDll.cpp | 33 + .../src/compiler/translator/InitializeDll.h | 15 + .../src/compiler/translator/InitializeGlobals.h | 13 + .../src/compiler/translator/IntermNode.cpp | 4226 +++ .../checkout/src/compiler/translator/IntermNode.h | 1046 + .../compiler/translator/IsASTDepthBelowLimit.cpp | 37 + .../src/compiler/translator/IsASTDepthBelowLimit.h | 20 + .../checkout/src/compiler/translator/Operator.cpp | 171 + .../src/compiler/translator/Operator_autogen.h | 578 + .../src/compiler/translator/OutputESSL.cpp | 55 + .../checkout/src/compiler/translator/OutputESSL.h | 30 + .../src/compiler/translator/OutputGLSL.cpp | 122 + .../checkout/src/compiler/translator/OutputGLSL.h | 31 + .../src/compiler/translator/OutputGLSLBase.cpp | 1513 + .../src/compiler/translator/OutputGLSLBase.h | 154 + .../src/compiler/translator/OutputHLSL.cpp | 3700 +++ .../checkout/src/compiler/translator/OutputHLSL.h | 289 + .../src/compiler/translator/OutputTree.cpp | 723 + .../checkout/src/compiler/translator/OutputTree.h | 22 + .../src/compiler/translator/ParseContext.cpp | 7538 +++++ .../src/compiler/translator/ParseContext.h | 818 + .../checkout/src/compiler/translator/PoolAlloc.cpp | 40 + .../checkout/src/compiler/translator/PoolAlloc.h | 102 + .../checkout/src/compiler/translator/Pragma.h | 28 + .../src/compiler/translator/QualifierTypes.cpp | 1007 + .../src/compiler/translator/QualifierTypes.h | 214 + .../src/compiler/translator/ResourcesHLSL.cpp | 989 + .../src/compiler/translator/ResourcesHLSL.h | 155 + .../checkout/src/compiler/translator/Severity.h | 22 + .../src/compiler/translator/ShaderLang.cpp | 1091 + .../translator/ShaderStorageBlockFunctionHLSL.cpp | 439 + .../translator/ShaderStorageBlockFunctionHLSL.h | 94 + .../translator/ShaderStorageBlockOutputHLSL.cpp | 667 + .../translator/ShaderStorageBlockOutputHLSL.h | 86 + .../src/compiler/translator/ShaderVars.cpp | 625 + .../checkout/src/compiler/translator/StaticType.h | 296 + .../src/compiler/translator/StructureHLSL.cpp | 668 + .../src/compiler/translator/StructureHLSL.h | 102 + .../checkout/src/compiler/translator/Symbol.cpp | 254 + .../checkout/src/compiler/translator/Symbol.h | 402 + .../src/compiler/translator/SymbolTable.cpp | 559 + .../checkout/src/compiler/translator/SymbolTable.h | 363 + .../translator/SymbolTable_ESSL_autogen.cpp | 30071 +++++++++++++++++++ .../src/compiler/translator/SymbolTable_autogen.h | 169 + .../src/compiler/translator/SymbolUniqueId.cpp | 27 + .../src/compiler/translator/SymbolUniqueId.h | 58 + .../compiler/translator/TextureFunctionHLSL.cpp | 1614 + .../src/compiler/translator/TextureFunctionHLSL.h | 77 + .../src/compiler/translator/TranslatorESSL.cpp | 219 + .../src/compiler/translator/TranslatorESSL.h | 35 + .../src/compiler/translator/TranslatorGLSL.cpp | 388 + .../src/compiler/translator/TranslatorGLSL.h | 38 + .../src/compiler/translator/TranslatorHLSL.cpp | 311 + .../src/compiler/translator/TranslatorHLSL.h | 56 + .../src/compiler/translator/TranslatorMetal.h | 62 + .../compiler/translator/TranslatorMetalDirect.h | 195 + .../src/compiler/translator/TranslatorVulkan.h | 60 + .../checkout/src/compiler/translator/Types.cpp | 984 + gfx/angle/checkout/src/compiler/translator/Types.h | 508 + .../checkout/src/compiler/translator/UtilsHLSL.cpp | 1223 + .../checkout/src/compiler/translator/UtilsHLSL.h | 148 + .../src/compiler/translator/ValidateAST.cpp | 1133 + .../checkout/src/compiler/translator/ValidateAST.h | 108 + .../translator/ValidateBarrierFunctionCall.cpp | 100 + .../translator/ValidateBarrierFunctionCall.h | 22 + .../translator/ValidateClipCullDistance.cpp | 200 + .../compiler/translator/ValidateClipCullDistance.h | 27 + .../translator/ValidateGlobalInitializer.cpp | 157 + .../translator/ValidateGlobalInitializer.h | 24 + .../compiler/translator/ValidateLimitations.cpp | 452 + .../src/compiler/translator/ValidateLimitations.h | 26 + .../compiler/translator/ValidateMaxParameters.cpp | 30 + .../compiler/translator/ValidateMaxParameters.h | 21 + .../src/compiler/translator/ValidateOutputs.cpp | 184 + .../src/compiler/translator/ValidateOutputs.h | 30 + .../src/compiler/translator/ValidateSwitch.cpp | 315 + .../src/compiler/translator/ValidateSwitch.h | 27 + .../translator/ValidateTypeSizeLimitations.cpp | 229 + .../translator/ValidateTypeSizeLimitations.h | 25 + .../translator/ValidateVaryingLocations.cpp | 368 + .../compiler/translator/ValidateVaryingLocations.h | 28 + .../src/compiler/translator/VariablePacker.cpp | 409 + .../src/compiler/translator/VariablePacker.h | 32 + .../src/compiler/translator/VersionGLSL.cpp | 156 + .../checkout/src/compiler/translator/VersionGLSL.h | 76 + .../src/compiler/translator/blocklayout.cpp | 666 + .../checkout/src/compiler/translator/blocklayout.h | 322 + .../src/compiler/translator/blocklayoutHLSL.cpp | 167 + .../src/compiler/translator/blocklayoutHLSL.h | 68 + .../emulated_builtin_functions_hlsl_autogen.cpp | 881 + .../checkout/src/compiler/translator/glslang.h | 24 + .../compiler/translator/glslang_lex_autogen.cpp | 4326 +++ .../compiler/translator/glslang_tab_autogen.cpp | 4909 +++ .../src/compiler/translator/glslang_tab_autogen.h | 320 + .../src/compiler/translator/glslang_wrapper.h | 46 + .../src/compiler/translator/length_limits.h | 26 + .../translator/tree_ops/ClampIndirectIndices.cpp | 136 + .../translator/tree_ops/ClampIndirectIndices.h | 27 + .../translator/tree_ops/ClampPointSize.cpp | 52 + .../compiler/translator/tree_ops/ClampPointSize.h | 28 + ...nvertUnsupportedConstructorsToFunctionCalls.cpp | 335 + ...ConvertUnsupportedConstructorsToFunctionCalls.h | 25 + ...DeclareAndInitBuiltinsForInstancedMultiview.cpp | 196 + .../DeclareAndInitBuiltinsForInstancedMultiview.h | 52 + .../tree_ops/DeferGlobalInitializers.cpp | 180 + .../translator/tree_ops/DeferGlobalInitializers.h | 38 + .../tree_ops/EmulateGLFragColorBroadcast.cpp | 142 + .../tree_ops/EmulateGLFragColorBroadcast.h | 35 + .../tree_ops/EmulateMultiDrawShaderBuiltins.cpp | 274 + .../tree_ops/EmulateMultiDrawShaderBuiltins.h | 47 + .../translator/tree_ops/FoldExpressions.cpp | 120 + .../compiler/translator/tree_ops/FoldExpressions.h | 29 + .../tree_ops/ForcePrecisionQualifier.cpp | 101 + .../translator/tree_ops/ForcePrecisionQualifier.h | 17 + .../translator/tree_ops/InitializeVariables.cpp | 359 + .../translator/tree_ops/InitializeVariables.h | 60 + .../tree_ops/MonomorphizeUnsupportedFunctions.cpp | 613 + .../tree_ops/MonomorphizeUnsupportedFunctions.h | 54 + .../tree_ops/NameNamelessUniformBuffers.cpp | 127 + .../tree_ops/NameNamelessUniformBuffers.h | 32 + .../translator/tree_ops/PruneEmptyCases.cpp | 127 + .../compiler/translator/tree_ops/PruneEmptyCases.h | 22 + .../compiler/translator/tree_ops/PruneNoOps.cpp | 215 + .../src/compiler/translator/tree_ops/PruneNoOps.h | 29 + .../tree_ops/RecordConstantPrecision.cpp | 119 + .../translator/tree_ops/RecordConstantPrecision.h | 33 + .../tree_ops/RemoveArrayLengthMethod.cpp | 109 + .../translator/tree_ops/RemoveArrayLengthMethod.h | 37 + .../tree_ops/RemoveAtomicCounterBuiltins.cpp | 74 + .../tree_ops/RemoveAtomicCounterBuiltins.h | 24 + .../translator/tree_ops/RemoveDynamicIndexing.cpp | 597 + .../translator/tree_ops/RemoveDynamicIndexing.h | 41 + .../tree_ops/RemoveInactiveInterfaceVariables.cpp | 209 + .../tree_ops/RemoveInactiveInterfaceVariables.h | 42 + .../tree_ops/RemoveInvariantDeclaration.cpp | 47 + .../tree_ops/RemoveInvariantDeclaration.h | 21 + .../tree_ops/RemoveUnreferencedVariables.cpp | 371 + .../tree_ops/RemoveUnreferencedVariables.h | 29 + .../RewriteArrayOfArrayOfOpaqueUniforms.cpp | 348 + .../tree_ops/RewriteArrayOfArrayOfOpaqueUniforms.h | 25 + .../translator/tree_ops/RewriteAtomicCounters.cpp | 328 + .../translator/tree_ops/RewriteAtomicCounters.h | 28 + .../tree_ops/RewriteCubeMapSamplersAs2DArray.cpp | 984 + .../tree_ops/RewriteCubeMapSamplersAs2DArray.h | 29 + .../compiler/translator/tree_ops/RewriteDfdy.cpp | 141 + .../src/compiler/translator/tree_ops/RewriteDfdy.h | 32 + .../tree_ops/RewritePixelLocalStorage.cpp | 861 + .../translator/tree_ops/RewritePixelLocalStorage.h | 29 + .../translator/tree_ops/RewriteStructSamplers.cpp | 673 + .../translator/tree_ops/RewriteStructSamplers.h | 38 + .../tree_ops/RewriteTexelFetchOffset.cpp | 168 + .../translator/tree_ops/RewriteTexelFetchOffset.h | 34 + .../tree_ops/ScalarizeVecAndMatConstructorArgs.cpp | 223 + .../tree_ops/ScalarizeVecAndMatConstructorArgs.h | 28 + .../translator/tree_ops/SeparateDeclarations.cpp | 199 + .../translator/tree_ops/SeparateDeclarations.h | 32 + .../SeparateStructFromUniformDeclarations.cpp | 115 + .../SeparateStructFromUniformDeclarations.h | 39 + .../translator/tree_ops/SimplifyLoopConditions.cpp | 499 + .../translator/tree_ops/SimplifyLoopConditions.h | 32 + .../translator/tree_ops/SplitSequenceOperator.cpp | 173 + .../translator/tree_ops/SplitSequenceOperator.h | 30 + .../tree_ops/apple/AddAndTrueToLoopCondition.cpp | 60 + .../tree_ops/apple/AddAndTrueToLoopCondition.h | 31 + .../translator/tree_ops/apple/RewriteDoWhile.cpp | 147 + .../translator/tree_ops/apple/RewriteDoWhile.h | 38 + .../tree_ops/apple/RewriteRowMajorMatrices.cpp | 1595 + .../tree_ops/apple/RewriteRowMajorMatrices.h | 37 + .../apple/RewriteUnaryMinusOperatorFloat.cpp | 97 + .../apple/RewriteUnaryMinusOperatorFloat.h | 31 + .../tree_ops/apple/UnfoldShortCircuitAST.cpp | 74 + .../tree_ops/apple/UnfoldShortCircuitAST.h | 33 + .../tree_ops/d3d/AddDefaultReturnStatements.cpp | 61 + .../tree_ops/d3d/AddDefaultReturnStatements.h | 24 + .../tree_ops/d3d/AggregateAssignArraysInSSBOs.cpp | 82 + .../tree_ops/d3d/AggregateAssignArraysInSSBOs.h | 23 + .../tree_ops/d3d/AggregateAssignStructsInSSBOs.cpp | 76 + .../tree_ops/d3d/AggregateAssignStructsInSSBOs.h | 23 + .../d3d/ArrayReturnValueToOutParameter.cpp | 233 + .../tree_ops/d3d/ArrayReturnValueToOutParameter.h | 27 + .../d3d/BreakVariableAliasingInInnerLoops.cpp | 110 + .../d3d/BreakVariableAliasingInInnerLoops.h | 25 + .../tree_ops/d3d/ExpandIntegerPowExpressions.cpp | 152 + .../tree_ops/d3d/ExpandIntegerPowExpressions.h | 34 + .../RecordUniformBlocksWithLargeArrayMember.cpp | 385 + .../d3d/RecordUniformBlocksWithLargeArrayMember.h | 28 + .../tree_ops/d3d/RemoveSwitchFallThrough.cpp | 270 + .../tree_ops/d3d/RemoveSwitchFallThrough.h | 27 + .../d3d/RewriteAtomicFunctionExpressions.cpp | 183 + .../d3d/RewriteAtomicFunctionExpressions.h | 42 + .../translator/tree_ops/d3d/RewriteElseBlocks.cpp | 123 + .../translator/tree_ops/d3d/RewriteElseBlocks.h | 27 + .../RewriteExpressionsWithShaderStorageBlock.cpp | 420 + .../d3d/RewriteExpressionsWithShaderStorageBlock.h | 37 + .../tree_ops/d3d/RewriteUnaryMinusOperatorInt.cpp | 117 + .../tree_ops/d3d/RewriteUnaryMinusOperatorInt.h | 23 + .../d3d/SeparateArrayConstructorStatements.cpp | 83 + .../d3d/SeparateArrayConstructorStatements.h | 25 + .../tree_ops/d3d/SeparateArrayInitialization.cpp | 89 + .../tree_ops/d3d/SeparateArrayInitialization.h | 32 + .../d3d/SeparateExpressionsReturningArrays.cpp | 138 + .../d3d/SeparateExpressionsReturningArrays.h | 28 + .../tree_ops/d3d/UnfoldShortCircuitToIf.cpp | 200 + .../tree_ops/d3d/UnfoldShortCircuitToIf.h | 30 + .../tree_ops/d3d/WrapSwitchStatementsInBlocks.cpp | 126 + .../tree_ops/d3d/WrapSwitchStatementsInBlocks.h | 25 + .../translator/tree_ops/gl/ClampFragDepth.cpp | 54 + .../translator/tree_ops/gl/ClampFragDepth.h | 39 + .../tree_ops/gl/RegenerateStructNames.cpp | 119 + .../translator/tree_ops/gl/RegenerateStructNames.h | 34 + .../gl/RewriteRepeatedAssignToSwizzled.cpp | 97 + .../tree_ops/gl/RewriteRepeatedAssignToSwizzled.h | 40 + .../tree_ops/gl/UseInterfaceBlockFields.cpp | 108 + .../tree_ops/gl/UseInterfaceBlockFields.h | 44 + .../src/compiler/translator/tree_util/AsNode.h | 212 + .../src/compiler/translator/tree_util/BuiltIn.h | 18 + .../translator/tree_util/BuiltIn_ESSL_autogen.h | 4177 +++ .../tree_util/BuiltIn_complete_autogen.h | 5008 +++ .../translator/tree_util/DriverUniform.cpp | 435 + .../compiler/translator/tree_util/DriverUniform.h | 110 + .../compiler/translator/tree_util/FindFunction.cpp | 32 + .../compiler/translator/tree_util/FindFunction.h | 21 + .../src/compiler/translator/tree_util/FindMain.cpp | 54 + .../src/compiler/translator/tree_util/FindMain.h | 24 + .../translator/tree_util/FindPreciseNodes.cpp | 703 + .../translator/tree_util/FindPreciseNodes.h | 25 + .../translator/tree_util/FindSymbolNode.cpp | 53 + .../compiler/translator/tree_util/FindSymbolNode.h | 23 + .../tree_util/IntermNodePatternMatcher.cpp | 213 + .../tree_util/IntermNodePatternMatcher.h | 81 + .../translator/tree_util/IntermNode_util.cpp | 436 + .../translator/tree_util/IntermNode_util.h | 128 + .../translator/tree_util/IntermRebuild.cpp | 1046 + .../compiler/translator/tree_util/IntermRebuild.h | 328 + .../translator/tree_util/IntermTraverse.cpp | 708 + .../compiler/translator/tree_util/IntermTraverse.h | 379 + .../src/compiler/translator/tree_util/NodeSearch.h | 56 + .../src/compiler/translator/tree_util/NodeType.h | 155 + .../tree_util/ReplaceArrayOfMatrixVarying.cpp | 175 + .../tree_util/ReplaceArrayOfMatrixVarying.h | 33 + .../tree_util/ReplaceClipCullDistanceVariable.cpp | 591 + .../tree_util/ReplaceClipCullDistanceVariable.h | 43 + .../tree_util/ReplaceShadowingVariables.cpp | 142 + .../tree_util/ReplaceShadowingVariables.h | 26 + .../translator/tree_util/ReplaceVariable.cpp | 145 + .../translator/tree_util/ReplaceVariable.h | 48 + .../tree_util/RewriteSampleMaskVariable.cpp | 198 + .../tree_util/RewriteSampleMaskVariable.h | 38 + .../tree_util/RunAtTheBeginningOfShader.cpp | 35 + .../tree_util/RunAtTheBeginningOfShader.h | 27 + .../translator/tree_util/RunAtTheEndOfShader.cpp | 129 + .../translator/tree_util/RunAtTheEndOfShader.h | 29 + .../tree_util/SpecializationConstant.cpp | 122 + .../translator/tree_util/SpecializationConstant.h | 55 + .../src/compiler/translator/tree_util/Visit.h | 22 + .../checkout/src/compiler/translator/util.cpp | 1023 + gfx/angle/checkout/src/compiler/translator/util.h | 108 + .../checkout/src/gpu_info_util/SystemInfo.cpp | 418 + gfx/angle/checkout/src/gpu_info_util/SystemInfo.h | 179 + .../src/gpu_info_util/SystemInfo_internal.h | 42 + .../src/gpu_info_util/SystemInfo_vulkan.cpp | 284 + .../checkout/src/gpu_info_util/SystemInfo_vulkan.h | 23 + .../checkout/src/gpu_info_util/SystemInfo_win.cpp | 117 + gfx/angle/checkout/src/image_util/copyimage.cpp | 74 + gfx/angle/checkout/src/image_util/copyimage.h | 46 + gfx/angle/checkout/src/image_util/copyimage.inc | 38 + gfx/angle/checkout/src/image_util/generatemip.h | 34 + gfx/angle/checkout/src/image_util/generatemip.inc | 268 + gfx/angle/checkout/src/image_util/imageformats.cpp | 1954 ++ gfx/angle/checkout/src/image_util/imageformats.h | 816 + gfx/angle/checkout/src/image_util/loadimage.cpp | 1796 ++ gfx/angle/checkout/src/image_util/loadimage.h | 976 + gfx/angle/checkout/src/image_util/loadimage.inc | 201 + .../checkout/src/image_util/loadimage_astc.cpp | 84 + .../checkout/src/image_util/loadimage_etc.cpp | 1994 ++ .../checkout/src/image_util/loadimage_paletted.cpp | 158 + gfx/angle/checkout/src/libANGLE/AttributeMap.cpp | 147 + gfx/angle/checkout/src/libANGLE/AttributeMap.h | 100 + gfx/angle/checkout/src/libANGLE/BinaryStream.h | 286 + gfx/angle/checkout/src/libANGLE/BlobCache.cpp | 277 + gfx/angle/checkout/src/libANGLE/BlobCache.h | 182 + gfx/angle/checkout/src/libANGLE/Buffer.cpp | 449 + gfx/angle/checkout/src/libANGLE/Buffer.h | 218 + gfx/angle/checkout/src/libANGLE/Caps.cpp | 1371 + gfx/angle/checkout/src/libANGLE/Caps.h | 786 + gfx/angle/checkout/src/libANGLE/Compiler.cpp | 422 + gfx/angle/checkout/src/libANGLE/Compiler.h | 78 + gfx/angle/checkout/src/libANGLE/Config.cpp | 416 + gfx/angle/checkout/src/libANGLE/Config.h | 115 + gfx/angle/checkout/src/libANGLE/Constants.h | 125 + gfx/angle/checkout/src/libANGLE/Context.cpp | 10472 +++++++ gfx/angle/checkout/src/libANGLE/Context.h | 901 + gfx/angle/checkout/src/libANGLE/Context.inl.h | 176 + gfx/angle/checkout/src/libANGLE/Context_gl.cpp | 3706 +++ .../checkout/src/libANGLE/Context_gl_1_autogen.h | 349 + .../checkout/src/libANGLE/Context_gl_2_autogen.h | 44 + .../checkout/src/libANGLE/Context_gl_3_autogen.h | 82 + .../checkout/src/libANGLE/Context_gl_4_autogen.h | 358 + .../checkout/src/libANGLE/Context_gles_1_0.cpp | 746 + .../src/libANGLE/Context_gles_1_0_autogen.h | 109 + .../src/libANGLE/Context_gles_2_0_autogen.h | 190 + .../src/libANGLE/Context_gles_3_0_autogen.h | 164 + .../src/libANGLE/Context_gles_3_1_autogen.h | 133 + .../src/libANGLE/Context_gles_3_2_autogen.h | 83 + .../src/libANGLE/Context_gles_ext_autogen.h | 616 + gfx/angle/checkout/src/libANGLE/Debug.cpp | 507 + gfx/angle/checkout/src/libANGLE/Debug.h | 180 + gfx/angle/checkout/src/libANGLE/Device.cpp | 133 + gfx/angle/checkout/src/libANGLE/Device.h | 60 + gfx/angle/checkout/src/libANGLE/Display.cpp | 2506 ++ gfx/angle/checkout/src/libANGLE/Display.h | 427 + gfx/angle/checkout/src/libANGLE/EGLSync.cpp | 114 + gfx/angle/checkout/src/libANGLE/EGLSync.h | 72 + gfx/angle/checkout/src/libANGLE/Error.cpp | 67 + gfx/angle/checkout/src/libANGLE/Error.h | 206 + gfx/angle/checkout/src/libANGLE/Error.inc | 91 + gfx/angle/checkout/src/libANGLE/ErrorStrings.h | 627 + gfx/angle/checkout/src/libANGLE/Fence.cpp | 124 + gfx/angle/checkout/src/libANGLE/Fence.h | 88 + gfx/angle/checkout/src/libANGLE/Framebuffer.cpp | 2727 ++ gfx/angle/checkout/src/libANGLE/Framebuffer.h | 538 + .../src/libANGLE/FramebufferAttachment.cpp | 350 + .../checkout/src/libANGLE/FramebufferAttachment.h | 307 + gfx/angle/checkout/src/libANGLE/GLES1Renderer.cpp | 1197 + gfx/angle/checkout/src/libANGLE/GLES1Renderer.h | 340 + gfx/angle/checkout/src/libANGLE/GLES1Shaders.inc | 1218 + gfx/angle/checkout/src/libANGLE/GLES1State.cpp | 609 + gfx/angle/checkout/src/libANGLE/GLES1State.h | 351 + .../checkout/src/libANGLE/HandleAllocator.cpp | 184 + gfx/angle/checkout/src/libANGLE/HandleAllocator.h | 65 + gfx/angle/checkout/src/libANGLE/Image.cpp | 581 + gfx/angle/checkout/src/libANGLE/Image.h | 216 + gfx/angle/checkout/src/libANGLE/ImageIndex.cpp | 388 + gfx/angle/checkout/src/libANGLE/ImageIndex.h | 133 + .../checkout/src/libANGLE/IndexRangeCache.cpp | 116 + gfx/angle/checkout/src/libANGLE/IndexRangeCache.h | 63 + gfx/angle/checkout/src/libANGLE/InfoLog.h | 90 + .../checkout/src/libANGLE/LoggingAnnotator.cpp | 63 + gfx/angle/checkout/src/libANGLE/LoggingAnnotator.h | 39 + gfx/angle/checkout/src/libANGLE/MemoryObject.cpp | 66 + gfx/angle/checkout/src/libANGLE/MemoryObject.h | 60 + .../checkout/src/libANGLE/MemoryProgramCache.cpp | 283 + .../checkout/src/libANGLE/MemoryProgramCache.h | 87 + .../checkout/src/libANGLE/MemoryShaderCache.cpp | 155 + .../checkout/src/libANGLE/MemoryShaderCache.h | 60 + gfx/angle/checkout/src/libANGLE/Observer.cpp | 113 + gfx/angle/checkout/src/libANGLE/Observer.h | 167 + gfx/angle/checkout/src/libANGLE/Overlay.cpp | 103 + gfx/angle/checkout/src/libANGLE/Overlay.h | 154 + gfx/angle/checkout/src/libANGLE/OverlayWidgets.cpp | 737 + gfx/angle/checkout/src/libANGLE/OverlayWidgets.h | 201 + .../checkout/src/libANGLE/Overlay_autogen.cpp | 824 + gfx/angle/checkout/src/libANGLE/Overlay_autogen.h | 83 + .../checkout/src/libANGLE/Overlay_font_autogen.cpp | 5078 ++++ .../checkout/src/libANGLE/Overlay_font_autogen.h | 27 + .../checkout/src/libANGLE/PixelLocalStorage.cpp | 826 + .../checkout/src/libANGLE/PixelLocalStorage.h | 177 + gfx/angle/checkout/src/libANGLE/Platform.cpp | 76 + gfx/angle/checkout/src/libANGLE/Program.cpp | 3810 +++ gfx/angle/checkout/src/libANGLE/Program.h | 897 + .../checkout/src/libANGLE/ProgramExecutable.cpp | 1785 ++ .../checkout/src/libANGLE/ProgramExecutable.h | 517 + .../src/libANGLE/ProgramLinkedResources.cpp | 2377 ++ .../checkout/src/libANGLE/ProgramLinkedResources.h | 333 + .../checkout/src/libANGLE/ProgramPipeline.cpp | 721 + gfx/angle/checkout/src/libANGLE/ProgramPipeline.h | 176 + gfx/angle/checkout/src/libANGLE/Query.cpp | 96 + gfx/angle/checkout/src/libANGLE/Query.h | 60 + gfx/angle/checkout/src/libANGLE/RefCountObject.h | 327 + gfx/angle/checkout/src/libANGLE/Renderbuffer.cpp | 423 + gfx/angle/checkout/src/libANGLE/Renderbuffer.h | 181 + .../checkout/src/libANGLE/ResourceManager.cpp | 522 + gfx/angle/checkout/src/libANGLE/ResourceManager.h | 353 + gfx/angle/checkout/src/libANGLE/ResourceMap.h | 346 + gfx/angle/checkout/src/libANGLE/Sampler.cpp | 211 + gfx/angle/checkout/src/libANGLE/Sampler.h | 92 + gfx/angle/checkout/src/libANGLE/Semaphore.cpp | 52 + gfx/angle/checkout/src/libANGLE/Semaphore.h | 57 + gfx/angle/checkout/src/libANGLE/Shader.cpp | 1331 + gfx/angle/checkout/src/libANGLE/Shader.h | 305 + gfx/angle/checkout/src/libANGLE/SizedMRUCache.h | 156 + gfx/angle/checkout/src/libANGLE/State.cpp | 3866 +++ gfx/angle/checkout/src/libANGLE/State.h | 1258 + gfx/angle/checkout/src/libANGLE/Stream.cpp | 282 + gfx/angle/checkout/src/libANGLE/Stream.h | 149 + gfx/angle/checkout/src/libANGLE/Surface.cpp | 941 + gfx/angle/checkout/src/libANGLE/Surface.h | 388 + gfx/angle/checkout/src/libANGLE/Texture.cpp | 2494 ++ gfx/angle/checkout/src/libANGLE/Texture.h | 738 + gfx/angle/checkout/src/libANGLE/Thread.cpp | 168 + gfx/angle/checkout/src/libANGLE/Thread.h | 80 + .../checkout/src/libANGLE/TransformFeedback.cpp | 347 + .../checkout/src/libANGLE/TransformFeedback.h | 120 + gfx/angle/checkout/src/libANGLE/Uniform.cpp | 179 + gfx/angle/checkout/src/libANGLE/Uniform.h | 138 + gfx/angle/checkout/src/libANGLE/VaryingPacking.cpp | 1152 + gfx/angle/checkout/src/libANGLE/VaryingPacking.h | 329 + gfx/angle/checkout/src/libANGLE/Version.h | 34 + gfx/angle/checkout/src/libANGLE/Version.inc | 59 + gfx/angle/checkout/src/libANGLE/VertexArray.cpp | 906 + gfx/angle/checkout/src/libANGLE/VertexArray.h | 436 + .../checkout/src/libANGLE/VertexAttribute.cpp | 170 + gfx/angle/checkout/src/libANGLE/VertexAttribute.h | 139 + .../checkout/src/libANGLE/VertexAttribute.inc | 58 + gfx/angle/checkout/src/libANGLE/WorkerThread.cpp | 356 + gfx/angle/checkout/src/libANGLE/WorkerThread.h | 94 + gfx/angle/checkout/src/libANGLE/angletypes.cpp | 1039 + gfx/angle/checkout/src/libANGLE/angletypes.h | 1203 + gfx/angle/checkout/src/libANGLE/angletypes.inc | 35 + .../checkout/src/libANGLE/capture/FrameCapture.h | 1208 + .../src/libANGLE/capture/FrameCapture_mock.cpp | 55 + .../checkout/src/libANGLE/capture/capture_egl.h | 69 + .../src/libANGLE/capture/capture_gl_1_autogen.h | 2072 ++ .../src/libANGLE/capture/capture_gl_2_autogen.h | 266 + .../src/libANGLE/capture/capture_gl_3_autogen.h | 609 + .../src/libANGLE/capture/capture_gl_4_autogen.h | 2524 ++ .../libANGLE/capture/capture_gles_1_0_autogen.h | 582 + .../libANGLE/capture/capture_gles_2_0_autogen.h | 1195 + .../libANGLE/capture/capture_gles_3_0_autogen.h | 1079 + .../libANGLE/capture/capture_gles_3_1_autogen.h | 728 + .../libANGLE/capture/capture_gles_3_2_autogen.h | 553 + .../libANGLE/capture/capture_gles_ext_autogen.h | 5231 ++++ .../src/libANGLE/capture/frame_capture_utils.h | 23 + .../libANGLE/capture/frame_capture_utils_autogen.h | 3257 ++ .../libANGLE/capture/frame_capture_utils_mock.cpp | 19 + .../checkout/src/libANGLE/capture/gl_enum_utils.h | 32 + .../src/libANGLE/capture/gl_enum_utils_autogen.h | 419 + .../checkout/src/libANGLE/entry_points_utils.h | 127 + .../libANGLE/es3_copy_conversion_table_autogen.cpp | 171 + gfx/angle/checkout/src/libANGLE/features.h | 56 + .../checkout/src/libANGLE/format_map_autogen.cpp | 1781 ++ .../checkout/src/libANGLE/format_map_desktop.cpp | 128 + gfx/angle/checkout/src/libANGLE/formatutils.cpp | 3220 ++ gfx/angle/checkout/src/libANGLE/formatutils.h | 577 + .../src/libANGLE/gles_extensions_autogen.cpp | 278 + .../src/libANGLE/gles_extensions_autogen.h | 727 + gfx/angle/checkout/src/libANGLE/histogram_macros.h | 110 + .../checkout/src/libANGLE/queryconversions.cpp | 315 + gfx/angle/checkout/src/libANGLE/queryconversions.h | 138 + gfx/angle/checkout/src/libANGLE/queryutils.cpp | 4525 +++ gfx/angle/checkout/src/libANGLE/queryutils.h | 293 + .../checkout/src/libANGLE/renderer/BufferImpl.cpp | 39 + .../checkout/src/libANGLE/renderer/BufferImpl.h | 98 + .../checkout/src/libANGLE/renderer/CompilerImpl.h | 32 + .../checkout/src/libANGLE/renderer/ContextImpl.cpp | 88 + .../checkout/src/libANGLE/renderer/ContextImpl.h | 274 + .../checkout/src/libANGLE/renderer/DeviceImpl.cpp | 18 + .../checkout/src/libANGLE/renderer/DeviceImpl.h | 42 + .../checkout/src/libANGLE/renderer/DisplayImpl.cpp | 168 + .../checkout/src/libANGLE/renderer/DisplayImpl.h | 169 + .../src/libANGLE/renderer/EGLImplFactory.h | 104 + .../src/libANGLE/renderer/EGLReusableSync.cpp | 116 + .../src/libANGLE/renderer/EGLReusableSync.h | 54 + .../checkout/src/libANGLE/renderer/EGLSyncImpl.cpp | 37 + .../checkout/src/libANGLE/renderer/EGLSyncImpl.h | 57 + .../checkout/src/libANGLE/renderer/FenceNVImpl.h | 38 + gfx/angle/checkout/src/libANGLE/renderer/Format.h | 238 + .../src/libANGLE/renderer/FormatID_autogen.h | 264 + .../src/libANGLE/renderer/Format_table_autogen.cpp | 762 + .../renderer/FramebufferAttachmentObjectImpl.h | 65 + .../src/libANGLE/renderer/FramebufferImpl.cpp | 18 + .../src/libANGLE/renderer/FramebufferImpl.h | 123 + .../checkout/src/libANGLE/renderer/GLImplFactory.h | 116 + .../checkout/src/libANGLE/renderer/ImageImpl.cpp | 30 + .../checkout/src/libANGLE/renderer/ImageImpl.h | 68 + .../src/libANGLE/renderer/MemoryObjectImpl.h | 47 + .../checkout/src/libANGLE/renderer/OverlayImpl.h | 42 + .../checkout/src/libANGLE/renderer/ProgramImpl.cpp | 18 + .../checkout/src/libANGLE/renderer/ProgramImpl.h | 176 + .../src/libANGLE/renderer/ProgramPipelineImpl.cpp | 26 + .../src/libANGLE/renderer/ProgramPipelineImpl.h | 42 + .../checkout/src/libANGLE/renderer/QueryImpl.cpp | 21 + .../checkout/src/libANGLE/renderer/QueryImpl.h | 49 + .../src/libANGLE/renderer/RenderTargetCache.h | 186 + .../src/libANGLE/renderer/RenderbufferImpl.cpp | 19 + .../src/libANGLE/renderer/RenderbufferImpl.h | 164 + .../checkout/src/libANGLE/renderer/SamplerImpl.h | 44 + .../checkout/src/libANGLE/renderer/SemaphoreImpl.h | 50 + .../checkout/src/libANGLE/renderer/ShaderImpl.cpp | 105 + .../checkout/src/libANGLE/renderer/ShaderImpl.h | 77 + .../src/libANGLE/renderer/StreamProducerImpl.h | 40 + .../checkout/src/libANGLE/renderer/SurfaceImpl.cpp | 158 + .../checkout/src/libANGLE/renderer/SurfaceImpl.h | 136 + .../checkout/src/libANGLE/renderer/SyncImpl.h | 45 + .../checkout/src/libANGLE/renderer/TextureImpl.cpp | 200 + .../checkout/src/libANGLE/renderer/TextureImpl.h | 254 + .../libANGLE/renderer/TransformFeedbackImpl.cpp | 19 + .../src/libANGLE/renderer/TransformFeedbackImpl.h | 42 + .../src/libANGLE/renderer/VertexArrayImpl.cpp | 18 + .../src/libANGLE/renderer/VertexArrayImpl.h | 70 + .../checkout/src/libANGLE/renderer/copyvertex.h | 80 + .../src/libANGLE/renderer/copyvertex.inc.h | 635 + .../src/libANGLE/renderer/d3d/BufferD3D.cpp | 191 + .../checkout/src/libANGLE/renderer/d3d/BufferD3D.h | 89 + .../src/libANGLE/renderer/d3d/CompilerD3D.cpp | 24 + .../src/libANGLE/renderer/d3d/CompilerD3D.h | 32 + .../src/libANGLE/renderer/d3d/ContextD3D.h | 24 + .../src/libANGLE/renderer/d3d/DeviceD3D.cpp | 84 + .../checkout/src/libANGLE/renderer/d3d/DeviceD3D.h | 39 + .../src/libANGLE/renderer/d3d/DisplayD3D.cpp | 462 + .../src/libANGLE/renderer/d3d/DisplayD3D.h | 179 + .../src/libANGLE/renderer/d3d/DynamicHLSL.cpp | 1537 + .../src/libANGLE/renderer/d3d/DynamicHLSL.h | 212 + .../libANGLE/renderer/d3d/DynamicImage2DHLSL.cpp | 919 + .../src/libANGLE/renderer/d3d/DynamicImage2DHLSL.h | 28 + .../src/libANGLE/renderer/d3d/EGLImageD3D.cpp | 93 + .../src/libANGLE/renderer/d3d/EGLImageD3D.h | 55 + .../src/libANGLE/renderer/d3d/FramebufferD3D.cpp | 402 + .../src/libANGLE/renderer/d3d/FramebufferD3D.h | 143 + .../src/libANGLE/renderer/d3d/HLSLCompiler.cpp | 387 + .../src/libANGLE/renderer/d3d/HLSLCompiler.h | 74 + .../src/libANGLE/renderer/d3d/ImageD3D.cpp | 56 + .../checkout/src/libANGLE/renderer/d3d/ImageD3D.h | 105 + .../src/libANGLE/renderer/d3d/IndexBuffer.cpp | 183 + .../src/libANGLE/renderer/d3d/IndexBuffer.h | 125 + .../src/libANGLE/renderer/d3d/IndexDataManager.cpp | 318 + .../src/libANGLE/renderer/d3d/IndexDataManager.h | 112 + .../src/libANGLE/renderer/d3d/NativeWindowD3D.cpp | 19 + .../src/libANGLE/renderer/d3d/NativeWindowD3D.h | 38 + .../src/libANGLE/renderer/d3d/ProgramD3D.cpp | 3412 +++ .../src/libANGLE/renderer/d3d/ProgramD3D.h | 613 + .../src/libANGLE/renderer/d3d/RenderTargetD3D.cpp | 31 + .../src/libANGLE/renderer/d3d/RenderTargetD3D.h | 44 + .../src/libANGLE/renderer/d3d/RenderbufferD3D.cpp | 126 + .../src/libANGLE/renderer/d3d/RenderbufferD3D.h | 63 + .../src/libANGLE/renderer/d3d/RendererD3D.cpp | 247 + .../src/libANGLE/renderer/d3d/RendererD3D.h | 489 + .../src/libANGLE/renderer/d3d/SamplerD3D.h | 33 + .../src/libANGLE/renderer/d3d/ShaderD3D.cpp | 391 + .../checkout/src/libANGLE/renderer/d3d/ShaderD3D.h | 126 + .../libANGLE/renderer/d3d/ShaderExecutableD3D.cpp | 67 + .../libANGLE/renderer/d3d/ShaderExecutableD3D.h | 57 + .../src/libANGLE/renderer/d3d/SurfaceD3D.cpp | 517 + .../src/libANGLE/renderer/d3d/SurfaceD3D.h | 145 + .../src/libANGLE/renderer/d3d/SwapChainD3D.cpp | 34 + .../src/libANGLE/renderer/d3d/SwapChainD3D.h | 83 + .../src/libANGLE/renderer/d3d/TextureD3D.cpp | 4640 +++ .../src/libANGLE/renderer/d3d/TextureD3D.h | 1050 + .../src/libANGLE/renderer/d3d/TextureStorage.h | 135 + .../src/libANGLE/renderer/d3d/VertexBuffer.cpp | 308 + .../src/libANGLE/renderer/d3d/VertexBuffer.h | 189 + .../libANGLE/renderer/d3d/VertexDataManager.cpp | 683 + .../src/libANGLE/renderer/d3d/VertexDataManager.h | 163 + .../src/libANGLE/renderer/d3d/d3d11/Blit11.cpp | 1943 ++ .../src/libANGLE/renderer/d3d/d3d11/Blit11.h | 300 + .../renderer/d3d/d3d11/Blit11Helper_autogen.inc | 1575 + .../src/libANGLE/renderer/d3d/d3d11/Buffer11.cpp | 1888 ++ .../src/libANGLE/renderer/d3d/d3d11/Buffer11.h | 234 + .../src/libANGLE/renderer/d3d/d3d11/Clear11.cpp | 813 + .../src/libANGLE/renderer/d3d/d3d11/Clear11.h | 102 + .../src/libANGLE/renderer/d3d/d3d11/Context11.cpp | 1048 + .../src/libANGLE/renderer/d3d/d3d11/Context11.h | 282 + .../renderer/d3d/d3d11/DebugAnnotator11.cpp | 148 + .../libANGLE/renderer/d3d/d3d11/DebugAnnotator11.h | 60 + .../d3d/d3d11/ExternalImageSiblingImpl11.cpp | 209 + .../d3d/d3d11/ExternalImageSiblingImpl11.h | 70 + .../src/libANGLE/renderer/d3d/d3d11/Fence11.cpp | 234 + .../src/libANGLE/renderer/d3d/d3d11/Fence11.h | 76 + .../libANGLE/renderer/d3d/d3d11/Framebuffer11.cpp | 452 + .../libANGLE/renderer/d3d/d3d11/Framebuffer11.h | 100 + .../src/libANGLE/renderer/d3d/d3d11/Image11.cpp | 676 + .../src/libANGLE/renderer/d3d/d3d11/Image11.h | 128 + .../libANGLE/renderer/d3d/d3d11/IndexBuffer11.cpp | 160 + .../libANGLE/renderer/d3d/d3d11/IndexBuffer11.h | 58 + .../renderer/d3d/d3d11/InputLayoutCache.cpp | 313 + .../libANGLE/renderer/d3d/d3d11/InputLayoutCache.h | 123 + .../d3d/d3d11/MappedSubresourceVerifier11.cpp | 119 + .../d3d/d3d11/MappedSubresourceVerifier11.h | 63 + .../libANGLE/renderer/d3d/d3d11/NativeWindow11.h | 38 + .../renderer/d3d/d3d11/PixelTransfer11.cpp | 271 + .../libANGLE/renderer/d3d/d3d11/PixelTransfer11.h | 96 + .../src/libANGLE/renderer/d3d/d3d11/Program11.cpp | 34 + .../src/libANGLE/renderer/d3d/d3d11/Program11.h | 28 + .../renderer/d3d/d3d11/ProgramPipeline11.cpp | 21 + .../renderer/d3d/d3d11/ProgramPipeline11.h | 27 + .../src/libANGLE/renderer/d3d/d3d11/Query11.cpp | 357 + .../src/libANGLE/renderer/d3d/d3d11/Query11.h | 71 + .../renderer/d3d/d3d11/RenderStateCache.cpp | 323 + .../libANGLE/renderer/d3d/d3d11/RenderStateCache.h | 124 + .../libANGLE/renderer/d3d/d3d11/RenderTarget11.cpp | 403 + .../libANGLE/renderer/d3d/d3d11/RenderTarget11.h | 133 + .../src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp | 4454 +++ .../src/libANGLE/renderer/d3d/d3d11/Renderer11.h | 632 + .../renderer/d3d/d3d11/ResourceManager11.cpp | 560 + .../renderer/d3d/d3d11/ResourceManager11.h | 411 + .../renderer/d3d/d3d11/ShaderExecutable11.cpp | 116 + .../renderer/d3d/d3d11/ShaderExecutable11.h | 69 + .../libANGLE/renderer/d3d/d3d11/StateManager11.cpp | 4004 +++ .../libANGLE/renderer/d3d/d3d11/StateManager11.h | 692 + .../d3d/d3d11/StreamProducerD3DTexture.cpp | 166 + .../renderer/d3d/d3d11/StreamProducerD3DTexture.h | 44 + .../libANGLE/renderer/d3d/d3d11/SwapChain11.cpp | 1119 + .../src/libANGLE/renderer/d3d/d3d11/SwapChain11.h | 134 + .../renderer/d3d/d3d11/TextureStorage11.cpp | 4352 +++ .../libANGLE/renderer/d3d/d3d11/TextureStorage11.h | 1003 + .../renderer/d3d/d3d11/TransformFeedback11.cpp | 131 + .../renderer/d3d/d3d11/TransformFeedback11.h | 61 + .../src/libANGLE/renderer/d3d/d3d11/Trim11.cpp | 103 + .../src/libANGLE/renderer/d3d/d3d11/Trim11.h | 43 + .../libANGLE/renderer/d3d/d3d11/VertexArray11.cpp | 375 + .../libANGLE/renderer/d3d/d3d11/VertexArray11.h | 112 + .../libANGLE/renderer/d3d/d3d11/VertexBuffer11.cpp | 167 + .../libANGLE/renderer/d3d/d3d11/VertexBuffer11.h | 65 + .../d3d11/converged/CompositorNativeWindow11.cpp | 457 + .../d3d/d3d11/converged/CompositorNativeWindow11.h | 116 + .../libANGLE/renderer/d3d/d3d11/formatutils11.cpp | 1029 + .../libANGLE/renderer/d3d/d3d11/formatutils11.h | 64 + .../renderer/d3d/d3d11/renderer11_utils.cpp | 2751 ++ .../libANGLE/renderer/d3d/d3d11/renderer11_utils.h | 478 + .../d3d11/shaders/compiled/buffertotexture11_gs.h | 80 + .../shaders/compiled/buffertotexture11_ps_4f.h | 65 + .../shaders/compiled/buffertotexture11_ps_4i.h | 65 + .../shaders/compiled/buffertotexture11_ps_4ui.h | 65 + .../d3d11/shaders/compiled/buffertotexture11_vs.h | 145 + .../d3d/d3d11/shaders/compiled/clear11_fl9vs.h | 71 + .../d3d11/shaders/compiled/clear11multiviewgs.h | 83 + .../d3d11/shaders/compiled/clear11multiviewvs.h | 80 + .../d3d/d3d11/shaders/compiled/clear11vs.h | 69 + .../d3d/d3d11/shaders/compiled/cleardepth11ps.h | 74 + .../d3d11/shaders/compiled/clearfloat11_fl9ps.h | 128 + .../d3d/d3d11/shaders/compiled/clearfloat11ps1.h | 85 + .../d3d/d3d11/shaders/compiled/clearfloat11ps2.h | 91 + .../d3d/d3d11/shaders/compiled/clearfloat11ps3.h | 97 + .../d3d/d3d11/shaders/compiled/clearfloat11ps4.h | 104 + .../d3d/d3d11/shaders/compiled/clearfloat11ps5.h | 110 + .../d3d/d3d11/shaders/compiled/clearfloat11ps6.h | 116 + .../d3d/d3d11/shaders/compiled/clearfloat11ps7.h | 122 + .../d3d/d3d11/shaders/compiled/clearfloat11ps8.h | 128 + .../d3d/d3d11/shaders/compiled/clearsint11ps1.h | 85 + .../d3d/d3d11/shaders/compiled/clearsint11ps2.h | 91 + .../d3d/d3d11/shaders/compiled/clearsint11ps3.h | 97 + .../d3d/d3d11/shaders/compiled/clearsint11ps4.h | 104 + .../d3d/d3d11/shaders/compiled/clearsint11ps5.h | 110 + .../d3d/d3d11/shaders/compiled/clearsint11ps6.h | 116 + .../d3d/d3d11/shaders/compiled/clearsint11ps7.h | 122 + .../d3d/d3d11/shaders/compiled/clearsint11ps8.h | 128 + .../d3d/d3d11/shaders/compiled/clearuint11ps1.h | 85 + .../d3d/d3d11/shaders/compiled/clearuint11ps2.h | 91 + .../d3d/d3d11/shaders/compiled/clearuint11ps3.h | 97 + .../d3d/d3d11/shaders/compiled/clearuint11ps4.h | 104 + .../d3d/d3d11/shaders/compiled/clearuint11ps5.h | 110 + .../d3d/d3d11/shaders/compiled/clearuint11ps6.h | 116 + .../d3d/d3d11/shaders/compiled/clearuint11ps7.h | 122 + .../d3d/d3d11/shaders/compiled/clearuint11ps8.h | 128 + .../compiled/multiplyalpha_ftof_pm_luma_2d_ps.h | 76 + .../multiplyalpha_ftof_pm_luma_2darray_ps.h | 86 + .../compiled/multiplyalpha_ftof_pm_luma_3d_ps.h | 80 + .../multiplyalpha_ftof_pm_lumaalpha_2d_ps.h | 76 + .../multiplyalpha_ftof_pm_lumaalpha_2darray_ps.h | 86 + .../multiplyalpha_ftof_pm_lumaalpha_3d_ps.h | 80 + .../compiled/multiplyalpha_ftof_pm_rgb_2d_ps.h | 76 + .../multiplyalpha_ftof_pm_rgb_2darray_ps.h | 86 + .../compiled/multiplyalpha_ftof_pm_rgb_3d_ps.h | 80 + .../compiled/multiplyalpha_ftof_pm_rgb_565_2d_ps.h | 84 + .../multiplyalpha_ftof_pm_rgb_565_2darray_ps.h | 94 + .../compiled/multiplyalpha_ftof_pm_rgb_565_3d_ps.h | 88 + .../compiled/multiplyalpha_ftof_pm_rgba_2d_ps.h | 76 + .../multiplyalpha_ftof_pm_rgba_2darray_ps.h | 86 + .../compiled/multiplyalpha_ftof_pm_rgba_3d_ps.h | 80 + .../multiplyalpha_ftof_pm_rgba_4444_2d_ps.h | 82 + .../multiplyalpha_ftof_pm_rgba_4444_2darray_ps.h | 92 + .../multiplyalpha_ftof_pm_rgba_4444_3d_ps.h | 86 + .../multiplyalpha_ftof_pm_rgba_5551_2d_ps.h | 82 + .../multiplyalpha_ftof_pm_rgba_5551_2darray_ps.h | 92 + .../multiplyalpha_ftof_pm_rgba_5551_3d_ps.h | 86 + .../compiled/multiplyalpha_ftof_um_luma_2d_ps.h | 82 + .../multiplyalpha_ftof_um_luma_2darray_ps.h | 91 + .../compiled/multiplyalpha_ftof_um_luma_3d_ps.h | 85 + .../multiplyalpha_ftof_um_lumaalpha_2d_ps.h | 82 + .../multiplyalpha_ftof_um_lumaalpha_2darray_ps.h | 91 + .../multiplyalpha_ftof_um_lumaalpha_3d_ps.h | 85 + .../compiled/multiplyalpha_ftof_um_rgb_2d_ps.h | 82 + .../multiplyalpha_ftof_um_rgb_2darray_ps.h | 91 + .../compiled/multiplyalpha_ftof_um_rgb_3d_ps.h | 85 + .../compiled/multiplyalpha_ftof_um_rgb_565_2d_ps.h | 90 + .../multiplyalpha_ftof_um_rgb_565_2darray_ps.h | 100 + .../compiled/multiplyalpha_ftof_um_rgb_565_3d_ps.h | 93 + .../compiled/multiplyalpha_ftof_um_rgba_2d_ps.h | 82 + .../multiplyalpha_ftof_um_rgba_2darray_ps.h | 91 + .../compiled/multiplyalpha_ftof_um_rgba_3d_ps.h | 85 + .../multiplyalpha_ftof_um_rgba_4444_2d_ps.h | 88 + .../multiplyalpha_ftof_um_rgba_4444_2darray_ps.h | 98 + .../multiplyalpha_ftof_um_rgba_4444_3d_ps.h | 91 + .../multiplyalpha_ftof_um_rgba_5551_2d_ps.h | 88 + .../multiplyalpha_ftof_um_rgba_5551_2darray_ps.h | 98 + .../multiplyalpha_ftof_um_rgba_5551_3d_ps.h | 91 + .../multiplyalpha_ftoi_pm_rgb_2darray_ps.h | 96 + .../compiled/multiplyalpha_ftoi_pm_rgb_3d_ps.h | 90 + .../multiplyalpha_ftoi_pm_rgba_2darray_ps.h | 94 + .../compiled/multiplyalpha_ftoi_pm_rgba_3d_ps.h | 88 + .../multiplyalpha_ftoi_pt_rgb_2darray_ps.h | 94 + .../compiled/multiplyalpha_ftoi_pt_rgb_3d_ps.h | 88 + .../multiplyalpha_ftoi_pt_rgba_2darray_ps.h | 92 + .../compiled/multiplyalpha_ftoi_pt_rgba_3d_ps.h | 85 + .../multiplyalpha_ftoi_um_rgb_2darray_ps.h | 102 + .../compiled/multiplyalpha_ftoi_um_rgb_3d_ps.h | 95 + .../multiplyalpha_ftoi_um_rgba_2darray_ps.h | 100 + .../compiled/multiplyalpha_ftoi_um_rgba_3d_ps.h | 93 + .../compiled/multiplyalpha_ftou_pm_rgb_2d_ps.h | 81 + .../multiplyalpha_ftou_pm_rgb_2darray_ps.h | 91 + .../compiled/multiplyalpha_ftou_pm_rgb_3d_ps.h | 85 + .../compiled/multiplyalpha_ftou_pm_rgba_2d_ps.h | 79 + .../multiplyalpha_ftou_pm_rgba_2darray_ps.h | 89 + .../compiled/multiplyalpha_ftou_pm_rgba_3d_ps.h | 83 + .../compiled/multiplyalpha_ftou_pt_rgb_2d_ps.h | 79 + .../multiplyalpha_ftou_pt_rgb_2darray_ps.h | 89 + .../compiled/multiplyalpha_ftou_pt_rgb_3d_ps.h | 80 + .../compiled/multiplyalpha_ftou_pt_rgba_2d_ps.h | 77 + .../multiplyalpha_ftou_pt_rgba_2darray_ps.h | 87 + .../compiled/multiplyalpha_ftou_pt_rgba_3d_ps.h | 80 + .../compiled/multiplyalpha_ftou_um_rgb_2d_ps.h | 87 + .../multiplyalpha_ftou_um_rgb_2darray_ps.h | 97 + .../compiled/multiplyalpha_ftou_um_rgb_3d_ps.h | 90 + .../compiled/multiplyalpha_ftou_um_rgba_2d_ps.h | 85 + .../multiplyalpha_ftou_um_rgba_2darray_ps.h | 95 + .../compiled/multiplyalpha_ftou_um_rgba_3d_ps.h | 88 + .../d3d/d3d11/shaders/compiled/passthrough2d11vs.h | 91 + .../d3d/d3d11/shaders/compiled/passthrough3d11gs.h | 93 + .../d3d/d3d11/shaders/compiled/passthrough3d11vs.h | 75 + .../d3d11/shaders/compiled/passthrougha2d11ps.h | 103 + .../shaders/compiled/passthroughdepth2d11ps.h | 73 + .../d3d11/shaders/compiled/passthroughlum2d11ps.h | 103 + .../shaders/compiled/passthroughlum2darray11ps.h | 85 + .../d3d11/shaders/compiled/passthroughlum3d11ps.h | 79 + .../shaders/compiled/passthroughlumalpha2d11ps.h | 98 + .../compiled/passthroughlumalpha2darray11ps.h | 83 + .../shaders/compiled/passthroughlumalpha3d11ps.h | 77 + .../d3d11/shaders/compiled/passthroughr2d11ps.h | 104 + .../shaders/compiled/passthroughr2darray11ps.h | 86 + .../shaders/compiled/passthroughr2darrayi11ps.h | 90 + .../shaders/compiled/passthroughr2darrayui11ps.h | 90 + .../d3d11/shaders/compiled/passthroughr2di11ps.h | 83 + .../d3d11/shaders/compiled/passthroughr2dui11ps.h | 83 + .../d3d11/shaders/compiled/passthroughr3d11ps.h | 80 + .../d3d11/shaders/compiled/passthroughr3di11ps.h | 86 + .../d3d11/shaders/compiled/passthroughr3dui11ps.h | 86 + .../d3d11/shaders/compiled/passthroughrg2d11ps.h | 104 + .../shaders/compiled/passthroughrg2darray11ps.h | 86 + .../shaders/compiled/passthroughrg2darrayi11ps.h | 90 + .../shaders/compiled/passthroughrg2darrayui11ps.h | 90 + .../d3d11/shaders/compiled/passthroughrg2di11ps.h | 83 + .../d3d11/shaders/compiled/passthroughrg2dui11ps.h | 83 + .../d3d11/shaders/compiled/passthroughrg3d11ps.h | 80 + .../d3d11/shaders/compiled/passthroughrg3di11ps.h | 86 + .../d3d11/shaders/compiled/passthroughrg3dui11ps.h | 86 + .../d3d11/shaders/compiled/passthroughrgb2d11ps.h | 103 + .../shaders/compiled/passthroughrgb2d_565_11ps.h | 118 + .../shaders/compiled/passthroughrgb2darray11ps.h | 85 + .../compiled/passthroughrgb2darray_565_11ps.h | 91 + .../shaders/compiled/passthroughrgb2darrayi11ps.h | 89 + .../shaders/compiled/passthroughrgb2darrayui11ps.h | 89 + .../d3d11/shaders/compiled/passthroughrgb2di11ps.h | 82 + .../shaders/compiled/passthroughrgb2dui11ps.h | 82 + .../d3d11/shaders/compiled/passthroughrgb3d11ps.h | 79 + .../shaders/compiled/passthroughrgb3d_565_11ps.h | 85 + .../d3d11/shaders/compiled/passthroughrgb3di11ps.h | 85 + .../shaders/compiled/passthroughrgb3dui11ps.h | 85 + .../d3d11/shaders/compiled/passthroughrgba2d11ps.h | 93 + .../shaders/compiled/passthroughrgba2d_4444_11ps.h | 112 + .../shaders/compiled/passthroughrgba2d_5551_11ps.h | 112 + .../shaders/compiled/passthroughrgba2darray11ps.h | 81 + .../compiled/passthroughrgba2darray_4444_11ps.h | 89 + .../compiled/passthroughrgba2darray_5551_11ps.h | 89 + .../shaders/compiled/passthroughrgba2darrayi11ps.h | 85 + .../compiled/passthroughrgba2darrayui11ps.h | 85 + .../shaders/compiled/passthroughrgba2di11ps.h | 78 + .../shaders/compiled/passthroughrgba2dms11ps.h | 80 + .../shaders/compiled/passthroughrgba2dui11ps.h | 78 + .../d3d11/shaders/compiled/passthroughrgba3d11ps.h | 74 + .../shaders/compiled/passthroughrgba3d_4444_11ps.h | 83 + .../shaders/compiled/passthroughrgba3d_5551_11ps.h | 83 + .../shaders/compiled/passthroughrgba3di11ps.h | 81 + .../shaders/compiled/passthroughrgba3dui11ps.h | 81 + .../d3d/d3d11/shaders/compiled/resolvecolor2dps.h | 103 + .../d3d/d3d11/shaders/compiled/resolvedepth11_ps.h | 81 + .../shaders/compiled/resolvedepthstencil11_ps.h | 92 + .../shaders/compiled/resolvedepthstencil11_vs.h | 83 + .../d3d11/shaders/compiled/resolvestencil11_ps.h | 84 + .../d3d/d3d11/shaders/compiled/swizzlef2darrayps.h | 135 + .../d3d/d3d11/shaders/compiled/swizzlef2dps.h | 126 + .../d3d/d3d11/shaders/compiled/swizzlef3dps.h | 129 + .../d3d/d3d11/shaders/compiled/swizzlei2darrayps.h | 139 + .../d3d/d3d11/shaders/compiled/swizzlei2dps.h | 132 + .../d3d/d3d11/shaders/compiled/swizzlei3dps.h | 135 + .../d3d11/shaders/compiled/swizzleui2darrayps.h | 139 + .../d3d/d3d11/shaders/compiled/swizzleui2dps.h | 132 + .../d3d/d3d11/shaders/compiled/swizzleui3dps.h | 135 + .../renderer/d3d/d3d11/texture_format_table.cpp | 35 + .../renderer/d3d/d3d11/texture_format_table.h | 118 + .../d3d/d3d11/texture_format_table_autogen.cpp | 3269 ++ .../d3d/d3d11/texture_format_table_utils.h | 90 + .../d3d/d3d11/win32/NativeWindow11Win32.cpp | 218 + .../renderer/d3d/d3d11/win32/NativeWindow11Win32.h | 53 + .../src/libANGLE/renderer/d3d/d3d9/Blit9.cpp | 760 + .../src/libANGLE/renderer/d3d/d3d9/Blit9.h | 166 + .../src/libANGLE/renderer/d3d/d3d9/Buffer9.cpp | 141 + .../src/libANGLE/renderer/d3d/d3d9/Buffer9.h | 63 + .../src/libANGLE/renderer/d3d/d3d9/Context9.cpp | 529 + .../src/libANGLE/renderer/d3d/d3d9/Context9.h | 265 + .../libANGLE/renderer/d3d/d3d9/DebugAnnotator9.cpp | 48 + .../libANGLE/renderer/d3d/d3d9/DebugAnnotator9.h | 38 + .../src/libANGLE/renderer/d3d/d3d9/Fence9.cpp | 73 + .../src/libANGLE/renderer/d3d/d3d9/Fence9.h | 39 + .../libANGLE/renderer/d3d/d3d9/Framebuffer9.cpp | 416 + .../src/libANGLE/renderer/d3d/d3d9/Framebuffer9.h | 89 + .../src/libANGLE/renderer/d3d/d3d9/Image9.cpp | 907 + .../src/libANGLE/renderer/d3d/d3d9/Image9.h | 112 + .../libANGLE/renderer/d3d/d3d9/IndexBuffer9.cpp | 161 + .../src/libANGLE/renderer/d3d/d3d9/IndexBuffer9.h | 57 + .../libANGLE/renderer/d3d/d3d9/NativeWindow9.cpp | 37 + .../src/libANGLE/renderer/d3d/d3d9/NativeWindow9.h | 35 + .../src/libANGLE/renderer/d3d/d3d9/Query9.cpp | 176 + .../src/libANGLE/renderer/d3d/d3d9/Query9.h | 50 + .../libANGLE/renderer/d3d/d3d9/RenderTarget9.cpp | 160 + .../src/libANGLE/renderer/d3d/d3d9/RenderTarget9.h | 98 + .../src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp | 3338 ++ .../src/libANGLE/renderer/d3d/d3d9/Renderer9.h | 586 + .../src/libANGLE/renderer/d3d/d3d9/ShaderCache.h | 110 + .../renderer/d3d/d3d9/ShaderExecutable9.cpp | 51 + .../libANGLE/renderer/d3d/d3d9/ShaderExecutable9.h | 35 + .../libANGLE/renderer/d3d/d3d9/StateManager9.cpp | 888 + .../src/libANGLE/renderer/d3d/d3d9/StateManager9.h | 211 + .../src/libANGLE/renderer/d3d/d3d9/SwapChain9.cpp | 472 + .../src/libANGLE/renderer/d3d/d3d9/SwapChain9.h | 80 + .../libANGLE/renderer/d3d/d3d9/TextureStorage9.cpp | 575 + .../libANGLE/renderer/d3d/d3d9/TextureStorage9.h | 186 + .../src/libANGLE/renderer/d3d/d3d9/VertexArray9.h | 57 + .../libANGLE/renderer/d3d/d3d9/VertexBuffer9.cpp | 153 + .../src/libANGLE/renderer/d3d/d3d9/VertexBuffer9.h | 56 + .../renderer/d3d/d3d9/VertexDeclarationCache.cpp | 262 + .../renderer/d3d/d3d9/VertexDeclarationCache.h | 68 + .../libANGLE/renderer/d3d/d3d9/formatutils9.cpp | 695 + .../src/libANGLE/renderer/d3d/d3d9/formatutils9.h | 59 + .../libANGLE/renderer/d3d/d3d9/renderer9_utils.cpp | 845 + .../libANGLE/renderer/d3d/d3d9/renderer9_utils.h | 105 + .../d3d9/shaders/compiled/componentmaskpremultps.h | 50 + .../d3d/d3d9/shaders/compiled/componentmaskps.h | 48 + .../d3d9/shaders/compiled/componentmaskunmultps.h | 54 + .../d3d/d3d9/shaders/compiled/luminancepremultps.h | 50 + .../d3d/d3d9/shaders/compiled/luminanceps.h | 53 + .../d3d/d3d9/shaders/compiled/luminanceunmultps.h | 54 + .../d3d/d3d9/shaders/compiled/passthroughps.h | 37 + .../d3d/d3d9/shaders/compiled/standardvs.h | 46 + .../libANGLE/renderer/d3d/d3d9/vertexconversion.h | 197 + .../src/libANGLE/renderer/d3d/driver_utils_d3d.cpp | 26 + .../src/libANGLE/renderer/d3d/driver_utils_d3d.h | 21 + .../src/libANGLE/renderer/d3d/formatutilsD3D.h | 24 + .../checkout/src/libANGLE/renderer/d3d_format.cpp | 206 + .../checkout/src/libANGLE/renderer/d3d_format.h | 58 + .../src/libANGLE/renderer/driver_utils.cpp | 438 + .../checkout/src/libANGLE/renderer/driver_utils.h | 278 + .../src/libANGLE/renderer/dxgi_format_map.h | 27 + .../libANGLE/renderer/dxgi_format_map_autogen.cpp | 516 + .../src/libANGLE/renderer/dxgi_support_table.h | 43 + .../renderer/dxgi_support_table_autogen.cpp | 3042 ++ .../src/libANGLE/renderer/gl/functionsgl_enums.h | 1376 + .../src/libANGLE/renderer/load_functions_table.h | 20 + .../renderer/load_functions_table_autogen.cpp | 5465 ++++ .../src/libANGLE/renderer/renderer_utils.cpp | 1583 + .../src/libANGLE/renderer/renderer_utils.h | 499 + .../checkout/src/libANGLE/renderer/serial_utils.h | 126 + gfx/angle/checkout/src/libANGLE/trace.h | 26 + gfx/angle/checkout/src/libANGLE/validationEGL.cpp | 6782 +++++ gfx/angle/checkout/src/libANGLE/validationEGL.h | 201 + .../checkout/src/libANGLE/validationEGL_autogen.h | 510 + gfx/angle/checkout/src/libANGLE/validationES.cpp | 8666 ++++++ gfx/angle/checkout/src/libANGLE/validationES.h | 1272 + gfx/angle/checkout/src/libANGLE/validationES1.cpp | 2129 ++ gfx/angle/checkout/src/libANGLE/validationES1.h | 20 + .../checkout/src/libANGLE/validationES1_autogen.h | 395 + gfx/angle/checkout/src/libANGLE/validationES2.cpp | 6544 ++++ gfx/angle/checkout/src/libANGLE/validationES2.h | 207 + .../checkout/src/libANGLE/validationES2_autogen.h | 666 + gfx/angle/checkout/src/libANGLE/validationES3.cpp | 5311 ++++ gfx/angle/checkout/src/libANGLE/validationES3.h | 72 + gfx/angle/checkout/src/libANGLE/validationES31.cpp | 3157 ++ gfx/angle/checkout/src/libANGLE/validationES31.h | 300 + .../checkout/src/libANGLE/validationES31_autogen.h | 415 + gfx/angle/checkout/src/libANGLE/validationES32.cpp | 628 + gfx/angle/checkout/src/libANGLE/validationES32.h | 20 + .../checkout/src/libANGLE/validationES32_autogen.h | 281 + .../checkout/src/libANGLE/validationES3_autogen.h | 578 + .../checkout/src/libANGLE/validationESEXT.cpp | 3599 +++ gfx/angle/checkout/src/libANGLE/validationESEXT.h | 20 + .../src/libANGLE/validationESEXT_autogen.h | 2646 ++ gfx/angle/checkout/src/libANGLE/validationGL1.cpp | 2421 ++ .../checkout/src/libANGLE/validationGL1_autogen.h | 1192 + gfx/angle/checkout/src/libANGLE/validationGL2.cpp | 262 + .../checkout/src/libANGLE/validationGL2_autogen.h | 158 + gfx/angle/checkout/src/libANGLE/validationGL3.cpp | 634 + .../checkout/src/libANGLE/validationGL3_autogen.h | 367 + gfx/angle/checkout/src/libANGLE/validationGL4.cpp | 2223 ++ .../checkout/src/libANGLE/validationGL4_autogen.h | 1375 + .../checkout/src/libEGL/egl_loader_autogen.cpp | 320 + gfx/angle/checkout/src/libEGL/egl_loader_autogen.h | 250 + gfx/angle/checkout/src/libEGL/libEGL.rc | 103 + gfx/angle/checkout/src/libEGL/libEGL_autogen.cpp | 917 + gfx/angle/checkout/src/libEGL/libEGL_autogen.def | 193 + gfx/angle/checkout/src/libEGL/resource.h | 14 + gfx/angle/checkout/src/libGLESv2/egl_ext_stubs.cpp | 974 + .../checkout/src/libGLESv2/egl_ext_stubs_autogen.h | 264 + gfx/angle/checkout/src/libGLESv2/egl_stubs.cpp | 777 + .../checkout/src/libGLESv2/egl_stubs_autogen.h | 165 + .../src/libGLESv2/entry_points_egl_autogen.cpp | 865 + .../src/libGLESv2/entry_points_egl_autogen.h | 138 + .../src/libGLESv2/entry_points_egl_ext_autogen.cpp | 1403 + .../src/libGLESv2/entry_points_egl_ext_autogen.h | 284 + .../libGLESv2/entry_points_gles_1_0_autogen.cpp | 2116 ++ .../src/libGLESv2/entry_points_gles_1_0_autogen.h | 123 + .../libGLESv2/entry_points_gles_2_0_autogen.cpp | 3864 +++ .../src/libGLESv2/entry_points_gles_2_0_autogen.h | 309 + .../libGLESv2/entry_points_gles_3_0_autogen.cpp | 3057 ++ .../src/libGLESv2/entry_points_gles_3_0_autogen.h | 299 + .../libGLESv2/entry_points_gles_3_1_autogen.cpp | 2098 ++ .../src/libGLESv2/entry_points_gles_3_1_autogen.h | 235 + .../libGLESv2/entry_points_gles_3_2_autogen.cpp | 1327 + .../src/libGLESv2/entry_points_gles_3_2_autogen.h | 172 + .../libGLESv2/entry_points_gles_ext_autogen.cpp | 11984 ++++++++ .../src/libGLESv2/entry_points_gles_ext_autogen.h | 1788 ++ gfx/angle/checkout/src/libGLESv2/global_state.cpp | 373 + gfx/angle/checkout/src/libGLESv2/global_state.h | 215 + gfx/angle/checkout/src/libGLESv2/libGLESv2.rc | 137 + .../checkout/src/libGLESv2/libGLESv2_autogen.cpp | 9704 ++++++ .../checkout/src/libGLESv2/libGLESv2_autogen.def | 1362 + gfx/angle/checkout/src/libGLESv2/proc_table_egl.h | 25 + .../src/libGLESv2/proc_table_egl_autogen.cpp | 1623 + gfx/angle/checkout/src/libGLESv2/resource.h | 17 + .../src/third_party/systeminfo/SystemInfo.cpp | 67 + .../src/third_party/systeminfo/SystemInfo.h | 36 + .../src/third_party/trace_event/trace_event.h | 777 + gfx/angle/checkout/src/third_party/volk/volk.c | 2396 ++ gfx/angle/checkout/src/third_party/volk/volk.h | 1578 + .../vulkan-headers/src/include/vulkan/vk_icd.h | 245 + .../vulkan-headers/src/include/vulkan/vk_layer.h | 210 + .../src/include/vulkan/vk_platform.h | 84 + .../src/include/vulkan/vk_sdk_platform.h | 69 + .../vulkan-headers/src/include/vulkan/vulkan.h | 91 + .../vulkan-headers/src/include/vulkan/vulkan.hpp | 15303 ++++++++++ .../src/include/vulkan/vulkan_core.h | 16027 ++++++++++ .../src/include/vulkan/vulkan_screen.h | 54 + .../zlib/google/compression_utils_portable.cc | 205 + .../zlib/google/compression_utils_portable.h | 63 + 1139 files changed, 555321 insertions(+) create mode 100644 gfx/angle/checkout/LICENSE create mode 100644 gfx/angle/checkout/include/EGL/egl.h create mode 100644 gfx/angle/checkout/include/EGL/eglext.h create mode 100644 gfx/angle/checkout/include/EGL/eglext_angle.h create mode 100644 gfx/angle/checkout/include/EGL/eglplatform.h create mode 100644 gfx/angle/checkout/include/GLES/gl.h create mode 100644 gfx/angle/checkout/include/GLES/glext.h create mode 100644 gfx/angle/checkout/include/GLES/glplatform.h create mode 100644 gfx/angle/checkout/include/GLES2/gl2.h create mode 100644 gfx/angle/checkout/include/GLES2/gl2ext.h create mode 100644 gfx/angle/checkout/include/GLES2/gl2ext_angle.h create mode 100644 gfx/angle/checkout/include/GLES2/gl2platform.h create mode 100644 gfx/angle/checkout/include/GLES3/gl3.h create mode 100644 gfx/angle/checkout/include/GLES3/gl31.h create mode 100644 gfx/angle/checkout/include/GLES3/gl32.h create mode 100644 gfx/angle/checkout/include/GLES3/gl3platform.h create mode 100644 gfx/angle/checkout/include/GLSLANG/ShaderLang.h create mode 100644 gfx/angle/checkout/include/GLSLANG/ShaderVars.h create mode 100644 gfx/angle/checkout/include/GLX/glxext.h create mode 100644 gfx/angle/checkout/include/KHR/khrplatform.h create mode 100644 gfx/angle/checkout/include/WGL/wgl.h create mode 100644 gfx/angle/checkout/include/angle_gl.h create mode 100644 gfx/angle/checkout/include/export.h create mode 100644 gfx/angle/checkout/include/platform/Feature.h create mode 100644 gfx/angle/checkout/include/platform/FeaturesD3D_autogen.h create mode 100644 gfx/angle/checkout/include/platform/FeaturesGL_autogen.h create mode 100644 gfx/angle/checkout/include/platform/FeaturesMtl_autogen.h create mode 100644 gfx/angle/checkout/include/platform/FeaturesVk_autogen.h create mode 100644 gfx/angle/checkout/include/platform/FrontendFeatures_autogen.h create mode 100644 gfx/angle/checkout/include/platform/PlatformMethods.h create mode 100644 gfx/angle/checkout/include/vulkan/vulkan_fuchsia_ext.h create mode 100644 gfx/angle/checkout/out/gen/angle/angle_commit.h create mode 100644 gfx/angle/checkout/src/common/CircularBuffer.h create mode 100644 gfx/angle/checkout/src/common/Color.h create mode 100644 gfx/angle/checkout/src/common/Color.inc create mode 100644 gfx/angle/checkout/src/common/FastVector.h create mode 100644 gfx/angle/checkout/src/common/FixedVector.h create mode 100644 gfx/angle/checkout/src/common/Float16ToFloat32.cpp create mode 100644 gfx/angle/checkout/src/common/MemoryBuffer.cpp create mode 100644 gfx/angle/checkout/src/common/MemoryBuffer.h create mode 100644 gfx/angle/checkout/src/common/Optional.h create mode 100644 gfx/angle/checkout/src/common/PackedEGLEnums_autogen.cpp create mode 100644 gfx/angle/checkout/src/common/PackedEGLEnums_autogen.h create mode 100644 gfx/angle/checkout/src/common/PackedEnums.cpp create mode 100644 gfx/angle/checkout/src/common/PackedEnums.h create mode 100644 gfx/angle/checkout/src/common/PackedGLEnums_autogen.cpp create mode 100644 gfx/angle/checkout/src/common/PackedGLEnums_autogen.h create mode 100644 gfx/angle/checkout/src/common/PoolAlloc.cpp create mode 100644 gfx/angle/checkout/src/common/PoolAlloc.h create mode 100644 gfx/angle/checkout/src/common/Spinlock.h create mode 100644 gfx/angle/checkout/src/common/SynchronizedValue.h create mode 100644 gfx/angle/checkout/src/common/aligned_memory.cpp create mode 100644 gfx/angle/checkout/src/common/aligned_memory.h create mode 100644 gfx/angle/checkout/src/common/android_util.cpp create mode 100644 gfx/angle/checkout/src/common/android_util.h create mode 100644 gfx/angle/checkout/src/common/angle_version.h create mode 100644 gfx/angle/checkout/src/common/angle_version_info.cpp create mode 100644 gfx/angle/checkout/src/common/angle_version_info.h create mode 100644 gfx/angle/checkout/src/common/angleutils.cpp create mode 100644 gfx/angle/checkout/src/common/angleutils.h create mode 100644 gfx/angle/checkout/src/common/apple_platform_utils.h create mode 100644 gfx/angle/checkout/src/common/bitset_utils.h create mode 100644 gfx/angle/checkout/src/common/debug.cpp create mode 100644 gfx/angle/checkout/src/common/debug.h create mode 100644 gfx/angle/checkout/src/common/entry_points_enum_autogen.cpp create mode 100644 gfx/angle/checkout/src/common/entry_points_enum_autogen.h create mode 100644 gfx/angle/checkout/src/common/event_tracer.cpp create mode 100644 gfx/angle/checkout/src/common/event_tracer.h create mode 100644 gfx/angle/checkout/src/common/hash_utils.h create mode 100644 gfx/angle/checkout/src/common/mathutil.cpp create mode 100644 gfx/angle/checkout/src/common/mathutil.h create mode 100644 gfx/angle/checkout/src/common/matrix_utils.cpp create mode 100644 gfx/angle/checkout/src/common/matrix_utils.h create mode 100644 gfx/angle/checkout/src/common/platform.h create mode 100644 gfx/angle/checkout/src/common/spirv/spirv_types.h create mode 100644 gfx/angle/checkout/src/common/string_utils.cpp create mode 100644 gfx/angle/checkout/src/common/string_utils.h create mode 100644 gfx/angle/checkout/src/common/system_utils.cpp create mode 100644 gfx/angle/checkout/src/common/system_utils.h create mode 100644 gfx/angle/checkout/src/common/system_utils_apple.cpp create mode 100644 gfx/angle/checkout/src/common/system_utils_linux.cpp create mode 100644 gfx/angle/checkout/src/common/system_utils_mac.cpp create mode 100644 gfx/angle/checkout/src/common/system_utils_posix.cpp create mode 100644 gfx/angle/checkout/src/common/system_utils_win.cpp create mode 100644 gfx/angle/checkout/src/common/system_utils_win32.cpp create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/base_export.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/containers/mru_cache.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/logging.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/macros.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/no_destructor.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/checked_math.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/checked_math_impl.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/clamped_math.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/clamped_math_impl.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/math_constants.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/ranges.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/safe_conversions.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/safe_conversions_arm_impl.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/safe_conversions_impl.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/safe_math.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/safe_math_arm_impl.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/safe_math_clang_gcc_impl.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/safe_math_shared_impl.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/sha1.cc create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/sha1.h create mode 100644 gfx/angle/checkout/src/common/third_party/base/anglebase/sys_byteorder.h create mode 100644 gfx/angle/checkout/src/common/third_party/smhasher/src/PMurHash.cpp create mode 100644 gfx/angle/checkout/src/common/third_party/smhasher/src/PMurHash.h create mode 100644 gfx/angle/checkout/src/common/third_party/xxhash/xxhash.c create mode 100644 gfx/angle/checkout/src/common/third_party/xxhash/xxhash.h create mode 100644 gfx/angle/checkout/src/common/tls.cpp create mode 100644 gfx/angle/checkout/src/common/tls.h create mode 100644 gfx/angle/checkout/src/common/uniform_type_info_autogen.cpp create mode 100644 gfx/angle/checkout/src/common/utilities.cpp create mode 100644 gfx/angle/checkout/src/common/utilities.h create mode 100644 gfx/angle/checkout/src/common/vector_utils.h create mode 100644 gfx/angle/checkout/src/common/vulkan/libvulkan_loader.cpp create mode 100644 gfx/angle/checkout/src/common/vulkan/libvulkan_loader.h create mode 100644 gfx/angle/checkout/src/common/vulkan/vk_google_filtering_precision.h create mode 100644 gfx/angle/checkout/src/common/vulkan/vk_headers.h create mode 100644 gfx/angle/checkout/src/common/vulkan/vulkan_icd.cpp create mode 100644 gfx/angle/checkout/src/common/vulkan/vulkan_icd.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/DiagnosticsBase.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/DiagnosticsBase.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/DirectiveHandlerBase.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/DirectiveHandlerBase.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/DirectiveParser.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/DirectiveParser.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/ExpressionParser.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Input.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Input.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Lexer.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Lexer.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Macro.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Macro.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/MacroExpander.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/MacroExpander.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Preprocessor.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Preprocessor.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/SourceLocation.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Token.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Token.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/Tokenizer.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/numeric_lex.h create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/preprocessor_lex_autogen.cpp create mode 100644 gfx/angle/checkout/src/compiler/preprocessor/preprocessor_tab_autogen.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ASTMetadataHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ASTMetadataHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/AtomicCounterFunctionHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/AtomicCounterFunctionHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/BaseTypes.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/BaseTypes.h create mode 100644 gfx/angle/checkout/src/compiler/translator/BuiltInFunctionEmulator.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/BuiltInFunctionEmulator.h create mode 100644 gfx/angle/checkout/src/compiler/translator/BuiltInFunctionEmulatorGLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/BuiltInFunctionEmulatorGLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/BuiltInFunctionEmulatorHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/BuiltInFunctionEmulatorHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/BuiltinsWorkaroundGLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/BuiltinsWorkaroundGLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/CallDAG.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/CallDAG.h create mode 100644 gfx/angle/checkout/src/compiler/translator/CodeGen.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/CollectVariables.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/CollectVariables.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Common.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Compiler.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/Compiler.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ConstantUnion.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ConstantUnion.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Declarator.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/Declarator.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Diagnostics.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/Diagnostics.h create mode 100644 gfx/angle/checkout/src/compiler/translator/DirectiveHandler.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/DirectiveHandler.h create mode 100644 gfx/angle/checkout/src/compiler/translator/DriverUniformMetal.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ExtensionBehavior.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ExtensionBehavior.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ExtensionGLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ExtensionGLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/FlagStd140Structs.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/FlagStd140Structs.h create mode 100644 gfx/angle/checkout/src/compiler/translator/FunctionLookup.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/FunctionLookup.h create mode 100644 gfx/angle/checkout/src/compiler/translator/HashNames.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/HashNames.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ImageFunctionHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ImageFunctionHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ImmutableString.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ImmutableStringBuilder.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ImmutableStringBuilder.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ImmutableString_ESSL_autogen.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/InfoSink.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/InfoSink.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Initialize.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/Initialize.h create mode 100644 gfx/angle/checkout/src/compiler/translator/InitializeDll.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/InitializeDll.h create mode 100644 gfx/angle/checkout/src/compiler/translator/InitializeGlobals.h create mode 100644 gfx/angle/checkout/src/compiler/translator/IntermNode.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/IntermNode.h create mode 100644 gfx/angle/checkout/src/compiler/translator/IsASTDepthBelowLimit.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/IsASTDepthBelowLimit.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Operator.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/Operator_autogen.h create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputESSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputESSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputGLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputGLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputGLSLBase.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputGLSLBase.h create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputTree.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/OutputTree.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ParseContext.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ParseContext.h create mode 100644 gfx/angle/checkout/src/compiler/translator/PoolAlloc.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/PoolAlloc.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Pragma.h create mode 100644 gfx/angle/checkout/src/compiler/translator/QualifierTypes.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/QualifierTypes.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ResourcesHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ResourcesHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Severity.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ShaderLang.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ShaderStorageBlockFunctionHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ShaderStorageBlockFunctionHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ShaderStorageBlockOutputHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ShaderStorageBlockOutputHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ShaderVars.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/StaticType.h create mode 100644 gfx/angle/checkout/src/compiler/translator/StructureHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/StructureHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Symbol.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/Symbol.h create mode 100644 gfx/angle/checkout/src/compiler/translator/SymbolTable.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/SymbolTable.h create mode 100644 gfx/angle/checkout/src/compiler/translator/SymbolTable_ESSL_autogen.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/SymbolTable_autogen.h create mode 100644 gfx/angle/checkout/src/compiler/translator/SymbolUniqueId.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/SymbolUniqueId.h create mode 100644 gfx/angle/checkout/src/compiler/translator/TextureFunctionHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/TextureFunctionHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/TranslatorESSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/TranslatorESSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/TranslatorGLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/TranslatorGLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/TranslatorHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/TranslatorHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/TranslatorMetal.h create mode 100644 gfx/angle/checkout/src/compiler/translator/TranslatorMetalDirect.h create mode 100644 gfx/angle/checkout/src/compiler/translator/TranslatorVulkan.h create mode 100644 gfx/angle/checkout/src/compiler/translator/Types.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/Types.h create mode 100644 gfx/angle/checkout/src/compiler/translator/UtilsHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/UtilsHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateAST.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateAST.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateBarrierFunctionCall.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateBarrierFunctionCall.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateClipCullDistance.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateClipCullDistance.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateGlobalInitializer.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateGlobalInitializer.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateLimitations.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateLimitations.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateMaxParameters.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateMaxParameters.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateOutputs.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateOutputs.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateSwitch.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateSwitch.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateTypeSizeLimitations.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateTypeSizeLimitations.h create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateVaryingLocations.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/ValidateVaryingLocations.h create mode 100644 gfx/angle/checkout/src/compiler/translator/VariablePacker.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/VariablePacker.h create mode 100644 gfx/angle/checkout/src/compiler/translator/VersionGLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/VersionGLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/blocklayout.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/blocklayout.h create mode 100644 gfx/angle/checkout/src/compiler/translator/blocklayoutHLSL.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/blocklayoutHLSL.h create mode 100644 gfx/angle/checkout/src/compiler/translator/emulated_builtin_functions_hlsl_autogen.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/glslang.h create mode 100644 gfx/angle/checkout/src/compiler/translator/glslang_lex_autogen.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/glslang_tab_autogen.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/glslang_tab_autogen.h create mode 100644 gfx/angle/checkout/src/compiler/translator/glslang_wrapper.h create mode 100644 gfx/angle/checkout/src/compiler/translator/length_limits.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ClampIndirectIndices.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ClampIndirectIndices.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ClampPointSize.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ClampPointSize.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ConvertUnsupportedConstructorsToFunctionCalls.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ConvertUnsupportedConstructorsToFunctionCalls.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/DeclareAndInitBuiltinsForInstancedMultiview.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/DeclareAndInitBuiltinsForInstancedMultiview.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/DeferGlobalInitializers.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/DeferGlobalInitializers.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/EmulateGLFragColorBroadcast.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/EmulateGLFragColorBroadcast.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/EmulateMultiDrawShaderBuiltins.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/EmulateMultiDrawShaderBuiltins.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/FoldExpressions.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/FoldExpressions.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ForcePrecisionQualifier.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ForcePrecisionQualifier.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/InitializeVariables.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/InitializeVariables.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/MonomorphizeUnsupportedFunctions.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/MonomorphizeUnsupportedFunctions.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/NameNamelessUniformBuffers.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/NameNamelessUniformBuffers.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/PruneEmptyCases.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/PruneEmptyCases.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/PruneNoOps.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/PruneNoOps.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RecordConstantPrecision.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RecordConstantPrecision.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveArrayLengthMethod.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveArrayLengthMethod.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveAtomicCounterBuiltins.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveAtomicCounterBuiltins.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveDynamicIndexing.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveDynamicIndexing.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveInvariantDeclaration.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveInvariantDeclaration.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveUnreferencedVariables.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RemoveUnreferencedVariables.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteArrayOfArrayOfOpaqueUniforms.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteArrayOfArrayOfOpaqueUniforms.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteAtomicCounters.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteAtomicCounters.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteCubeMapSamplersAs2DArray.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteCubeMapSamplersAs2DArray.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteDfdy.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteDfdy.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewritePixelLocalStorage.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewritePixelLocalStorage.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteStructSamplers.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteStructSamplers.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteTexelFetchOffset.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/RewriteTexelFetchOffset.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ScalarizeVecAndMatConstructorArgs.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/ScalarizeVecAndMatConstructorArgs.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/SeparateDeclarations.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/SeparateDeclarations.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/SeparateStructFromUniformDeclarations.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/SeparateStructFromUniformDeclarations.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/SimplifyLoopConditions.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/SimplifyLoopConditions.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/SplitSequenceOperator.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/SplitSequenceOperator.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/AddAndTrueToLoopCondition.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/AddAndTrueToLoopCondition.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/RewriteDoWhile.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/RewriteDoWhile.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/RewriteRowMajorMatrices.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/RewriteRowMajorMatrices.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/RewriteUnaryMinusOperatorFloat.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/RewriteUnaryMinusOperatorFloat.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/UnfoldShortCircuitAST.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/apple/UnfoldShortCircuitAST.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/AddDefaultReturnStatements.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/AddDefaultReturnStatements.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/AggregateAssignArraysInSSBOs.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/AggregateAssignArraysInSSBOs.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/AggregateAssignStructsInSSBOs.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/AggregateAssignStructsInSSBOs.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/ArrayReturnValueToOutParameter.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/ArrayReturnValueToOutParameter.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/BreakVariableAliasingInInnerLoops.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/BreakVariableAliasingInInnerLoops.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/ExpandIntegerPowExpressions.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/ExpandIntegerPowExpressions.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RecordUniformBlocksWithLargeArrayMember.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RecordUniformBlocksWithLargeArrayMember.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RemoveSwitchFallThrough.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RemoveSwitchFallThrough.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RewriteAtomicFunctionExpressions.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RewriteAtomicFunctionExpressions.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RewriteElseBlocks.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RewriteElseBlocks.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RewriteExpressionsWithShaderStorageBlock.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RewriteExpressionsWithShaderStorageBlock.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RewriteUnaryMinusOperatorInt.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/RewriteUnaryMinusOperatorInt.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/SeparateArrayConstructorStatements.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/SeparateArrayConstructorStatements.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/SeparateArrayInitialization.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/SeparateArrayInitialization.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/SeparateExpressionsReturningArrays.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/SeparateExpressionsReturningArrays.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/UnfoldShortCircuitToIf.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/UnfoldShortCircuitToIf.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/WrapSwitchStatementsInBlocks.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/d3d/WrapSwitchStatementsInBlocks.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/gl/ClampFragDepth.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/gl/ClampFragDepth.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/gl/RegenerateStructNames.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/gl/RegenerateStructNames.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/gl/RewriteRepeatedAssignToSwizzled.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/gl/RewriteRepeatedAssignToSwizzled.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/gl/UseInterfaceBlockFields.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_ops/gl/UseInterfaceBlockFields.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/AsNode.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/BuiltIn.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/BuiltIn_ESSL_autogen.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/BuiltIn_complete_autogen.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/DriverUniform.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/DriverUniform.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/FindFunction.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/FindFunction.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/FindMain.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/FindMain.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/FindPreciseNodes.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/FindPreciseNodes.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/FindSymbolNode.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/FindSymbolNode.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/IntermNodePatternMatcher.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/IntermNodePatternMatcher.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/IntermNode_util.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/IntermNode_util.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/IntermRebuild.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/IntermRebuild.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/IntermTraverse.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/IntermTraverse.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/NodeSearch.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/NodeType.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/ReplaceArrayOfMatrixVarying.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/ReplaceArrayOfMatrixVarying.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/ReplaceClipCullDistanceVariable.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/ReplaceClipCullDistanceVariable.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/ReplaceShadowingVariables.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/ReplaceShadowingVariables.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/ReplaceVariable.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/ReplaceVariable.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/RewriteSampleMaskVariable.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/RewriteSampleMaskVariable.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/RunAtTheBeginningOfShader.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/RunAtTheBeginningOfShader.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/RunAtTheEndOfShader.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/RunAtTheEndOfShader.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/SpecializationConstant.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/SpecializationConstant.h create mode 100644 gfx/angle/checkout/src/compiler/translator/tree_util/Visit.h create mode 100644 gfx/angle/checkout/src/compiler/translator/util.cpp create mode 100644 gfx/angle/checkout/src/compiler/translator/util.h create mode 100644 gfx/angle/checkout/src/gpu_info_util/SystemInfo.cpp create mode 100644 gfx/angle/checkout/src/gpu_info_util/SystemInfo.h create mode 100644 gfx/angle/checkout/src/gpu_info_util/SystemInfo_internal.h create mode 100644 gfx/angle/checkout/src/gpu_info_util/SystemInfo_vulkan.cpp create mode 100644 gfx/angle/checkout/src/gpu_info_util/SystemInfo_vulkan.h create mode 100644 gfx/angle/checkout/src/gpu_info_util/SystemInfo_win.cpp create mode 100644 gfx/angle/checkout/src/image_util/copyimage.cpp create mode 100644 gfx/angle/checkout/src/image_util/copyimage.h create mode 100644 gfx/angle/checkout/src/image_util/copyimage.inc create mode 100644 gfx/angle/checkout/src/image_util/generatemip.h create mode 100644 gfx/angle/checkout/src/image_util/generatemip.inc create mode 100644 gfx/angle/checkout/src/image_util/imageformats.cpp create mode 100644 gfx/angle/checkout/src/image_util/imageformats.h create mode 100644 gfx/angle/checkout/src/image_util/loadimage.cpp create mode 100644 gfx/angle/checkout/src/image_util/loadimage.h create mode 100644 gfx/angle/checkout/src/image_util/loadimage.inc create mode 100644 gfx/angle/checkout/src/image_util/loadimage_astc.cpp create mode 100644 gfx/angle/checkout/src/image_util/loadimage_etc.cpp create mode 100644 gfx/angle/checkout/src/image_util/loadimage_paletted.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/AttributeMap.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/AttributeMap.h create mode 100644 gfx/angle/checkout/src/libANGLE/BinaryStream.h create mode 100644 gfx/angle/checkout/src/libANGLE/BlobCache.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/BlobCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/Buffer.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Buffer.h create mode 100644 gfx/angle/checkout/src/libANGLE/Caps.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Caps.h create mode 100644 gfx/angle/checkout/src/libANGLE/Compiler.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Compiler.h create mode 100644 gfx/angle/checkout/src/libANGLE/Config.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Config.h create mode 100644 gfx/angle/checkout/src/libANGLE/Constants.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Context.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context.inl.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gl_1_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gl_2_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gl_3_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gl_4_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gles_1_0.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gles_1_0_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gles_2_0_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gles_3_0_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gles_3_1_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gles_3_2_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Context_gles_ext_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Debug.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Debug.h create mode 100644 gfx/angle/checkout/src/libANGLE/Device.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Device.h create mode 100644 gfx/angle/checkout/src/libANGLE/Display.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Display.h create mode 100644 gfx/angle/checkout/src/libANGLE/EGLSync.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/EGLSync.h create mode 100644 gfx/angle/checkout/src/libANGLE/Error.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Error.h create mode 100644 gfx/angle/checkout/src/libANGLE/Error.inc create mode 100644 gfx/angle/checkout/src/libANGLE/ErrorStrings.h create mode 100644 gfx/angle/checkout/src/libANGLE/Fence.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Fence.h create mode 100644 gfx/angle/checkout/src/libANGLE/Framebuffer.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Framebuffer.h create mode 100644 gfx/angle/checkout/src/libANGLE/FramebufferAttachment.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/FramebufferAttachment.h create mode 100644 gfx/angle/checkout/src/libANGLE/GLES1Renderer.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/GLES1Renderer.h create mode 100644 gfx/angle/checkout/src/libANGLE/GLES1Shaders.inc create mode 100644 gfx/angle/checkout/src/libANGLE/GLES1State.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/GLES1State.h create mode 100644 gfx/angle/checkout/src/libANGLE/HandleAllocator.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/HandleAllocator.h create mode 100644 gfx/angle/checkout/src/libANGLE/Image.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Image.h create mode 100644 gfx/angle/checkout/src/libANGLE/ImageIndex.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/ImageIndex.h create mode 100644 gfx/angle/checkout/src/libANGLE/IndexRangeCache.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/IndexRangeCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/InfoLog.h create mode 100644 gfx/angle/checkout/src/libANGLE/LoggingAnnotator.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/LoggingAnnotator.h create mode 100644 gfx/angle/checkout/src/libANGLE/MemoryObject.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/MemoryObject.h create mode 100644 gfx/angle/checkout/src/libANGLE/MemoryProgramCache.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/MemoryProgramCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/MemoryShaderCache.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/MemoryShaderCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/Observer.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Observer.h create mode 100644 gfx/angle/checkout/src/libANGLE/Overlay.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Overlay.h create mode 100644 gfx/angle/checkout/src/libANGLE/OverlayWidgets.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/OverlayWidgets.h create mode 100644 gfx/angle/checkout/src/libANGLE/Overlay_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Overlay_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/Overlay_font_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Overlay_font_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/PixelLocalStorage.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/PixelLocalStorage.h create mode 100644 gfx/angle/checkout/src/libANGLE/Platform.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Program.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Program.h create mode 100644 gfx/angle/checkout/src/libANGLE/ProgramExecutable.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/ProgramExecutable.h create mode 100644 gfx/angle/checkout/src/libANGLE/ProgramLinkedResources.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/ProgramLinkedResources.h create mode 100644 gfx/angle/checkout/src/libANGLE/ProgramPipeline.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/ProgramPipeline.h create mode 100644 gfx/angle/checkout/src/libANGLE/Query.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Query.h create mode 100644 gfx/angle/checkout/src/libANGLE/RefCountObject.h create mode 100644 gfx/angle/checkout/src/libANGLE/Renderbuffer.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Renderbuffer.h create mode 100644 gfx/angle/checkout/src/libANGLE/ResourceManager.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/ResourceManager.h create mode 100644 gfx/angle/checkout/src/libANGLE/ResourceMap.h create mode 100644 gfx/angle/checkout/src/libANGLE/Sampler.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Sampler.h create mode 100644 gfx/angle/checkout/src/libANGLE/Semaphore.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Semaphore.h create mode 100644 gfx/angle/checkout/src/libANGLE/Shader.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Shader.h create mode 100644 gfx/angle/checkout/src/libANGLE/SizedMRUCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/State.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/State.h create mode 100644 gfx/angle/checkout/src/libANGLE/Stream.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Stream.h create mode 100644 gfx/angle/checkout/src/libANGLE/Surface.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Surface.h create mode 100644 gfx/angle/checkout/src/libANGLE/Texture.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Texture.h create mode 100644 gfx/angle/checkout/src/libANGLE/Thread.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Thread.h create mode 100644 gfx/angle/checkout/src/libANGLE/TransformFeedback.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/TransformFeedback.h create mode 100644 gfx/angle/checkout/src/libANGLE/Uniform.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/Uniform.h create mode 100644 gfx/angle/checkout/src/libANGLE/VaryingPacking.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/VaryingPacking.h create mode 100644 gfx/angle/checkout/src/libANGLE/Version.h create mode 100644 gfx/angle/checkout/src/libANGLE/Version.inc create mode 100644 gfx/angle/checkout/src/libANGLE/VertexArray.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/VertexArray.h create mode 100644 gfx/angle/checkout/src/libANGLE/VertexAttribute.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/VertexAttribute.h create mode 100644 gfx/angle/checkout/src/libANGLE/VertexAttribute.inc create mode 100644 gfx/angle/checkout/src/libANGLE/WorkerThread.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/WorkerThread.h create mode 100644 gfx/angle/checkout/src/libANGLE/angletypes.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/angletypes.h create mode 100644 gfx/angle/checkout/src/libANGLE/angletypes.inc create mode 100644 gfx/angle/checkout/src/libANGLE/capture/FrameCapture.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/FrameCapture_mock.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_egl.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gl_1_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gl_2_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gl_3_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gl_4_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gles_1_0_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gles_2_0_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gles_3_0_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gles_3_1_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gles_3_2_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/capture_gles_ext_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/frame_capture_utils.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/frame_capture_utils_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/frame_capture_utils_mock.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/capture/gl_enum_utils.h create mode 100644 gfx/angle/checkout/src/libANGLE/capture/gl_enum_utils_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/entry_points_utils.h create mode 100644 gfx/angle/checkout/src/libANGLE/es3_copy_conversion_table_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/features.h create mode 100644 gfx/angle/checkout/src/libANGLE/format_map_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/format_map_desktop.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/formatutils.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/formatutils.h create mode 100644 gfx/angle/checkout/src/libANGLE/gles_extensions_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/gles_extensions_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/histogram_macros.h create mode 100644 gfx/angle/checkout/src/libANGLE/queryconversions.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/queryconversions.h create mode 100644 gfx/angle/checkout/src/libANGLE/queryutils.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/queryutils.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/BufferImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/BufferImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/CompilerImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ContextImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ContextImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/DeviceImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/DeviceImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/DisplayImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/DisplayImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/EGLImplFactory.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/EGLReusableSync.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/EGLReusableSync.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/EGLSyncImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/EGLSyncImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/FenceNVImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/Format.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/FormatID_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/Format_table_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/FramebufferAttachmentObjectImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/FramebufferImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/FramebufferImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/GLImplFactory.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ImageImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ImageImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/MemoryObjectImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/OverlayImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ProgramImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ProgramImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ProgramPipelineImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ProgramPipelineImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/QueryImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/QueryImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/RenderTargetCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/RenderbufferImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/RenderbufferImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/SamplerImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/SemaphoreImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ShaderImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/ShaderImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/StreamProducerImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/SurfaceImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/SurfaceImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/SyncImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/TextureImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/TextureImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/TransformFeedbackImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/TransformFeedbackImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/VertexArrayImpl.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/VertexArrayImpl.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/copyvertex.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/copyvertex.inc.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/BufferD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/BufferD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/CompilerD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/CompilerD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/ContextD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/DeviceD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/DeviceD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/DisplayD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/DisplayD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/DynamicHLSL.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/DynamicHLSL.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/DynamicImage2DHLSL.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/DynamicImage2DHLSL.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/EGLImageD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/EGLImageD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/FramebufferD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/FramebufferD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/HLSLCompiler.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/HLSLCompiler.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/ImageD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/ImageD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/IndexBuffer.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/IndexBuffer.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/IndexDataManager.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/IndexDataManager.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/NativeWindowD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/NativeWindowD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/ProgramD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/ProgramD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/RenderTargetD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/RenderTargetD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/RenderbufferD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/RenderbufferD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/RendererD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/RendererD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/SamplerD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/ShaderD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/ShaderD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/ShaderExecutableD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/ShaderExecutableD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/SurfaceD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/SurfaceD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/SwapChainD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/SwapChainD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/TextureD3D.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/TextureD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/TextureStorage.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/VertexBuffer.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/VertexBuffer.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/VertexDataManager.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/VertexDataManager.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Blit11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Blit11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Blit11Helper_autogen.inc create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Buffer11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Buffer11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Clear11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Clear11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Context11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Context11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/DebugAnnotator11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/DebugAnnotator11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/ExternalImageSiblingImpl11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/ExternalImageSiblingImpl11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Fence11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Fence11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Framebuffer11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Framebuffer11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Image11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Image11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/IndexBuffer11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/IndexBuffer11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/InputLayoutCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/MappedSubresourceVerifier11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/MappedSubresourceVerifier11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/NativeWindow11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/PixelTransfer11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/PixelTransfer11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Program11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Program11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/ProgramPipeline11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/ProgramPipeline11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Query11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Query11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/RenderStateCache.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/RenderStateCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/RenderTarget11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/RenderTarget11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Renderer11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/ResourceManager11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/ResourceManager11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/ShaderExecutable11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/ShaderExecutable11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/StateManager11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/StateManager11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/StreamProducerD3DTexture.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/StreamProducerD3DTexture.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/SwapChain11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/SwapChain11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/TextureStorage11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/TextureStorage11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/TransformFeedback11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/TransformFeedback11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Trim11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/Trim11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/VertexArray11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/VertexArray11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/VertexBuffer11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/VertexBuffer11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/converged/CompositorNativeWindow11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/converged/CompositorNativeWindow11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/formatutils11.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/formatutils11.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/renderer11_utils.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/renderer11_utils.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/buffertotexture11_gs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/buffertotexture11_ps_4f.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/buffertotexture11_ps_4i.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/buffertotexture11_ps_4ui.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/buffertotexture11_vs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clear11_fl9vs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clear11multiviewgs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clear11multiviewvs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clear11vs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/cleardepth11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearfloat11_fl9ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearfloat11ps1.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearfloat11ps2.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearfloat11ps3.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearfloat11ps4.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearfloat11ps5.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearfloat11ps6.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearfloat11ps7.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearfloat11ps8.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearsint11ps1.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearsint11ps2.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearsint11ps3.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearsint11ps4.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearsint11ps5.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearsint11ps6.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearsint11ps7.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearsint11ps8.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearuint11ps1.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearuint11ps2.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearuint11ps3.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearuint11ps4.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearuint11ps5.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearuint11ps6.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearuint11ps7.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/clearuint11ps8.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_luma_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_luma_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_luma_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_lumaalpha_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_lumaalpha_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_lumaalpha_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgb_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgb_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgb_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgb_565_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgb_565_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgb_565_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_4444_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_4444_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_4444_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_5551_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_5551_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_pm_rgba_5551_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_luma_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_luma_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_luma_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_lumaalpha_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_lumaalpha_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_lumaalpha_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgb_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgb_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgb_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgb_565_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgb_565_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgb_565_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_4444_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_4444_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_4444_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_5551_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_5551_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftof_um_rgba_5551_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_pm_rgb_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_pm_rgb_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_pm_rgba_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_pm_rgba_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_pt_rgb_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_pt_rgb_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_pt_rgba_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_pt_rgba_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_um_rgb_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_um_rgb_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_um_rgba_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftoi_um_rgba_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pm_rgb_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pm_rgb_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pm_rgb_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pm_rgba_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pm_rgba_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pm_rgba_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pt_rgb_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pt_rgb_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pt_rgb_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pt_rgba_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pt_rgba_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_pt_rgba_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_um_rgb_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_um_rgb_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_um_rgb_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_um_rgba_2d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_um_rgba_2darray_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/multiplyalpha_ftou_um_rgba_3d_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthrough2d11vs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthrough3d11gs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthrough3d11vs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthrougha2d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughdepth2d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughlum2d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughlum2darray11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughlum3d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughlumalpha2d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughlumalpha2darray11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughlumalpha3d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughr2d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughr2darray11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughr2darrayi11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughr2darrayui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughr2di11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughr2dui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughr3d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughr3di11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughr3dui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrg2d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrg2darray11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrg2darrayi11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrg2darrayui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrg2di11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrg2dui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrg3d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrg3di11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrg3dui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb2d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb2d_565_11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb2darray11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb2darray_565_11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb2darrayi11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb2darrayui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb2di11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb2dui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb3d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb3d_565_11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb3di11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgb3dui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2d_4444_11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2d_5551_11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2darray11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2darray_4444_11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2darray_5551_11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2darrayi11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2darrayui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2di11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2dms11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba2dui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba3d11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba3d_4444_11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba3d_5551_11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba3di11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/passthroughrgba3dui11ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/resolvecolor2dps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/resolvedepth11_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/resolvedepthstencil11_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/resolvedepthstencil11_vs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/resolvestencil11_ps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/swizzlef2darrayps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/swizzlef2dps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/swizzlef3dps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/swizzlei2darrayps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/swizzlei2dps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/swizzlei3dps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/swizzleui2darrayps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/swizzleui2dps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/shaders/compiled/swizzleui3dps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/texture_format_table.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/texture_format_table.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/texture_format_table_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/texture_format_table_utils.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/win32/NativeWindow11Win32.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d11/win32/NativeWindow11Win32.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Blit9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Blit9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Buffer9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Buffer9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Context9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Context9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/DebugAnnotator9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/DebugAnnotator9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Fence9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Fence9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Framebuffer9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Framebuffer9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Image9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Image9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/IndexBuffer9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/IndexBuffer9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/NativeWindow9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/NativeWindow9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Query9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Query9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/RenderTarget9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/RenderTarget9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/Renderer9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/ShaderCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/ShaderExecutable9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/ShaderExecutable9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/StateManager9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/StateManager9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/SwapChain9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/SwapChain9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/TextureStorage9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/TextureStorage9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/VertexArray9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/VertexBuffer9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/VertexBuffer9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/VertexDeclarationCache.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/VertexDeclarationCache.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/formatutils9.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/formatutils9.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/renderer9_utils.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/renderer9_utils.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/shaders/compiled/componentmaskpremultps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/shaders/compiled/componentmaskps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/shaders/compiled/componentmaskunmultps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/shaders/compiled/luminancepremultps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/shaders/compiled/luminanceps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/shaders/compiled/luminanceunmultps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/shaders/compiled/passthroughps.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/shaders/compiled/standardvs.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/d3d9/vertexconversion.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/driver_utils_d3d.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/driver_utils_d3d.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d/formatutilsD3D.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d_format.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/d3d_format.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/driver_utils.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/driver_utils.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/dxgi_format_map.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/dxgi_format_map_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/dxgi_support_table.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/dxgi_support_table_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/gl/functionsgl_enums.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/load_functions_table.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/load_functions_table_autogen.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/renderer_utils.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/renderer_utils.h create mode 100644 gfx/angle/checkout/src/libANGLE/renderer/serial_utils.h create mode 100644 gfx/angle/checkout/src/libANGLE/trace.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationEGL.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationEGL.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationEGL_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationES.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES1.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationES1.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES1_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES2.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationES2.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES2_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES3.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationES3.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES31.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationES31.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES31_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES32.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationES32.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES32_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationES3_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationESEXT.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationESEXT.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationESEXT_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationGL1.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationGL1_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationGL2.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationGL2_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationGL3.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationGL3_autogen.h create mode 100644 gfx/angle/checkout/src/libANGLE/validationGL4.cpp create mode 100644 gfx/angle/checkout/src/libANGLE/validationGL4_autogen.h create mode 100644 gfx/angle/checkout/src/libEGL/egl_loader_autogen.cpp create mode 100644 gfx/angle/checkout/src/libEGL/egl_loader_autogen.h create mode 100644 gfx/angle/checkout/src/libEGL/libEGL.rc create mode 100644 gfx/angle/checkout/src/libEGL/libEGL_autogen.cpp create mode 100644 gfx/angle/checkout/src/libEGL/libEGL_autogen.def create mode 100644 gfx/angle/checkout/src/libEGL/resource.h create mode 100644 gfx/angle/checkout/src/libGLESv2/egl_ext_stubs.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/egl_ext_stubs_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/egl_stubs.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/egl_stubs_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_egl_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_egl_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_egl_ext_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_egl_ext_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_1_0_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_1_0_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_2_0_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_2_0_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_3_0_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_3_0_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_3_1_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_3_1_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_3_2_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_3_2_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_ext_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/entry_points_gles_ext_autogen.h create mode 100644 gfx/angle/checkout/src/libGLESv2/global_state.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/global_state.h create mode 100644 gfx/angle/checkout/src/libGLESv2/libGLESv2.rc create mode 100644 gfx/angle/checkout/src/libGLESv2/libGLESv2_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/libGLESv2_autogen.def create mode 100644 gfx/angle/checkout/src/libGLESv2/proc_table_egl.h create mode 100644 gfx/angle/checkout/src/libGLESv2/proc_table_egl_autogen.cpp create mode 100644 gfx/angle/checkout/src/libGLESv2/resource.h create mode 100644 gfx/angle/checkout/src/third_party/systeminfo/SystemInfo.cpp create mode 100644 gfx/angle/checkout/src/third_party/systeminfo/SystemInfo.h create mode 100644 gfx/angle/checkout/src/third_party/trace_event/trace_event.h create mode 100644 gfx/angle/checkout/src/third_party/volk/volk.c create mode 100644 gfx/angle/checkout/src/third_party/volk/volk.h create mode 100644 gfx/angle/checkout/third_party/vulkan-deps/vulkan-headers/src/include/vulkan/vk_icd.h create mode 100644 gfx/angle/checkout/third_party/vulkan-deps/vulkan-headers/src/include/vulkan/vk_layer.h create mode 100644 gfx/angle/checkout/third_party/vulkan-deps/vulkan-headers/src/include/vulkan/vk_platform.h create mode 100644 gfx/angle/checkout/third_party/vulkan-deps/vulkan-headers/src/include/vulkan/vk_sdk_platform.h create mode 100644 gfx/angle/checkout/third_party/vulkan-deps/vulkan-headers/src/include/vulkan/vulkan.h create mode 100644 gfx/angle/checkout/third_party/vulkan-deps/vulkan-headers/src/include/vulkan/vulkan.hpp create mode 100644 gfx/angle/checkout/third_party/vulkan-deps/vulkan-headers/src/include/vulkan/vulkan_core.h create mode 100644 gfx/angle/checkout/third_party/vulkan-deps/vulkan-headers/src/include/vulkan/vulkan_screen.h create mode 100644 gfx/angle/checkout/third_party/zlib/google/compression_utils_portable.cc create mode 100644 gfx/angle/checkout/third_party/zlib/google/compression_utils_portable.h (limited to 'gfx/angle/checkout') diff --git a/gfx/angle/checkout/LICENSE b/gfx/angle/checkout/LICENSE new file mode 100644 index 0000000000..0f65fd60fd --- /dev/null +++ b/gfx/angle/checkout/LICENSE @@ -0,0 +1,32 @@ +// Copyright 2018 The ANGLE Project Authors. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions +// are met: +// +// Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// +// Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following +// disclaimer in the documentation and/or other materials provided +// with the distribution. +// +// Neither the name of TransGaming Inc., Google Inc., 3DLabs Inc. +// Ltd., nor the names of their contributors may be used to endorse +// or promote products derived from this software without specific +// prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +// FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +// COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +// INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +// CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +// LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN +// ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +// POSSIBILITY OF SUCH DAMAGE. diff --git a/gfx/angle/checkout/include/EGL/egl.h b/gfx/angle/checkout/include/EGL/egl.h new file mode 100644 index 0000000000..97d0878cc7 --- /dev/null +++ b/gfx/angle/checkout/include/EGL/egl.h @@ -0,0 +1,342 @@ +#ifndef __egl_h_ +#define __egl_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright 2013-2020 The Khronos Group Inc. +** SPDX-License-Identifier: Apache-2.0 +** +** This header is generated from the Khronos EGL XML API Registry. +** The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** http://www.khronos.org/registry/egl +** +** Khronos $Git commit SHA1: 6fb1daea15 $ on $Git commit date: 2022-05-25 09:41:13 -0600 $ +*/ + +#include + +#ifndef EGL_EGL_PROTOTYPES +#define EGL_EGL_PROTOTYPES 1 +#endif + +/* Generated on date 20220525 */ + +/* Generated C header for: + * API: egl + * Versions considered: .* + * Versions emitted: .* + * Default extensions included: None + * Additional extensions included: _nomatch_^ + * Extensions removed: _nomatch_^ + */ + +#ifndef EGL_VERSION_1_0 +#define EGL_VERSION_1_0 1 +typedef unsigned int EGLBoolean; +typedef void *EGLDisplay; +#include +#include +typedef void *EGLConfig; +typedef void *EGLSurface; +typedef void *EGLContext; +typedef void (*__eglMustCastToProperFunctionPointerType)(void); +#define EGL_ALPHA_SIZE 0x3021 +#define EGL_BAD_ACCESS 0x3002 +#define EGL_BAD_ALLOC 0x3003 +#define EGL_BAD_ATTRIBUTE 0x3004 +#define EGL_BAD_CONFIG 0x3005 +#define EGL_BAD_CONTEXT 0x3006 +#define EGL_BAD_CURRENT_SURFACE 0x3007 +#define EGL_BAD_DISPLAY 0x3008 +#define EGL_BAD_MATCH 0x3009 +#define EGL_BAD_NATIVE_PIXMAP 0x300A +#define EGL_BAD_NATIVE_WINDOW 0x300B +#define EGL_BAD_PARAMETER 0x300C +#define EGL_BAD_SURFACE 0x300D +#define EGL_BLUE_SIZE 0x3022 +#define EGL_BUFFER_SIZE 0x3020 +#define EGL_CONFIG_CAVEAT 0x3027 +#define EGL_CONFIG_ID 0x3028 +#define EGL_CORE_NATIVE_ENGINE 0x305B +#define EGL_DEPTH_SIZE 0x3025 +#define EGL_DONT_CARE EGL_CAST(EGLint,-1) +#define EGL_DRAW 0x3059 +#define EGL_EXTENSIONS 0x3055 +#define EGL_FALSE 0 +#define EGL_GREEN_SIZE 0x3023 +#define EGL_HEIGHT 0x3056 +#define EGL_LARGEST_PBUFFER 0x3058 +#define EGL_LEVEL 0x3029 +#define EGL_MAX_PBUFFER_HEIGHT 0x302A +#define EGL_MAX_PBUFFER_PIXELS 0x302B +#define EGL_MAX_PBUFFER_WIDTH 0x302C +#define EGL_NATIVE_RENDERABLE 0x302D +#define EGL_NATIVE_VISUAL_ID 0x302E +#define EGL_NATIVE_VISUAL_TYPE 0x302F +#define EGL_NONE 0x3038 +#define EGL_NON_CONFORMANT_CONFIG 0x3051 +#define EGL_NOT_INITIALIZED 0x3001 +#define EGL_NO_CONTEXT EGL_CAST(EGLContext,0) +#define EGL_NO_DISPLAY EGL_CAST(EGLDisplay,0) +#define EGL_NO_SURFACE EGL_CAST(EGLSurface,0) +#define EGL_PBUFFER_BIT 0x0001 +#define EGL_PIXMAP_BIT 0x0002 +#define EGL_READ 0x305A +#define EGL_RED_SIZE 0x3024 +#define EGL_SAMPLES 0x3031 +#define EGL_SAMPLE_BUFFERS 0x3032 +#define EGL_SLOW_CONFIG 0x3050 +#define EGL_STENCIL_SIZE 0x3026 +#define EGL_SUCCESS 0x3000 +#define EGL_SURFACE_TYPE 0x3033 +#define EGL_TRANSPARENT_BLUE_VALUE 0x3035 +#define EGL_TRANSPARENT_GREEN_VALUE 0x3036 +#define EGL_TRANSPARENT_RED_VALUE 0x3037 +#define EGL_TRANSPARENT_RGB 0x3052 +#define EGL_TRANSPARENT_TYPE 0x3034 +#define EGL_TRUE 1 +#define EGL_VENDOR 0x3053 +#define EGL_VERSION 0x3054 +#define EGL_WIDTH 0x3057 +#define EGL_WINDOW_BIT 0x0004 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCHOOSECONFIGPROC) (EGLDisplay dpy, const EGLint *attrib_list, EGLConfig *configs, EGLint config_size, EGLint *num_config); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCOPYBUFFERSPROC) (EGLDisplay dpy, EGLSurface surface, EGLNativePixmapType target); +typedef EGLContext (EGLAPIENTRYP PFNEGLCREATECONTEXTPROC) (EGLDisplay dpy, EGLConfig config, EGLContext share_context, const EGLint *attrib_list); +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPBUFFERSURFACEPROC) (EGLDisplay dpy, EGLConfig config, const EGLint *attrib_list); +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPIXMAPSURFACEPROC) (EGLDisplay dpy, EGLConfig config, EGLNativePixmapType pixmap, const EGLint *attrib_list); +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEWINDOWSURFACEPROC) (EGLDisplay dpy, EGLConfig config, EGLNativeWindowType win, const EGLint *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYCONTEXTPROC) (EGLDisplay dpy, EGLContext ctx); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYSURFACEPROC) (EGLDisplay dpy, EGLSurface surface); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETCONFIGATTRIBPROC) (EGLDisplay dpy, EGLConfig config, EGLint attribute, EGLint *value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETCONFIGSPROC) (EGLDisplay dpy, EGLConfig *configs, EGLint config_size, EGLint *num_config); +typedef EGLDisplay (EGLAPIENTRYP PFNEGLGETCURRENTDISPLAYPROC) (void); +typedef EGLSurface (EGLAPIENTRYP PFNEGLGETCURRENTSURFACEPROC) (EGLint readdraw); +typedef EGLDisplay (EGLAPIENTRYP PFNEGLGETDISPLAYPROC) (EGLNativeDisplayType display_id); +typedef EGLint (EGLAPIENTRYP PFNEGLGETERRORPROC) (void); +typedef __eglMustCastToProperFunctionPointerType (EGLAPIENTRYP PFNEGLGETPROCADDRESSPROC) (const char *procname); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLINITIALIZEPROC) (EGLDisplay dpy, EGLint *major, EGLint *minor); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLMAKECURRENTPROC) (EGLDisplay dpy, EGLSurface draw, EGLSurface read, EGLContext ctx); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYCONTEXTPROC) (EGLDisplay dpy, EGLContext ctx, EGLint attribute, EGLint *value); +typedef const char *(EGLAPIENTRYP PFNEGLQUERYSTRINGPROC) (EGLDisplay dpy, EGLint name); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSURFACEPROC) (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLint *value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSPROC) (EGLDisplay dpy, EGLSurface surface); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLTERMINATEPROC) (EGLDisplay dpy); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLWAITGLPROC) (void); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLWAITNATIVEPROC) (EGLint engine); +#if EGL_EGL_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglChooseConfig (EGLDisplay dpy, const EGLint *attrib_list, EGLConfig *configs, EGLint config_size, EGLint *num_config); +EGLAPI EGLBoolean EGLAPIENTRY eglCopyBuffers (EGLDisplay dpy, EGLSurface surface, EGLNativePixmapType target); +EGLAPI EGLContext EGLAPIENTRY eglCreateContext (EGLDisplay dpy, EGLConfig config, EGLContext share_context, const EGLint *attrib_list); +EGLAPI EGLSurface EGLAPIENTRY eglCreatePbufferSurface (EGLDisplay dpy, EGLConfig config, const EGLint *attrib_list); +EGLAPI EGLSurface EGLAPIENTRY eglCreatePixmapSurface (EGLDisplay dpy, EGLConfig config, EGLNativePixmapType pixmap, const EGLint *attrib_list); +EGLAPI EGLSurface EGLAPIENTRY eglCreateWindowSurface (EGLDisplay dpy, EGLConfig config, EGLNativeWindowType win, const EGLint *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglDestroyContext (EGLDisplay dpy, EGLContext ctx); +EGLAPI EGLBoolean EGLAPIENTRY eglDestroySurface (EGLDisplay dpy, EGLSurface surface); +EGLAPI EGLBoolean EGLAPIENTRY eglGetConfigAttrib (EGLDisplay dpy, EGLConfig config, EGLint attribute, EGLint *value); +EGLAPI EGLBoolean EGLAPIENTRY eglGetConfigs (EGLDisplay dpy, EGLConfig *configs, EGLint config_size, EGLint *num_config); +EGLAPI EGLDisplay EGLAPIENTRY eglGetCurrentDisplay (void); +EGLAPI EGLSurface EGLAPIENTRY eglGetCurrentSurface (EGLint readdraw); +EGLAPI EGLDisplay EGLAPIENTRY eglGetDisplay (EGLNativeDisplayType display_id); +EGLAPI EGLint EGLAPIENTRY eglGetError (void); +EGLAPI __eglMustCastToProperFunctionPointerType EGLAPIENTRY eglGetProcAddress (const char *procname); +EGLAPI EGLBoolean EGLAPIENTRY eglInitialize (EGLDisplay dpy, EGLint *major, EGLint *minor); +EGLAPI EGLBoolean EGLAPIENTRY eglMakeCurrent (EGLDisplay dpy, EGLSurface draw, EGLSurface read, EGLContext ctx); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryContext (EGLDisplay dpy, EGLContext ctx, EGLint attribute, EGLint *value); +EGLAPI const char *EGLAPIENTRY eglQueryString (EGLDisplay dpy, EGLint name); +EGLAPI EGLBoolean EGLAPIENTRY eglQuerySurface (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLint *value); +EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers (EGLDisplay dpy, EGLSurface surface); +EGLAPI EGLBoolean EGLAPIENTRY eglTerminate (EGLDisplay dpy); +EGLAPI EGLBoolean EGLAPIENTRY eglWaitGL (void); +EGLAPI EGLBoolean EGLAPIENTRY eglWaitNative (EGLint engine); +#endif +#endif /* EGL_VERSION_1_0 */ + +#ifndef EGL_VERSION_1_1 +#define EGL_VERSION_1_1 1 +#define EGL_BACK_BUFFER 0x3084 +#define EGL_BIND_TO_TEXTURE_RGB 0x3039 +#define EGL_BIND_TO_TEXTURE_RGBA 0x303A +#define EGL_CONTEXT_LOST 0x300E +#define EGL_MIN_SWAP_INTERVAL 0x303B +#define EGL_MAX_SWAP_INTERVAL 0x303C +#define EGL_MIPMAP_TEXTURE 0x3082 +#define EGL_MIPMAP_LEVEL 0x3083 +#define EGL_NO_TEXTURE 0x305C +#define EGL_TEXTURE_2D 0x305F +#define EGL_TEXTURE_FORMAT 0x3080 +#define EGL_TEXTURE_RGB 0x305D +#define EGL_TEXTURE_RGBA 0x305E +#define EGL_TEXTURE_TARGET 0x3081 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLBINDTEXIMAGEPROC) (EGLDisplay dpy, EGLSurface surface, EGLint buffer); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLRELEASETEXIMAGEPROC) (EGLDisplay dpy, EGLSurface surface, EGLint buffer); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSURFACEATTRIBPROC) (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLint value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPINTERVALPROC) (EGLDisplay dpy, EGLint interval); +#if EGL_EGL_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglBindTexImage (EGLDisplay dpy, EGLSurface surface, EGLint buffer); +EGLAPI EGLBoolean EGLAPIENTRY eglReleaseTexImage (EGLDisplay dpy, EGLSurface surface, EGLint buffer); +EGLAPI EGLBoolean EGLAPIENTRY eglSurfaceAttrib (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLint value); +EGLAPI EGLBoolean EGLAPIENTRY eglSwapInterval (EGLDisplay dpy, EGLint interval); +#endif +#endif /* EGL_VERSION_1_1 */ + +#ifndef EGL_VERSION_1_2 +#define EGL_VERSION_1_2 1 +typedef unsigned int EGLenum; +typedef void *EGLClientBuffer; +#define EGL_ALPHA_FORMAT 0x3088 +#define EGL_ALPHA_FORMAT_NONPRE 0x308B +#define EGL_ALPHA_FORMAT_PRE 0x308C +#define EGL_ALPHA_MASK_SIZE 0x303E +#define EGL_BUFFER_PRESERVED 0x3094 +#define EGL_BUFFER_DESTROYED 0x3095 +#define EGL_CLIENT_APIS 0x308D +#define EGL_COLORSPACE 0x3087 +#define EGL_COLORSPACE_sRGB 0x3089 +#define EGL_COLORSPACE_LINEAR 0x308A +#define EGL_COLOR_BUFFER_TYPE 0x303F +#define EGL_CONTEXT_CLIENT_TYPE 0x3097 +#define EGL_DISPLAY_SCALING 10000 +#define EGL_HORIZONTAL_RESOLUTION 0x3090 +#define EGL_LUMINANCE_BUFFER 0x308F +#define EGL_LUMINANCE_SIZE 0x303D +#define EGL_OPENGL_ES_BIT 0x0001 +#define EGL_OPENVG_BIT 0x0002 +#define EGL_OPENGL_ES_API 0x30A0 +#define EGL_OPENVG_API 0x30A1 +#define EGL_OPENVG_IMAGE 0x3096 +#define EGL_PIXEL_ASPECT_RATIO 0x3092 +#define EGL_RENDERABLE_TYPE 0x3040 +#define EGL_RENDER_BUFFER 0x3086 +#define EGL_RGB_BUFFER 0x308E +#define EGL_SINGLE_BUFFER 0x3085 +#define EGL_SWAP_BEHAVIOR 0x3093 +#define EGL_UNKNOWN EGL_CAST(EGLint,-1) +#define EGL_VERTICAL_RESOLUTION 0x3091 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLBINDAPIPROC) (EGLenum api); +typedef EGLenum (EGLAPIENTRYP PFNEGLQUERYAPIPROC) (void); +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPBUFFERFROMCLIENTBUFFERPROC) (EGLDisplay dpy, EGLenum buftype, EGLClientBuffer buffer, EGLConfig config, const EGLint *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLRELEASETHREADPROC) (void); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLWAITCLIENTPROC) (void); +#if EGL_EGL_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglBindAPI (EGLenum api); +EGLAPI EGLenum EGLAPIENTRY eglQueryAPI (void); +EGLAPI EGLSurface EGLAPIENTRY eglCreatePbufferFromClientBuffer (EGLDisplay dpy, EGLenum buftype, EGLClientBuffer buffer, EGLConfig config, const EGLint *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglReleaseThread (void); +EGLAPI EGLBoolean EGLAPIENTRY eglWaitClient (void); +#endif +#endif /* EGL_VERSION_1_2 */ + +#ifndef EGL_VERSION_1_3 +#define EGL_VERSION_1_3 1 +#define EGL_CONFORMANT 0x3042 +#define EGL_CONTEXT_CLIENT_VERSION 0x3098 +#define EGL_MATCH_NATIVE_PIXMAP 0x3041 +#define EGL_OPENGL_ES2_BIT 0x0004 +#define EGL_VG_ALPHA_FORMAT 0x3088 +#define EGL_VG_ALPHA_FORMAT_NONPRE 0x308B +#define EGL_VG_ALPHA_FORMAT_PRE 0x308C +#define EGL_VG_ALPHA_FORMAT_PRE_BIT 0x0040 +#define EGL_VG_COLORSPACE 0x3087 +#define EGL_VG_COLORSPACE_sRGB 0x3089 +#define EGL_VG_COLORSPACE_LINEAR 0x308A +#define EGL_VG_COLORSPACE_LINEAR_BIT 0x0020 +#endif /* EGL_VERSION_1_3 */ + +#ifndef EGL_VERSION_1_4 +#define EGL_VERSION_1_4 1 +#define EGL_DEFAULT_DISPLAY EGL_CAST(EGLNativeDisplayType,0) +#define EGL_MULTISAMPLE_RESOLVE_BOX_BIT 0x0200 +#define EGL_MULTISAMPLE_RESOLVE 0x3099 +#define EGL_MULTISAMPLE_RESOLVE_DEFAULT 0x309A +#define EGL_MULTISAMPLE_RESOLVE_BOX 0x309B +#define EGL_OPENGL_API 0x30A2 +#define EGL_OPENGL_BIT 0x0008 +#define EGL_SWAP_BEHAVIOR_PRESERVED_BIT 0x0400 +typedef EGLContext (EGLAPIENTRYP PFNEGLGETCURRENTCONTEXTPROC) (void); +#if EGL_EGL_PROTOTYPES +EGLAPI EGLContext EGLAPIENTRY eglGetCurrentContext (void); +#endif +#endif /* EGL_VERSION_1_4 */ + +#ifndef EGL_VERSION_1_5 +#define EGL_VERSION_1_5 1 +typedef void *EGLSync; +typedef intptr_t EGLAttrib; +typedef khronos_utime_nanoseconds_t EGLTime; +typedef void *EGLImage; +#define EGL_CONTEXT_MAJOR_VERSION 0x3098 +#define EGL_CONTEXT_MINOR_VERSION 0x30FB +#define EGL_CONTEXT_OPENGL_PROFILE_MASK 0x30FD +#define EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY 0x31BD +#define EGL_NO_RESET_NOTIFICATION 0x31BE +#define EGL_LOSE_CONTEXT_ON_RESET 0x31BF +#define EGL_CONTEXT_OPENGL_CORE_PROFILE_BIT 0x00000001 +#define EGL_CONTEXT_OPENGL_COMPATIBILITY_PROFILE_BIT 0x00000002 +#define EGL_CONTEXT_OPENGL_DEBUG 0x31B0 +#define EGL_CONTEXT_OPENGL_FORWARD_COMPATIBLE 0x31B1 +#define EGL_CONTEXT_OPENGL_ROBUST_ACCESS 0x31B2 +#define EGL_OPENGL_ES3_BIT 0x00000040 +#define EGL_CL_EVENT_HANDLE 0x309C +#define EGL_SYNC_CL_EVENT 0x30FE +#define EGL_SYNC_CL_EVENT_COMPLETE 0x30FF +#define EGL_SYNC_PRIOR_COMMANDS_COMPLETE 0x30F0 +#define EGL_SYNC_TYPE 0x30F7 +#define EGL_SYNC_STATUS 0x30F1 +#define EGL_SYNC_CONDITION 0x30F8 +#define EGL_SIGNALED 0x30F2 +#define EGL_UNSIGNALED 0x30F3 +#define EGL_SYNC_FLUSH_COMMANDS_BIT 0x0001 +#define EGL_FOREVER 0xFFFFFFFFFFFFFFFFull +#define EGL_TIMEOUT_EXPIRED 0x30F5 +#define EGL_CONDITION_SATISFIED 0x30F6 +#define EGL_NO_SYNC EGL_CAST(EGLSync,0) +#define EGL_SYNC_FENCE 0x30F9 +#define EGL_GL_COLORSPACE 0x309D +#define EGL_GL_COLORSPACE_SRGB 0x3089 +#define EGL_GL_COLORSPACE_LINEAR 0x308A +#define EGL_GL_RENDERBUFFER 0x30B9 +#define EGL_GL_TEXTURE_2D 0x30B1 +#define EGL_GL_TEXTURE_LEVEL 0x30BC +#define EGL_GL_TEXTURE_3D 0x30B2 +#define EGL_GL_TEXTURE_ZOFFSET 0x30BD +#define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x30B3 +#define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x30B4 +#define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x30B5 +#define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x30B6 +#define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x30B7 +#define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x30B8 +#define EGL_IMAGE_PRESERVED 0x30D2 +#define EGL_NO_IMAGE EGL_CAST(EGLImage,0) +typedef EGLSync (EGLAPIENTRYP PFNEGLCREATESYNCPROC) (EGLDisplay dpy, EGLenum type, const EGLAttrib *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYSYNCPROC) (EGLDisplay dpy, EGLSync sync); +typedef EGLint (EGLAPIENTRYP PFNEGLCLIENTWAITSYNCPROC) (EGLDisplay dpy, EGLSync sync, EGLint flags, EGLTime timeout); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETSYNCATTRIBPROC) (EGLDisplay dpy, EGLSync sync, EGLint attribute, EGLAttrib *value); +typedef EGLImage (EGLAPIENTRYP PFNEGLCREATEIMAGEPROC) (EGLDisplay dpy, EGLContext ctx, EGLenum target, EGLClientBuffer buffer, const EGLAttrib *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYIMAGEPROC) (EGLDisplay dpy, EGLImage image); +typedef EGLDisplay (EGLAPIENTRYP PFNEGLGETPLATFORMDISPLAYPROC) (EGLenum platform, void *native_display, const EGLAttrib *attrib_list); +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPLATFORMWINDOWSURFACEPROC) (EGLDisplay dpy, EGLConfig config, void *native_window, const EGLAttrib *attrib_list); +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPLATFORMPIXMAPSURFACEPROC) (EGLDisplay dpy, EGLConfig config, void *native_pixmap, const EGLAttrib *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLWAITSYNCPROC) (EGLDisplay dpy, EGLSync sync, EGLint flags); +#if EGL_EGL_PROTOTYPES +EGLAPI EGLSync EGLAPIENTRY eglCreateSync (EGLDisplay dpy, EGLenum type, const EGLAttrib *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglDestroySync (EGLDisplay dpy, EGLSync sync); +EGLAPI EGLint EGLAPIENTRY eglClientWaitSync (EGLDisplay dpy, EGLSync sync, EGLint flags, EGLTime timeout); +EGLAPI EGLBoolean EGLAPIENTRY eglGetSyncAttrib (EGLDisplay dpy, EGLSync sync, EGLint attribute, EGLAttrib *value); +EGLAPI EGLImage EGLAPIENTRY eglCreateImage (EGLDisplay dpy, EGLContext ctx, EGLenum target, EGLClientBuffer buffer, const EGLAttrib *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglDestroyImage (EGLDisplay dpy, EGLImage image); +EGLAPI EGLDisplay EGLAPIENTRY eglGetPlatformDisplay (EGLenum platform, void *native_display, const EGLAttrib *attrib_list); +EGLAPI EGLSurface EGLAPIENTRY eglCreatePlatformWindowSurface (EGLDisplay dpy, EGLConfig config, void *native_window, const EGLAttrib *attrib_list); +EGLAPI EGLSurface EGLAPIENTRY eglCreatePlatformPixmapSurface (EGLDisplay dpy, EGLConfig config, void *native_pixmap, const EGLAttrib *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglWaitSync (EGLDisplay dpy, EGLSync sync, EGLint flags); +#endif +#endif /* EGL_VERSION_1_5 */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/EGL/eglext.h b/gfx/angle/checkout/include/EGL/eglext.h new file mode 100644 index 0000000000..d226b7f6da --- /dev/null +++ b/gfx/angle/checkout/include/EGL/eglext.h @@ -0,0 +1,1486 @@ +#ifndef __eglext_h_ +#define __eglext_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright 2013-2020 The Khronos Group Inc. +** SPDX-License-Identifier: Apache-2.0 +** +** This header is generated from the Khronos EGL XML API Registry. +** The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** http://www.khronos.org/registry/egl +** +** Khronos $Git commit SHA1: 6fb1daea15 $ on $Git commit date: 2022-05-25 09:41:13 -0600 $ +*/ + +#include + +#define EGL_EGLEXT_VERSION 20220525 + +/* Generated C header for: + * API: egl + * Versions considered: .* + * Versions emitted: _nomatch_^ + * Default extensions included: egl + * Additional extensions included: _nomatch_^ + * Extensions removed: _nomatch_^ + */ + +#ifndef EGL_KHR_cl_event +#define EGL_KHR_cl_event 1 +#define EGL_CL_EVENT_HANDLE_KHR 0x309C +#define EGL_SYNC_CL_EVENT_KHR 0x30FE +#define EGL_SYNC_CL_EVENT_COMPLETE_KHR 0x30FF +#endif /* EGL_KHR_cl_event */ + +#ifndef EGL_KHR_cl_event2 +#define EGL_KHR_cl_event2 1 +typedef void *EGLSyncKHR; +typedef intptr_t EGLAttribKHR; +typedef EGLSyncKHR (EGLAPIENTRYP PFNEGLCREATESYNC64KHRPROC) (EGLDisplay dpy, EGLenum type, const EGLAttribKHR *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLSyncKHR EGLAPIENTRY eglCreateSync64KHR (EGLDisplay dpy, EGLenum type, const EGLAttribKHR *attrib_list); +#endif +#endif /* EGL_KHR_cl_event2 */ + +#ifndef EGL_KHR_client_get_all_proc_addresses +#define EGL_KHR_client_get_all_proc_addresses 1 +#endif /* EGL_KHR_client_get_all_proc_addresses */ + +#ifndef EGL_KHR_config_attribs +#define EGL_KHR_config_attribs 1 +#define EGL_CONFORMANT_KHR 0x3042 +#define EGL_VG_COLORSPACE_LINEAR_BIT_KHR 0x0020 +#define EGL_VG_ALPHA_FORMAT_PRE_BIT_KHR 0x0040 +#endif /* EGL_KHR_config_attribs */ + +#ifndef EGL_KHR_context_flush_control +#define EGL_KHR_context_flush_control 1 +#define EGL_CONTEXT_RELEASE_BEHAVIOR_NONE_KHR 0 +#define EGL_CONTEXT_RELEASE_BEHAVIOR_KHR 0x2097 +#define EGL_CONTEXT_RELEASE_BEHAVIOR_FLUSH_KHR 0x2098 +#endif /* EGL_KHR_context_flush_control */ + +#ifndef EGL_KHR_create_context +#define EGL_KHR_create_context 1 +#define EGL_CONTEXT_MAJOR_VERSION_KHR 0x3098 +#define EGL_CONTEXT_MINOR_VERSION_KHR 0x30FB +#define EGL_CONTEXT_FLAGS_KHR 0x30FC +#define EGL_CONTEXT_OPENGL_PROFILE_MASK_KHR 0x30FD +#define EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_KHR 0x31BD +#define EGL_NO_RESET_NOTIFICATION_KHR 0x31BE +#define EGL_LOSE_CONTEXT_ON_RESET_KHR 0x31BF +#define EGL_CONTEXT_OPENGL_DEBUG_BIT_KHR 0x00000001 +#define EGL_CONTEXT_OPENGL_FORWARD_COMPATIBLE_BIT_KHR 0x00000002 +#define EGL_CONTEXT_OPENGL_ROBUST_ACCESS_BIT_KHR 0x00000004 +#define EGL_CONTEXT_OPENGL_CORE_PROFILE_BIT_KHR 0x00000001 +#define EGL_CONTEXT_OPENGL_COMPATIBILITY_PROFILE_BIT_KHR 0x00000002 +#define EGL_OPENGL_ES3_BIT_KHR 0x00000040 +#endif /* EGL_KHR_create_context */ + +#ifndef EGL_KHR_create_context_no_error +#define EGL_KHR_create_context_no_error 1 +#define EGL_CONTEXT_OPENGL_NO_ERROR_KHR 0x31B3 +#endif /* EGL_KHR_create_context_no_error */ + +#ifndef EGL_KHR_debug +#define EGL_KHR_debug 1 +typedef void *EGLLabelKHR; +typedef void *EGLObjectKHR; +typedef void (EGLAPIENTRY *EGLDEBUGPROCKHR)(EGLenum error,const char *command,EGLint messageType,EGLLabelKHR threadLabel,EGLLabelKHR objectLabel,const char* message); +#define EGL_OBJECT_THREAD_KHR 0x33B0 +#define EGL_OBJECT_DISPLAY_KHR 0x33B1 +#define EGL_OBJECT_CONTEXT_KHR 0x33B2 +#define EGL_OBJECT_SURFACE_KHR 0x33B3 +#define EGL_OBJECT_IMAGE_KHR 0x33B4 +#define EGL_OBJECT_SYNC_KHR 0x33B5 +#define EGL_OBJECT_STREAM_KHR 0x33B6 +#define EGL_DEBUG_MSG_CRITICAL_KHR 0x33B9 +#define EGL_DEBUG_MSG_ERROR_KHR 0x33BA +#define EGL_DEBUG_MSG_WARN_KHR 0x33BB +#define EGL_DEBUG_MSG_INFO_KHR 0x33BC +#define EGL_DEBUG_CALLBACK_KHR 0x33B8 +typedef EGLint (EGLAPIENTRYP PFNEGLDEBUGMESSAGECONTROLKHRPROC) (EGLDEBUGPROCKHR callback, const EGLAttrib *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDEBUGKHRPROC) (EGLint attribute, EGLAttrib *value); +typedef EGLint (EGLAPIENTRYP PFNEGLLABELOBJECTKHRPROC) (EGLDisplay display, EGLenum objectType, EGLObjectKHR object, EGLLabelKHR label); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLint EGLAPIENTRY eglDebugMessageControlKHR (EGLDEBUGPROCKHR callback, const EGLAttrib *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDebugKHR (EGLint attribute, EGLAttrib *value); +EGLAPI EGLint EGLAPIENTRY eglLabelObjectKHR (EGLDisplay display, EGLenum objectType, EGLObjectKHR object, EGLLabelKHR label); +#endif +#endif /* EGL_KHR_debug */ + +#ifndef EGL_KHR_display_reference +#define EGL_KHR_display_reference 1 +#define EGL_TRACK_REFERENCES_KHR 0x3352 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDISPLAYATTRIBKHRPROC) (EGLDisplay dpy, EGLint name, EGLAttrib *value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDisplayAttribKHR (EGLDisplay dpy, EGLint name, EGLAttrib *value); +#endif +#endif /* EGL_KHR_display_reference */ + +#ifndef EGL_KHR_fence_sync +#define EGL_KHR_fence_sync 1 +typedef khronos_utime_nanoseconds_t EGLTimeKHR; +#ifdef KHRONOS_SUPPORT_INT64 +#define EGL_SYNC_PRIOR_COMMANDS_COMPLETE_KHR 0x30F0 +#define EGL_SYNC_CONDITION_KHR 0x30F8 +#define EGL_SYNC_FENCE_KHR 0x30F9 +typedef EGLSyncKHR (EGLAPIENTRYP PFNEGLCREATESYNCKHRPROC) (EGLDisplay dpy, EGLenum type, const EGLint *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYSYNCKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync); +typedef EGLint (EGLAPIENTRYP PFNEGLCLIENTWAITSYNCKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync, EGLint flags, EGLTimeKHR timeout); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETSYNCATTRIBKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync, EGLint attribute, EGLint *value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLSyncKHR EGLAPIENTRY eglCreateSyncKHR (EGLDisplay dpy, EGLenum type, const EGLint *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglDestroySyncKHR (EGLDisplay dpy, EGLSyncKHR sync); +EGLAPI EGLint EGLAPIENTRY eglClientWaitSyncKHR (EGLDisplay dpy, EGLSyncKHR sync, EGLint flags, EGLTimeKHR timeout); +EGLAPI EGLBoolean EGLAPIENTRY eglGetSyncAttribKHR (EGLDisplay dpy, EGLSyncKHR sync, EGLint attribute, EGLint *value); +#endif +#endif /* KHRONOS_SUPPORT_INT64 */ +#endif /* EGL_KHR_fence_sync */ + +#ifndef EGL_KHR_get_all_proc_addresses +#define EGL_KHR_get_all_proc_addresses 1 +#endif /* EGL_KHR_get_all_proc_addresses */ + +#ifndef EGL_KHR_gl_colorspace +#define EGL_KHR_gl_colorspace 1 +#define EGL_GL_COLORSPACE_KHR 0x309D +#define EGL_GL_COLORSPACE_SRGB_KHR 0x3089 +#define EGL_GL_COLORSPACE_LINEAR_KHR 0x308A +#endif /* EGL_KHR_gl_colorspace */ + +#ifndef EGL_KHR_gl_renderbuffer_image +#define EGL_KHR_gl_renderbuffer_image 1 +#define EGL_GL_RENDERBUFFER_KHR 0x30B9 +#endif /* EGL_KHR_gl_renderbuffer_image */ + +#ifndef EGL_KHR_gl_texture_2D_image +#define EGL_KHR_gl_texture_2D_image 1 +#define EGL_GL_TEXTURE_2D_KHR 0x30B1 +#define EGL_GL_TEXTURE_LEVEL_KHR 0x30BC +#endif /* EGL_KHR_gl_texture_2D_image */ + +#ifndef EGL_KHR_gl_texture_3D_image +#define EGL_KHR_gl_texture_3D_image 1 +#define EGL_GL_TEXTURE_3D_KHR 0x30B2 +#define EGL_GL_TEXTURE_ZOFFSET_KHR 0x30BD +#endif /* EGL_KHR_gl_texture_3D_image */ + +#ifndef EGL_KHR_gl_texture_cubemap_image +#define EGL_KHR_gl_texture_cubemap_image 1 +#define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_X_KHR 0x30B3 +#define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_X_KHR 0x30B4 +#define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Y_KHR 0x30B5 +#define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_KHR 0x30B6 +#define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Z_KHR 0x30B7 +#define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_KHR 0x30B8 +#endif /* EGL_KHR_gl_texture_cubemap_image */ + +#ifndef EGL_KHR_image +#define EGL_KHR_image 1 +typedef void *EGLImageKHR; +#define EGL_NATIVE_PIXMAP_KHR 0x30B0 +#define EGL_NO_IMAGE_KHR EGL_CAST(EGLImageKHR,0) +typedef EGLImageKHR (EGLAPIENTRYP PFNEGLCREATEIMAGEKHRPROC) (EGLDisplay dpy, EGLContext ctx, EGLenum target, EGLClientBuffer buffer, const EGLint *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYIMAGEKHRPROC) (EGLDisplay dpy, EGLImageKHR image); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLImageKHR EGLAPIENTRY eglCreateImageKHR (EGLDisplay dpy, EGLContext ctx, EGLenum target, EGLClientBuffer buffer, const EGLint *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglDestroyImageKHR (EGLDisplay dpy, EGLImageKHR image); +#endif +#endif /* EGL_KHR_image */ + +#ifndef EGL_KHR_image_base +#define EGL_KHR_image_base 1 +#define EGL_IMAGE_PRESERVED_KHR 0x30D2 +#endif /* EGL_KHR_image_base */ + +#ifndef EGL_KHR_image_pixmap +#define EGL_KHR_image_pixmap 1 +#endif /* EGL_KHR_image_pixmap */ + +#ifndef EGL_KHR_lock_surface +#define EGL_KHR_lock_surface 1 +#define EGL_READ_SURFACE_BIT_KHR 0x0001 +#define EGL_WRITE_SURFACE_BIT_KHR 0x0002 +#define EGL_LOCK_SURFACE_BIT_KHR 0x0080 +#define EGL_OPTIMAL_FORMAT_BIT_KHR 0x0100 +#define EGL_MATCH_FORMAT_KHR 0x3043 +#define EGL_FORMAT_RGB_565_EXACT_KHR 0x30C0 +#define EGL_FORMAT_RGB_565_KHR 0x30C1 +#define EGL_FORMAT_RGBA_8888_EXACT_KHR 0x30C2 +#define EGL_FORMAT_RGBA_8888_KHR 0x30C3 +#define EGL_MAP_PRESERVE_PIXELS_KHR 0x30C4 +#define EGL_LOCK_USAGE_HINT_KHR 0x30C5 +#define EGL_BITMAP_POINTER_KHR 0x30C6 +#define EGL_BITMAP_PITCH_KHR 0x30C7 +#define EGL_BITMAP_ORIGIN_KHR 0x30C8 +#define EGL_BITMAP_PIXEL_RED_OFFSET_KHR 0x30C9 +#define EGL_BITMAP_PIXEL_GREEN_OFFSET_KHR 0x30CA +#define EGL_BITMAP_PIXEL_BLUE_OFFSET_KHR 0x30CB +#define EGL_BITMAP_PIXEL_ALPHA_OFFSET_KHR 0x30CC +#define EGL_BITMAP_PIXEL_LUMINANCE_OFFSET_KHR 0x30CD +#define EGL_LOWER_LEFT_KHR 0x30CE +#define EGL_UPPER_LEFT_KHR 0x30CF +typedef EGLBoolean (EGLAPIENTRYP PFNEGLLOCKSURFACEKHRPROC) (EGLDisplay dpy, EGLSurface surface, const EGLint *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLUNLOCKSURFACEKHRPROC) (EGLDisplay dpy, EGLSurface surface); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglLockSurfaceKHR (EGLDisplay dpy, EGLSurface surface, const EGLint *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglUnlockSurfaceKHR (EGLDisplay dpy, EGLSurface surface); +#endif +#endif /* EGL_KHR_lock_surface */ + +#ifndef EGL_KHR_lock_surface2 +#define EGL_KHR_lock_surface2 1 +#define EGL_BITMAP_PIXEL_SIZE_KHR 0x3110 +#endif /* EGL_KHR_lock_surface2 */ + +#ifndef EGL_KHR_lock_surface3 +#define EGL_KHR_lock_surface3 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSURFACE64KHRPROC) (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLAttribKHR *value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQuerySurface64KHR (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLAttribKHR *value); +#endif +#endif /* EGL_KHR_lock_surface3 */ + +#ifndef EGL_KHR_mutable_render_buffer +#define EGL_KHR_mutable_render_buffer 1 +#define EGL_MUTABLE_RENDER_BUFFER_BIT_KHR 0x1000 +#endif /* EGL_KHR_mutable_render_buffer */ + +#ifndef EGL_KHR_no_config_context +#define EGL_KHR_no_config_context 1 +#define EGL_NO_CONFIG_KHR EGL_CAST(EGLConfig,0) +#endif /* EGL_KHR_no_config_context */ + +#ifndef EGL_KHR_partial_update +#define EGL_KHR_partial_update 1 +#define EGL_BUFFER_AGE_KHR 0x313D +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSETDAMAGEREGIONKHRPROC) (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglSetDamageRegionKHR (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects); +#endif +#endif /* EGL_KHR_partial_update */ + +#ifndef EGL_KHR_platform_android +#define EGL_KHR_platform_android 1 +#define EGL_PLATFORM_ANDROID_KHR 0x3141 +#endif /* EGL_KHR_platform_android */ + +#ifndef EGL_KHR_platform_gbm +#define EGL_KHR_platform_gbm 1 +#define EGL_PLATFORM_GBM_KHR 0x31D7 +#endif /* EGL_KHR_platform_gbm */ + +#ifndef EGL_KHR_platform_wayland +#define EGL_KHR_platform_wayland 1 +#define EGL_PLATFORM_WAYLAND_KHR 0x31D8 +#endif /* EGL_KHR_platform_wayland */ + +#ifndef EGL_KHR_platform_x11 +#define EGL_KHR_platform_x11 1 +#define EGL_PLATFORM_X11_KHR 0x31D5 +#define EGL_PLATFORM_X11_SCREEN_KHR 0x31D6 +#endif /* EGL_KHR_platform_x11 */ + +#ifndef EGL_KHR_reusable_sync +#define EGL_KHR_reusable_sync 1 +#ifdef KHRONOS_SUPPORT_INT64 +#define EGL_SYNC_STATUS_KHR 0x30F1 +#define EGL_SIGNALED_KHR 0x30F2 +#define EGL_UNSIGNALED_KHR 0x30F3 +#define EGL_TIMEOUT_EXPIRED_KHR 0x30F5 +#define EGL_CONDITION_SATISFIED_KHR 0x30F6 +#define EGL_SYNC_TYPE_KHR 0x30F7 +#define EGL_SYNC_REUSABLE_KHR 0x30FA +#define EGL_SYNC_FLUSH_COMMANDS_BIT_KHR 0x0001 +#define EGL_FOREVER_KHR 0xFFFFFFFFFFFFFFFFull +#define EGL_NO_SYNC_KHR EGL_CAST(EGLSyncKHR,0) +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSIGNALSYNCKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync, EGLenum mode); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglSignalSyncKHR (EGLDisplay dpy, EGLSyncKHR sync, EGLenum mode); +#endif +#endif /* KHRONOS_SUPPORT_INT64 */ +#endif /* EGL_KHR_reusable_sync */ + +#ifndef EGL_KHR_stream +#define EGL_KHR_stream 1 +typedef void *EGLStreamKHR; +typedef khronos_uint64_t EGLuint64KHR; +#ifdef KHRONOS_SUPPORT_INT64 +#define EGL_NO_STREAM_KHR EGL_CAST(EGLStreamKHR,0) +#define EGL_CONSUMER_LATENCY_USEC_KHR 0x3210 +#define EGL_PRODUCER_FRAME_KHR 0x3212 +#define EGL_CONSUMER_FRAME_KHR 0x3213 +#define EGL_STREAM_STATE_KHR 0x3214 +#define EGL_STREAM_STATE_CREATED_KHR 0x3215 +#define EGL_STREAM_STATE_CONNECTING_KHR 0x3216 +#define EGL_STREAM_STATE_EMPTY_KHR 0x3217 +#define EGL_STREAM_STATE_NEW_FRAME_AVAILABLE_KHR 0x3218 +#define EGL_STREAM_STATE_OLD_FRAME_AVAILABLE_KHR 0x3219 +#define EGL_STREAM_STATE_DISCONNECTED_KHR 0x321A +#define EGL_BAD_STREAM_KHR 0x321B +#define EGL_BAD_STATE_KHR 0x321C +typedef EGLStreamKHR (EGLAPIENTRYP PFNEGLCREATESTREAMKHRPROC) (EGLDisplay dpy, const EGLint *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYSTREAMKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMATTRIBKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint *value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMU64KHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLuint64KHR *value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLStreamKHR EGLAPIENTRY eglCreateStreamKHR (EGLDisplay dpy, const EGLint *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglDestroyStreamKHR (EGLDisplay dpy, EGLStreamKHR stream); +EGLAPI EGLBoolean EGLAPIENTRY eglStreamAttribKHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint value); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamKHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint *value); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamu64KHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLuint64KHR *value); +#endif +#endif /* KHRONOS_SUPPORT_INT64 */ +#endif /* EGL_KHR_stream */ + +#ifndef EGL_KHR_stream_attrib +#define EGL_KHR_stream_attrib 1 +#ifdef KHRONOS_SUPPORT_INT64 +typedef EGLStreamKHR (EGLAPIENTRYP PFNEGLCREATESTREAMATTRIBKHRPROC) (EGLDisplay dpy, const EGLAttrib *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSETSTREAMATTRIBKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLAttrib value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMATTRIBKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLAttrib *value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERACQUIREATTRIBKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, const EGLAttrib *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERRELEASEATTRIBKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, const EGLAttrib *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLStreamKHR EGLAPIENTRY eglCreateStreamAttribKHR (EGLDisplay dpy, const EGLAttrib *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglSetStreamAttribKHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLAttrib value); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamAttribKHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLAttrib *value); +EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerAcquireAttribKHR (EGLDisplay dpy, EGLStreamKHR stream, const EGLAttrib *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerReleaseAttribKHR (EGLDisplay dpy, EGLStreamKHR stream, const EGLAttrib *attrib_list); +#endif +#endif /* KHRONOS_SUPPORT_INT64 */ +#endif /* EGL_KHR_stream_attrib */ + +#ifndef EGL_KHR_stream_consumer_gltexture +#define EGL_KHR_stream_consumer_gltexture 1 +#ifdef EGL_KHR_stream +#define EGL_CONSUMER_ACQUIRE_TIMEOUT_USEC_KHR 0x321E +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERGLTEXTUREEXTERNALKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERACQUIREKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERRELEASEKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerGLTextureExternalKHR (EGLDisplay dpy, EGLStreamKHR stream); +EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerAcquireKHR (EGLDisplay dpy, EGLStreamKHR stream); +EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerReleaseKHR (EGLDisplay dpy, EGLStreamKHR stream); +#endif +#endif /* EGL_KHR_stream */ +#endif /* EGL_KHR_stream_consumer_gltexture */ + +#ifndef EGL_KHR_stream_cross_process_fd +#define EGL_KHR_stream_cross_process_fd 1 +typedef int EGLNativeFileDescriptorKHR; +#ifdef EGL_KHR_stream +#define EGL_NO_FILE_DESCRIPTOR_KHR EGL_CAST(EGLNativeFileDescriptorKHR,-1) +typedef EGLNativeFileDescriptorKHR (EGLAPIENTRYP PFNEGLGETSTREAMFILEDESCRIPTORKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream); +typedef EGLStreamKHR (EGLAPIENTRYP PFNEGLCREATESTREAMFROMFILEDESCRIPTORKHRPROC) (EGLDisplay dpy, EGLNativeFileDescriptorKHR file_descriptor); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLNativeFileDescriptorKHR EGLAPIENTRY eglGetStreamFileDescriptorKHR (EGLDisplay dpy, EGLStreamKHR stream); +EGLAPI EGLStreamKHR EGLAPIENTRY eglCreateStreamFromFileDescriptorKHR (EGLDisplay dpy, EGLNativeFileDescriptorKHR file_descriptor); +#endif +#endif /* EGL_KHR_stream */ +#endif /* EGL_KHR_stream_cross_process_fd */ + +#ifndef EGL_KHR_stream_fifo +#define EGL_KHR_stream_fifo 1 +#ifdef EGL_KHR_stream +#define EGL_STREAM_FIFO_LENGTH_KHR 0x31FC +#define EGL_STREAM_TIME_NOW_KHR 0x31FD +#define EGL_STREAM_TIME_CONSUMER_KHR 0x31FE +#define EGL_STREAM_TIME_PRODUCER_KHR 0x31FF +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMTIMEKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLTimeKHR *value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamTimeKHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLTimeKHR *value); +#endif +#endif /* EGL_KHR_stream */ +#endif /* EGL_KHR_stream_fifo */ + +#ifndef EGL_KHR_stream_producer_aldatalocator +#define EGL_KHR_stream_producer_aldatalocator 1 +#ifdef EGL_KHR_stream +#endif /* EGL_KHR_stream */ +#endif /* EGL_KHR_stream_producer_aldatalocator */ + +#ifndef EGL_KHR_stream_producer_eglsurface +#define EGL_KHR_stream_producer_eglsurface 1 +#ifdef EGL_KHR_stream +#define EGL_STREAM_BIT_KHR 0x0800 +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATESTREAMPRODUCERSURFACEKHRPROC) (EGLDisplay dpy, EGLConfig config, EGLStreamKHR stream, const EGLint *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLSurface EGLAPIENTRY eglCreateStreamProducerSurfaceKHR (EGLDisplay dpy, EGLConfig config, EGLStreamKHR stream, const EGLint *attrib_list); +#endif +#endif /* EGL_KHR_stream */ +#endif /* EGL_KHR_stream_producer_eglsurface */ + +#ifndef EGL_KHR_surfaceless_context +#define EGL_KHR_surfaceless_context 1 +#endif /* EGL_KHR_surfaceless_context */ + +#ifndef EGL_KHR_swap_buffers_with_damage +#define EGL_KHR_swap_buffers_with_damage 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSWITHDAMAGEKHRPROC) (EGLDisplay dpy, EGLSurface surface, const EGLint *rects, EGLint n_rects); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithDamageKHR (EGLDisplay dpy, EGLSurface surface, const EGLint *rects, EGLint n_rects); +#endif +#endif /* EGL_KHR_swap_buffers_with_damage */ + +#ifndef EGL_KHR_vg_parent_image +#define EGL_KHR_vg_parent_image 1 +#define EGL_VG_PARENT_IMAGE_KHR 0x30BA +#endif /* EGL_KHR_vg_parent_image */ + +#ifndef EGL_KHR_wait_sync +#define EGL_KHR_wait_sync 1 +typedef EGLint (EGLAPIENTRYP PFNEGLWAITSYNCKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync, EGLint flags); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLint EGLAPIENTRY eglWaitSyncKHR (EGLDisplay dpy, EGLSyncKHR sync, EGLint flags); +#endif +#endif /* EGL_KHR_wait_sync */ + +#ifndef EGL_ANDROID_GLES_layers +#define EGL_ANDROID_GLES_layers 1 +#endif /* EGL_ANDROID_GLES_layers */ + +#ifndef EGL_ANDROID_blob_cache +#define EGL_ANDROID_blob_cache 1 +typedef khronos_ssize_t EGLsizeiANDROID; +typedef void (*EGLSetBlobFuncANDROID) (const void *key, EGLsizeiANDROID keySize, const void *value, EGLsizeiANDROID valueSize); +typedef EGLsizeiANDROID (*EGLGetBlobFuncANDROID) (const void *key, EGLsizeiANDROID keySize, void *value, EGLsizeiANDROID valueSize); +typedef void (EGLAPIENTRYP PFNEGLSETBLOBCACHEFUNCSANDROIDPROC) (EGLDisplay dpy, EGLSetBlobFuncANDROID set, EGLGetBlobFuncANDROID get); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI void EGLAPIENTRY eglSetBlobCacheFuncsANDROID (EGLDisplay dpy, EGLSetBlobFuncANDROID set, EGLGetBlobFuncANDROID get); +#endif +#endif /* EGL_ANDROID_blob_cache */ + +#ifndef EGL_ANDROID_create_native_client_buffer +#define EGL_ANDROID_create_native_client_buffer 1 +#define EGL_NATIVE_BUFFER_USAGE_ANDROID 0x3143 +#define EGL_NATIVE_BUFFER_USAGE_PROTECTED_BIT_ANDROID 0x00000001 +#define EGL_NATIVE_BUFFER_USAGE_RENDERBUFFER_BIT_ANDROID 0x00000002 +#define EGL_NATIVE_BUFFER_USAGE_TEXTURE_BIT_ANDROID 0x00000004 +typedef EGLClientBuffer (EGLAPIENTRYP PFNEGLCREATENATIVECLIENTBUFFERANDROIDPROC) (const EGLint *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLClientBuffer EGLAPIENTRY eglCreateNativeClientBufferANDROID (const EGLint *attrib_list); +#endif +#endif /* EGL_ANDROID_create_native_client_buffer */ + +#ifndef EGL_ANDROID_framebuffer_target +#define EGL_ANDROID_framebuffer_target 1 +#define EGL_FRAMEBUFFER_TARGET_ANDROID 0x3147 +#endif /* EGL_ANDROID_framebuffer_target */ + +#ifndef EGL_ANDROID_front_buffer_auto_refresh +#define EGL_ANDROID_front_buffer_auto_refresh 1 +#define EGL_FRONT_BUFFER_AUTO_REFRESH_ANDROID 0x314C +#endif /* EGL_ANDROID_front_buffer_auto_refresh */ + +#ifndef EGL_ANDROID_get_frame_timestamps +#define EGL_ANDROID_get_frame_timestamps 1 +typedef khronos_stime_nanoseconds_t EGLnsecsANDROID; +#define EGL_TIMESTAMP_PENDING_ANDROID EGL_CAST(EGLnsecsANDROID,-2) +#define EGL_TIMESTAMP_INVALID_ANDROID EGL_CAST(EGLnsecsANDROID,-1) +#define EGL_TIMESTAMPS_ANDROID 0x3430 +#define EGL_COMPOSITE_DEADLINE_ANDROID 0x3431 +#define EGL_COMPOSITE_INTERVAL_ANDROID 0x3432 +#define EGL_COMPOSITE_TO_PRESENT_LATENCY_ANDROID 0x3433 +#define EGL_REQUESTED_PRESENT_TIME_ANDROID 0x3434 +#define EGL_RENDERING_COMPLETE_TIME_ANDROID 0x3435 +#define EGL_COMPOSITION_LATCH_TIME_ANDROID 0x3436 +#define EGL_FIRST_COMPOSITION_START_TIME_ANDROID 0x3437 +#define EGL_LAST_COMPOSITION_START_TIME_ANDROID 0x3438 +#define EGL_FIRST_COMPOSITION_GPU_FINISHED_TIME_ANDROID 0x3439 +#define EGL_DISPLAY_PRESENT_TIME_ANDROID 0x343A +#define EGL_DEQUEUE_READY_TIME_ANDROID 0x343B +#define EGL_READS_DONE_TIME_ANDROID 0x343C +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETCOMPOSITORTIMINGSUPPORTEDANDROIDPROC) (EGLDisplay dpy, EGLSurface surface, EGLint name); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETCOMPOSITORTIMINGANDROIDPROC) (EGLDisplay dpy, EGLSurface surface, EGLint numTimestamps, const EGLint *names, EGLnsecsANDROID *values); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETNEXTFRAMEIDANDROIDPROC) (EGLDisplay dpy, EGLSurface surface, EGLuint64KHR *frameId); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETFRAMETIMESTAMPSUPPORTEDANDROIDPROC) (EGLDisplay dpy, EGLSurface surface, EGLint timestamp); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETFRAMETIMESTAMPSANDROIDPROC) (EGLDisplay dpy, EGLSurface surface, EGLuint64KHR frameId, EGLint numTimestamps, const EGLint *timestamps, EGLnsecsANDROID *values); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglGetCompositorTimingSupportedANDROID (EGLDisplay dpy, EGLSurface surface, EGLint name); +EGLAPI EGLBoolean EGLAPIENTRY eglGetCompositorTimingANDROID (EGLDisplay dpy, EGLSurface surface, EGLint numTimestamps, const EGLint *names, EGLnsecsANDROID *values); +EGLAPI EGLBoolean EGLAPIENTRY eglGetNextFrameIdANDROID (EGLDisplay dpy, EGLSurface surface, EGLuint64KHR *frameId); +EGLAPI EGLBoolean EGLAPIENTRY eglGetFrameTimestampSupportedANDROID (EGLDisplay dpy, EGLSurface surface, EGLint timestamp); +EGLAPI EGLBoolean EGLAPIENTRY eglGetFrameTimestampsANDROID (EGLDisplay dpy, EGLSurface surface, EGLuint64KHR frameId, EGLint numTimestamps, const EGLint *timestamps, EGLnsecsANDROID *values); +#endif +#endif /* EGL_ANDROID_get_frame_timestamps */ + +#ifndef EGL_ANDROID_get_native_client_buffer +#define EGL_ANDROID_get_native_client_buffer 1 +struct AHardwareBuffer; +typedef EGLClientBuffer (EGLAPIENTRYP PFNEGLGETNATIVECLIENTBUFFERANDROIDPROC) (const struct AHardwareBuffer *buffer); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLClientBuffer EGLAPIENTRY eglGetNativeClientBufferANDROID (const struct AHardwareBuffer *buffer); +#endif +#endif /* EGL_ANDROID_get_native_client_buffer */ + +#ifndef EGL_ANDROID_image_native_buffer +#define EGL_ANDROID_image_native_buffer 1 +#define EGL_NATIVE_BUFFER_ANDROID 0x3140 +#endif /* EGL_ANDROID_image_native_buffer */ + +#ifndef EGL_ANDROID_native_fence_sync +#define EGL_ANDROID_native_fence_sync 1 +#define EGL_SYNC_NATIVE_FENCE_ANDROID 0x3144 +#define EGL_SYNC_NATIVE_FENCE_FD_ANDROID 0x3145 +#define EGL_SYNC_NATIVE_FENCE_SIGNALED_ANDROID 0x3146 +#define EGL_NO_NATIVE_FENCE_FD_ANDROID -1 +typedef EGLint (EGLAPIENTRYP PFNEGLDUPNATIVEFENCEFDANDROIDPROC) (EGLDisplay dpy, EGLSyncKHR sync); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLint EGLAPIENTRY eglDupNativeFenceFDANDROID (EGLDisplay dpy, EGLSyncKHR sync); +#endif +#endif /* EGL_ANDROID_native_fence_sync */ + +#ifndef EGL_ANDROID_presentation_time +#define EGL_ANDROID_presentation_time 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLPRESENTATIONTIMEANDROIDPROC) (EGLDisplay dpy, EGLSurface surface, EGLnsecsANDROID time); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglPresentationTimeANDROID (EGLDisplay dpy, EGLSurface surface, EGLnsecsANDROID time); +#endif +#endif /* EGL_ANDROID_presentation_time */ + +#ifndef EGL_ANDROID_recordable +#define EGL_ANDROID_recordable 1 +#define EGL_RECORDABLE_ANDROID 0x3142 +#endif /* EGL_ANDROID_recordable */ + +#ifndef EGL_ANGLE_d3d_share_handle_client_buffer +#define EGL_ANGLE_d3d_share_handle_client_buffer 1 +#define EGL_D3D_TEXTURE_2D_SHARE_HANDLE_ANGLE 0x3200 +#endif /* EGL_ANGLE_d3d_share_handle_client_buffer */ + +#ifndef EGL_ANGLE_device_d3d +#define EGL_ANGLE_device_d3d 1 +#define EGL_D3D9_DEVICE_ANGLE 0x33A0 +#define EGL_D3D11_DEVICE_ANGLE 0x33A1 +#endif /* EGL_ANGLE_device_d3d */ + +#ifndef EGL_ANGLE_query_surface_pointer +#define EGL_ANGLE_query_surface_pointer 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSURFACEPOINTERANGLEPROC) (EGLDisplay dpy, EGLSurface surface, EGLint attribute, void **value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQuerySurfacePointerANGLE (EGLDisplay dpy, EGLSurface surface, EGLint attribute, void **value); +#endif +#endif /* EGL_ANGLE_query_surface_pointer */ + +#ifndef EGL_ANGLE_surface_d3d_texture_2d_share_handle +#define EGL_ANGLE_surface_d3d_texture_2d_share_handle 1 +#endif /* EGL_ANGLE_surface_d3d_texture_2d_share_handle */ + +#ifndef EGL_ANGLE_sync_control_rate +#define EGL_ANGLE_sync_control_rate 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETMSCRATEANGLEPROC) (EGLDisplay dpy, EGLSurface surface, EGLint *numerator, EGLint *denominator); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglGetMscRateANGLE (EGLDisplay dpy, EGLSurface surface, EGLint *numerator, EGLint *denominator); +#endif +#endif /* EGL_ANGLE_sync_control_rate */ + +#ifndef EGL_ANGLE_window_fixed_size +#define EGL_ANGLE_window_fixed_size 1 +#define EGL_FIXED_SIZE_ANGLE 0x3201 +#endif /* EGL_ANGLE_window_fixed_size */ + +#ifndef EGL_ARM_image_format +#define EGL_ARM_image_format 1 +#define EGL_COLOR_COMPONENT_TYPE_UNSIGNED_INTEGER_ARM 0x3287 +#define EGL_COLOR_COMPONENT_TYPE_INTEGER_ARM 0x3288 +#endif /* EGL_ARM_image_format */ + +#ifndef EGL_ARM_implicit_external_sync +#define EGL_ARM_implicit_external_sync 1 +#define EGL_SYNC_PRIOR_COMMANDS_IMPLICIT_EXTERNAL_ARM 0x328A +#endif /* EGL_ARM_implicit_external_sync */ + +#ifndef EGL_ARM_pixmap_multisample_discard +#define EGL_ARM_pixmap_multisample_discard 1 +#define EGL_DISCARD_SAMPLES_ARM 0x3286 +#endif /* EGL_ARM_pixmap_multisample_discard */ + +#ifndef EGL_EXT_bind_to_front +#define EGL_EXT_bind_to_front 1 +#define EGL_FRONT_BUFFER_EXT 0x3464 +#endif /* EGL_EXT_bind_to_front */ + +#ifndef EGL_EXT_buffer_age +#define EGL_EXT_buffer_age 1 +#define EGL_BUFFER_AGE_EXT 0x313D +#endif /* EGL_EXT_buffer_age */ + +#ifndef EGL_EXT_client_extensions +#define EGL_EXT_client_extensions 1 +#endif /* EGL_EXT_client_extensions */ + +#ifndef EGL_EXT_client_sync +#define EGL_EXT_client_sync 1 +#define EGL_SYNC_CLIENT_EXT 0x3364 +#define EGL_SYNC_CLIENT_SIGNAL_EXT 0x3365 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCLIENTSIGNALSYNCEXTPROC) (EGLDisplay dpy, EGLSync sync, const EGLAttrib *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglClientSignalSyncEXT (EGLDisplay dpy, EGLSync sync, const EGLAttrib *attrib_list); +#endif +#endif /* EGL_EXT_client_sync */ + +#ifndef EGL_EXT_compositor +#define EGL_EXT_compositor 1 +#define EGL_PRIMARY_COMPOSITOR_CONTEXT_EXT 0x3460 +#define EGL_EXTERNAL_REF_ID_EXT 0x3461 +#define EGL_COMPOSITOR_DROP_NEWEST_FRAME_EXT 0x3462 +#define EGL_COMPOSITOR_KEEP_NEWEST_FRAME_EXT 0x3463 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCOMPOSITORSETCONTEXTLISTEXTPROC) (const EGLint *external_ref_ids, EGLint num_entries); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCOMPOSITORSETCONTEXTATTRIBUTESEXTPROC) (EGLint external_ref_id, const EGLint *context_attributes, EGLint num_entries); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCOMPOSITORSETWINDOWLISTEXTPROC) (EGLint external_ref_id, const EGLint *external_win_ids, EGLint num_entries); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCOMPOSITORSETWINDOWATTRIBUTESEXTPROC) (EGLint external_win_id, const EGLint *window_attributes, EGLint num_entries); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCOMPOSITORBINDTEXWINDOWEXTPROC) (EGLint external_win_id); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCOMPOSITORSETSIZEEXTPROC) (EGLint external_win_id, EGLint width, EGLint height); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLCOMPOSITORSWAPPOLICYEXTPROC) (EGLint external_win_id, EGLint policy); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglCompositorSetContextListEXT (const EGLint *external_ref_ids, EGLint num_entries); +EGLAPI EGLBoolean EGLAPIENTRY eglCompositorSetContextAttributesEXT (EGLint external_ref_id, const EGLint *context_attributes, EGLint num_entries); +EGLAPI EGLBoolean EGLAPIENTRY eglCompositorSetWindowListEXT (EGLint external_ref_id, const EGLint *external_win_ids, EGLint num_entries); +EGLAPI EGLBoolean EGLAPIENTRY eglCompositorSetWindowAttributesEXT (EGLint external_win_id, const EGLint *window_attributes, EGLint num_entries); +EGLAPI EGLBoolean EGLAPIENTRY eglCompositorBindTexWindowEXT (EGLint external_win_id); +EGLAPI EGLBoolean EGLAPIENTRY eglCompositorSetSizeEXT (EGLint external_win_id, EGLint width, EGLint height); +EGLAPI EGLBoolean EGLAPIENTRY eglCompositorSwapPolicyEXT (EGLint external_win_id, EGLint policy); +#endif +#endif /* EGL_EXT_compositor */ + +#ifndef EGL_EXT_config_select_group +#define EGL_EXT_config_select_group 1 +#define EGL_CONFIG_SELECT_GROUP_EXT 0x34C0 +#endif /* EGL_EXT_config_select_group */ + +#ifndef EGL_EXT_create_context_robustness +#define EGL_EXT_create_context_robustness 1 +#define EGL_CONTEXT_OPENGL_ROBUST_ACCESS_EXT 0x30BF +#define EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_EXT 0x3138 +#define EGL_NO_RESET_NOTIFICATION_EXT 0x31BE +#define EGL_LOSE_CONTEXT_ON_RESET_EXT 0x31BF +#endif /* EGL_EXT_create_context_robustness */ + +#ifndef EGL_EXT_device_base +#define EGL_EXT_device_base 1 +typedef void *EGLDeviceEXT; +#define EGL_NO_DEVICE_EXT EGL_CAST(EGLDeviceEXT,0) +#define EGL_BAD_DEVICE_EXT 0x322B +#define EGL_DEVICE_EXT 0x322C +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDEVICEATTRIBEXTPROC) (EGLDeviceEXT device, EGLint attribute, EGLAttrib *value); +typedef const char *(EGLAPIENTRYP PFNEGLQUERYDEVICESTRINGEXTPROC) (EGLDeviceEXT device, EGLint name); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDEVICESEXTPROC) (EGLint max_devices, EGLDeviceEXT *devices, EGLint *num_devices); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDISPLAYATTRIBEXTPROC) (EGLDisplay dpy, EGLint attribute, EGLAttrib *value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDeviceAttribEXT (EGLDeviceEXT device, EGLint attribute, EGLAttrib *value); +EGLAPI const char *EGLAPIENTRY eglQueryDeviceStringEXT (EGLDeviceEXT device, EGLint name); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDevicesEXT (EGLint max_devices, EGLDeviceEXT *devices, EGLint *num_devices); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDisplayAttribEXT (EGLDisplay dpy, EGLint attribute, EGLAttrib *value); +#endif +#endif /* EGL_EXT_device_base */ + +#ifndef EGL_EXT_device_drm +#define EGL_EXT_device_drm 1 +#define EGL_DRM_DEVICE_FILE_EXT 0x3233 +#define EGL_DRM_MASTER_FD_EXT 0x333C +#endif /* EGL_EXT_device_drm */ + +#ifndef EGL_EXT_device_drm_render_node +#define EGL_EXT_device_drm_render_node 1 +#define EGL_DRM_RENDER_NODE_FILE_EXT 0x3377 +#endif /* EGL_EXT_device_drm_render_node */ + +#ifndef EGL_EXT_device_enumeration +#define EGL_EXT_device_enumeration 1 +#endif /* EGL_EXT_device_enumeration */ + +#ifndef EGL_EXT_device_openwf +#define EGL_EXT_device_openwf 1 +#define EGL_OPENWF_DEVICE_ID_EXT 0x3237 +#define EGL_OPENWF_DEVICE_EXT 0x333D +#endif /* EGL_EXT_device_openwf */ + +#ifndef EGL_EXT_device_persistent_id +#define EGL_EXT_device_persistent_id 1 +#define EGL_DEVICE_UUID_EXT 0x335C +#define EGL_DRIVER_UUID_EXT 0x335D +#define EGL_DRIVER_NAME_EXT 0x335E +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDEVICEBINARYEXTPROC) (EGLDeviceEXT device, EGLint name, EGLint max_size, void *value, EGLint *size); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDeviceBinaryEXT (EGLDeviceEXT device, EGLint name, EGLint max_size, void *value, EGLint *size); +#endif +#endif /* EGL_EXT_device_persistent_id */ + +#ifndef EGL_EXT_device_query +#define EGL_EXT_device_query 1 +#endif /* EGL_EXT_device_query */ + +#ifndef EGL_EXT_device_query_name +#define EGL_EXT_device_query_name 1 +#define EGL_RENDERER_EXT 0x335F +#endif /* EGL_EXT_device_query_name */ + +#ifndef EGL_EXT_explicit_device +#define EGL_EXT_explicit_device 1 +#endif /* EGL_EXT_explicit_device */ + +#ifndef EGL_EXT_gl_colorspace_bt2020_linear +#define EGL_EXT_gl_colorspace_bt2020_linear 1 +#define EGL_GL_COLORSPACE_BT2020_LINEAR_EXT 0x333F +#endif /* EGL_EXT_gl_colorspace_bt2020_linear */ + +#ifndef EGL_EXT_gl_colorspace_bt2020_pq +#define EGL_EXT_gl_colorspace_bt2020_pq 1 +#define EGL_GL_COLORSPACE_BT2020_PQ_EXT 0x3340 +#endif /* EGL_EXT_gl_colorspace_bt2020_pq */ + +#ifndef EGL_EXT_gl_colorspace_display_p3 +#define EGL_EXT_gl_colorspace_display_p3 1 +#define EGL_GL_COLORSPACE_DISPLAY_P3_EXT 0x3363 +#endif /* EGL_EXT_gl_colorspace_display_p3 */ + +#ifndef EGL_EXT_gl_colorspace_display_p3_linear +#define EGL_EXT_gl_colorspace_display_p3_linear 1 +#define EGL_GL_COLORSPACE_DISPLAY_P3_LINEAR_EXT 0x3362 +#endif /* EGL_EXT_gl_colorspace_display_p3_linear */ + +#ifndef EGL_EXT_gl_colorspace_display_p3_passthrough +#define EGL_EXT_gl_colorspace_display_p3_passthrough 1 +#define EGL_GL_COLORSPACE_DISPLAY_P3_PASSTHROUGH_EXT 0x3490 +#endif /* EGL_EXT_gl_colorspace_display_p3_passthrough */ + +#ifndef EGL_EXT_gl_colorspace_scrgb +#define EGL_EXT_gl_colorspace_scrgb 1 +#define EGL_GL_COLORSPACE_SCRGB_EXT 0x3351 +#endif /* EGL_EXT_gl_colorspace_scrgb */ + +#ifndef EGL_EXT_gl_colorspace_scrgb_linear +#define EGL_EXT_gl_colorspace_scrgb_linear 1 +#define EGL_GL_COLORSPACE_SCRGB_LINEAR_EXT 0x3350 +#endif /* EGL_EXT_gl_colorspace_scrgb_linear */ + +#ifndef EGL_EXT_image_dma_buf_import +#define EGL_EXT_image_dma_buf_import 1 +#define EGL_LINUX_DMA_BUF_EXT 0x3270 +#define EGL_LINUX_DRM_FOURCC_EXT 0x3271 +#define EGL_DMA_BUF_PLANE0_FD_EXT 0x3272 +#define EGL_DMA_BUF_PLANE0_OFFSET_EXT 0x3273 +#define EGL_DMA_BUF_PLANE0_PITCH_EXT 0x3274 +#define EGL_DMA_BUF_PLANE1_FD_EXT 0x3275 +#define EGL_DMA_BUF_PLANE1_OFFSET_EXT 0x3276 +#define EGL_DMA_BUF_PLANE1_PITCH_EXT 0x3277 +#define EGL_DMA_BUF_PLANE2_FD_EXT 0x3278 +#define EGL_DMA_BUF_PLANE2_OFFSET_EXT 0x3279 +#define EGL_DMA_BUF_PLANE2_PITCH_EXT 0x327A +#define EGL_YUV_COLOR_SPACE_HINT_EXT 0x327B +#define EGL_SAMPLE_RANGE_HINT_EXT 0x327C +#define EGL_YUV_CHROMA_HORIZONTAL_SITING_HINT_EXT 0x327D +#define EGL_YUV_CHROMA_VERTICAL_SITING_HINT_EXT 0x327E +#define EGL_ITU_REC601_EXT 0x327F +#define EGL_ITU_REC709_EXT 0x3280 +#define EGL_ITU_REC2020_EXT 0x3281 +#define EGL_YUV_FULL_RANGE_EXT 0x3282 +#define EGL_YUV_NARROW_RANGE_EXT 0x3283 +#define EGL_YUV_CHROMA_SITING_0_EXT 0x3284 +#define EGL_YUV_CHROMA_SITING_0_5_EXT 0x3285 +#endif /* EGL_EXT_image_dma_buf_import */ + +#ifndef EGL_EXT_image_dma_buf_import_modifiers +#define EGL_EXT_image_dma_buf_import_modifiers 1 +#define EGL_DMA_BUF_PLANE3_FD_EXT 0x3440 +#define EGL_DMA_BUF_PLANE3_OFFSET_EXT 0x3441 +#define EGL_DMA_BUF_PLANE3_PITCH_EXT 0x3442 +#define EGL_DMA_BUF_PLANE0_MODIFIER_LO_EXT 0x3443 +#define EGL_DMA_BUF_PLANE0_MODIFIER_HI_EXT 0x3444 +#define EGL_DMA_BUF_PLANE1_MODIFIER_LO_EXT 0x3445 +#define EGL_DMA_BUF_PLANE1_MODIFIER_HI_EXT 0x3446 +#define EGL_DMA_BUF_PLANE2_MODIFIER_LO_EXT 0x3447 +#define EGL_DMA_BUF_PLANE2_MODIFIER_HI_EXT 0x3448 +#define EGL_DMA_BUF_PLANE3_MODIFIER_LO_EXT 0x3449 +#define EGL_DMA_BUF_PLANE3_MODIFIER_HI_EXT 0x344A +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDMABUFFORMATSEXTPROC) (EGLDisplay dpy, EGLint max_formats, EGLint *formats, EGLint *num_formats); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDMABUFMODIFIERSEXTPROC) (EGLDisplay dpy, EGLint format, EGLint max_modifiers, EGLuint64KHR *modifiers, EGLBoolean *external_only, EGLint *num_modifiers); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDmaBufFormatsEXT (EGLDisplay dpy, EGLint max_formats, EGLint *formats, EGLint *num_formats); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDmaBufModifiersEXT (EGLDisplay dpy, EGLint format, EGLint max_modifiers, EGLuint64KHR *modifiers, EGLBoolean *external_only, EGLint *num_modifiers); +#endif +#endif /* EGL_EXT_image_dma_buf_import_modifiers */ + +#ifndef EGL_EXT_image_gl_colorspace +#define EGL_EXT_image_gl_colorspace 1 +#define EGL_GL_COLORSPACE_DEFAULT_EXT 0x314D +#endif /* EGL_EXT_image_gl_colorspace */ + +#ifndef EGL_EXT_image_implicit_sync_control +#define EGL_EXT_image_implicit_sync_control 1 +#define EGL_IMPORT_SYNC_TYPE_EXT 0x3470 +#define EGL_IMPORT_IMPLICIT_SYNC_EXT 0x3471 +#define EGL_IMPORT_EXPLICIT_SYNC_EXT 0x3472 +#endif /* EGL_EXT_image_implicit_sync_control */ + +#ifndef EGL_EXT_multiview_window +#define EGL_EXT_multiview_window 1 +#define EGL_MULTIVIEW_VIEW_COUNT_EXT 0x3134 +#endif /* EGL_EXT_multiview_window */ + +#ifndef EGL_EXT_output_base +#define EGL_EXT_output_base 1 +typedef void *EGLOutputLayerEXT; +typedef void *EGLOutputPortEXT; +#define EGL_NO_OUTPUT_LAYER_EXT EGL_CAST(EGLOutputLayerEXT,0) +#define EGL_NO_OUTPUT_PORT_EXT EGL_CAST(EGLOutputPortEXT,0) +#define EGL_BAD_OUTPUT_LAYER_EXT 0x322D +#define EGL_BAD_OUTPUT_PORT_EXT 0x322E +#define EGL_SWAP_INTERVAL_EXT 0x322F +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETOUTPUTLAYERSEXTPROC) (EGLDisplay dpy, const EGLAttrib *attrib_list, EGLOutputLayerEXT *layers, EGLint max_layers, EGLint *num_layers); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETOUTPUTPORTSEXTPROC) (EGLDisplay dpy, const EGLAttrib *attrib_list, EGLOutputPortEXT *ports, EGLint max_ports, EGLint *num_ports); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLOUTPUTLAYERATTRIBEXTPROC) (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint attribute, EGLAttrib value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYOUTPUTLAYERATTRIBEXTPROC) (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint attribute, EGLAttrib *value); +typedef const char *(EGLAPIENTRYP PFNEGLQUERYOUTPUTLAYERSTRINGEXTPROC) (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint name); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLOUTPUTPORTATTRIBEXTPROC) (EGLDisplay dpy, EGLOutputPortEXT port, EGLint attribute, EGLAttrib value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYOUTPUTPORTATTRIBEXTPROC) (EGLDisplay dpy, EGLOutputPortEXT port, EGLint attribute, EGLAttrib *value); +typedef const char *(EGLAPIENTRYP PFNEGLQUERYOUTPUTPORTSTRINGEXTPROC) (EGLDisplay dpy, EGLOutputPortEXT port, EGLint name); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglGetOutputLayersEXT (EGLDisplay dpy, const EGLAttrib *attrib_list, EGLOutputLayerEXT *layers, EGLint max_layers, EGLint *num_layers); +EGLAPI EGLBoolean EGLAPIENTRY eglGetOutputPortsEXT (EGLDisplay dpy, const EGLAttrib *attrib_list, EGLOutputPortEXT *ports, EGLint max_ports, EGLint *num_ports); +EGLAPI EGLBoolean EGLAPIENTRY eglOutputLayerAttribEXT (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint attribute, EGLAttrib value); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryOutputLayerAttribEXT (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint attribute, EGLAttrib *value); +EGLAPI const char *EGLAPIENTRY eglQueryOutputLayerStringEXT (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint name); +EGLAPI EGLBoolean EGLAPIENTRY eglOutputPortAttribEXT (EGLDisplay dpy, EGLOutputPortEXT port, EGLint attribute, EGLAttrib value); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryOutputPortAttribEXT (EGLDisplay dpy, EGLOutputPortEXT port, EGLint attribute, EGLAttrib *value); +EGLAPI const char *EGLAPIENTRY eglQueryOutputPortStringEXT (EGLDisplay dpy, EGLOutputPortEXT port, EGLint name); +#endif +#endif /* EGL_EXT_output_base */ + +#ifndef EGL_EXT_output_drm +#define EGL_EXT_output_drm 1 +#define EGL_DRM_CRTC_EXT 0x3234 +#define EGL_DRM_PLANE_EXT 0x3235 +#define EGL_DRM_CONNECTOR_EXT 0x3236 +#endif /* EGL_EXT_output_drm */ + +#ifndef EGL_EXT_output_openwf +#define EGL_EXT_output_openwf 1 +#define EGL_OPENWF_PIPELINE_ID_EXT 0x3238 +#define EGL_OPENWF_PORT_ID_EXT 0x3239 +#endif /* EGL_EXT_output_openwf */ + +#ifndef EGL_EXT_pixel_format_float +#define EGL_EXT_pixel_format_float 1 +#define EGL_COLOR_COMPONENT_TYPE_EXT 0x3339 +#define EGL_COLOR_COMPONENT_TYPE_FIXED_EXT 0x333A +#define EGL_COLOR_COMPONENT_TYPE_FLOAT_EXT 0x333B +#endif /* EGL_EXT_pixel_format_float */ + +#ifndef EGL_EXT_platform_base +#define EGL_EXT_platform_base 1 +typedef EGLDisplay (EGLAPIENTRYP PFNEGLGETPLATFORMDISPLAYEXTPROC) (EGLenum platform, void *native_display, const EGLint *attrib_list); +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPLATFORMWINDOWSURFACEEXTPROC) (EGLDisplay dpy, EGLConfig config, void *native_window, const EGLint *attrib_list); +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPLATFORMPIXMAPSURFACEEXTPROC) (EGLDisplay dpy, EGLConfig config, void *native_pixmap, const EGLint *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLDisplay EGLAPIENTRY eglGetPlatformDisplayEXT (EGLenum platform, void *native_display, const EGLint *attrib_list); +EGLAPI EGLSurface EGLAPIENTRY eglCreatePlatformWindowSurfaceEXT (EGLDisplay dpy, EGLConfig config, void *native_window, const EGLint *attrib_list); +EGLAPI EGLSurface EGLAPIENTRY eglCreatePlatformPixmapSurfaceEXT (EGLDisplay dpy, EGLConfig config, void *native_pixmap, const EGLint *attrib_list); +#endif +#endif /* EGL_EXT_platform_base */ + +#ifndef EGL_EXT_platform_device +#define EGL_EXT_platform_device 1 +#define EGL_PLATFORM_DEVICE_EXT 0x313F +#endif /* EGL_EXT_platform_device */ + +#ifndef EGL_EXT_platform_wayland +#define EGL_EXT_platform_wayland 1 +#define EGL_PLATFORM_WAYLAND_EXT 0x31D8 +#endif /* EGL_EXT_platform_wayland */ + +#ifndef EGL_EXT_platform_x11 +#define EGL_EXT_platform_x11 1 +#define EGL_PLATFORM_X11_EXT 0x31D5 +#define EGL_PLATFORM_X11_SCREEN_EXT 0x31D6 +#endif /* EGL_EXT_platform_x11 */ + +#ifndef EGL_EXT_platform_xcb +#define EGL_EXT_platform_xcb 1 +#define EGL_PLATFORM_XCB_EXT 0x31DC +#define EGL_PLATFORM_XCB_SCREEN_EXT 0x31DE +#endif /* EGL_EXT_platform_xcb */ + +#ifndef EGL_EXT_present_opaque +#define EGL_EXT_present_opaque 1 +#define EGL_PRESENT_OPAQUE_EXT 0x31DF +#endif /* EGL_EXT_present_opaque */ + +#ifndef EGL_EXT_protected_content +#define EGL_EXT_protected_content 1 +#define EGL_PROTECTED_CONTENT_EXT 0x32C0 +#endif /* EGL_EXT_protected_content */ + +#ifndef EGL_EXT_protected_surface +#define EGL_EXT_protected_surface 1 +#endif /* EGL_EXT_protected_surface */ + +#ifndef EGL_EXT_stream_consumer_egloutput +#define EGL_EXT_stream_consumer_egloutput 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMEROUTPUTEXTPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLOutputLayerEXT layer); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerOutputEXT (EGLDisplay dpy, EGLStreamKHR stream, EGLOutputLayerEXT layer); +#endif +#endif /* EGL_EXT_stream_consumer_egloutput */ + +#ifndef EGL_EXT_surface_CTA861_3_metadata +#define EGL_EXT_surface_CTA861_3_metadata 1 +#define EGL_CTA861_3_MAX_CONTENT_LIGHT_LEVEL_EXT 0x3360 +#define EGL_CTA861_3_MAX_FRAME_AVERAGE_LEVEL_EXT 0x3361 +#endif /* EGL_EXT_surface_CTA861_3_metadata */ + +#ifndef EGL_EXT_surface_SMPTE2086_metadata +#define EGL_EXT_surface_SMPTE2086_metadata 1 +#define EGL_SMPTE2086_DISPLAY_PRIMARY_RX_EXT 0x3341 +#define EGL_SMPTE2086_DISPLAY_PRIMARY_RY_EXT 0x3342 +#define EGL_SMPTE2086_DISPLAY_PRIMARY_GX_EXT 0x3343 +#define EGL_SMPTE2086_DISPLAY_PRIMARY_GY_EXT 0x3344 +#define EGL_SMPTE2086_DISPLAY_PRIMARY_BX_EXT 0x3345 +#define EGL_SMPTE2086_DISPLAY_PRIMARY_BY_EXT 0x3346 +#define EGL_SMPTE2086_WHITE_POINT_X_EXT 0x3347 +#define EGL_SMPTE2086_WHITE_POINT_Y_EXT 0x3348 +#define EGL_SMPTE2086_MAX_LUMINANCE_EXT 0x3349 +#define EGL_SMPTE2086_MIN_LUMINANCE_EXT 0x334A +#define EGL_METADATA_SCALING_EXT 50000 +#endif /* EGL_EXT_surface_SMPTE2086_metadata */ + +#ifndef EGL_EXT_surface_compression +#define EGL_EXT_surface_compression 1 +#define EGL_SURFACE_COMPRESSION_EXT 0x34B0 +#define EGL_SURFACE_COMPRESSION_PLANE1_EXT 0x328E +#define EGL_SURFACE_COMPRESSION_PLANE2_EXT 0x328F +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_NONE_EXT 0x34B1 +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_DEFAULT_EXT 0x34B2 +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_1BPC_EXT 0x34B4 +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_2BPC_EXT 0x34B5 +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_3BPC_EXT 0x34B6 +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_4BPC_EXT 0x34B7 +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_5BPC_EXT 0x34B8 +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_6BPC_EXT 0x34B9 +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_7BPC_EXT 0x34BA +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_8BPC_EXT 0x34BB +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_9BPC_EXT 0x34BC +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_10BPC_EXT 0x34BD +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_11BPC_EXT 0x34BE +#define EGL_SURFACE_COMPRESSION_FIXED_RATE_12BPC_EXT 0x34BF +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSUPPORTEDCOMPRESSIONRATESEXTPROC) (EGLDisplay dpy, EGLConfig config, const EGLAttrib *attrib_list, EGLint *rates, EGLint rate_size, EGLint *num_rates); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQuerySupportedCompressionRatesEXT (EGLDisplay dpy, EGLConfig config, const EGLAttrib *attrib_list, EGLint *rates, EGLint rate_size, EGLint *num_rates); +#endif +#endif /* EGL_EXT_surface_compression */ + +#ifndef EGL_EXT_swap_buffers_with_damage +#define EGL_EXT_swap_buffers_with_damage 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSWITHDAMAGEEXTPROC) (EGLDisplay dpy, EGLSurface surface, const EGLint *rects, EGLint n_rects); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithDamageEXT (EGLDisplay dpy, EGLSurface surface, const EGLint *rects, EGLint n_rects); +#endif +#endif /* EGL_EXT_swap_buffers_with_damage */ + +#ifndef EGL_EXT_sync_reuse +#define EGL_EXT_sync_reuse 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLUNSIGNALSYNCEXTPROC) (EGLDisplay dpy, EGLSync sync, const EGLAttrib *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglUnsignalSyncEXT (EGLDisplay dpy, EGLSync sync, const EGLAttrib *attrib_list); +#endif +#endif /* EGL_EXT_sync_reuse */ + +#ifndef EGL_EXT_yuv_surface +#define EGL_EXT_yuv_surface 1 +#define EGL_YUV_ORDER_EXT 0x3301 +#define EGL_YUV_NUMBER_OF_PLANES_EXT 0x3311 +#define EGL_YUV_SUBSAMPLE_EXT 0x3312 +#define EGL_YUV_DEPTH_RANGE_EXT 0x3317 +#define EGL_YUV_CSC_STANDARD_EXT 0x330A +#define EGL_YUV_PLANE_BPP_EXT 0x331A +#define EGL_YUV_BUFFER_EXT 0x3300 +#define EGL_YUV_ORDER_YUV_EXT 0x3302 +#define EGL_YUV_ORDER_YVU_EXT 0x3303 +#define EGL_YUV_ORDER_YUYV_EXT 0x3304 +#define EGL_YUV_ORDER_UYVY_EXT 0x3305 +#define EGL_YUV_ORDER_YVYU_EXT 0x3306 +#define EGL_YUV_ORDER_VYUY_EXT 0x3307 +#define EGL_YUV_ORDER_AYUV_EXT 0x3308 +#define EGL_YUV_SUBSAMPLE_4_2_0_EXT 0x3313 +#define EGL_YUV_SUBSAMPLE_4_2_2_EXT 0x3314 +#define EGL_YUV_SUBSAMPLE_4_4_4_EXT 0x3315 +#define EGL_YUV_DEPTH_RANGE_LIMITED_EXT 0x3318 +#define EGL_YUV_DEPTH_RANGE_FULL_EXT 0x3319 +#define EGL_YUV_CSC_STANDARD_601_EXT 0x330B +#define EGL_YUV_CSC_STANDARD_709_EXT 0x330C +#define EGL_YUV_CSC_STANDARD_2020_EXT 0x330D +#define EGL_YUV_PLANE_BPP_0_EXT 0x331B +#define EGL_YUV_PLANE_BPP_8_EXT 0x331C +#define EGL_YUV_PLANE_BPP_10_EXT 0x331D +#endif /* EGL_EXT_yuv_surface */ + +#ifndef EGL_HI_clientpixmap +#define EGL_HI_clientpixmap 1 +struct EGLClientPixmapHI { + void *pData; + EGLint iWidth; + EGLint iHeight; + EGLint iStride; +}; +#define EGL_CLIENT_PIXMAP_POINTER_HI 0x8F74 +typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPIXMAPSURFACEHIPROC) (EGLDisplay dpy, EGLConfig config, struct EGLClientPixmapHI *pixmap); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLSurface EGLAPIENTRY eglCreatePixmapSurfaceHI (EGLDisplay dpy, EGLConfig config, struct EGLClientPixmapHI *pixmap); +#endif +#endif /* EGL_HI_clientpixmap */ + +#ifndef EGL_HI_colorformats +#define EGL_HI_colorformats 1 +#define EGL_COLOR_FORMAT_HI 0x8F70 +#define EGL_COLOR_RGB_HI 0x8F71 +#define EGL_COLOR_RGBA_HI 0x8F72 +#define EGL_COLOR_ARGB_HI 0x8F73 +#endif /* EGL_HI_colorformats */ + +#ifndef EGL_IMG_context_priority +#define EGL_IMG_context_priority 1 +#define EGL_CONTEXT_PRIORITY_LEVEL_IMG 0x3100 +#define EGL_CONTEXT_PRIORITY_HIGH_IMG 0x3101 +#define EGL_CONTEXT_PRIORITY_MEDIUM_IMG 0x3102 +#define EGL_CONTEXT_PRIORITY_LOW_IMG 0x3103 +#endif /* EGL_IMG_context_priority */ + +#ifndef EGL_IMG_image_plane_attribs +#define EGL_IMG_image_plane_attribs 1 +#define EGL_NATIVE_BUFFER_MULTIPLANE_SEPARATE_IMG 0x3105 +#define EGL_NATIVE_BUFFER_PLANE_OFFSET_IMG 0x3106 +#endif /* EGL_IMG_image_plane_attribs */ + +#ifndef EGL_MESA_drm_image +#define EGL_MESA_drm_image 1 +#define EGL_DRM_BUFFER_FORMAT_MESA 0x31D0 +#define EGL_DRM_BUFFER_USE_MESA 0x31D1 +#define EGL_DRM_BUFFER_FORMAT_ARGB32_MESA 0x31D2 +#define EGL_DRM_BUFFER_MESA 0x31D3 +#define EGL_DRM_BUFFER_STRIDE_MESA 0x31D4 +#define EGL_DRM_BUFFER_USE_SCANOUT_MESA 0x00000001 +#define EGL_DRM_BUFFER_USE_SHARE_MESA 0x00000002 +#define EGL_DRM_BUFFER_USE_CURSOR_MESA 0x00000004 +typedef EGLImageKHR (EGLAPIENTRYP PFNEGLCREATEDRMIMAGEMESAPROC) (EGLDisplay dpy, const EGLint *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLEXPORTDRMIMAGEMESAPROC) (EGLDisplay dpy, EGLImageKHR image, EGLint *name, EGLint *handle, EGLint *stride); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLImageKHR EGLAPIENTRY eglCreateDRMImageMESA (EGLDisplay dpy, const EGLint *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglExportDRMImageMESA (EGLDisplay dpy, EGLImageKHR image, EGLint *name, EGLint *handle, EGLint *stride); +#endif +#endif /* EGL_MESA_drm_image */ + +#ifndef EGL_MESA_image_dma_buf_export +#define EGL_MESA_image_dma_buf_export 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLEXPORTDMABUFIMAGEQUERYMESAPROC) (EGLDisplay dpy, EGLImageKHR image, int *fourcc, int *num_planes, EGLuint64KHR *modifiers); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLEXPORTDMABUFIMAGEMESAPROC) (EGLDisplay dpy, EGLImageKHR image, int *fds, EGLint *strides, EGLint *offsets); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglExportDMABUFImageQueryMESA (EGLDisplay dpy, EGLImageKHR image, int *fourcc, int *num_planes, EGLuint64KHR *modifiers); +EGLAPI EGLBoolean EGLAPIENTRY eglExportDMABUFImageMESA (EGLDisplay dpy, EGLImageKHR image, int *fds, EGLint *strides, EGLint *offsets); +#endif +#endif /* EGL_MESA_image_dma_buf_export */ + +#ifndef EGL_MESA_platform_gbm +#define EGL_MESA_platform_gbm 1 +#define EGL_PLATFORM_GBM_MESA 0x31D7 +#endif /* EGL_MESA_platform_gbm */ + +#ifndef EGL_MESA_platform_surfaceless +#define EGL_MESA_platform_surfaceless 1 +#define EGL_PLATFORM_SURFACELESS_MESA 0x31DD +#endif /* EGL_MESA_platform_surfaceless */ + +#ifndef EGL_MESA_query_driver +#define EGL_MESA_query_driver 1 +typedef char *(EGLAPIENTRYP PFNEGLGETDISPLAYDRIVERCONFIGPROC) (EGLDisplay dpy); +typedef const char *(EGLAPIENTRYP PFNEGLGETDISPLAYDRIVERNAMEPROC) (EGLDisplay dpy); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI char *EGLAPIENTRY eglGetDisplayDriverConfig (EGLDisplay dpy); +EGLAPI const char *EGLAPIENTRY eglGetDisplayDriverName (EGLDisplay dpy); +#endif +#endif /* EGL_MESA_query_driver */ + +#ifndef EGL_NOK_swap_region +#define EGL_NOK_swap_region 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSREGIONNOKPROC) (EGLDisplay dpy, EGLSurface surface, EGLint numRects, const EGLint *rects); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersRegionNOK (EGLDisplay dpy, EGLSurface surface, EGLint numRects, const EGLint *rects); +#endif +#endif /* EGL_NOK_swap_region */ + +#ifndef EGL_NOK_swap_region2 +#define EGL_NOK_swap_region2 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSREGION2NOKPROC) (EGLDisplay dpy, EGLSurface surface, EGLint numRects, const EGLint *rects); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersRegion2NOK (EGLDisplay dpy, EGLSurface surface, EGLint numRects, const EGLint *rects); +#endif +#endif /* EGL_NOK_swap_region2 */ + +#ifndef EGL_NOK_texture_from_pixmap +#define EGL_NOK_texture_from_pixmap 1 +#define EGL_Y_INVERTED_NOK 0x307F +#endif /* EGL_NOK_texture_from_pixmap */ + +#ifndef EGL_NV_3dvision_surface +#define EGL_NV_3dvision_surface 1 +#define EGL_AUTO_STEREO_NV 0x3136 +#endif /* EGL_NV_3dvision_surface */ + +#ifndef EGL_NV_context_priority_realtime +#define EGL_NV_context_priority_realtime 1 +#define EGL_CONTEXT_PRIORITY_REALTIME_NV 0x3357 +#endif /* EGL_NV_context_priority_realtime */ + +#ifndef EGL_NV_coverage_sample +#define EGL_NV_coverage_sample 1 +#define EGL_COVERAGE_BUFFERS_NV 0x30E0 +#define EGL_COVERAGE_SAMPLES_NV 0x30E1 +#endif /* EGL_NV_coverage_sample */ + +#ifndef EGL_NV_coverage_sample_resolve +#define EGL_NV_coverage_sample_resolve 1 +#define EGL_COVERAGE_SAMPLE_RESOLVE_NV 0x3131 +#define EGL_COVERAGE_SAMPLE_RESOLVE_DEFAULT_NV 0x3132 +#define EGL_COVERAGE_SAMPLE_RESOLVE_NONE_NV 0x3133 +#endif /* EGL_NV_coverage_sample_resolve */ + +#ifndef EGL_NV_cuda_event +#define EGL_NV_cuda_event 1 +#define EGL_CUDA_EVENT_HANDLE_NV 0x323B +#define EGL_SYNC_CUDA_EVENT_NV 0x323C +#define EGL_SYNC_CUDA_EVENT_COMPLETE_NV 0x323D +#endif /* EGL_NV_cuda_event */ + +#ifndef EGL_NV_depth_nonlinear +#define EGL_NV_depth_nonlinear 1 +#define EGL_DEPTH_ENCODING_NV 0x30E2 +#define EGL_DEPTH_ENCODING_NONE_NV 0 +#define EGL_DEPTH_ENCODING_NONLINEAR_NV 0x30E3 +#endif /* EGL_NV_depth_nonlinear */ + +#ifndef EGL_NV_device_cuda +#define EGL_NV_device_cuda 1 +#define EGL_CUDA_DEVICE_NV 0x323A +#endif /* EGL_NV_device_cuda */ + +#ifndef EGL_NV_native_query +#define EGL_NV_native_query 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYNATIVEDISPLAYNVPROC) (EGLDisplay dpy, EGLNativeDisplayType *display_id); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYNATIVEWINDOWNVPROC) (EGLDisplay dpy, EGLSurface surf, EGLNativeWindowType *window); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYNATIVEPIXMAPNVPROC) (EGLDisplay dpy, EGLSurface surf, EGLNativePixmapType *pixmap); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQueryNativeDisplayNV (EGLDisplay dpy, EGLNativeDisplayType *display_id); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryNativeWindowNV (EGLDisplay dpy, EGLSurface surf, EGLNativeWindowType *window); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryNativePixmapNV (EGLDisplay dpy, EGLSurface surf, EGLNativePixmapType *pixmap); +#endif +#endif /* EGL_NV_native_query */ + +#ifndef EGL_NV_post_convert_rounding +#define EGL_NV_post_convert_rounding 1 +#endif /* EGL_NV_post_convert_rounding */ + +#ifndef EGL_NV_post_sub_buffer +#define EGL_NV_post_sub_buffer 1 +#define EGL_POST_SUB_BUFFER_SUPPORTED_NV 0x30BE +typedef EGLBoolean (EGLAPIENTRYP PFNEGLPOSTSUBBUFFERNVPROC) (EGLDisplay dpy, EGLSurface surface, EGLint x, EGLint y, EGLint width, EGLint height); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglPostSubBufferNV (EGLDisplay dpy, EGLSurface surface, EGLint x, EGLint y, EGLint width, EGLint height); +#endif +#endif /* EGL_NV_post_sub_buffer */ + +#ifndef EGL_NV_quadruple_buffer +#define EGL_NV_quadruple_buffer 1 +#define EGL_QUADRUPLE_BUFFER_NV 0x3231 +#endif /* EGL_NV_quadruple_buffer */ + +#ifndef EGL_NV_robustness_video_memory_purge +#define EGL_NV_robustness_video_memory_purge 1 +#define EGL_GENERATE_RESET_ON_VIDEO_MEMORY_PURGE_NV 0x334C +#endif /* EGL_NV_robustness_video_memory_purge */ + +#ifndef EGL_NV_stream_consumer_eglimage +#define EGL_NV_stream_consumer_eglimage 1 +#define EGL_STREAM_CONSUMER_IMAGE_NV 0x3373 +#define EGL_STREAM_IMAGE_ADD_NV 0x3374 +#define EGL_STREAM_IMAGE_REMOVE_NV 0x3375 +#define EGL_STREAM_IMAGE_AVAILABLE_NV 0x3376 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMIMAGECONSUMERCONNECTNVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLint num_modifiers, const EGLuint64KHR *modifiers, const EGLAttrib *attrib_list); +typedef EGLint (EGLAPIENTRYP PFNEGLQUERYSTREAMCONSUMEREVENTNVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLTime timeout, EGLenum *event, EGLAttrib *aux); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMACQUIREIMAGENVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLImage *pImage, EGLSync sync); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMRELEASEIMAGENVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLImage image, EGLSync sync); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglStreamImageConsumerConnectNV (EGLDisplay dpy, EGLStreamKHR stream, EGLint num_modifiers, const EGLuint64KHR *modifiers, const EGLAttrib *attrib_list); +EGLAPI EGLint EGLAPIENTRY eglQueryStreamConsumerEventNV (EGLDisplay dpy, EGLStreamKHR stream, EGLTime timeout, EGLenum *event, EGLAttrib *aux); +EGLAPI EGLBoolean EGLAPIENTRY eglStreamAcquireImageNV (EGLDisplay dpy, EGLStreamKHR stream, EGLImage *pImage, EGLSync sync); +EGLAPI EGLBoolean EGLAPIENTRY eglStreamReleaseImageNV (EGLDisplay dpy, EGLStreamKHR stream, EGLImage image, EGLSync sync); +#endif +#endif /* EGL_NV_stream_consumer_eglimage */ + +#ifndef EGL_NV_stream_consumer_gltexture_yuv +#define EGL_NV_stream_consumer_gltexture_yuv 1 +#define EGL_YUV_PLANE0_TEXTURE_UNIT_NV 0x332C +#define EGL_YUV_PLANE1_TEXTURE_UNIT_NV 0x332D +#define EGL_YUV_PLANE2_TEXTURE_UNIT_NV 0x332E +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERGLTEXTUREEXTERNALATTRIBSNVPROC) (EGLDisplay dpy, EGLStreamKHR stream, const EGLAttrib *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerGLTextureExternalAttribsNV (EGLDisplay dpy, EGLStreamKHR stream, const EGLAttrib *attrib_list); +#endif +#endif /* EGL_NV_stream_consumer_gltexture_yuv */ + +#ifndef EGL_NV_stream_cross_display +#define EGL_NV_stream_cross_display 1 +#define EGL_STREAM_CROSS_DISPLAY_NV 0x334E +#endif /* EGL_NV_stream_cross_display */ + +#ifndef EGL_NV_stream_cross_object +#define EGL_NV_stream_cross_object 1 +#define EGL_STREAM_CROSS_OBJECT_NV 0x334D +#endif /* EGL_NV_stream_cross_object */ + +#ifndef EGL_NV_stream_cross_partition +#define EGL_NV_stream_cross_partition 1 +#define EGL_STREAM_CROSS_PARTITION_NV 0x323F +#endif /* EGL_NV_stream_cross_partition */ + +#ifndef EGL_NV_stream_cross_process +#define EGL_NV_stream_cross_process 1 +#define EGL_STREAM_CROSS_PROCESS_NV 0x3245 +#endif /* EGL_NV_stream_cross_process */ + +#ifndef EGL_NV_stream_cross_system +#define EGL_NV_stream_cross_system 1 +#define EGL_STREAM_CROSS_SYSTEM_NV 0x334F +#endif /* EGL_NV_stream_cross_system */ + +#ifndef EGL_NV_stream_dma +#define EGL_NV_stream_dma 1 +#define EGL_STREAM_DMA_NV 0x3371 +#define EGL_STREAM_DMA_SERVER_NV 0x3372 +#endif /* EGL_NV_stream_dma */ + +#ifndef EGL_NV_stream_fifo_next +#define EGL_NV_stream_fifo_next 1 +#define EGL_PENDING_FRAME_NV 0x3329 +#define EGL_STREAM_TIME_PENDING_NV 0x332A +#endif /* EGL_NV_stream_fifo_next */ + +#ifndef EGL_NV_stream_fifo_synchronous +#define EGL_NV_stream_fifo_synchronous 1 +#define EGL_STREAM_FIFO_SYNCHRONOUS_NV 0x3336 +#endif /* EGL_NV_stream_fifo_synchronous */ + +#ifndef EGL_NV_stream_flush +#define EGL_NV_stream_flush 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMFLUSHNVPROC) (EGLDisplay dpy, EGLStreamKHR stream); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglStreamFlushNV (EGLDisplay dpy, EGLStreamKHR stream); +#endif +#endif /* EGL_NV_stream_flush */ + +#ifndef EGL_NV_stream_frame_limits +#define EGL_NV_stream_frame_limits 1 +#define EGL_PRODUCER_MAX_FRAME_HINT_NV 0x3337 +#define EGL_CONSUMER_MAX_FRAME_HINT_NV 0x3338 +#endif /* EGL_NV_stream_frame_limits */ + +#ifndef EGL_NV_stream_metadata +#define EGL_NV_stream_metadata 1 +#define EGL_MAX_STREAM_METADATA_BLOCKS_NV 0x3250 +#define EGL_MAX_STREAM_METADATA_BLOCK_SIZE_NV 0x3251 +#define EGL_MAX_STREAM_METADATA_TOTAL_SIZE_NV 0x3252 +#define EGL_PRODUCER_METADATA_NV 0x3253 +#define EGL_CONSUMER_METADATA_NV 0x3254 +#define EGL_PENDING_METADATA_NV 0x3328 +#define EGL_METADATA0_SIZE_NV 0x3255 +#define EGL_METADATA1_SIZE_NV 0x3256 +#define EGL_METADATA2_SIZE_NV 0x3257 +#define EGL_METADATA3_SIZE_NV 0x3258 +#define EGL_METADATA0_TYPE_NV 0x3259 +#define EGL_METADATA1_TYPE_NV 0x325A +#define EGL_METADATA2_TYPE_NV 0x325B +#define EGL_METADATA3_TYPE_NV 0x325C +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDISPLAYATTRIBNVPROC) (EGLDisplay dpy, EGLint attribute, EGLAttrib *value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSETSTREAMMETADATANVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLint n, EGLint offset, EGLint size, const void *data); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMMETADATANVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum name, EGLint n, EGLint offset, EGLint size, void *data); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDisplayAttribNV (EGLDisplay dpy, EGLint attribute, EGLAttrib *value); +EGLAPI EGLBoolean EGLAPIENTRY eglSetStreamMetadataNV (EGLDisplay dpy, EGLStreamKHR stream, EGLint n, EGLint offset, EGLint size, const void *data); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamMetadataNV (EGLDisplay dpy, EGLStreamKHR stream, EGLenum name, EGLint n, EGLint offset, EGLint size, void *data); +#endif +#endif /* EGL_NV_stream_metadata */ + +#ifndef EGL_NV_stream_origin +#define EGL_NV_stream_origin 1 +#define EGL_STREAM_FRAME_ORIGIN_X_NV 0x3366 +#define EGL_STREAM_FRAME_ORIGIN_Y_NV 0x3367 +#define EGL_STREAM_FRAME_MAJOR_AXIS_NV 0x3368 +#define EGL_CONSUMER_AUTO_ORIENTATION_NV 0x3369 +#define EGL_PRODUCER_AUTO_ORIENTATION_NV 0x336A +#define EGL_LEFT_NV 0x336B +#define EGL_RIGHT_NV 0x336C +#define EGL_TOP_NV 0x336D +#define EGL_BOTTOM_NV 0x336E +#define EGL_X_AXIS_NV 0x336F +#define EGL_Y_AXIS_NV 0x3370 +#endif /* EGL_NV_stream_origin */ + +#ifndef EGL_NV_stream_remote +#define EGL_NV_stream_remote 1 +#define EGL_STREAM_STATE_INITIALIZING_NV 0x3240 +#define EGL_STREAM_TYPE_NV 0x3241 +#define EGL_STREAM_PROTOCOL_NV 0x3242 +#define EGL_STREAM_ENDPOINT_NV 0x3243 +#define EGL_STREAM_LOCAL_NV 0x3244 +#define EGL_STREAM_PRODUCER_NV 0x3247 +#define EGL_STREAM_CONSUMER_NV 0x3248 +#define EGL_STREAM_PROTOCOL_FD_NV 0x3246 +#endif /* EGL_NV_stream_remote */ + +#ifndef EGL_NV_stream_reset +#define EGL_NV_stream_reset 1 +#define EGL_SUPPORT_RESET_NV 0x3334 +#define EGL_SUPPORT_REUSE_NV 0x3335 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLRESETSTREAMNVPROC) (EGLDisplay dpy, EGLStreamKHR stream); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglResetStreamNV (EGLDisplay dpy, EGLStreamKHR stream); +#endif +#endif /* EGL_NV_stream_reset */ + +#ifndef EGL_NV_stream_socket +#define EGL_NV_stream_socket 1 +#define EGL_STREAM_PROTOCOL_SOCKET_NV 0x324B +#define EGL_SOCKET_HANDLE_NV 0x324C +#define EGL_SOCKET_TYPE_NV 0x324D +#endif /* EGL_NV_stream_socket */ + +#ifndef EGL_NV_stream_socket_inet +#define EGL_NV_stream_socket_inet 1 +#define EGL_SOCKET_TYPE_INET_NV 0x324F +#endif /* EGL_NV_stream_socket_inet */ + +#ifndef EGL_NV_stream_socket_unix +#define EGL_NV_stream_socket_unix 1 +#define EGL_SOCKET_TYPE_UNIX_NV 0x324E +#endif /* EGL_NV_stream_socket_unix */ + +#ifndef EGL_NV_stream_sync +#define EGL_NV_stream_sync 1 +#define EGL_SYNC_NEW_FRAME_NV 0x321F +typedef EGLSyncKHR (EGLAPIENTRYP PFNEGLCREATESTREAMSYNCNVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum type, const EGLint *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLSyncKHR EGLAPIENTRY eglCreateStreamSyncNV (EGLDisplay dpy, EGLStreamKHR stream, EGLenum type, const EGLint *attrib_list); +#endif +#endif /* EGL_NV_stream_sync */ + +#ifndef EGL_NV_sync +#define EGL_NV_sync 1 +typedef void *EGLSyncNV; +typedef khronos_utime_nanoseconds_t EGLTimeNV; +#ifdef KHRONOS_SUPPORT_INT64 +#define EGL_SYNC_PRIOR_COMMANDS_COMPLETE_NV 0x30E6 +#define EGL_SYNC_STATUS_NV 0x30E7 +#define EGL_SIGNALED_NV 0x30E8 +#define EGL_UNSIGNALED_NV 0x30E9 +#define EGL_SYNC_FLUSH_COMMANDS_BIT_NV 0x0001 +#define EGL_FOREVER_NV 0xFFFFFFFFFFFFFFFFull +#define EGL_ALREADY_SIGNALED_NV 0x30EA +#define EGL_TIMEOUT_EXPIRED_NV 0x30EB +#define EGL_CONDITION_SATISFIED_NV 0x30EC +#define EGL_SYNC_TYPE_NV 0x30ED +#define EGL_SYNC_CONDITION_NV 0x30EE +#define EGL_SYNC_FENCE_NV 0x30EF +#define EGL_NO_SYNC_NV EGL_CAST(EGLSyncNV,0) +typedef EGLSyncNV (EGLAPIENTRYP PFNEGLCREATEFENCESYNCNVPROC) (EGLDisplay dpy, EGLenum condition, const EGLint *attrib_list); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYSYNCNVPROC) (EGLSyncNV sync); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLFENCENVPROC) (EGLSyncNV sync); +typedef EGLint (EGLAPIENTRYP PFNEGLCLIENTWAITSYNCNVPROC) (EGLSyncNV sync, EGLint flags, EGLTimeNV timeout); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSIGNALSYNCNVPROC) (EGLSyncNV sync, EGLenum mode); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETSYNCATTRIBNVPROC) (EGLSyncNV sync, EGLint attribute, EGLint *value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLSyncNV EGLAPIENTRY eglCreateFenceSyncNV (EGLDisplay dpy, EGLenum condition, const EGLint *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglDestroySyncNV (EGLSyncNV sync); +EGLAPI EGLBoolean EGLAPIENTRY eglFenceNV (EGLSyncNV sync); +EGLAPI EGLint EGLAPIENTRY eglClientWaitSyncNV (EGLSyncNV sync, EGLint flags, EGLTimeNV timeout); +EGLAPI EGLBoolean EGLAPIENTRY eglSignalSyncNV (EGLSyncNV sync, EGLenum mode); +EGLAPI EGLBoolean EGLAPIENTRY eglGetSyncAttribNV (EGLSyncNV sync, EGLint attribute, EGLint *value); +#endif +#endif /* KHRONOS_SUPPORT_INT64 */ +#endif /* EGL_NV_sync */ + +#ifndef EGL_NV_system_time +#define EGL_NV_system_time 1 +typedef khronos_utime_nanoseconds_t EGLuint64NV; +#ifdef KHRONOS_SUPPORT_INT64 +typedef EGLuint64NV (EGLAPIENTRYP PFNEGLGETSYSTEMTIMEFREQUENCYNVPROC) (void); +typedef EGLuint64NV (EGLAPIENTRYP PFNEGLGETSYSTEMTIMENVPROC) (void); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLuint64NV EGLAPIENTRY eglGetSystemTimeFrequencyNV (void); +EGLAPI EGLuint64NV EGLAPIENTRY eglGetSystemTimeNV (void); +#endif +#endif /* KHRONOS_SUPPORT_INT64 */ +#endif /* EGL_NV_system_time */ + +#ifndef EGL_NV_triple_buffer +#define EGL_NV_triple_buffer 1 +#define EGL_TRIPLE_BUFFER_NV 0x3230 +#endif /* EGL_NV_triple_buffer */ + +#ifndef EGL_TIZEN_image_native_buffer +#define EGL_TIZEN_image_native_buffer 1 +#define EGL_NATIVE_BUFFER_TIZEN 0x32A0 +#endif /* EGL_TIZEN_image_native_buffer */ + +#ifndef EGL_TIZEN_image_native_surface +#define EGL_TIZEN_image_native_surface 1 +#define EGL_NATIVE_SURFACE_TIZEN 0x32A1 +#endif /* EGL_TIZEN_image_native_surface */ + +#ifndef EGL_WL_bind_wayland_display +#define EGL_WL_bind_wayland_display 1 +#define PFNEGLBINDWAYLANDDISPLAYWL PFNEGLBINDWAYLANDDISPLAYWLPROC +#define PFNEGLUNBINDWAYLANDDISPLAYWL PFNEGLUNBINDWAYLANDDISPLAYWLPROC +#define PFNEGLQUERYWAYLANDBUFFERWL PFNEGLQUERYWAYLANDBUFFERWLPROC +struct wl_display; +struct wl_resource; +#define EGL_WAYLAND_BUFFER_WL 0x31D5 +#define EGL_WAYLAND_PLANE_WL 0x31D6 +#define EGL_TEXTURE_Y_U_V_WL 0x31D7 +#define EGL_TEXTURE_Y_UV_WL 0x31D8 +#define EGL_TEXTURE_Y_XUXV_WL 0x31D9 +#define EGL_TEXTURE_EXTERNAL_WL 0x31DA +#define EGL_WAYLAND_Y_INVERTED_WL 0x31DB +typedef EGLBoolean (EGLAPIENTRYP PFNEGLBINDWAYLANDDISPLAYWLPROC) (EGLDisplay dpy, struct wl_display *display); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLUNBINDWAYLANDDISPLAYWLPROC) (EGLDisplay dpy, struct wl_display *display); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYWAYLANDBUFFERWLPROC) (EGLDisplay dpy, struct wl_resource *buffer, EGLint attribute, EGLint *value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglBindWaylandDisplayWL (EGLDisplay dpy, struct wl_display *display); +EGLAPI EGLBoolean EGLAPIENTRY eglUnbindWaylandDisplayWL (EGLDisplay dpy, struct wl_display *display); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryWaylandBufferWL (EGLDisplay dpy, struct wl_resource *buffer, EGLint attribute, EGLint *value); +#endif +#endif /* EGL_WL_bind_wayland_display */ + +#ifndef EGL_WL_create_wayland_buffer_from_image +#define EGL_WL_create_wayland_buffer_from_image 1 +#define PFNEGLCREATEWAYLANDBUFFERFROMIMAGEWL PFNEGLCREATEWAYLANDBUFFERFROMIMAGEWLPROC +struct wl_buffer; +typedef struct wl_buffer *(EGLAPIENTRYP PFNEGLCREATEWAYLANDBUFFERFROMIMAGEWLPROC) (EGLDisplay dpy, EGLImageKHR image); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI struct wl_buffer *EGLAPIENTRY eglCreateWaylandBufferFromImageWL (EGLDisplay dpy, EGLImageKHR image); +#endif +#endif /* EGL_WL_create_wayland_buffer_from_image */ + +/* ANGLE EGL extensions */ +#include "eglext_angle.h" + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/EGL/eglext_angle.h b/gfx/angle/checkout/include/EGL/eglext_angle.h new file mode 100644 index 0000000000..caf3780172 --- /dev/null +++ b/gfx/angle/checkout/include/EGL/eglext_angle.h @@ -0,0 +1,412 @@ +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// eglext_angle.h: ANGLE modifications to the eglext.h header file. +// Currently we don't include this file directly, we patch eglext.h +// to include it implicitly so it is visible throughout our code. + +#ifndef INCLUDE_EGL_EGLEXT_ANGLE_ +#define INCLUDE_EGL_EGLEXT_ANGLE_ + +// clang-format off + +#ifndef EGL_ANGLE_robust_resource_initialization +#define EGL_ANGLE_robust_resource_initialization 1 +#define EGL_ROBUST_RESOURCE_INITIALIZATION_ANGLE 0x3453 +#endif /* EGL_ANGLE_robust_resource_initialization */ + +#ifndef EGL_ANGLE_keyed_mutex +#define EGL_ANGLE_keyed_mutex 1 +#define EGL_DXGI_KEYED_MUTEX_ANGLE 0x33A2 +#endif /* EGL_ANGLE_keyed_mutex */ + +#ifndef EGL_ANGLE_d3d_texture_client_buffer +#define EGL_ANGLE_d3d_texture_client_buffer 1 +#define EGL_D3D_TEXTURE_ANGLE 0x33A3 +#define EGL_TEXTURE_OFFSET_X_ANGLE 0x3490 +#define EGL_TEXTURE_OFFSET_Y_ANGLE 0x3491 +#define EGL_D3D11_TEXTURE_PLANE_ANGLE 0x3492 +#define EGL_D3D11_TEXTURE_ARRAY_SLICE_ANGLE 0x3493 +#endif /* EGL_ANGLE_d3d_texture_client_buffer */ + +#ifndef EGL_ANGLE_software_display +#define EGL_ANGLE_software_display 1 +#define EGL_SOFTWARE_DISPLAY_ANGLE ((EGLNativeDisplayType)-1) +#endif /* EGL_ANGLE_software_display */ + +#ifndef EGL_ANGLE_direct3d_display +#define EGL_ANGLE_direct3d_display 1 +#define EGL_D3D11_ELSE_D3D9_DISPLAY_ANGLE ((EGLNativeDisplayType)-2) +#define EGL_D3D11_ONLY_DISPLAY_ANGLE ((EGLNativeDisplayType)-3) +#endif /* EGL_ANGLE_direct3d_display */ + +#ifndef EGL_ANGLE_direct_composition +#define EGL_ANGLE_direct_composition 1 +#define EGL_DIRECT_COMPOSITION_ANGLE 0x33A5 +#endif /* EGL_ANGLE_direct_composition */ + +#ifndef EGL_ANGLE_platform_angle +#define EGL_ANGLE_platform_angle 1 +#define EGL_PLATFORM_ANGLE_ANGLE 0x3202 +#define EGL_PLATFORM_ANGLE_TYPE_ANGLE 0x3203 +#define EGL_PLATFORM_ANGLE_MAX_VERSION_MAJOR_ANGLE 0x3204 +#define EGL_PLATFORM_ANGLE_MAX_VERSION_MINOR_ANGLE 0x3205 +#define EGL_PLATFORM_ANGLE_TYPE_DEFAULT_ANGLE 0x3206 +#define EGL_PLATFORM_ANGLE_DEBUG_LAYERS_ENABLED_ANGLE 0x3451 +#define EGL_PLATFORM_ANGLE_DEVICE_TYPE_ANGLE 0x3209 +#define EGL_PLATFORM_ANGLE_DEVICE_TYPE_HARDWARE_ANGLE 0x320A +#define EGL_PLATFORM_ANGLE_DEVICE_TYPE_NULL_ANGLE 0x345E +#define EGL_PLATFORM_ANGLE_NATIVE_PLATFORM_TYPE_ANGLE 0x348F +#endif /* EGL_ANGLE_platform_angle */ + +#ifndef EGL_ANGLE_platform_angle_d3d +#define EGL_ANGLE_platform_angle_d3d 1 +#define EGL_PLATFORM_ANGLE_TYPE_D3D9_ANGLE 0x3207 +#define EGL_PLATFORM_ANGLE_TYPE_D3D11_ANGLE 0x3208 +#define EGL_PLATFORM_ANGLE_DEVICE_TYPE_D3D_WARP_ANGLE 0x320B +#define EGL_PLATFORM_ANGLE_DEVICE_TYPE_D3D_REFERENCE_ANGLE 0x320C +#define EGL_PLATFORM_ANGLE_ENABLE_AUTOMATIC_TRIM_ANGLE 0x320F +#endif /* EGL_ANGLE_platform_angle_d3d */ + +#ifndef EGL_ANGLE_platform_angle_d3d_luid +#define EGL_ANGLE_platform_angle_d3d_luid 1 +#define EGL_PLATFORM_ANGLE_D3D_LUID_HIGH_ANGLE 0x34A0 +#define EGL_PLATFORM_ANGLE_D3D_LUID_LOW_ANGLE 0x34A1 +#endif /* EGL_ANGLE_platform_angle_d3d_luid */ + +#ifndef EGL_ANGLE_platform_angle_d3d11on12 +#define EGL_ANGLE_platform_angle_d3d11on12 1 +#define EGL_PLATFORM_ANGLE_D3D11ON12_ANGLE 0x3488 +#endif /* EGL_ANGLE_platform_angle_d3d11on12 */ + +#ifndef EGL_ANGLE_platform_angle_opengl +#define EGL_ANGLE_platform_angle_opengl 1 +#define EGL_PLATFORM_ANGLE_TYPE_OPENGL_ANGLE 0x320D +#define EGL_PLATFORM_ANGLE_TYPE_OPENGLES_ANGLE 0x320E +#define EGL_PLATFORM_ANGLE_EGL_HANDLE_ANGLE 0x3480 +#endif /* EGL_ANGLE_platform_angle_opengl */ + +#ifndef EGL_ANGLE_platform_angle_null +#define EGL_ANGLE_platform_angle_null 1 +#define EGL_PLATFORM_ANGLE_TYPE_NULL_ANGLE 0x33AE +#endif /* EGL_ANGLE_platform_angle_null */ + +#ifndef EGL_ANGLE_platform_angle_vulkan +#define EGL_ANGLE_platform_angle_vulkan 1 +#define EGL_PLATFORM_ANGLE_TYPE_VULKAN_ANGLE 0x3450 +#define EGL_PLATFORM_VULKAN_DISPLAY_MODE_SIMPLE_ANGLE 0x34A4 +#define EGL_PLATFORM_VULKAN_DISPLAY_MODE_HEADLESS_ANGLE 0x34A5 +#endif /* EGL_ANGLE_platform_angle_vulkan */ + +#ifndef EGL_ANGLE_platform_angle_metal +#define EGL_ANGLE_platform_angle_metal 1 +#define EGL_PLATFORM_ANGLE_TYPE_METAL_ANGLE 0x3489 +#endif /* EGL_ANGLE_platform_angle_metal */ + +#ifndef EGL_ANGLE_platform_angle_device_type_swiftshader +#define EGL_ANGLE_platform_angle_device_type_swiftshader +#define EGL_PLATFORM_ANGLE_DEVICE_TYPE_SWIFTSHADER_ANGLE 0x3487 +#endif /* EGL_ANGLE_platform_angle_device_type_swiftshader */ + +#ifndef EGL_ANGLE_platform_angle_device_type_egl_angle +#define EGL_ANGLE_platform_angle_device_type_egl_angle +#define EGL_PLATFORM_ANGLE_DEVICE_TYPE_EGL_ANGLE 0x348E +#endif /* EGL_ANGLE_platform_angle_device_type_egl_angle */ + +#ifndef EGL_ANGLE_context_virtualization +#define EGL_ANGLE_context_virtualization 1 +#define EGL_CONTEXT_VIRTUALIZATION_GROUP_ANGLE 0x3481 +#endif /* EGL_ANGLE_context_virtualization */ + +#ifndef EGL_ANGLE_platform_angle_device_context_volatile_eagl +#define EGL_ANGLE_platform_angle_device_context_volatile_eagl 1 +#define EGL_PLATFORM_ANGLE_DEVICE_CONTEXT_VOLATILE_EAGL_ANGLE 0x34A2 +#endif /* EGL_ANGLE_platform_angle_device_context_volatile_eagl */ + +#ifndef EGL_ANGLE_platform_angle_device_context_volatile_cgl +#define EGL_ANGLE_platform_angle_device_context_volatile_cgl 1 +#define EGL_PLATFORM_ANGLE_DEVICE_CONTEXT_VOLATILE_CGL_ANGLE 0x34A3 +#endif /* EGL_ANGLE_platform_angle_device_context_volatile_cgl */ + +#ifndef EGL_ANGLE_platform_angle_device_id +#define EGL_ANGLE_platform_angle_device_id +#define EGL_PLATFORM_ANGLE_DEVICE_ID_HIGH_ANGLE 0x34D6 +#define EGL_PLATFORM_ANGLE_DEVICE_ID_LOW_ANGLE 0x34D7 +#endif /* EGL_ANGLE_platform_angle_device_id */ + +#ifndef EGL_ANGLE_x11_visual +#define EGL_ANGLE_x11_visual +#define EGL_X11_VISUAL_ID_ANGLE 0x33A3 +#endif /* EGL_ANGLE_x11_visual */ + +#ifndef EGL_ANGLE_surface_orientation +#define EGL_ANGLE_surface_orientation +#define EGL_OPTIMAL_SURFACE_ORIENTATION_ANGLE 0x33A7 +#define EGL_SURFACE_ORIENTATION_ANGLE 0x33A8 +#define EGL_SURFACE_ORIENTATION_INVERT_X_ANGLE 0x0001 +#define EGL_SURFACE_ORIENTATION_INVERT_Y_ANGLE 0x0002 +#endif /* EGL_ANGLE_surface_orientation */ + +#ifndef EGL_ANGLE_experimental_present_path +#define EGL_ANGLE_experimental_present_path +#define EGL_EXPERIMENTAL_PRESENT_PATH_ANGLE 0x33A4 +#define EGL_EXPERIMENTAL_PRESENT_PATH_FAST_ANGLE 0x33A9 +#define EGL_EXPERIMENTAL_PRESENT_PATH_COPY_ANGLE 0x33AA +#endif /* EGL_ANGLE_experimental_present_path */ + +#ifndef EGL_ANGLE_stream_producer_d3d_texture +#define EGL_ANGLE_stream_producer_d3d_texture +#define EGL_D3D_TEXTURE_SUBRESOURCE_ID_ANGLE 0x33AB +typedef EGLBoolean(EGLAPIENTRYP PFNEGLCREATESTREAMPRODUCERD3DTEXTUREANGLEPROC)(EGLDisplay dpy, EGLStreamKHR stream, const EGLAttrib *attrib_list); +typedef EGLBoolean(EGLAPIENTRYP PFNEGLSTREAMPOSTD3DTEXTUREANGLEPROC)(EGLDisplay dpy, EGLStreamKHR stream, void *texture, const EGLAttrib *attrib_list); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglCreateStreamProducerD3DTextureANGLE(EGLDisplay dpy, EGLStreamKHR stream, const EGLAttrib *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglStreamPostD3DTextureANGLE(EGLDisplay dpy, EGLStreamKHR stream, void *texture, const EGLAttrib *attrib_list); +#endif +#endif /* EGL_ANGLE_stream_producer_d3d_texture */ + +#ifndef EGL_ANGLE_create_context_webgl_compatibility +#define EGL_ANGLE_create_context_webgl_compatibility 1 +#define EGL_CONTEXT_WEBGL_COMPATIBILITY_ANGLE 0x33AC +#endif /* EGL_ANGLE_create_context_webgl_compatibility */ + +#ifndef EGL_ANGLE_display_texture_share_group +#define EGL_ANGLE_display_texture_share_group 1 +#define EGL_DISPLAY_TEXTURE_SHARE_GROUP_ANGLE 0x33AF +#endif /* EGL_ANGLE_display_texture_share_group */ + +#ifndef EGL_CHROMIUM_create_context_bind_generates_resource +#define EGL_CHROMIUM_create_context_bind_generates_resource 1 +#define EGL_CONTEXT_BIND_GENERATES_RESOURCE_CHROMIUM 0x33AD +#endif /* EGL_CHROMIUM_create_context_bind_generates_resource */ + +#ifndef EGL_ANGLE_metal_create_context_ownership_identity +#define EGL_ANGLE_metal_create_context_ownership_identity 1 +#define EGL_CONTEXT_METAL_OWNERSHIP_IDENTITY_ANGLE 0x34D2 +#endif /* EGL_ANGLE_metal_create_context_ownership_identity */ + +#ifndef EGL_ANGLE_create_context_client_arrays +#define EGL_ANGLE_create_context_client_arrays 1 +#define EGL_CONTEXT_CLIENT_ARRAYS_ENABLED_ANGLE 0x3452 +#endif /* EGL_ANGLE_create_context_client_arrays */ + +#ifndef EGL_ANGLE_device_creation +#define EGL_ANGLE_device_creation 1 +typedef EGLDeviceEXT(EGLAPIENTRYP PFNEGLCREATEDEVICEANGLEPROC) (EGLint device_type, void *native_device, const EGLAttrib *attrib_list); +typedef EGLBoolean(EGLAPIENTRYP PFNEGLRELEASEDEVICEANGLEPROC) (EGLDeviceEXT device); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLDeviceEXT EGLAPIENTRY eglCreateDeviceANGLE(EGLint device_type, void *native_device, const EGLAttrib *attrib_list); +EGLAPI EGLBoolean EGLAPIENTRY eglReleaseDeviceANGLE(EGLDeviceEXT device); +#endif +#endif /* EGL_ANGLE_device_creation */ + +#ifndef EGL_ANGLE_program_cache_control +#define EGL_ANGLE_program_cache_control 1 +#define EGL_PROGRAM_CACHE_SIZE_ANGLE 0x3455 +#define EGL_PROGRAM_CACHE_KEY_LENGTH_ANGLE 0x3456 +#define EGL_PROGRAM_CACHE_RESIZE_ANGLE 0x3457 +#define EGL_PROGRAM_CACHE_TRIM_ANGLE 0x3458 +#define EGL_CONTEXT_PROGRAM_BINARY_CACHE_ENABLED_ANGLE 0x3459 +typedef EGLint (EGLAPIENTRYP PFNEGLPROGRAMCACHEGETATTRIBANGLEPROC) (EGLDisplay dpy, EGLenum attrib); +typedef void (EGLAPIENTRYP PFNEGLPROGRAMCACHEQUERYANGLEPROC) (EGLDisplay dpy, EGLint index, void *key, EGLint *keysize, void *binary, EGLint *binarysize); +typedef void (EGLAPIENTRYP PFNEGLPROGRAMCACHEPOPULATEANGLEPROC) (EGLDisplay dpy, const void *key, EGLint keysize, const void *binary, EGLint binarysize); +typedef EGLint (EGLAPIENTRYP PFNEGLPROGRAMCACHERESIZEANGLEPROC) (EGLDisplay dpy, EGLint limit, EGLint mode); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLint EGLAPIENTRY eglProgramCacheGetAttribANGLE(EGLDisplay dpy, EGLenum attrib); +EGLAPI void EGLAPIENTRY eglProgramCacheQueryANGLE(EGLDisplay dpy, EGLint index, void *key, EGLint *keysize, void *binary, EGLint *binarysize); +EGLAPI void EGLAPIENTRY eglProgramCachePopulateANGLE(EGLDisplay dpy, const void *key, EGLint keysize, const void *binary, EGLint binarysize); +EGLAPI EGLint EGLAPIENTRY eglProgramCacheResizeANGLE(EGLDisplay dpy, EGLint limit, EGLint mode); +#endif +#endif /* EGL_ANGLE_program_cache_control */ + +#ifndef EGL_ANGLE_iosurface_client_buffer +#define EGL_ANGLE_iosurface_client_buffer 1 +#define EGL_IOSURFACE_ANGLE 0x3454 +#define EGL_IOSURFACE_PLANE_ANGLE 0x345A +#define EGL_TEXTURE_RECTANGLE_ANGLE 0x345B +#define EGL_TEXTURE_TYPE_ANGLE 0x345C +#define EGL_TEXTURE_INTERNAL_FORMAT_ANGLE 0x345D +#define EGL_IOSURFACE_USAGE_HINT_ANGLE 0x348A +#define EGL_IOSURFACE_READ_HINT_ANGLE 0x0001 +#define EGL_IOSURFACE_WRITE_HINT_ANGLE 0x0002 +#define EGL_BIND_TO_TEXTURE_TARGET_ANGLE 0x348D +#endif /* EGL_ANGLE_iosurface_client_buffer */ + +#ifndef ANGLE_metal_texture_client_buffer +#define ANGLE_metal_texture_client_buffer 1 +#define EGL_METAL_TEXTURE_ANGLE 0x34A7 +#endif /* ANGLE_metal_texture_client_buffer */ + +#ifndef EGL_ANGLE_create_context_extensions_enabled +#define EGL_ANGLE_create_context_extensions_enabled 1 +#define EGL_EXTENSIONS_ENABLED_ANGLE 0x345F +#endif /* EGL_ANGLE_create_context_extensions_enabled */ + +#ifndef EGL_CHROMIUM_sync_control +#define EGL_CHROMIUM_sync_control 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETSYNCVALUESCHROMIUMPROC) (EGLDisplay dpy, + EGLSurface surface, + EGLuint64KHR *ust, + EGLuint64KHR *msc, + EGLuint64KHR *sbc); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglGetSyncValuesCHROMIUM(EGLDisplay dpy, + EGLSurface surface, + EGLuint64KHR *ust, + EGLuint64KHR *msc, + EGLuint64KHR *sbc); +#endif +#endif /* EGL_CHROMIUM_sync_control */ + +#ifndef EGL_ANGLE_sync_control_rate +#define EGL_ANGLE_sync_control_rate 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETMSCRATEANGLEPROC) (EGLDisplay dpy, + EGLSurface surface, + EGLint *numerator, + EGLint *denominator); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglGetMscRateANGLE(EGLDisplay dpy, + EGLSurface surface, + EGLint *numerator, + EGLint *denominator); +#endif +#endif /* EGL_ANGLE_sync_control_rate */ + +#ifndef EGL_ANGLE_power_preference +#define EGL_ANGLE_power_preference 1 +#define EGL_POWER_PREFERENCE_ANGLE 0x3482 +#define EGL_LOW_POWER_ANGLE 0x0001 +#define EGL_HIGH_POWER_ANGLE 0x0002 +typedef void(EGLAPIENTRYP PFNEGLRELEASEHIGHPOWERGPUANGLEPROC) (EGLDisplay dpy, EGLContext ctx); +typedef void(EGLAPIENTRYP PFNEGLREACQUIREHIGHPOWERGPUANGLEPROC) (EGLDisplay dpy, EGLContext ctx); +typedef void(EGLAPIENTRYP PFNEGLHANDLEGPUSWITCHANGLEPROC) (EGLDisplay dpy); +typedef void(EGLAPIENTRYP PFNEGLFORCEGPUSWITCHANGLEPROC) (EGLDisplay dpy, EGLint gpuIDHigh, EGLint gpuIDLow); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI void EGLAPIENTRY eglReleaseHighPowerGPUANGLE(EGLDisplay dpy, EGLContext ctx); +EGLAPI void EGLAPIENTRY eglReacquireHighPowerGPUANGLE(EGLDisplay dpy, EGLContext ctx); +EGLAPI void EGLAPIENTRY eglHandleGPUSwitchANGLE(EGLDisplay dpy); +EGLAPI void EGLAPIENTRY eglForceGPUSwitchANGLE(EGLDisplay dpy, EGLint gpuIDHigh, EGLint gpuIDLow); +#endif +#endif /* EGL_ANGLE_power_preference */ + +#ifndef EGL_ANGLE_feature_control +#define EGL_ANGLE_feature_control 1 +#define EGL_FEATURE_NAME_ANGLE 0x3460 +#define EGL_FEATURE_CATEGORY_ANGLE 0x3461 +#define EGL_FEATURE_DESCRIPTION_ANGLE 0x3462 +#define EGL_FEATURE_BUG_ANGLE 0x3463 +#define EGL_FEATURE_STATUS_ANGLE 0x3464 +#define EGL_FEATURE_COUNT_ANGLE 0x3465 +#define EGL_FEATURE_OVERRIDES_ENABLED_ANGLE 0x3466 +#define EGL_FEATURE_OVERRIDES_DISABLED_ANGLE 0x3467 +#define EGL_FEATURE_CONDITION_ANGLE 0x3468 +#define EGL_FEATURE_ALL_DISABLED_ANGLE 0x3469 +typedef const char *(EGLAPIENTRYP PFNEGLQUERYSTRINGIANGLEPROC) (EGLDisplay dpy, EGLint name, EGLint index); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDISPLAYATTRIBANGLEPROC) (EGLDisplay dpy, EGLint attribute, EGLAttrib *value); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI const char *EGLAPIENTRY eglQueryStringiANGLE(EGLDisplay dpy, EGLint name, EGLint index); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryDisplayAttribANGLE(EGLDisplay dpy, EGLint attribute, EGLAttrib *value); +#endif +#endif /* EGL_ANGLE_feature_control */ + +#ifndef EGL_ANGLE_image_d3d11_texture +#define EGL_D3D11_TEXTURE_ANGLE 0x3484 +#define EGL_TEXTURE_INTERNAL_FORMAT_ANGLE 0x345D +#endif /* EGL_ANGLE_image_d3d11_texture */ + +#ifndef EGL_ANGLE_create_context_backwards_compatible +#define EGL_ANGLE_create_context_backwards_compatible 1 +#define EGL_CONTEXT_OPENGL_BACKWARDS_COMPATIBLE_ANGLE 0x3483 +#endif /* EGL_ANGLE_create_context_backwards_compatible */ + +#ifndef EGL_ANGLE_device_cgl +#define EGL_ANGLE_device_cgl 1 +#define EGL_CGL_CONTEXT_ANGLE 0x3485 +#define EGL_CGL_PIXEL_FORMAT_ANGLE 0x3486 +#endif + +#ifndef EGL_ANGLE_ggp_stream_descriptor +#define EGL_ANGLE_ggp_stream_descriptor 1 +#define EGL_GGP_STREAM_DESCRIPTOR_ANGLE 0x348B +#endif /* EGL_ANGLE_ggp_stream_descriptor */ + +#ifndef EGL_ANGLE_swap_with_frame_token +#define EGL_ANGLE_swap_with_frame_token 1 +typedef khronos_uint64_t EGLFrameTokenANGLE; +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSWITHFRAMETOKENANGLEPROC)(EGLDisplay dpy, EGLSurface surface, EGLFrameTokenANGLE frametoken); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithFrameTokenANGLE(EGLDisplay dpy, EGLSurface surface, EGLFrameTokenANGLE frametoken); +#endif +#endif /* EGL_ANGLE_swap_with_frame_token */ + +#ifndef EGL_ANGLE_prepare_swap_buffers +#define EGL_ANGLE_prepare_swap_buffers 1 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLPREPARESWAPBUFFERSANGLEPROC)(EGLDisplay dpy, EGLSurface surface); +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglPrepareSwapBuffersANGLE(EGLDisplay dpy, EGLSurface surface); +#endif +#endif /* EGL_ANGLE_prepare_swap_buffers */ + +#ifndef EGL_ANGLE_device_eagl +#define EGL_ANGLE_device_eagl 1 +#define EGL_EAGL_CONTEXT_ANGLE 0x348C +#endif + +#ifndef EGL_ANGLE_device_metal +#define EGL_ANGLE_device_metal 1 +#define EGL_METAL_DEVICE_ANGLE 0x34A6 +#endif /* EGL_ANGLE_device_metal */ + +#ifndef EGL_ANGLE_display_semaphore_share_group +#define EGL_ANGLE_display_semaphore_share_group 1 +#define EGL_DISPLAY_SEMAPHORE_SHARE_GROUP_ANGLE 0x348D +#endif /* EGL_ANGLE_display_semaphore_share_group */ + +#ifndef EGL_ANGLE_external_context_and_surface +#define EGL_ANGLE_external_context_and_surface 1 +#define EGL_EXTERNAL_CONTEXT_ANGLE 0x348E +#define EGL_EXTERNAL_SURFACE_ANGLE 0x348F +#define EGL_EXTERNAL_CONTEXT_SAVE_STATE_ANGLE 0x3490 +#endif /* EGL_ANGLE_external_context_and_surface */ + +#ifndef EGL_ANGLE_create_surface_swap_interval +#define EGL_ANGLE_create_surface_swap_interval 1 +#define EGL_SWAP_INTERVAL_ANGLE 0x322F +#endif /* EGL_ANGLE_create_surface_swap_interval */ + +#ifndef EGL_ANGLE_device_vulkan +#define EGL_ANGLE_device_vulkan 1 +#define EGL_VULKAN_VERSION_ANGLE 0x34A8 +#define EGL_VULKAN_INSTANCE_ANGLE 0x34A9 +#define EGL_VULKAN_INSTANCE_EXTENSIONS_ANGLE 0x34AA +#define EGL_VULKAN_PHYSICAL_DEVICE_ANGLE 0x34AB +#define EGL_VULKAN_DEVICE_ANGLE 0x34AC +#define EGL_VULKAN_DEVICE_EXTENSIONS_ANGLE 0x34AD +#define EGL_VULKAN_FEATURES_ANGLE 0x34AE +#define EGL_VULKAN_QUEUE_ANGLE 0x34AF +#define EGL_VULKAN_QUEUE_FAMILIY_INDEX_ANGLE 0x34D0 +#define EGL_VULKAN_GET_INSTANCE_PROC_ADDR 0x34D1 +#endif /* EGL_ANGLE_device_vulkan */ + +#ifndef EGL_ANGLE_vulkan_image +#define EGL_ANGLE_vulkan_image +#define EGL_VULKAN_IMAGE_ANGLE 0x34D3 +#define EGL_VULKAN_IMAGE_CREATE_INFO_HI_ANGLE 0x34D4 +#define EGL_VULKAN_IMAGE_CREATE_INFO_LO_ANGLE 0x34D5 +typedef EGLBoolean (EGLAPIENTRYP PFNEGLEXPORTVKIMAGEANGLEPROC)(EGLDisplay dpy, EGLImage image, void* vk_image, void* vk_image_create_info); +#endif /* EGL_ANGLE_vulkan_image */ + +#ifndef EGL_ANGLE_metal_shared_event_sync +#define EGL_ANGLE_metal_hared_event_sync 1 +#define EGL_SYNC_METAL_SHARED_EVENT_ANGLE 0x34D8 +#define EGL_SYNC_METAL_SHARED_EVENT_OBJECT_ANGLE 0x34D9 +#define EGL_SYNC_METAL_SHARED_EVENT_SIGNAL_VALUE_LO_ANGLE 0x34DA +#define EGL_SYNC_METAL_SHARED_EVENT_SIGNAL_VALUE_HI_ANGLE 0x34DB +typedef void* (EGLAPIENTRYP PFNEGLCOPYMETALSHAREDEVENTANGLEPROC)(EGLDisplay dpy, EGLSyncKHR sync); +#endif /* EGL_ANGLE_metal_shared_event_sync */ + +// clang-format on + +#endif // INCLUDE_EGL_EGLEXT_ANGLE_ diff --git a/gfx/angle/checkout/include/EGL/eglplatform.h b/gfx/angle/checkout/include/EGL/eglplatform.h new file mode 100644 index 0000000000..777e985588 --- /dev/null +++ b/gfx/angle/checkout/include/EGL/eglplatform.h @@ -0,0 +1,175 @@ +#ifndef __eglplatform_h_ +#define __eglplatform_h_ + +/* +** Copyright 2007-2020 The Khronos Group Inc. +** SPDX-License-Identifier: Apache-2.0 +*/ + +/* Platform-specific types and definitions for egl.h + * + * Adopters may modify khrplatform.h and this file to suit their platform. + * You are encouraged to submit all modifications to the Khronos group so that + * they can be included in future versions of this file. Please submit changes + * by filing an issue or pull request on the public Khronos EGL Registry, at + * https://www.github.com/KhronosGroup/EGL-Registry/ + */ + +#include + +/* Macros used in EGL function prototype declarations. + * + * EGL functions should be prototyped as: + * + * EGLAPI return-type EGLAPIENTRY eglFunction(arguments); + * typedef return-type (EXPAPIENTRYP PFNEGLFUNCTIONPROC) (arguments); + * + * KHRONOS_APICALL and KHRONOS_APIENTRY are defined in KHR/khrplatform.h + */ + +#ifndef EGLAPI +#define EGLAPI KHRONOS_APICALL +#endif + +#ifndef EGLAPIENTRY +#define EGLAPIENTRY KHRONOS_APIENTRY +#endif +#define EGLAPIENTRYP EGLAPIENTRY* + +/* The types NativeDisplayType, NativeWindowType, and NativePixmapType + * are aliases of window-system-dependent types, such as X Display * or + * Windows Device Context. They must be defined in platform-specific + * code below. The EGL-prefixed versions of Native*Type are the same + * types, renamed in EGL 1.3 so all types in the API start with "EGL". + * + * Khronos STRONGLY RECOMMENDS that you use the default definitions + * provided below, since these changes affect both binary and source + * portability of applications using EGL running on different EGL + * implementations. + */ + +#if defined(EGL_NO_PLATFORM_SPECIFIC_TYPES) + +typedef void *EGLNativeDisplayType; +typedef void *EGLNativePixmapType; +typedef void *EGLNativeWindowType; + +#elif defined(_WIN32) || defined(__VC32__) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) /* Win32 and WinCE */ +#ifndef WIN32_LEAN_AND_MEAN +#define WIN32_LEAN_AND_MEAN 1 +#endif +#include + +typedef HDC EGLNativeDisplayType; +typedef HBITMAP EGLNativePixmapType; + +#if !defined(WINAPI_FAMILY) || (WINAPI_FAMILY == WINAPI_FAMILY_DESKTOP_APP) /* Windows Desktop */ +typedef HWND EGLNativeWindowType; +#else /* Windows Store */ +#include +typedef IInspectable* EGLNativeWindowType; +#endif + +#elif defined(__EMSCRIPTEN__) + +typedef int EGLNativeDisplayType; +typedef int EGLNativePixmapType; +typedef int EGLNativeWindowType; + +#elif defined(__WINSCW__) || defined(__SYMBIAN32__) /* Symbian */ + +typedef int EGLNativeDisplayType; +typedef void *EGLNativePixmapType; +typedef void *EGLNativeWindowType; + +#elif defined(WL_EGL_PLATFORM) + +typedef struct wl_display *EGLNativeDisplayType; +typedef struct wl_egl_pixmap *EGLNativePixmapType; +typedef struct wl_egl_window *EGLNativeWindowType; + +#elif defined(__GBM__) + +typedef struct gbm_device *EGLNativeDisplayType; +typedef struct gbm_bo *EGLNativePixmapType; +typedef void *EGLNativeWindowType; + +#elif defined(__ANDROID__) || defined(ANDROID) + +struct ANativeWindow; +struct egl_native_pixmap_t; + +typedef void* EGLNativeDisplayType; +typedef struct egl_native_pixmap_t* EGLNativePixmapType; +typedef struct ANativeWindow* EGLNativeWindowType; + +#elif defined(USE_OZONE) + +typedef intptr_t EGLNativeDisplayType; +typedef intptr_t EGLNativePixmapType; +typedef intptr_t EGLNativeWindowType; + +#elif defined(USE_X11) + +/* X11 (tentative) */ +#include +#include + +typedef Display *EGLNativeDisplayType; +typedef Pixmap EGLNativePixmapType; +typedef Window EGLNativeWindowType; + +#elif defined(__unix__) + +typedef void *EGLNativeDisplayType; +typedef khronos_uintptr_t EGLNativePixmapType; +typedef khronos_uintptr_t EGLNativeWindowType; + +#elif defined(__APPLE__) + +typedef int EGLNativeDisplayType; +typedef void *EGLNativePixmapType; +typedef void *EGLNativeWindowType; + +#elif defined(__HAIKU__) + +#include + +typedef void *EGLNativeDisplayType; +typedef khronos_uintptr_t EGLNativePixmapType; +typedef khronos_uintptr_t EGLNativeWindowType; + +#elif defined(__Fuchsia__) + +typedef void *EGLNativeDisplayType; +typedef khronos_uintptr_t EGLNativePixmapType; +typedef khronos_uintptr_t EGLNativeWindowType; + +#else +#error "Platform not recognized" +#endif + +/* EGL 1.2 types, renamed for consistency in EGL 1.3 */ +typedef EGLNativeDisplayType NativeDisplayType; +typedef EGLNativePixmapType NativePixmapType; +typedef EGLNativeWindowType NativeWindowType; + + +/* Define EGLint. This must be a signed integral type large enough to contain + * all legal attribute names and values passed into and out of EGL, whether + * their type is boolean, bitmask, enumerant (symbolic constant), integer, + * handle, or other. While in general a 32-bit integer will suffice, if + * handles are 64 bit types, then EGLint should be defined as a signed 64-bit + * integer type. + */ +typedef khronos_int32_t EGLint; + + +/* C++ / C typecast macros for special EGL handle values */ +#if defined(__cplusplus) +#define EGL_CAST(type, value) (static_cast(value)) +#else +#define EGL_CAST(type, value) ((type) (value)) +#endif + +#endif /* __eglplatform_h */ diff --git a/gfx/angle/checkout/include/GLES/gl.h b/gfx/angle/checkout/include/GLES/gl.h new file mode 100644 index 0000000000..9f3ed3438a --- /dev/null +++ b/gfx/angle/checkout/include/GLES/gl.h @@ -0,0 +1,743 @@ +#ifndef __gles1_gl_h_ +#define __gles1_gl_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright (c) 2013-2018 The Khronos Group Inc. +** +** Permission is hereby granted, free of charge, to any person obtaining a +** copy of this software and/or associated documentation files (the +** "Materials"), to deal in the Materials without restriction, including +** without limitation the rights to use, copy, modify, merge, publish, +** distribute, sublicense, and/or sell copies of the Materials, and to +** permit persons to whom the Materials are furnished to do so, subject to +** the following conditions: +** +** The above copyright notice and this permission notice shall be included +** in all copies or substantial portions of the Materials. +** +** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. +*/ +/* +** This header is generated from the Khronos OpenGL / OpenGL ES XML +** API Registry. The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** https://github.com/KhronosGroup/OpenGL-Registry +*/ + +#include + +#ifndef GL_APIENTRYP +#define GL_APIENTRYP GL_APIENTRY* +#endif + +/* Generated on date 20181204 */ + +/* Generated C header for: + * API: gles1 + * Profile: common + * Versions considered: .* + * Versions emitted: .* + * Default extensions included: None + * Additional extensions included: ^(GL_OES_read_format|GL_OES_compressed_paletted_texture|GL_OES_point_size_array|GL_OES_point_sprite)$ + * Extensions removed: _nomatch_^ + */ + +#ifndef GL_VERSION_ES_CM_1_0 +#define GL_VERSION_ES_CM_1_0 1 +#include +typedef khronos_int8_t GLbyte; +typedef khronos_float_t GLclampf; +typedef khronos_int16_t GLshort; +typedef khronos_uint16_t GLushort; +typedef void GLvoid; +typedef unsigned int GLenum; +typedef khronos_float_t GLfloat; +typedef khronos_int32_t GLfixed; +typedef unsigned int GLuint; +typedef khronos_ssize_t GLsizeiptr; +typedef khronos_intptr_t GLintptr; +typedef unsigned int GLbitfield; +typedef int GLint; +typedef khronos_uint8_t GLubyte; +typedef unsigned char GLboolean; +typedef int GLsizei; +typedef khronos_int32_t GLclampx; +#define GL_VERSION_ES_CL_1_0 1 +#define GL_VERSION_ES_CM_1_1 1 +#define GL_VERSION_ES_CL_1_1 1 +#define GL_DEPTH_BUFFER_BIT 0x00000100 +#define GL_STENCIL_BUFFER_BIT 0x00000400 +#define GL_COLOR_BUFFER_BIT 0x00004000 +#define GL_FALSE 0 +#define GL_TRUE 1 +#define GL_POINTS 0x0000 +#define GL_LINES 0x0001 +#define GL_LINE_LOOP 0x0002 +#define GL_LINE_STRIP 0x0003 +#define GL_TRIANGLES 0x0004 +#define GL_TRIANGLE_STRIP 0x0005 +#define GL_TRIANGLE_FAN 0x0006 +#define GL_NEVER 0x0200 +#define GL_LESS 0x0201 +#define GL_EQUAL 0x0202 +#define GL_LEQUAL 0x0203 +#define GL_GREATER 0x0204 +#define GL_NOTEQUAL 0x0205 +#define GL_GEQUAL 0x0206 +#define GL_ALWAYS 0x0207 +#define GL_ZERO 0 +#define GL_ONE 1 +#define GL_SRC_COLOR 0x0300 +#define GL_ONE_MINUS_SRC_COLOR 0x0301 +#define GL_SRC_ALPHA 0x0302 +#define GL_ONE_MINUS_SRC_ALPHA 0x0303 +#define GL_DST_ALPHA 0x0304 +#define GL_ONE_MINUS_DST_ALPHA 0x0305 +#define GL_DST_COLOR 0x0306 +#define GL_ONE_MINUS_DST_COLOR 0x0307 +#define GL_SRC_ALPHA_SATURATE 0x0308 +#define GL_CLIP_PLANE0 0x3000 +#define GL_CLIP_PLANE1 0x3001 +#define GL_CLIP_PLANE2 0x3002 +#define GL_CLIP_PLANE3 0x3003 +#define GL_CLIP_PLANE4 0x3004 +#define GL_CLIP_PLANE5 0x3005 +#define GL_FRONT 0x0404 +#define GL_BACK 0x0405 +#define GL_FRONT_AND_BACK 0x0408 +#define GL_FOG 0x0B60 +#define GL_LIGHTING 0x0B50 +#define GL_TEXTURE_2D 0x0DE1 +#define GL_CULL_FACE 0x0B44 +#define GL_ALPHA_TEST 0x0BC0 +#define GL_BLEND 0x0BE2 +#define GL_COLOR_LOGIC_OP 0x0BF2 +#define GL_DITHER 0x0BD0 +#define GL_STENCIL_TEST 0x0B90 +#define GL_DEPTH_TEST 0x0B71 +#define GL_POINT_SMOOTH 0x0B10 +#define GL_LINE_SMOOTH 0x0B20 +#define GL_SCISSOR_TEST 0x0C11 +#define GL_COLOR_MATERIAL 0x0B57 +#define GL_NORMALIZE 0x0BA1 +#define GL_RESCALE_NORMAL 0x803A +#define GL_VERTEX_ARRAY 0x8074 +#define GL_NORMAL_ARRAY 0x8075 +#define GL_COLOR_ARRAY 0x8076 +#define GL_TEXTURE_COORD_ARRAY 0x8078 +#define GL_MULTISAMPLE 0x809D +#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E +#define GL_SAMPLE_ALPHA_TO_ONE 0x809F +#define GL_SAMPLE_COVERAGE 0x80A0 +#define GL_NO_ERROR 0 +#define GL_INVALID_ENUM 0x0500 +#define GL_INVALID_VALUE 0x0501 +#define GL_INVALID_OPERATION 0x0502 +#define GL_STACK_OVERFLOW 0x0503 +#define GL_STACK_UNDERFLOW 0x0504 +#define GL_OUT_OF_MEMORY 0x0505 +#define GL_EXP 0x0800 +#define GL_EXP2 0x0801 +#define GL_FOG_DENSITY 0x0B62 +#define GL_FOG_START 0x0B63 +#define GL_FOG_END 0x0B64 +#define GL_FOG_MODE 0x0B65 +#define GL_FOG_COLOR 0x0B66 +#define GL_CW 0x0900 +#define GL_CCW 0x0901 +#define GL_CURRENT_COLOR 0x0B00 +#define GL_CURRENT_NORMAL 0x0B02 +#define GL_CURRENT_TEXTURE_COORDS 0x0B03 +#define GL_POINT_SIZE 0x0B11 +#define GL_POINT_SIZE_MIN 0x8126 +#define GL_POINT_SIZE_MAX 0x8127 +#define GL_POINT_FADE_THRESHOLD_SIZE 0x8128 +#define GL_POINT_DISTANCE_ATTENUATION 0x8129 +#define GL_SMOOTH_POINT_SIZE_RANGE 0x0B12 +#define GL_LINE_WIDTH 0x0B21 +#define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22 +#define GL_ALIASED_POINT_SIZE_RANGE 0x846D +#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E +#define GL_CULL_FACE_MODE 0x0B45 +#define GL_FRONT_FACE 0x0B46 +#define GL_SHADE_MODEL 0x0B54 +#define GL_DEPTH_RANGE 0x0B70 +#define GL_DEPTH_WRITEMASK 0x0B72 +#define GL_DEPTH_CLEAR_VALUE 0x0B73 +#define GL_DEPTH_FUNC 0x0B74 +#define GL_STENCIL_CLEAR_VALUE 0x0B91 +#define GL_STENCIL_FUNC 0x0B92 +#define GL_STENCIL_VALUE_MASK 0x0B93 +#define GL_STENCIL_FAIL 0x0B94 +#define GL_STENCIL_PASS_DEPTH_FAIL 0x0B95 +#define GL_STENCIL_PASS_DEPTH_PASS 0x0B96 +#define GL_STENCIL_REF 0x0B97 +#define GL_STENCIL_WRITEMASK 0x0B98 +#define GL_MATRIX_MODE 0x0BA0 +#define GL_VIEWPORT 0x0BA2 +#define GL_MODELVIEW_STACK_DEPTH 0x0BA3 +#define GL_PROJECTION_STACK_DEPTH 0x0BA4 +#define GL_TEXTURE_STACK_DEPTH 0x0BA5 +#define GL_MODELVIEW_MATRIX 0x0BA6 +#define GL_PROJECTION_MATRIX 0x0BA7 +#define GL_TEXTURE_MATRIX 0x0BA8 +#define GL_ALPHA_TEST_FUNC 0x0BC1 +#define GL_ALPHA_TEST_REF 0x0BC2 +#define GL_BLEND_DST 0x0BE0 +#define GL_BLEND_SRC 0x0BE1 +#define GL_LOGIC_OP_MODE 0x0BF0 +#define GL_SCISSOR_BOX 0x0C10 +#define GL_COLOR_CLEAR_VALUE 0x0C22 +#define GL_COLOR_WRITEMASK 0x0C23 +#define GL_MAX_LIGHTS 0x0D31 +#define GL_MAX_CLIP_PLANES 0x0D32 +#define GL_MAX_TEXTURE_SIZE 0x0D33 +#define GL_MAX_MODELVIEW_STACK_DEPTH 0x0D36 +#define GL_MAX_PROJECTION_STACK_DEPTH 0x0D38 +#define GL_MAX_TEXTURE_STACK_DEPTH 0x0D39 +#define GL_MAX_VIEWPORT_DIMS 0x0D3A +#define GL_MAX_TEXTURE_UNITS 0x84E2 +#define GL_SUBPIXEL_BITS 0x0D50 +#define GL_RED_BITS 0x0D52 +#define GL_GREEN_BITS 0x0D53 +#define GL_BLUE_BITS 0x0D54 +#define GL_ALPHA_BITS 0x0D55 +#define GL_DEPTH_BITS 0x0D56 +#define GL_STENCIL_BITS 0x0D57 +#define GL_POLYGON_OFFSET_UNITS 0x2A00 +#define GL_POLYGON_OFFSET_FILL 0x8037 +#define GL_POLYGON_OFFSET_FACTOR 0x8038 +#define GL_TEXTURE_BINDING_2D 0x8069 +#define GL_VERTEX_ARRAY_SIZE 0x807A +#define GL_VERTEX_ARRAY_TYPE 0x807B +#define GL_VERTEX_ARRAY_STRIDE 0x807C +#define GL_NORMAL_ARRAY_TYPE 0x807E +#define GL_NORMAL_ARRAY_STRIDE 0x807F +#define GL_COLOR_ARRAY_SIZE 0x8081 +#define GL_COLOR_ARRAY_TYPE 0x8082 +#define GL_COLOR_ARRAY_STRIDE 0x8083 +#define GL_TEXTURE_COORD_ARRAY_SIZE 0x8088 +#define GL_TEXTURE_COORD_ARRAY_TYPE 0x8089 +#define GL_TEXTURE_COORD_ARRAY_STRIDE 0x808A +#define GL_VERTEX_ARRAY_POINTER 0x808E +#define GL_NORMAL_ARRAY_POINTER 0x808F +#define GL_COLOR_ARRAY_POINTER 0x8090 +#define GL_TEXTURE_COORD_ARRAY_POINTER 0x8092 +#define GL_SAMPLE_BUFFERS 0x80A8 +#define GL_SAMPLES 0x80A9 +#define GL_SAMPLE_COVERAGE_VALUE 0x80AA +#define GL_SAMPLE_COVERAGE_INVERT 0x80AB +#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 +#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 +#define GL_DONT_CARE 0x1100 +#define GL_FASTEST 0x1101 +#define GL_NICEST 0x1102 +#define GL_PERSPECTIVE_CORRECTION_HINT 0x0C50 +#define GL_POINT_SMOOTH_HINT 0x0C51 +#define GL_LINE_SMOOTH_HINT 0x0C52 +#define GL_FOG_HINT 0x0C54 +#define GL_GENERATE_MIPMAP_HINT 0x8192 +#define GL_LIGHT_MODEL_AMBIENT 0x0B53 +#define GL_LIGHT_MODEL_TWO_SIDE 0x0B52 +#define GL_AMBIENT 0x1200 +#define GL_DIFFUSE 0x1201 +#define GL_SPECULAR 0x1202 +#define GL_POSITION 0x1203 +#define GL_SPOT_DIRECTION 0x1204 +#define GL_SPOT_EXPONENT 0x1205 +#define GL_SPOT_CUTOFF 0x1206 +#define GL_CONSTANT_ATTENUATION 0x1207 +#define GL_LINEAR_ATTENUATION 0x1208 +#define GL_QUADRATIC_ATTENUATION 0x1209 +#define GL_BYTE 0x1400 +#define GL_UNSIGNED_BYTE 0x1401 +#define GL_SHORT 0x1402 +#define GL_UNSIGNED_SHORT 0x1403 +#define GL_FLOAT 0x1406 +#define GL_FIXED 0x140C +#define GL_CLEAR 0x1500 +#define GL_AND 0x1501 +#define GL_AND_REVERSE 0x1502 +#define GL_COPY 0x1503 +#define GL_AND_INVERTED 0x1504 +#define GL_NOOP 0x1505 +#define GL_XOR 0x1506 +#define GL_OR 0x1507 +#define GL_NOR 0x1508 +#define GL_EQUIV 0x1509 +#define GL_INVERT 0x150A +#define GL_OR_REVERSE 0x150B +#define GL_COPY_INVERTED 0x150C +#define GL_OR_INVERTED 0x150D +#define GL_NAND 0x150E +#define GL_SET 0x150F +#define GL_EMISSION 0x1600 +#define GL_SHININESS 0x1601 +#define GL_AMBIENT_AND_DIFFUSE 0x1602 +#define GL_MODELVIEW 0x1700 +#define GL_PROJECTION 0x1701 +#define GL_TEXTURE 0x1702 +#define GL_ALPHA 0x1906 +#define GL_RGB 0x1907 +#define GL_RGBA 0x1908 +#define GL_LUMINANCE 0x1909 +#define GL_LUMINANCE_ALPHA 0x190A +#define GL_UNPACK_ALIGNMENT 0x0CF5 +#define GL_PACK_ALIGNMENT 0x0D05 +#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033 +#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034 +#define GL_UNSIGNED_SHORT_5_6_5 0x8363 +#define GL_FLAT 0x1D00 +#define GL_SMOOTH 0x1D01 +#define GL_KEEP 0x1E00 +#define GL_REPLACE 0x1E01 +#define GL_INCR 0x1E02 +#define GL_DECR 0x1E03 +#define GL_VENDOR 0x1F00 +#define GL_RENDERER 0x1F01 +#define GL_VERSION 0x1F02 +#define GL_EXTENSIONS 0x1F03 +#define GL_MODULATE 0x2100 +#define GL_DECAL 0x2101 +#define GL_ADD 0x0104 +#define GL_TEXTURE_ENV_MODE 0x2200 +#define GL_TEXTURE_ENV_COLOR 0x2201 +#define GL_TEXTURE_ENV 0x2300 +#define GL_NEAREST 0x2600 +#define GL_LINEAR 0x2601 +#define GL_NEAREST_MIPMAP_NEAREST 0x2700 +#define GL_LINEAR_MIPMAP_NEAREST 0x2701 +#define GL_NEAREST_MIPMAP_LINEAR 0x2702 +#define GL_LINEAR_MIPMAP_LINEAR 0x2703 +#define GL_TEXTURE_MAG_FILTER 0x2800 +#define GL_TEXTURE_MIN_FILTER 0x2801 +#define GL_TEXTURE_WRAP_S 0x2802 +#define GL_TEXTURE_WRAP_T 0x2803 +#define GL_GENERATE_MIPMAP 0x8191 +#define GL_TEXTURE0 0x84C0 +#define GL_TEXTURE1 0x84C1 +#define GL_TEXTURE2 0x84C2 +#define GL_TEXTURE3 0x84C3 +#define GL_TEXTURE4 0x84C4 +#define GL_TEXTURE5 0x84C5 +#define GL_TEXTURE6 0x84C6 +#define GL_TEXTURE7 0x84C7 +#define GL_TEXTURE8 0x84C8 +#define GL_TEXTURE9 0x84C9 +#define GL_TEXTURE10 0x84CA +#define GL_TEXTURE11 0x84CB +#define GL_TEXTURE12 0x84CC +#define GL_TEXTURE13 0x84CD +#define GL_TEXTURE14 0x84CE +#define GL_TEXTURE15 0x84CF +#define GL_TEXTURE16 0x84D0 +#define GL_TEXTURE17 0x84D1 +#define GL_TEXTURE18 0x84D2 +#define GL_TEXTURE19 0x84D3 +#define GL_TEXTURE20 0x84D4 +#define GL_TEXTURE21 0x84D5 +#define GL_TEXTURE22 0x84D6 +#define GL_TEXTURE23 0x84D7 +#define GL_TEXTURE24 0x84D8 +#define GL_TEXTURE25 0x84D9 +#define GL_TEXTURE26 0x84DA +#define GL_TEXTURE27 0x84DB +#define GL_TEXTURE28 0x84DC +#define GL_TEXTURE29 0x84DD +#define GL_TEXTURE30 0x84DE +#define GL_TEXTURE31 0x84DF +#define GL_ACTIVE_TEXTURE 0x84E0 +#define GL_CLIENT_ACTIVE_TEXTURE 0x84E1 +#define GL_REPEAT 0x2901 +#define GL_CLAMP_TO_EDGE 0x812F +#define GL_LIGHT0 0x4000 +#define GL_LIGHT1 0x4001 +#define GL_LIGHT2 0x4002 +#define GL_LIGHT3 0x4003 +#define GL_LIGHT4 0x4004 +#define GL_LIGHT5 0x4005 +#define GL_LIGHT6 0x4006 +#define GL_LIGHT7 0x4007 +#define GL_ARRAY_BUFFER 0x8892 +#define GL_ELEMENT_ARRAY_BUFFER 0x8893 +#define GL_ARRAY_BUFFER_BINDING 0x8894 +#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895 +#define GL_VERTEX_ARRAY_BUFFER_BINDING 0x8896 +#define GL_NORMAL_ARRAY_BUFFER_BINDING 0x8897 +#define GL_COLOR_ARRAY_BUFFER_BINDING 0x8898 +#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING 0x889A +#define GL_STATIC_DRAW 0x88E4 +#define GL_DYNAMIC_DRAW 0x88E8 +#define GL_BUFFER_SIZE 0x8764 +#define GL_BUFFER_USAGE 0x8765 +#define GL_SUBTRACT 0x84E7 +#define GL_COMBINE 0x8570 +#define GL_COMBINE_RGB 0x8571 +#define GL_COMBINE_ALPHA 0x8572 +#define GL_RGB_SCALE 0x8573 +#define GL_ADD_SIGNED 0x8574 +#define GL_INTERPOLATE 0x8575 +#define GL_CONSTANT 0x8576 +#define GL_PRIMARY_COLOR 0x8577 +#define GL_PREVIOUS 0x8578 +#define GL_OPERAND0_RGB 0x8590 +#define GL_OPERAND1_RGB 0x8591 +#define GL_OPERAND2_RGB 0x8592 +#define GL_OPERAND0_ALPHA 0x8598 +#define GL_OPERAND1_ALPHA 0x8599 +#define GL_OPERAND2_ALPHA 0x859A +#define GL_ALPHA_SCALE 0x0D1C +#define GL_SRC0_RGB 0x8580 +#define GL_SRC1_RGB 0x8581 +#define GL_SRC2_RGB 0x8582 +#define GL_SRC0_ALPHA 0x8588 +#define GL_SRC1_ALPHA 0x8589 +#define GL_SRC2_ALPHA 0x858A +#define GL_DOT3_RGB 0x86AE +#define GL_DOT3_RGBA 0x86AF +typedef void (GL_APIENTRYP PFNGLALPHAFUNCPROC) (GLenum func, GLfloat ref); +typedef void (GL_APIENTRYP PFNGLCLEARCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLCLEARDEPTHFPROC) (GLfloat d); +typedef void (GL_APIENTRYP PFNGLCLIPPLANEFPROC) (GLenum p, const GLfloat *eqn); +typedef void (GL_APIENTRYP PFNGLCOLOR4FPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEFPROC) (GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLFOGFPROC) (GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLFOGFVPROC) (GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLFRUSTUMFPROC) (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLGETCLIPPLANEFPROC) (GLenum plane, GLfloat *equation); +typedef void (GL_APIENTRYP PFNGLGETFLOATVPROC) (GLenum pname, GLfloat *data); +typedef void (GL_APIENTRYP PFNGLGETLIGHTFVPROC) (GLenum light, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETMATERIALFVPROC) (GLenum face, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETTEXENVFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLLIGHTMODELFPROC) (GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLLIGHTMODELFVPROC) (GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLLIGHTFPROC) (GLenum light, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLLIGHTFVPROC) (GLenum light, GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLLINEWIDTHPROC) (GLfloat width); +typedef void (GL_APIENTRYP PFNGLLOADMATRIXFPROC) (const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATERIALFPROC) (GLenum face, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLMATERIALFVPROC) (GLenum face, GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLMULTMATRIXFPROC) (const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMULTITEXCOORD4FPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q); +typedef void (GL_APIENTRYP PFNGLNORMAL3FPROC) (GLfloat nx, GLfloat ny, GLfloat nz); +typedef void (GL_APIENTRYP PFNGLORTHOFPROC) (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLPOINTPARAMETERFPROC) (GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLPOINTPARAMETERFVPROC) (GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLPOINTSIZEPROC) (GLfloat size); +typedef void (GL_APIENTRYP PFNGLPOLYGONOFFSETPROC) (GLfloat factor, GLfloat units); +typedef void (GL_APIENTRYP PFNGLROTATEFPROC) (GLfloat angle, GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLSCALEFPROC) (GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLTEXENVFPROC) (GLenum target, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLTEXENVFVPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFPROC) (GLenum target, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLTRANSLATEFPROC) (GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); +typedef void (GL_APIENTRYP PFNGLALPHAFUNCXPROC) (GLenum func, GLfixed ref); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERPROC) (GLenum target, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLBINDTEXTUREPROC) (GLenum target, GLuint texture); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCPROC) (GLenum sfactor, GLenum dfactor); +typedef void (GL_APIENTRYP PFNGLBUFFERDATAPROC) (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +typedef void (GL_APIENTRYP PFNGLBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +typedef void (GL_APIENTRYP PFNGLCLEARPROC) (GLbitfield mask); +typedef void (GL_APIENTRYP PFNGLCLEARCOLORXPROC) (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha); +typedef void (GL_APIENTRYP PFNGLCLEARDEPTHXPROC) (GLfixed depth); +typedef void (GL_APIENTRYP PFNGLCLEARSTENCILPROC) (GLint s); +typedef void (GL_APIENTRYP PFNGLCLIENTACTIVETEXTUREPROC) (GLenum texture); +typedef void (GL_APIENTRYP PFNGLCLIPPLANEXPROC) (GLenum plane, const GLfixed *equation); +typedef void (GL_APIENTRYP PFNGLCOLOR4UBPROC) (GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha); +typedef void (GL_APIENTRYP PFNGLCOLOR4XPROC) (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha); +typedef void (GL_APIENTRYP PFNGLCOLORMASKPROC) (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +typedef void (GL_APIENTRYP PFNGLCOLORPOINTERPROC) (GLint size, GLenum type, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOPYTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLCULLFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLDELETEBUFFERSPROC) (GLsizei n, const GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLDELETETEXTURESPROC) (GLsizei n, const GLuint *textures); +typedef void (GL_APIENTRYP PFNGLDEPTHFUNCPROC) (GLenum func); +typedef void (GL_APIENTRYP PFNGLDEPTHMASKPROC) (GLboolean flag); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEXPROC) (GLfixed n, GLfixed f); +typedef void (GL_APIENTRYP PFNGLDISABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLDISABLECLIENTSTATEPROC) (GLenum array); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSPROC) (GLenum mode, GLint first, GLsizei count); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices); +typedef void (GL_APIENTRYP PFNGLENABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLENABLECLIENTSTATEPROC) (GLenum array); +typedef void (GL_APIENTRYP PFNGLFINISHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFLUSHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFOGXPROC) (GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLFOGXVPROC) (GLenum pname, const GLfixed *param); +typedef void (GL_APIENTRYP PFNGLFRONTFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLFRUSTUMXPROC) (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f); +typedef void (GL_APIENTRYP PFNGLGETBOOLEANVPROC) (GLenum pname, GLboolean *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETCLIPPLANEXPROC) (GLenum plane, GLfixed *equation); +typedef void (GL_APIENTRYP PFNGLGENBUFFERSPROC) (GLsizei n, GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLGENTEXTURESPROC) (GLsizei n, GLuint *textures); +typedef GLenum (GL_APIENTRYP PFNGLGETERRORPROC) (void); +typedef void (GL_APIENTRYP PFNGLGETFIXEDVPROC) (GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLGETINTEGERVPROC) (GLenum pname, GLint *data); +typedef void (GL_APIENTRYP PFNGLGETLIGHTXVPROC) (GLenum light, GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLGETMATERIALXVPROC) (GLenum face, GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLGETPOINTERVPROC) (GLenum pname, void **params); +typedef const GLubyte *(GL_APIENTRYP PFNGLGETSTRINGPROC) (GLenum name); +typedef void (GL_APIENTRYP PFNGLGETTEXENVIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXENVXVPROC) (GLenum target, GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERXVPROC) (GLenum target, GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLHINTPROC) (GLenum target, GLenum mode); +typedef GLboolean (GL_APIENTRYP PFNGLISBUFFERPROC) (GLuint buffer); +typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDPROC) (GLenum cap); +typedef GLboolean (GL_APIENTRYP PFNGLISTEXTUREPROC) (GLuint texture); +typedef void (GL_APIENTRYP PFNGLLIGHTMODELXPROC) (GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLLIGHTMODELXVPROC) (GLenum pname, const GLfixed *param); +typedef void (GL_APIENTRYP PFNGLLIGHTXPROC) (GLenum light, GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLLIGHTXVPROC) (GLenum light, GLenum pname, const GLfixed *params); +typedef void (GL_APIENTRYP PFNGLLINEWIDTHXPROC) (GLfixed width); +typedef void (GL_APIENTRYP PFNGLLOADIDENTITYPROC) (void); +typedef void (GL_APIENTRYP PFNGLLOADMATRIXXPROC) (const GLfixed *m); +typedef void (GL_APIENTRYP PFNGLLOGICOPPROC) (GLenum opcode); +typedef void (GL_APIENTRYP PFNGLMATERIALXPROC) (GLenum face, GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLMATERIALXVPROC) (GLenum face, GLenum pname, const GLfixed *param); +typedef void (GL_APIENTRYP PFNGLMATRIXMODEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLMULTMATRIXXPROC) (const GLfixed *m); +typedef void (GL_APIENTRYP PFNGLMULTITEXCOORD4XPROC) (GLenum texture, GLfixed s, GLfixed t, GLfixed r, GLfixed q); +typedef void (GL_APIENTRYP PFNGLNORMAL3XPROC) (GLfixed nx, GLfixed ny, GLfixed nz); +typedef void (GL_APIENTRYP PFNGLNORMALPOINTERPROC) (GLenum type, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLORTHOXPROC) (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f); +typedef void (GL_APIENTRYP PFNGLPIXELSTOREIPROC) (GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLPOINTPARAMETERXPROC) (GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLPOINTPARAMETERXVPROC) (GLenum pname, const GLfixed *params); +typedef void (GL_APIENTRYP PFNGLPOINTSIZEXPROC) (GLfixed size); +typedef void (GL_APIENTRYP PFNGLPOLYGONOFFSETXPROC) (GLfixed factor, GLfixed units); +typedef void (GL_APIENTRYP PFNGLPOPMATRIXPROC) (void); +typedef void (GL_APIENTRYP PFNGLPUSHMATRIXPROC) (void); +typedef void (GL_APIENTRYP PFNGLREADPIXELSPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +typedef void (GL_APIENTRYP PFNGLROTATEXPROC) (GLfixed angle, GLfixed x, GLfixed y, GLfixed z); +typedef void (GL_APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert); +typedef void (GL_APIENTRYP PFNGLSAMPLECOVERAGEXPROC) (GLclampx value, GLboolean invert); +typedef void (GL_APIENTRYP PFNGLSCALEXPROC) (GLfixed x, GLfixed y, GLfixed z); +typedef void (GL_APIENTRYP PFNGLSCISSORPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSHADEMODELPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLSTENCILFUNCPROC) (GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILMASKPROC) (GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILOPPROC) (GLenum fail, GLenum zfail, GLenum zpass); +typedef void (GL_APIENTRYP PFNGLTEXCOORDPOINTERPROC) (GLint size, GLenum type, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLTEXENVIPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLTEXENVXPROC) (GLenum target, GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLTEXENVIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXENVXVPROC) (GLenum target, GLenum pname, const GLfixed *params); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE2DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERXPROC) (GLenum target, GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERXVPROC) (GLenum target, GLenum pname, const GLfixed *params); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTRANSLATEXPROC) (GLfixed x, GLfixed y, GLfixed z); +typedef void (GL_APIENTRYP PFNGLVERTEXPOINTERPROC) (GLint size, GLenum type, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLVIEWPORTPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +#if GL_GLES_PROTOTYPES +GL_API void GL_APIENTRY glAlphaFunc (GLenum func, GLfloat ref); +GL_API void GL_APIENTRY glClearColor (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_API void GL_APIENTRY glClearDepthf (GLfloat d); +GL_API void GL_APIENTRY glClipPlanef (GLenum p, const GLfloat *eqn); +GL_API void GL_APIENTRY glColor4f (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_API void GL_APIENTRY glDepthRangef (GLfloat n, GLfloat f); +GL_API void GL_APIENTRY glFogf (GLenum pname, GLfloat param); +GL_API void GL_APIENTRY glFogfv (GLenum pname, const GLfloat *params); +GL_API void GL_APIENTRY glFrustumf (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f); +GL_API void GL_APIENTRY glGetClipPlanef (GLenum plane, GLfloat *equation); +GL_API void GL_APIENTRY glGetFloatv (GLenum pname, GLfloat *data); +GL_API void GL_APIENTRY glGetLightfv (GLenum light, GLenum pname, GLfloat *params); +GL_API void GL_APIENTRY glGetMaterialfv (GLenum face, GLenum pname, GLfloat *params); +GL_API void GL_APIENTRY glGetTexEnvfv (GLenum target, GLenum pname, GLfloat *params); +GL_API void GL_APIENTRY glGetTexParameterfv (GLenum target, GLenum pname, GLfloat *params); +GL_API void GL_APIENTRY glLightModelf (GLenum pname, GLfloat param); +GL_API void GL_APIENTRY glLightModelfv (GLenum pname, const GLfloat *params); +GL_API void GL_APIENTRY glLightf (GLenum light, GLenum pname, GLfloat param); +GL_API void GL_APIENTRY glLightfv (GLenum light, GLenum pname, const GLfloat *params); +GL_API void GL_APIENTRY glLineWidth (GLfloat width); +GL_API void GL_APIENTRY glLoadMatrixf (const GLfloat *m); +GL_API void GL_APIENTRY glMaterialf (GLenum face, GLenum pname, GLfloat param); +GL_API void GL_APIENTRY glMaterialfv (GLenum face, GLenum pname, const GLfloat *params); +GL_API void GL_APIENTRY glMultMatrixf (const GLfloat *m); +GL_API void GL_APIENTRY glMultiTexCoord4f (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q); +GL_API void GL_APIENTRY glNormal3f (GLfloat nx, GLfloat ny, GLfloat nz); +GL_API void GL_APIENTRY glOrthof (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f); +GL_API void GL_APIENTRY glPointParameterf (GLenum pname, GLfloat param); +GL_API void GL_APIENTRY glPointParameterfv (GLenum pname, const GLfloat *params); +GL_API void GL_APIENTRY glPointSize (GLfloat size); +GL_API void GL_APIENTRY glPolygonOffset (GLfloat factor, GLfloat units); +GL_API void GL_APIENTRY glRotatef (GLfloat angle, GLfloat x, GLfloat y, GLfloat z); +GL_API void GL_APIENTRY glScalef (GLfloat x, GLfloat y, GLfloat z); +GL_API void GL_APIENTRY glTexEnvf (GLenum target, GLenum pname, GLfloat param); +GL_API void GL_APIENTRY glTexEnvfv (GLenum target, GLenum pname, const GLfloat *params); +GL_API void GL_APIENTRY glTexParameterf (GLenum target, GLenum pname, GLfloat param); +GL_API void GL_APIENTRY glTexParameterfv (GLenum target, GLenum pname, const GLfloat *params); +GL_API void GL_APIENTRY glTranslatef (GLfloat x, GLfloat y, GLfloat z); +GL_API void GL_APIENTRY glActiveTexture (GLenum texture); +GL_API void GL_APIENTRY glAlphaFuncx (GLenum func, GLfixed ref); +GL_API void GL_APIENTRY glBindBuffer (GLenum target, GLuint buffer); +GL_API void GL_APIENTRY glBindTexture (GLenum target, GLuint texture); +GL_API void GL_APIENTRY glBlendFunc (GLenum sfactor, GLenum dfactor); +GL_API void GL_APIENTRY glBufferData (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +GL_API void GL_APIENTRY glBufferSubData (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +GL_API void GL_APIENTRY glClear (GLbitfield mask); +GL_API void GL_APIENTRY glClearColorx (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha); +GL_API void GL_APIENTRY glClearDepthx (GLfixed depth); +GL_API void GL_APIENTRY glClearStencil (GLint s); +GL_API void GL_APIENTRY glClientActiveTexture (GLenum texture); +GL_API void GL_APIENTRY glClipPlanex (GLenum plane, const GLfixed *equation); +GL_API void GL_APIENTRY glColor4ub (GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha); +GL_API void GL_APIENTRY glColor4x (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha); +GL_API void GL_APIENTRY glColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +GL_API void GL_APIENTRY glColorPointer (GLint size, GLenum type, GLsizei stride, const void *pointer); +GL_API void GL_APIENTRY glCompressedTexImage2D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +GL_API void GL_APIENTRY glCompressedTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +GL_API void GL_APIENTRY glCopyTexImage2D (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +GL_API void GL_APIENTRY glCopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +GL_API void GL_APIENTRY glCullFace (GLenum mode); +GL_API void GL_APIENTRY glDeleteBuffers (GLsizei n, const GLuint *buffers); +GL_API void GL_APIENTRY glDeleteTextures (GLsizei n, const GLuint *textures); +GL_API void GL_APIENTRY glDepthFunc (GLenum func); +GL_API void GL_APIENTRY glDepthMask (GLboolean flag); +GL_API void GL_APIENTRY glDepthRangex (GLfixed n, GLfixed f); +GL_API void GL_APIENTRY glDisable (GLenum cap); +GL_API void GL_APIENTRY glDisableClientState (GLenum array); +GL_API void GL_APIENTRY glDrawArrays (GLenum mode, GLint first, GLsizei count); +GL_API void GL_APIENTRY glDrawElements (GLenum mode, GLsizei count, GLenum type, const void *indices); +GL_API void GL_APIENTRY glEnable (GLenum cap); +GL_API void GL_APIENTRY glEnableClientState (GLenum array); +GL_API void GL_APIENTRY glFinish (void); +GL_API void GL_APIENTRY glFlush (void); +GL_API void GL_APIENTRY glFogx (GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glFogxv (GLenum pname, const GLfixed *param); +GL_API void GL_APIENTRY glFrontFace (GLenum mode); +GL_API void GL_APIENTRY glFrustumx (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f); +GL_API void GL_APIENTRY glGetBooleanv (GLenum pname, GLboolean *data); +GL_API void GL_APIENTRY glGetBufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_API void GL_APIENTRY glGetClipPlanex (GLenum plane, GLfixed *equation); +GL_API void GL_APIENTRY glGenBuffers (GLsizei n, GLuint *buffers); +GL_API void GL_APIENTRY glGenTextures (GLsizei n, GLuint *textures); +GL_API GLenum GL_APIENTRY glGetError (void); +GL_API void GL_APIENTRY glGetFixedv (GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glGetIntegerv (GLenum pname, GLint *data); +GL_API void GL_APIENTRY glGetLightxv (GLenum light, GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glGetMaterialxv (GLenum face, GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glGetPointerv (GLenum pname, void **params); +GL_API const GLubyte *GL_APIENTRY glGetString (GLenum name); +GL_API void GL_APIENTRY glGetTexEnviv (GLenum target, GLenum pname, GLint *params); +GL_API void GL_APIENTRY glGetTexEnvxv (GLenum target, GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glGetTexParameteriv (GLenum target, GLenum pname, GLint *params); +GL_API void GL_APIENTRY glGetTexParameterxv (GLenum target, GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glHint (GLenum target, GLenum mode); +GL_API GLboolean GL_APIENTRY glIsBuffer (GLuint buffer); +GL_API GLboolean GL_APIENTRY glIsEnabled (GLenum cap); +GL_API GLboolean GL_APIENTRY glIsTexture (GLuint texture); +GL_API void GL_APIENTRY glLightModelx (GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glLightModelxv (GLenum pname, const GLfixed *param); +GL_API void GL_APIENTRY glLightx (GLenum light, GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glLightxv (GLenum light, GLenum pname, const GLfixed *params); +GL_API void GL_APIENTRY glLineWidthx (GLfixed width); +GL_API void GL_APIENTRY glLoadIdentity (void); +GL_API void GL_APIENTRY glLoadMatrixx (const GLfixed *m); +GL_API void GL_APIENTRY glLogicOp (GLenum opcode); +GL_API void GL_APIENTRY glMaterialx (GLenum face, GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glMaterialxv (GLenum face, GLenum pname, const GLfixed *param); +GL_API void GL_APIENTRY glMatrixMode (GLenum mode); +GL_API void GL_APIENTRY glMultMatrixx (const GLfixed *m); +GL_API void GL_APIENTRY glMultiTexCoord4x (GLenum texture, GLfixed s, GLfixed t, GLfixed r, GLfixed q); +GL_API void GL_APIENTRY glNormal3x (GLfixed nx, GLfixed ny, GLfixed nz); +GL_API void GL_APIENTRY glNormalPointer (GLenum type, GLsizei stride, const void *pointer); +GL_API void GL_APIENTRY glOrthox (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f); +GL_API void GL_APIENTRY glPixelStorei (GLenum pname, GLint param); +GL_API void GL_APIENTRY glPointParameterx (GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glPointParameterxv (GLenum pname, const GLfixed *params); +GL_API void GL_APIENTRY glPointSizex (GLfixed size); +GL_API void GL_APIENTRY glPolygonOffsetx (GLfixed factor, GLfixed units); +GL_API void GL_APIENTRY glPopMatrix (void); +GL_API void GL_APIENTRY glPushMatrix (void); +GL_API void GL_APIENTRY glReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +GL_API void GL_APIENTRY glRotatex (GLfixed angle, GLfixed x, GLfixed y, GLfixed z); +GL_API void GL_APIENTRY glSampleCoverage (GLfloat value, GLboolean invert); +GL_API void GL_APIENTRY glSampleCoveragex (GLclampx value, GLboolean invert); +GL_API void GL_APIENTRY glScalex (GLfixed x, GLfixed y, GLfixed z); +GL_API void GL_APIENTRY glScissor (GLint x, GLint y, GLsizei width, GLsizei height); +GL_API void GL_APIENTRY glShadeModel (GLenum mode); +GL_API void GL_APIENTRY glStencilFunc (GLenum func, GLint ref, GLuint mask); +GL_API void GL_APIENTRY glStencilMask (GLuint mask); +GL_API void GL_APIENTRY glStencilOp (GLenum fail, GLenum zfail, GLenum zpass); +GL_API void GL_APIENTRY glTexCoordPointer (GLint size, GLenum type, GLsizei stride, const void *pointer); +GL_API void GL_APIENTRY glTexEnvi (GLenum target, GLenum pname, GLint param); +GL_API void GL_APIENTRY glTexEnvx (GLenum target, GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glTexEnviv (GLenum target, GLenum pname, const GLint *params); +GL_API void GL_APIENTRY glTexEnvxv (GLenum target, GLenum pname, const GLfixed *params); +GL_API void GL_APIENTRY glTexImage2D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +GL_API void GL_APIENTRY glTexParameteri (GLenum target, GLenum pname, GLint param); +GL_API void GL_APIENTRY glTexParameterx (GLenum target, GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glTexParameteriv (GLenum target, GLenum pname, const GLint *params); +GL_API void GL_APIENTRY glTexParameterxv (GLenum target, GLenum pname, const GLfixed *params); +GL_API void GL_APIENTRY glTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +GL_API void GL_APIENTRY glTranslatex (GLfixed x, GLfixed y, GLfixed z); +GL_API void GL_APIENTRY glVertexPointer (GLint size, GLenum type, GLsizei stride, const void *pointer); +GL_API void GL_APIENTRY glViewport (GLint x, GLint y, GLsizei width, GLsizei height); +#endif +#endif /* GL_VERSION_ES_CM_1_0 */ + +#ifndef GL_OES_compressed_paletted_texture +#define GL_OES_compressed_paletted_texture 1 +#define GL_PALETTE4_RGB8_OES 0x8B90 +#define GL_PALETTE4_RGBA8_OES 0x8B91 +#define GL_PALETTE4_R5_G6_B5_OES 0x8B92 +#define GL_PALETTE4_RGBA4_OES 0x8B93 +#define GL_PALETTE4_RGB5_A1_OES 0x8B94 +#define GL_PALETTE8_RGB8_OES 0x8B95 +#define GL_PALETTE8_RGBA8_OES 0x8B96 +#define GL_PALETTE8_R5_G6_B5_OES 0x8B97 +#define GL_PALETTE8_RGBA4_OES 0x8B98 +#define GL_PALETTE8_RGB5_A1_OES 0x8B99 +#endif /* GL_OES_compressed_paletted_texture */ + +#ifndef GL_OES_point_size_array +#define GL_OES_point_size_array 1 +#define GL_POINT_SIZE_ARRAY_OES 0x8B9C +#define GL_POINT_SIZE_ARRAY_TYPE_OES 0x898A +#define GL_POINT_SIZE_ARRAY_STRIDE_OES 0x898B +#define GL_POINT_SIZE_ARRAY_POINTER_OES 0x898C +#define GL_POINT_SIZE_ARRAY_BUFFER_BINDING_OES 0x8B9F +typedef void (GL_APIENTRYP PFNGLPOINTSIZEPOINTEROESPROC) (GLenum type, GLsizei stride, const void *pointer); +#if GL_GLES_PROTOTYPES +GL_API void GL_APIENTRY glPointSizePointerOES (GLenum type, GLsizei stride, const void *pointer); +#endif +#endif /* GL_OES_point_size_array */ + +#ifndef GL_OES_point_sprite +#define GL_OES_point_sprite 1 +#define GL_POINT_SPRITE_OES 0x8861 +#define GL_COORD_REPLACE_OES 0x8862 +#endif /* GL_OES_point_sprite */ + +#ifndef GL_OES_read_format +#define GL_OES_read_format 1 +#define GL_IMPLEMENTATION_COLOR_READ_TYPE_OES 0x8B9A +#define GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES 0x8B9B +#endif /* GL_OES_read_format */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/GLES/glext.h b/gfx/angle/checkout/include/GLES/glext.h new file mode 100644 index 0000000000..d8933e37d5 --- /dev/null +++ b/gfx/angle/checkout/include/GLES/glext.h @@ -0,0 +1,962 @@ +#ifndef __glext_h_ +#define __glext_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright (c) 2013-2017 The Khronos Group Inc. +** +** Permission is hereby granted, free of charge, to any person obtaining a +** copy of this software and/or associated documentation files (the +** "Materials"), to deal in the Materials without restriction, including +** without limitation the rights to use, copy, modify, merge, publish, +** distribute, sublicense, and/or sell copies of the Materials, and to +** permit persons to whom the Materials are furnished to do so, subject to +** the following conditions: +** +** The above copyright notice and this permission notice shall be included +** in all copies or substantial portions of the Materials. +** +** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. +*/ +/* +** This header is generated from the Khronos OpenGL / OpenGL ES XML +** API Registry. The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** https://github.com/KhronosGroup/OpenGL-Registry +*/ + +#ifndef GL_APIENTRYP +#define GL_APIENTRYP GL_APIENTRY* +#endif + +/* Generated on date 20171212 */ + +/* Generated C header for: + * API: gles1 + * Profile: common + * Versions considered: .* + * Versions emitted: _nomatch_^ + * Default extensions included: gles1 + * Additional extensions included: _nomatch_^ + * Extensions removed: ^(GL_OES_read_format|GL_OES_compressed_paletted_texture|GL_OES_point_size_array|GL_OES_point_sprite)$ + */ + +#ifndef GL_OES_EGL_image +#define GL_OES_EGL_image 1 +typedef void *GLeglImageOES; +typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETTEXTURE2DOESPROC) (GLenum target, GLeglImageOES image); +typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETRENDERBUFFERSTORAGEOESPROC) (GLenum target, GLeglImageOES image); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glEGLImageTargetTexture2DOES (GLenum target, GLeglImageOES image); +GL_API void GL_APIENTRY glEGLImageTargetRenderbufferStorageOES (GLenum target, GLeglImageOES image); +#endif +#endif /* GL_OES_EGL_image */ + +#ifndef GL_OES_blend_equation_separate +#define GL_OES_blend_equation_separate 1 +#define GL_BLEND_EQUATION_RGB_OES 0x8009 +#define GL_BLEND_EQUATION_ALPHA_OES 0x883D +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEOESPROC) (GLenum modeRGB, GLenum modeAlpha); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glBlendEquationSeparateOES (GLenum modeRGB, GLenum modeAlpha); +#endif +#endif /* GL_OES_blend_equation_separate */ + +#ifndef GL_OES_blend_func_separate +#define GL_OES_blend_func_separate 1 +#define GL_BLEND_DST_RGB_OES 0x80C8 +#define GL_BLEND_SRC_RGB_OES 0x80C9 +#define GL_BLEND_DST_ALPHA_OES 0x80CA +#define GL_BLEND_SRC_ALPHA_OES 0x80CB +typedef void (GL_APIENTRYP PFNGLBLENDFUNCSEPARATEOESPROC) (GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glBlendFuncSeparateOES (GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha); +#endif +#endif /* GL_OES_blend_func_separate */ + +#ifndef GL_OES_blend_subtract +#define GL_OES_blend_subtract 1 +#define GL_BLEND_EQUATION_OES 0x8009 +#define GL_FUNC_ADD_OES 0x8006 +#define GL_FUNC_SUBTRACT_OES 0x800A +#define GL_FUNC_REVERSE_SUBTRACT_OES 0x800B +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONOESPROC) (GLenum mode); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glBlendEquationOES (GLenum mode); +#endif +#endif /* GL_OES_blend_subtract */ + +#ifndef GL_OES_byte_coordinates +#define GL_OES_byte_coordinates 1 +#endif /* GL_OES_byte_coordinates */ + +#ifndef GL_OES_compressed_ETC1_RGB8_sub_texture +#define GL_OES_compressed_ETC1_RGB8_sub_texture 1 +#endif /* GL_OES_compressed_ETC1_RGB8_sub_texture */ + +#ifndef GL_OES_compressed_ETC1_RGB8_texture +#define GL_OES_compressed_ETC1_RGB8_texture 1 +#define GL_ETC1_RGB8_OES 0x8D64 +#endif /* GL_OES_compressed_ETC1_RGB8_texture */ + +#ifndef GL_OES_depth24 +#define GL_OES_depth24 1 +#define GL_DEPTH_COMPONENT24_OES 0x81A6 +#endif /* GL_OES_depth24 */ + +#ifndef GL_OES_depth32 +#define GL_OES_depth32 1 +#define GL_DEPTH_COMPONENT32_OES 0x81A7 +#endif /* GL_OES_depth32 */ + +#ifndef GL_OES_draw_texture +#define GL_OES_draw_texture 1 +#define GL_TEXTURE_CROP_RECT_OES 0x8B9D +typedef void (GL_APIENTRYP PFNGLDRAWTEXSOESPROC) (GLshort x, GLshort y, GLshort z, GLshort width, GLshort height); +typedef void (GL_APIENTRYP PFNGLDRAWTEXIOESPROC) (GLint x, GLint y, GLint z, GLint width, GLint height); +typedef void (GL_APIENTRYP PFNGLDRAWTEXXOESPROC) (GLfixed x, GLfixed y, GLfixed z, GLfixed width, GLfixed height); +typedef void (GL_APIENTRYP PFNGLDRAWTEXSVOESPROC) (const GLshort *coords); +typedef void (GL_APIENTRYP PFNGLDRAWTEXIVOESPROC) (const GLint *coords); +typedef void (GL_APIENTRYP PFNGLDRAWTEXXVOESPROC) (const GLfixed *coords); +typedef void (GL_APIENTRYP PFNGLDRAWTEXFOESPROC) (GLfloat x, GLfloat y, GLfloat z, GLfloat width, GLfloat height); +typedef void (GL_APIENTRYP PFNGLDRAWTEXFVOESPROC) (const GLfloat *coords); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glDrawTexsOES (GLshort x, GLshort y, GLshort z, GLshort width, GLshort height); +GL_API void GL_APIENTRY glDrawTexiOES (GLint x, GLint y, GLint z, GLint width, GLint height); +GL_API void GL_APIENTRY glDrawTexxOES (GLfixed x, GLfixed y, GLfixed z, GLfixed width, GLfixed height); +GL_API void GL_APIENTRY glDrawTexsvOES (const GLshort *coords); +GL_API void GL_APIENTRY glDrawTexivOES (const GLint *coords); +GL_API void GL_APIENTRY glDrawTexxvOES (const GLfixed *coords); +GL_API void GL_APIENTRY glDrawTexfOES (GLfloat x, GLfloat y, GLfloat z, GLfloat width, GLfloat height); +GL_API void GL_APIENTRY glDrawTexfvOES (const GLfloat *coords); +#endif +#endif /* GL_OES_draw_texture */ + +#ifndef GL_OES_element_index_uint +#define GL_OES_element_index_uint 1 +#define GL_UNSIGNED_INT 0x1405 +#endif /* GL_OES_element_index_uint */ + +#ifndef GL_OES_extended_matrix_palette +#define GL_OES_extended_matrix_palette 1 +#endif /* GL_OES_extended_matrix_palette */ + +#ifndef GL_OES_fbo_render_mipmap +#define GL_OES_fbo_render_mipmap 1 +#endif /* GL_OES_fbo_render_mipmap */ + +#ifndef GL_OES_fixed_point +#define GL_OES_fixed_point 1 +#define GL_FIXED_OES 0x140C +typedef void (GL_APIENTRYP PFNGLALPHAFUNCXOESPROC) (GLenum func, GLfixed ref); +typedef void (GL_APIENTRYP PFNGLCLEARCOLORXOESPROC) (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha); +typedef void (GL_APIENTRYP PFNGLCLEARDEPTHXOESPROC) (GLfixed depth); +typedef void (GL_APIENTRYP PFNGLCLIPPLANEXOESPROC) (GLenum plane, const GLfixed *equation); +typedef void (GL_APIENTRYP PFNGLCOLOR4XOESPROC) (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEXOESPROC) (GLfixed n, GLfixed f); +typedef void (GL_APIENTRYP PFNGLFOGXOESPROC) (GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLFOGXVOESPROC) (GLenum pname, const GLfixed *param); +typedef void (GL_APIENTRYP PFNGLFRUSTUMXOESPROC) (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f); +typedef void (GL_APIENTRYP PFNGLGETCLIPPLANEXOESPROC) (GLenum plane, GLfixed *equation); +typedef void (GL_APIENTRYP PFNGLGETFIXEDVOESPROC) (GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLGETTEXENVXVOESPROC) (GLenum target, GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERXVOESPROC) (GLenum target, GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLLIGHTMODELXOESPROC) (GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLLIGHTMODELXVOESPROC) (GLenum pname, const GLfixed *param); +typedef void (GL_APIENTRYP PFNGLLIGHTXOESPROC) (GLenum light, GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLLIGHTXVOESPROC) (GLenum light, GLenum pname, const GLfixed *params); +typedef void (GL_APIENTRYP PFNGLLINEWIDTHXOESPROC) (GLfixed width); +typedef void (GL_APIENTRYP PFNGLLOADMATRIXXOESPROC) (const GLfixed *m); +typedef void (GL_APIENTRYP PFNGLMATERIALXOESPROC) (GLenum face, GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLMATERIALXVOESPROC) (GLenum face, GLenum pname, const GLfixed *param); +typedef void (GL_APIENTRYP PFNGLMULTMATRIXXOESPROC) (const GLfixed *m); +typedef void (GL_APIENTRYP PFNGLMULTITEXCOORD4XOESPROC) (GLenum texture, GLfixed s, GLfixed t, GLfixed r, GLfixed q); +typedef void (GL_APIENTRYP PFNGLNORMAL3XOESPROC) (GLfixed nx, GLfixed ny, GLfixed nz); +typedef void (GL_APIENTRYP PFNGLORTHOXOESPROC) (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f); +typedef void (GL_APIENTRYP PFNGLPOINTPARAMETERXVOESPROC) (GLenum pname, const GLfixed *params); +typedef void (GL_APIENTRYP PFNGLPOINTSIZEXOESPROC) (GLfixed size); +typedef void (GL_APIENTRYP PFNGLPOLYGONOFFSETXOESPROC) (GLfixed factor, GLfixed units); +typedef void (GL_APIENTRYP PFNGLROTATEXOESPROC) (GLfixed angle, GLfixed x, GLfixed y, GLfixed z); +typedef void (GL_APIENTRYP PFNGLSCALEXOESPROC) (GLfixed x, GLfixed y, GLfixed z); +typedef void (GL_APIENTRYP PFNGLTEXENVXOESPROC) (GLenum target, GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLTEXENVXVOESPROC) (GLenum target, GLenum pname, const GLfixed *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERXOESPROC) (GLenum target, GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERXVOESPROC) (GLenum target, GLenum pname, const GLfixed *params); +typedef void (GL_APIENTRYP PFNGLTRANSLATEXOESPROC) (GLfixed x, GLfixed y, GLfixed z); +typedef void (GL_APIENTRYP PFNGLGETLIGHTXVOESPROC) (GLenum light, GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLGETMATERIALXVOESPROC) (GLenum face, GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLPOINTPARAMETERXOESPROC) (GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLSAMPLECOVERAGEXOESPROC) (GLclampx value, GLboolean invert); +typedef void (GL_APIENTRYP PFNGLGETTEXGENXVOESPROC) (GLenum coord, GLenum pname, GLfixed *params); +typedef void (GL_APIENTRYP PFNGLTEXGENXOESPROC) (GLenum coord, GLenum pname, GLfixed param); +typedef void (GL_APIENTRYP PFNGLTEXGENXVOESPROC) (GLenum coord, GLenum pname, const GLfixed *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glAlphaFuncxOES (GLenum func, GLfixed ref); +GL_API void GL_APIENTRY glClearColorxOES (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha); +GL_API void GL_APIENTRY glClearDepthxOES (GLfixed depth); +GL_API void GL_APIENTRY glClipPlanexOES (GLenum plane, const GLfixed *equation); +GL_API void GL_APIENTRY glColor4xOES (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha); +GL_API void GL_APIENTRY glDepthRangexOES (GLfixed n, GLfixed f); +GL_API void GL_APIENTRY glFogxOES (GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glFogxvOES (GLenum pname, const GLfixed *param); +GL_API void GL_APIENTRY glFrustumxOES (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f); +GL_API void GL_APIENTRY glGetClipPlanexOES (GLenum plane, GLfixed *equation); +GL_API void GL_APIENTRY glGetFixedvOES (GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glGetTexEnvxvOES (GLenum target, GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glGetTexParameterxvOES (GLenum target, GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glLightModelxOES (GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glLightModelxvOES (GLenum pname, const GLfixed *param); +GL_API void GL_APIENTRY glLightxOES (GLenum light, GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glLightxvOES (GLenum light, GLenum pname, const GLfixed *params); +GL_API void GL_APIENTRY glLineWidthxOES (GLfixed width); +GL_API void GL_APIENTRY glLoadMatrixxOES (const GLfixed *m); +GL_API void GL_APIENTRY glMaterialxOES (GLenum face, GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glMaterialxvOES (GLenum face, GLenum pname, const GLfixed *param); +GL_API void GL_APIENTRY glMultMatrixxOES (const GLfixed *m); +GL_API void GL_APIENTRY glMultiTexCoord4xOES (GLenum texture, GLfixed s, GLfixed t, GLfixed r, GLfixed q); +GL_API void GL_APIENTRY glNormal3xOES (GLfixed nx, GLfixed ny, GLfixed nz); +GL_API void GL_APIENTRY glOrthoxOES (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f); +GL_API void GL_APIENTRY glPointParameterxvOES (GLenum pname, const GLfixed *params); +GL_API void GL_APIENTRY glPointSizexOES (GLfixed size); +GL_API void GL_APIENTRY glPolygonOffsetxOES (GLfixed factor, GLfixed units); +GL_API void GL_APIENTRY glRotatexOES (GLfixed angle, GLfixed x, GLfixed y, GLfixed z); +GL_API void GL_APIENTRY glScalexOES (GLfixed x, GLfixed y, GLfixed z); +GL_API void GL_APIENTRY glTexEnvxOES (GLenum target, GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glTexEnvxvOES (GLenum target, GLenum pname, const GLfixed *params); +GL_API void GL_APIENTRY glTexParameterxOES (GLenum target, GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glTexParameterxvOES (GLenum target, GLenum pname, const GLfixed *params); +GL_API void GL_APIENTRY glTranslatexOES (GLfixed x, GLfixed y, GLfixed z); +GL_API void GL_APIENTRY glGetLightxvOES (GLenum light, GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glGetMaterialxvOES (GLenum face, GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glPointParameterxOES (GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glSampleCoveragexOES (GLclampx value, GLboolean invert); +GL_API void GL_APIENTRY glGetTexGenxvOES (GLenum coord, GLenum pname, GLfixed *params); +GL_API void GL_APIENTRY glTexGenxOES (GLenum coord, GLenum pname, GLfixed param); +GL_API void GL_APIENTRY glTexGenxvOES (GLenum coord, GLenum pname, const GLfixed *params); +#endif +#endif /* GL_OES_fixed_point */ + +#ifndef GL_OES_framebuffer_object +#define GL_OES_framebuffer_object 1 +#define GL_NONE_OES 0 +#define GL_FRAMEBUFFER_OES 0x8D40 +#define GL_RENDERBUFFER_OES 0x8D41 +#define GL_RGBA4_OES 0x8056 +#define GL_RGB5_A1_OES 0x8057 +#define GL_RGB565_OES 0x8D62 +#define GL_DEPTH_COMPONENT16_OES 0x81A5 +#define GL_RENDERBUFFER_WIDTH_OES 0x8D42 +#define GL_RENDERBUFFER_HEIGHT_OES 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT_OES 0x8D44 +#define GL_RENDERBUFFER_RED_SIZE_OES 0x8D50 +#define GL_RENDERBUFFER_GREEN_SIZE_OES 0x8D51 +#define GL_RENDERBUFFER_BLUE_SIZE_OES 0x8D52 +#define GL_RENDERBUFFER_ALPHA_SIZE_OES 0x8D53 +#define GL_RENDERBUFFER_DEPTH_SIZE_OES 0x8D54 +#define GL_RENDERBUFFER_STENCIL_SIZE_OES 0x8D55 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_OES 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_OES 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_OES 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_OES 0x8CD3 +#define GL_COLOR_ATTACHMENT0_OES 0x8CE0 +#define GL_DEPTH_ATTACHMENT_OES 0x8D00 +#define GL_STENCIL_ATTACHMENT_OES 0x8D20 +#define GL_FRAMEBUFFER_COMPLETE_OES 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_OES 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_OES 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_OES 0x8CD9 +#define GL_FRAMEBUFFER_INCOMPLETE_FORMATS_OES 0x8CDA +#define GL_FRAMEBUFFER_UNSUPPORTED_OES 0x8CDD +#define GL_FRAMEBUFFER_BINDING_OES 0x8CA6 +#define GL_RENDERBUFFER_BINDING_OES 0x8CA7 +#define GL_MAX_RENDERBUFFER_SIZE_OES 0x84E8 +#define GL_INVALID_FRAMEBUFFER_OPERATION_OES 0x0506 +typedef GLboolean (GL_APIENTRYP PFNGLISRENDERBUFFEROESPROC) (GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLBINDRENDERBUFFEROESPROC) (GLenum target, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLDELETERENDERBUFFERSOESPROC) (GLsizei n, const GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLGENRENDERBUFFERSOESPROC) (GLsizei n, GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEOESPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVOESPROC) (GLenum target, GLenum pname, GLint *params); +typedef GLboolean (GL_APIENTRYP PFNGLISFRAMEBUFFEROESPROC) (GLuint framebuffer); +typedef void (GL_APIENTRYP PFNGLBINDFRAMEBUFFEROESPROC) (GLenum target, GLuint framebuffer); +typedef void (GL_APIENTRYP PFNGLDELETEFRAMEBUFFERSOESPROC) (GLsizei n, const GLuint *framebuffers); +typedef void (GL_APIENTRYP PFNGLGENFRAMEBUFFERSOESPROC) (GLsizei n, GLuint *framebuffers); +typedef GLenum (GL_APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSOESPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFEROESPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DOESPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVOESPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGENERATEMIPMAPOESPROC) (GLenum target); +#ifdef GL_GLEXT_PROTOTYPES +GL_API GLboolean GL_APIENTRY glIsRenderbufferOES (GLuint renderbuffer); +GL_API void GL_APIENTRY glBindRenderbufferOES (GLenum target, GLuint renderbuffer); +GL_API void GL_APIENTRY glDeleteRenderbuffersOES (GLsizei n, const GLuint *renderbuffers); +GL_API void GL_APIENTRY glGenRenderbuffersOES (GLsizei n, GLuint *renderbuffers); +GL_API void GL_APIENTRY glRenderbufferStorageOES (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +GL_API void GL_APIENTRY glGetRenderbufferParameterivOES (GLenum target, GLenum pname, GLint *params); +GL_API GLboolean GL_APIENTRY glIsFramebufferOES (GLuint framebuffer); +GL_API void GL_APIENTRY glBindFramebufferOES (GLenum target, GLuint framebuffer); +GL_API void GL_APIENTRY glDeleteFramebuffersOES (GLsizei n, const GLuint *framebuffers); +GL_API void GL_APIENTRY glGenFramebuffersOES (GLsizei n, GLuint *framebuffers); +GL_API GLenum GL_APIENTRY glCheckFramebufferStatusOES (GLenum target); +GL_API void GL_APIENTRY glFramebufferRenderbufferOES (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +GL_API void GL_APIENTRY glFramebufferTexture2DOES (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +GL_API void GL_APIENTRY glGetFramebufferAttachmentParameterivOES (GLenum target, GLenum attachment, GLenum pname, GLint *params); +GL_API void GL_APIENTRY glGenerateMipmapOES (GLenum target); +#endif +#endif /* GL_OES_framebuffer_object */ + +#ifndef GL_OES_mapbuffer +#define GL_OES_mapbuffer 1 +#define GL_WRITE_ONLY_OES 0x88B9 +#define GL_BUFFER_ACCESS_OES 0x88BB +#define GL_BUFFER_MAPPED_OES 0x88BC +#define GL_BUFFER_MAP_POINTER_OES 0x88BD +typedef void *(GL_APIENTRYP PFNGLMAPBUFFEROESPROC) (GLenum target, GLenum access); +typedef GLboolean (GL_APIENTRYP PFNGLUNMAPBUFFEROESPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVOESPROC) (GLenum target, GLenum pname, void **params); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void *GL_APIENTRY glMapBufferOES (GLenum target, GLenum access); +GL_API GLboolean GL_APIENTRY glUnmapBufferOES (GLenum target); +GL_API void GL_APIENTRY glGetBufferPointervOES (GLenum target, GLenum pname, void **params); +#endif +#endif /* GL_OES_mapbuffer */ + +#ifndef GL_OES_matrix_get +#define GL_OES_matrix_get 1 +#define GL_MODELVIEW_MATRIX_FLOAT_AS_INT_BITS_OES 0x898D +#define GL_PROJECTION_MATRIX_FLOAT_AS_INT_BITS_OES 0x898E +#define GL_TEXTURE_MATRIX_FLOAT_AS_INT_BITS_OES 0x898F +#endif /* GL_OES_matrix_get */ + +#ifndef GL_OES_matrix_palette +#define GL_OES_matrix_palette 1 +#define GL_MAX_VERTEX_UNITS_OES 0x86A4 +#define GL_MAX_PALETTE_MATRICES_OES 0x8842 +#define GL_MATRIX_PALETTE_OES 0x8840 +#define GL_MATRIX_INDEX_ARRAY_OES 0x8844 +#define GL_WEIGHT_ARRAY_OES 0x86AD +#define GL_CURRENT_PALETTE_MATRIX_OES 0x8843 +#define GL_MATRIX_INDEX_ARRAY_SIZE_OES 0x8846 +#define GL_MATRIX_INDEX_ARRAY_TYPE_OES 0x8847 +#define GL_MATRIX_INDEX_ARRAY_STRIDE_OES 0x8848 +#define GL_MATRIX_INDEX_ARRAY_POINTER_OES 0x8849 +#define GL_MATRIX_INDEX_ARRAY_BUFFER_BINDING_OES 0x8B9E +#define GL_WEIGHT_ARRAY_SIZE_OES 0x86AB +#define GL_WEIGHT_ARRAY_TYPE_OES 0x86A9 +#define GL_WEIGHT_ARRAY_STRIDE_OES 0x86AA +#define GL_WEIGHT_ARRAY_POINTER_OES 0x86AC +#define GL_WEIGHT_ARRAY_BUFFER_BINDING_OES 0x889E +typedef void (GL_APIENTRYP PFNGLCURRENTPALETTEMATRIXOESPROC) (GLuint matrixpaletteindex); +typedef void (GL_APIENTRYP PFNGLLOADPALETTEFROMMODELVIEWMATRIXOESPROC) (void); +typedef void (GL_APIENTRYP PFNGLMATRIXINDEXPOINTEROESPROC) (GLint size, GLenum type, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLWEIGHTPOINTEROESPROC) (GLint size, GLenum type, GLsizei stride, const void *pointer); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glCurrentPaletteMatrixOES (GLuint matrixpaletteindex); +GL_API void GL_APIENTRY glLoadPaletteFromModelViewMatrixOES (void); +GL_API void GL_APIENTRY glMatrixIndexPointerOES (GLint size, GLenum type, GLsizei stride, const void *pointer); +GL_API void GL_APIENTRY glWeightPointerOES (GLint size, GLenum type, GLsizei stride, const void *pointer); +#endif +#endif /* GL_OES_matrix_palette */ + +#ifndef GL_OES_packed_depth_stencil +#define GL_OES_packed_depth_stencil 1 +#define GL_DEPTH_STENCIL_OES 0x84F9 +#define GL_UNSIGNED_INT_24_8_OES 0x84FA +#define GL_DEPTH24_STENCIL8_OES 0x88F0 +#endif /* GL_OES_packed_depth_stencil */ + +#ifndef GL_OES_query_matrix +#define GL_OES_query_matrix 1 +typedef GLbitfield (GL_APIENTRYP PFNGLQUERYMATRIXXOESPROC) (GLfixed *mantissa, GLint *exponent); +#ifdef GL_GLEXT_PROTOTYPES +GL_API GLbitfield GL_APIENTRY glQueryMatrixxOES (GLfixed *mantissa, GLint *exponent); +#endif +#endif /* GL_OES_query_matrix */ + +#ifndef GL_OES_required_internalformat +#define GL_OES_required_internalformat 1 +#define GL_ALPHA8_OES 0x803C +#define GL_LUMINANCE4_ALPHA4_OES 0x8043 +#define GL_LUMINANCE8_ALPHA8_OES 0x8045 +#define GL_LUMINANCE8_OES 0x8040 +#define GL_RGB8_OES 0x8051 +#define GL_RGBA8_OES 0x8058 +#define GL_RGB10_EXT 0x8052 +#define GL_RGB10_A2_EXT 0x8059 +#endif /* GL_OES_required_internalformat */ + +#ifndef GL_OES_rgb8_rgba8 +#define GL_OES_rgb8_rgba8 1 +#endif /* GL_OES_rgb8_rgba8 */ + +#ifndef GL_OES_single_precision +#define GL_OES_single_precision 1 +typedef void (GL_APIENTRYP PFNGLCLEARDEPTHFOESPROC) (GLclampf depth); +typedef void (GL_APIENTRYP PFNGLCLIPPLANEFOESPROC) (GLenum plane, const GLfloat *equation); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEFOESPROC) (GLclampf n, GLclampf f); +typedef void (GL_APIENTRYP PFNGLFRUSTUMFOESPROC) (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLGETCLIPPLANEFOESPROC) (GLenum plane, GLfloat *equation); +typedef void (GL_APIENTRYP PFNGLORTHOFOESPROC) (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glClearDepthfOES (GLclampf depth); +GL_API void GL_APIENTRY glClipPlanefOES (GLenum plane, const GLfloat *equation); +GL_API void GL_APIENTRY glDepthRangefOES (GLclampf n, GLclampf f); +GL_API void GL_APIENTRY glFrustumfOES (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f); +GL_API void GL_APIENTRY glGetClipPlanefOES (GLenum plane, GLfloat *equation); +GL_API void GL_APIENTRY glOrthofOES (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f); +#endif +#endif /* GL_OES_single_precision */ + +#ifndef GL_OES_stencil1 +#define GL_OES_stencil1 1 +#define GL_STENCIL_INDEX1_OES 0x8D46 +#endif /* GL_OES_stencil1 */ + +#ifndef GL_OES_stencil4 +#define GL_OES_stencil4 1 +#define GL_STENCIL_INDEX4_OES 0x8D47 +#endif /* GL_OES_stencil4 */ + +#ifndef GL_OES_stencil8 +#define GL_OES_stencil8 1 +#define GL_STENCIL_INDEX8_OES 0x8D48 +#endif /* GL_OES_stencil8 */ + +#ifndef GL_OES_stencil_wrap +#define GL_OES_stencil_wrap 1 +#define GL_INCR_WRAP_OES 0x8507 +#define GL_DECR_WRAP_OES 0x8508 +#endif /* GL_OES_stencil_wrap */ + +#ifndef GL_OES_surfaceless_context +#define GL_OES_surfaceless_context 1 +#define GL_FRAMEBUFFER_UNDEFINED_OES 0x8219 +#endif /* GL_OES_surfaceless_context */ + +#ifndef GL_OES_texture_cube_map +#define GL_OES_texture_cube_map 1 +#define GL_NORMAL_MAP_OES 0x8511 +#define GL_REFLECTION_MAP_OES 0x8512 +#define GL_TEXTURE_CUBE_MAP_OES 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP_OES 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_OES 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_OES 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_OES 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_OES 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_OES 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_OES 0x851A +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_OES 0x851C +#define GL_TEXTURE_GEN_MODE_OES 0x2500 +#define GL_TEXTURE_GEN_STR_OES 0x8D60 +typedef void (GL_APIENTRYP PFNGLTEXGENFOESPROC) (GLenum coord, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLTEXGENFVOESPROC) (GLenum coord, GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLTEXGENIOESPROC) (GLenum coord, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLTEXGENIVOESPROC) (GLenum coord, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXGENFVOESPROC) (GLenum coord, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETTEXGENIVOESPROC) (GLenum coord, GLenum pname, GLint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glTexGenfOES (GLenum coord, GLenum pname, GLfloat param); +GL_API void GL_APIENTRY glTexGenfvOES (GLenum coord, GLenum pname, const GLfloat *params); +GL_API void GL_APIENTRY glTexGeniOES (GLenum coord, GLenum pname, GLint param); +GL_API void GL_APIENTRY glTexGenivOES (GLenum coord, GLenum pname, const GLint *params); +GL_API void GL_APIENTRY glGetTexGenfvOES (GLenum coord, GLenum pname, GLfloat *params); +GL_API void GL_APIENTRY glGetTexGenivOES (GLenum coord, GLenum pname, GLint *params); +#endif +#endif /* GL_OES_texture_cube_map */ + +#ifndef GL_OES_texture_env_crossbar +#define GL_OES_texture_env_crossbar 1 +#endif /* GL_OES_texture_env_crossbar */ + +#ifndef GL_OES_texture_mirrored_repeat +#define GL_OES_texture_mirrored_repeat 1 +#define GL_MIRRORED_REPEAT_OES 0x8370 +#endif /* GL_OES_texture_mirrored_repeat */ + +#ifndef GL_OES_texture_npot +#define GL_OES_texture_npot 1 +#endif /* GL_OES_texture_npot */ + +#ifndef GL_OES_vertex_array_object +#define GL_OES_vertex_array_object 1 +#define GL_VERTEX_ARRAY_BINDING_OES 0x85B5 +typedef void (GL_APIENTRYP PFNGLBINDVERTEXARRAYOESPROC) (GLuint array); +typedef void (GL_APIENTRYP PFNGLDELETEVERTEXARRAYSOESPROC) (GLsizei n, const GLuint *arrays); +typedef void (GL_APIENTRYP PFNGLGENVERTEXARRAYSOESPROC) (GLsizei n, GLuint *arrays); +typedef GLboolean (GL_APIENTRYP PFNGLISVERTEXARRAYOESPROC) (GLuint array); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glBindVertexArrayOES (GLuint array); +GL_API void GL_APIENTRY glDeleteVertexArraysOES (GLsizei n, const GLuint *arrays); +GL_API void GL_APIENTRY glGenVertexArraysOES (GLsizei n, GLuint *arrays); +GL_API GLboolean GL_APIENTRY glIsVertexArrayOES (GLuint array); +#endif +#endif /* GL_OES_vertex_array_object */ + +#ifndef GL_AMD_compressed_3DC_texture +#define GL_AMD_compressed_3DC_texture 1 +#define GL_3DC_X_AMD 0x87F9 +#define GL_3DC_XY_AMD 0x87FA +#endif /* GL_AMD_compressed_3DC_texture */ + +#ifndef GL_AMD_compressed_ATC_texture +#define GL_AMD_compressed_ATC_texture 1 +#define GL_ATC_RGB_AMD 0x8C92 +#define GL_ATC_RGBA_EXPLICIT_ALPHA_AMD 0x8C93 +#define GL_ATC_RGBA_INTERPOLATED_ALPHA_AMD 0x87EE +#endif /* GL_AMD_compressed_ATC_texture */ + +#ifndef GL_APPLE_copy_texture_levels +#define GL_APPLE_copy_texture_levels 1 +typedef void (GL_APIENTRYP PFNGLCOPYTEXTURELEVELSAPPLEPROC) (GLuint destinationTexture, GLuint sourceTexture, GLint sourceBaseLevel, GLsizei sourceLevelCount); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glCopyTextureLevelsAPPLE (GLuint destinationTexture, GLuint sourceTexture, GLint sourceBaseLevel, GLsizei sourceLevelCount); +#endif +#endif /* GL_APPLE_copy_texture_levels */ + +#ifndef GL_APPLE_framebuffer_multisample +#define GL_APPLE_framebuffer_multisample 1 +#define GL_RENDERBUFFER_SAMPLES_APPLE 0x8CAB +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_APPLE 0x8D56 +#define GL_MAX_SAMPLES_APPLE 0x8D57 +#define GL_READ_FRAMEBUFFER_APPLE 0x8CA8 +#define GL_DRAW_FRAMEBUFFER_APPLE 0x8CA9 +#define GL_DRAW_FRAMEBUFFER_BINDING_APPLE 0x8CA6 +#define GL_READ_FRAMEBUFFER_BINDING_APPLE 0x8CAA +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEAPPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLRESOLVEMULTISAMPLEFRAMEBUFFERAPPLEPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glRenderbufferStorageMultisampleAPPLE (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +GL_API void GL_APIENTRY glResolveMultisampleFramebufferAPPLE (void); +#endif +#endif /* GL_APPLE_framebuffer_multisample */ + +#ifndef GL_APPLE_sync +#define GL_APPLE_sync 1 +typedef struct __GLsync *GLsync; +typedef khronos_uint64_t GLuint64; +typedef khronos_int64_t GLint64; +#define GL_SYNC_OBJECT_APPLE 0x8A53 +#define GL_MAX_SERVER_WAIT_TIMEOUT_APPLE 0x9111 +#define GL_OBJECT_TYPE_APPLE 0x9112 +#define GL_SYNC_CONDITION_APPLE 0x9113 +#define GL_SYNC_STATUS_APPLE 0x9114 +#define GL_SYNC_FLAGS_APPLE 0x9115 +#define GL_SYNC_FENCE_APPLE 0x9116 +#define GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE 0x9117 +#define GL_UNSIGNALED_APPLE 0x9118 +#define GL_SIGNALED_APPLE 0x9119 +#define GL_ALREADY_SIGNALED_APPLE 0x911A +#define GL_TIMEOUT_EXPIRED_APPLE 0x911B +#define GL_CONDITION_SATISFIED_APPLE 0x911C +#define GL_WAIT_FAILED_APPLE 0x911D +#define GL_SYNC_FLUSH_COMMANDS_BIT_APPLE 0x00000001 +#define GL_TIMEOUT_IGNORED_APPLE 0xFFFFFFFFFFFFFFFFull +typedef GLsync (GL_APIENTRYP PFNGLFENCESYNCAPPLEPROC) (GLenum condition, GLbitfield flags); +typedef GLboolean (GL_APIENTRYP PFNGLISSYNCAPPLEPROC) (GLsync sync); +typedef void (GL_APIENTRYP PFNGLDELETESYNCAPPLEPROC) (GLsync sync); +typedef GLenum (GL_APIENTRYP PFNGLCLIENTWAITSYNCAPPLEPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLWAITSYNCAPPLEPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64VAPPLEPROC) (GLenum pname, GLint64 *params); +typedef void (GL_APIENTRYP PFNGLGETSYNCIVAPPLEPROC) (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values); +#ifdef GL_GLEXT_PROTOTYPES +GL_API GLsync GL_APIENTRY glFenceSyncAPPLE (GLenum condition, GLbitfield flags); +GL_API GLboolean GL_APIENTRY glIsSyncAPPLE (GLsync sync); +GL_API void GL_APIENTRY glDeleteSyncAPPLE (GLsync sync); +GL_API GLenum GL_APIENTRY glClientWaitSyncAPPLE (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_API void GL_APIENTRY glWaitSyncAPPLE (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_API void GL_APIENTRY glGetInteger64vAPPLE (GLenum pname, GLint64 *params); +GL_API void GL_APIENTRY glGetSyncivAPPLE (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values); +#endif +#endif /* GL_APPLE_sync */ + +#ifndef GL_APPLE_texture_2D_limited_npot +#define GL_APPLE_texture_2D_limited_npot 1 +#endif /* GL_APPLE_texture_2D_limited_npot */ + +#ifndef GL_APPLE_texture_format_BGRA8888 +#define GL_APPLE_texture_format_BGRA8888 1 +#define GL_BGRA_EXT 0x80E1 +#define GL_BGRA8_EXT 0x93A1 +#endif /* GL_APPLE_texture_format_BGRA8888 */ + +#ifndef GL_APPLE_texture_max_level +#define GL_APPLE_texture_max_level 1 +#define GL_TEXTURE_MAX_LEVEL_APPLE 0x813D +#endif /* GL_APPLE_texture_max_level */ + +#ifndef GL_ARM_rgba8 +#define GL_ARM_rgba8 1 +#endif /* GL_ARM_rgba8 */ + +#ifndef GL_EXT_blend_minmax +#define GL_EXT_blend_minmax 1 +#define GL_MIN_EXT 0x8007 +#define GL_MAX_EXT 0x8008 +#endif /* GL_EXT_blend_minmax */ + +#ifndef GL_EXT_debug_marker +#define GL_EXT_debug_marker 1 +typedef char GLchar; +typedef void (GL_APIENTRYP PFNGLINSERTEVENTMARKEREXTPROC) (GLsizei length, const GLchar *marker); +typedef void (GL_APIENTRYP PFNGLPUSHGROUPMARKEREXTPROC) (GLsizei length, const GLchar *marker); +typedef void (GL_APIENTRYP PFNGLPOPGROUPMARKEREXTPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glInsertEventMarkerEXT (GLsizei length, const GLchar *marker); +GL_API void GL_APIENTRY glPushGroupMarkerEXT (GLsizei length, const GLchar *marker); +GL_API void GL_APIENTRY glPopGroupMarkerEXT (void); +#endif +#endif /* GL_EXT_debug_marker */ + +#ifndef GL_EXT_discard_framebuffer +#define GL_EXT_discard_framebuffer 1 +#define GL_COLOR_EXT 0x1800 +#define GL_DEPTH_EXT 0x1801 +#define GL_STENCIL_EXT 0x1802 +typedef void (GL_APIENTRYP PFNGLDISCARDFRAMEBUFFEREXTPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glDiscardFramebufferEXT (GLenum target, GLsizei numAttachments, const GLenum *attachments); +#endif +#endif /* GL_EXT_discard_framebuffer */ + +#ifndef GL_EXT_map_buffer_range +#define GL_EXT_map_buffer_range 1 +#define GL_MAP_READ_BIT_EXT 0x0001 +#define GL_MAP_WRITE_BIT_EXT 0x0002 +#define GL_MAP_INVALIDATE_RANGE_BIT_EXT 0x0004 +#define GL_MAP_INVALIDATE_BUFFER_BIT_EXT 0x0008 +#define GL_MAP_FLUSH_EXPLICIT_BIT_EXT 0x0010 +#define GL_MAP_UNSYNCHRONIZED_BIT_EXT 0x0020 +typedef void *(GL_APIENTRYP PFNGLMAPBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +typedef void (GL_APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void *GL_APIENTRY glMapBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +GL_API void GL_APIENTRY glFlushMappedBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length); +#endif +#endif /* GL_EXT_map_buffer_range */ + +#ifndef GL_EXT_multi_draw_arrays +#define GL_EXT_multi_draw_arrays 1 +typedef void (GL_APIENTRYP PFNGLMULTIDRAWARRAYSEXTPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei primcount); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glMultiDrawArraysEXT (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount); +GL_API void GL_APIENTRY glMultiDrawElementsEXT (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei primcount); +#endif +#endif /* GL_EXT_multi_draw_arrays */ + +#ifndef GL_EXT_multisampled_render_to_texture +#define GL_EXT_multisampled_render_to_texture 1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_SAMPLES_EXT 0x8D6C +#define GL_RENDERBUFFER_SAMPLES_EXT 0x8CAB +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT 0x8D56 +#define GL_MAX_SAMPLES_EXT 0x8D57 +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEEXTPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glRenderbufferStorageMultisampleEXT (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +GL_API void GL_APIENTRY glFramebufferTexture2DMultisampleEXT (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); +#endif +#endif /* GL_EXT_multisampled_render_to_texture */ + +#ifndef GL_EXT_read_format_bgra +#define GL_EXT_read_format_bgra 1 +#define GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT 0x8365 +#define GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT 0x8366 +#endif /* GL_EXT_read_format_bgra */ + +#ifndef GL_EXT_robustness +#define GL_EXT_robustness 1 +#define GL_GUILTY_CONTEXT_RESET_EXT 0x8253 +#define GL_INNOCENT_CONTEXT_RESET_EXT 0x8254 +#define GL_UNKNOWN_CONTEXT_RESET_EXT 0x8255 +#define GL_CONTEXT_ROBUST_ACCESS_EXT 0x90F3 +#define GL_RESET_NOTIFICATION_STRATEGY_EXT 0x8256 +#define GL_LOSE_CONTEXT_ON_RESET_EXT 0x8252 +#define GL_NO_RESET_NOTIFICATION_EXT 0x8261 +typedef GLenum (GL_APIENTRYP PFNGLGETGRAPHICSRESETSTATUSEXTPROC) (void); +typedef void (GL_APIENTRYP PFNGLREADNPIXELSEXTPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMFVEXTPROC) (GLuint program, GLint location, GLsizei bufSize, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMIVEXTPROC) (GLuint program, GLint location, GLsizei bufSize, GLint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_API GLenum GL_APIENTRY glGetGraphicsResetStatusEXT (void); +GL_API void GL_APIENTRY glReadnPixelsEXT (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data); +GL_API void GL_APIENTRY glGetnUniformfvEXT (GLuint program, GLint location, GLsizei bufSize, GLfloat *params); +GL_API void GL_APIENTRY glGetnUniformivEXT (GLuint program, GLint location, GLsizei bufSize, GLint *params); +#endif +#endif /* GL_EXT_robustness */ + +#ifndef GL_EXT_sRGB +#define GL_EXT_sRGB 1 +#define GL_SRGB_EXT 0x8C40 +#define GL_SRGB_ALPHA_EXT 0x8C42 +#define GL_SRGB8_ALPHA8_EXT 0x8C43 +#define GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING_EXT 0x8210 +#endif /* GL_EXT_sRGB */ + +#ifndef GL_EXT_texture_compression_dxt1 +#define GL_EXT_texture_compression_dxt1 1 +#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0 +#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1 +#endif /* GL_EXT_texture_compression_dxt1 */ + +#ifndef GL_EXT_texture_filter_anisotropic +#define GL_EXT_texture_filter_anisotropic 1 +#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE +#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF +#endif /* GL_EXT_texture_filter_anisotropic */ + +#ifndef GL_EXT_texture_format_BGRA8888 +#define GL_EXT_texture_format_BGRA8888 1 +#endif /* GL_EXT_texture_format_BGRA8888 */ + +#ifndef GL_EXT_texture_lod_bias +#define GL_EXT_texture_lod_bias 1 +#define GL_MAX_TEXTURE_LOD_BIAS_EXT 0x84FD +#define GL_TEXTURE_FILTER_CONTROL_EXT 0x8500 +#define GL_TEXTURE_LOD_BIAS_EXT 0x8501 +#endif /* GL_EXT_texture_lod_bias */ + +#ifndef GL_EXT_texture_storage +#define GL_EXT_texture_storage 1 +#define GL_TEXTURE_IMMUTABLE_FORMAT_EXT 0x912F +#define GL_ALPHA8_EXT 0x803C +#define GL_LUMINANCE8_EXT 0x8040 +#define GL_LUMINANCE8_ALPHA8_EXT 0x8045 +#define GL_RGBA32F_EXT 0x8814 +#define GL_RGB32F_EXT 0x8815 +#define GL_ALPHA32F_EXT 0x8816 +#define GL_LUMINANCE32F_EXT 0x8818 +#define GL_LUMINANCE_ALPHA32F_EXT 0x8819 +#define GL_RGBA16F_EXT 0x881A +#define GL_RGB16F_EXT 0x881B +#define GL_ALPHA16F_EXT 0x881C +#define GL_LUMINANCE16F_EXT 0x881E +#define GL_LUMINANCE_ALPHA16F_EXT 0x881F +#define GL_R8_EXT 0x8229 +#define GL_RG8_EXT 0x822B +#define GL_R32F_EXT 0x822E +#define GL_RG32F_EXT 0x8230 +#define GL_R16F_EXT 0x822D +#define GL_RG16F_EXT 0x822F +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE1DEXTPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DEXTPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE3DEXTPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGE1DEXTPROC) (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGE2DEXTPROC) (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGE3DEXTPROC) (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glTexStorage1DEXT (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width); +GL_API void GL_APIENTRY glTexStorage2DEXT (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +GL_API void GL_APIENTRY glTexStorage3DEXT (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +GL_API void GL_APIENTRY glTextureStorage1DEXT (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width); +GL_API void GL_APIENTRY glTextureStorage2DEXT (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +GL_API void GL_APIENTRY glTextureStorage3DEXT (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +#endif +#endif /* GL_EXT_texture_storage */ + +#ifndef GL_IMG_multisampled_render_to_texture +#define GL_IMG_multisampled_render_to_texture 1 +#define GL_RENDERBUFFER_SAMPLES_IMG 0x9133 +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_IMG 0x9134 +#define GL_MAX_SAMPLES_IMG 0x9135 +#define GL_TEXTURE_SAMPLES_IMG 0x9136 +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEIMGPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEIMGPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glRenderbufferStorageMultisampleIMG (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +GL_API void GL_APIENTRY glFramebufferTexture2DMultisampleIMG (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); +#endif +#endif /* GL_IMG_multisampled_render_to_texture */ + +#ifndef GL_IMG_read_format +#define GL_IMG_read_format 1 +#define GL_BGRA_IMG 0x80E1 +#define GL_UNSIGNED_SHORT_4_4_4_4_REV_IMG 0x8365 +#endif /* GL_IMG_read_format */ + +#ifndef GL_IMG_texture_compression_pvrtc +#define GL_IMG_texture_compression_pvrtc 1 +#define GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG 0x8C00 +#define GL_COMPRESSED_RGB_PVRTC_2BPPV1_IMG 0x8C01 +#define GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG 0x8C02 +#define GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG 0x8C03 +#endif /* GL_IMG_texture_compression_pvrtc */ + +#ifndef GL_IMG_texture_env_enhanced_fixed_function +#define GL_IMG_texture_env_enhanced_fixed_function 1 +#define GL_MODULATE_COLOR_IMG 0x8C04 +#define GL_RECIP_ADD_SIGNED_ALPHA_IMG 0x8C05 +#define GL_TEXTURE_ALPHA_MODULATE_IMG 0x8C06 +#define GL_FACTOR_ALPHA_MODULATE_IMG 0x8C07 +#define GL_FRAGMENT_ALPHA_MODULATE_IMG 0x8C08 +#define GL_ADD_BLEND_IMG 0x8C09 +#define GL_DOT3_RGBA_IMG 0x86AF +#endif /* GL_IMG_texture_env_enhanced_fixed_function */ + +#ifndef GL_IMG_user_clip_plane +#define GL_IMG_user_clip_plane 1 +#define GL_CLIP_PLANE0_IMG 0x3000 +#define GL_CLIP_PLANE1_IMG 0x3001 +#define GL_CLIP_PLANE2_IMG 0x3002 +#define GL_CLIP_PLANE3_IMG 0x3003 +#define GL_CLIP_PLANE4_IMG 0x3004 +#define GL_CLIP_PLANE5_IMG 0x3005 +#define GL_MAX_CLIP_PLANES_IMG 0x0D32 +typedef void (GL_APIENTRYP PFNGLCLIPPLANEFIMGPROC) (GLenum p, const GLfloat *eqn); +typedef void (GL_APIENTRYP PFNGLCLIPPLANEXIMGPROC) (GLenum p, const GLfixed *eqn); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glClipPlanefIMG (GLenum p, const GLfloat *eqn); +GL_API void GL_APIENTRY glClipPlanexIMG (GLenum p, const GLfixed *eqn); +#endif +#endif /* GL_IMG_user_clip_plane */ + +#ifndef GL_NV_fence +#define GL_NV_fence 1 +#define GL_ALL_COMPLETED_NV 0x84F2 +#define GL_FENCE_STATUS_NV 0x84F3 +#define GL_FENCE_CONDITION_NV 0x84F4 +typedef void (GL_APIENTRYP PFNGLDELETEFENCESNVPROC) (GLsizei n, const GLuint *fences); +typedef void (GL_APIENTRYP PFNGLGENFENCESNVPROC) (GLsizei n, GLuint *fences); +typedef GLboolean (GL_APIENTRYP PFNGLISFENCENVPROC) (GLuint fence); +typedef GLboolean (GL_APIENTRYP PFNGLTESTFENCENVPROC) (GLuint fence); +typedef void (GL_APIENTRYP PFNGLGETFENCEIVNVPROC) (GLuint fence, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLFINISHFENCENVPROC) (GLuint fence); +typedef void (GL_APIENTRYP PFNGLSETFENCENVPROC) (GLuint fence, GLenum condition); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glDeleteFencesNV (GLsizei n, const GLuint *fences); +GL_API void GL_APIENTRY glGenFencesNV (GLsizei n, GLuint *fences); +GL_API GLboolean GL_APIENTRY glIsFenceNV (GLuint fence); +GL_API GLboolean GL_APIENTRY glTestFenceNV (GLuint fence); +GL_API void GL_APIENTRY glGetFenceivNV (GLuint fence, GLenum pname, GLint *params); +GL_API void GL_APIENTRY glFinishFenceNV (GLuint fence); +GL_API void GL_APIENTRY glSetFenceNV (GLuint fence, GLenum condition); +#endif +#endif /* GL_NV_fence */ + +#ifndef GL_QCOM_driver_control +#define GL_QCOM_driver_control 1 +typedef void (GL_APIENTRYP PFNGLGETDRIVERCONTROLSQCOMPROC) (GLint *num, GLsizei size, GLuint *driverControls); +typedef void (GL_APIENTRYP PFNGLGETDRIVERCONTROLSTRINGQCOMPROC) (GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString); +typedef void (GL_APIENTRYP PFNGLENABLEDRIVERCONTROLQCOMPROC) (GLuint driverControl); +typedef void (GL_APIENTRYP PFNGLDISABLEDRIVERCONTROLQCOMPROC) (GLuint driverControl); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glGetDriverControlsQCOM (GLint *num, GLsizei size, GLuint *driverControls); +GL_API void GL_APIENTRY glGetDriverControlStringQCOM (GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString); +GL_API void GL_APIENTRY glEnableDriverControlQCOM (GLuint driverControl); +GL_API void GL_APIENTRY glDisableDriverControlQCOM (GLuint driverControl); +#endif +#endif /* GL_QCOM_driver_control */ + +#ifndef GL_QCOM_extended_get +#define GL_QCOM_extended_get 1 +#define GL_TEXTURE_WIDTH_QCOM 0x8BD2 +#define GL_TEXTURE_HEIGHT_QCOM 0x8BD3 +#define GL_TEXTURE_DEPTH_QCOM 0x8BD4 +#define GL_TEXTURE_INTERNAL_FORMAT_QCOM 0x8BD5 +#define GL_TEXTURE_FORMAT_QCOM 0x8BD6 +#define GL_TEXTURE_TYPE_QCOM 0x8BD7 +#define GL_TEXTURE_IMAGE_VALID_QCOM 0x8BD8 +#define GL_TEXTURE_NUM_LEVELS_QCOM 0x8BD9 +#define GL_TEXTURE_TARGET_QCOM 0x8BDA +#define GL_TEXTURE_OBJECT_VALID_QCOM 0x8BDB +#define GL_STATE_RESTORE 0x8BDC +typedef void (GL_APIENTRYP PFNGLEXTGETTEXTURESQCOMPROC) (GLuint *textures, GLint maxTextures, GLint *numTextures); +typedef void (GL_APIENTRYP PFNGLEXTGETBUFFERSQCOMPROC) (GLuint *buffers, GLint maxBuffers, GLint *numBuffers); +typedef void (GL_APIENTRYP PFNGLEXTGETRENDERBUFFERSQCOMPROC) (GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers); +typedef void (GL_APIENTRYP PFNGLEXTGETFRAMEBUFFERSQCOMPROC) (GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers); +typedef void (GL_APIENTRYP PFNGLEXTGETTEXLEVELPARAMETERIVQCOMPROC) (GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLEXTTEXOBJECTSTATEOVERRIDEIQCOMPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLEXTGETTEXSUBIMAGEQCOMPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, void *texels); +typedef void (GL_APIENTRYP PFNGLEXTGETBUFFERPOINTERVQCOMPROC) (GLenum target, void **params); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glExtGetTexturesQCOM (GLuint *textures, GLint maxTextures, GLint *numTextures); +GL_API void GL_APIENTRY glExtGetBuffersQCOM (GLuint *buffers, GLint maxBuffers, GLint *numBuffers); +GL_API void GL_APIENTRY glExtGetRenderbuffersQCOM (GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers); +GL_API void GL_APIENTRY glExtGetFramebuffersQCOM (GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers); +GL_API void GL_APIENTRY glExtGetTexLevelParameterivQCOM (GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params); +GL_API void GL_APIENTRY glExtTexObjectStateOverrideiQCOM (GLenum target, GLenum pname, GLint param); +GL_API void GL_APIENTRY glExtGetTexSubImageQCOM (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, void *texels); +GL_API void GL_APIENTRY glExtGetBufferPointervQCOM (GLenum target, void **params); +#endif +#endif /* GL_QCOM_extended_get */ + +#ifndef GL_QCOM_extended_get2 +#define GL_QCOM_extended_get2 1 +typedef void (GL_APIENTRYP PFNGLEXTGETSHADERSQCOMPROC) (GLuint *shaders, GLint maxShaders, GLint *numShaders); +typedef void (GL_APIENTRYP PFNGLEXTGETPROGRAMSQCOMPROC) (GLuint *programs, GLint maxPrograms, GLint *numPrograms); +typedef GLboolean (GL_APIENTRYP PFNGLEXTISPROGRAMBINARYQCOMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLEXTGETPROGRAMBINARYSOURCEQCOMPROC) (GLuint program, GLenum shadertype, GLchar *source, GLint *length); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glExtGetShadersQCOM (GLuint *shaders, GLint maxShaders, GLint *numShaders); +GL_API void GL_APIENTRY glExtGetProgramsQCOM (GLuint *programs, GLint maxPrograms, GLint *numPrograms); +GL_API GLboolean GL_APIENTRY glExtIsProgramBinaryQCOM (GLuint program); +GL_API void GL_APIENTRY glExtGetProgramBinarySourceQCOM (GLuint program, GLenum shadertype, GLchar *source, GLint *length); +#endif +#endif /* GL_QCOM_extended_get2 */ + +#ifndef GL_QCOM_perfmon_global_mode +#define GL_QCOM_perfmon_global_mode 1 +#define GL_PERFMON_GLOBAL_MODE_QCOM 0x8FA0 +#endif /* GL_QCOM_perfmon_global_mode */ + +#ifndef GL_QCOM_tiled_rendering +#define GL_QCOM_tiled_rendering 1 +#define GL_COLOR_BUFFER_BIT0_QCOM 0x00000001 +#define GL_COLOR_BUFFER_BIT1_QCOM 0x00000002 +#define GL_COLOR_BUFFER_BIT2_QCOM 0x00000004 +#define GL_COLOR_BUFFER_BIT3_QCOM 0x00000008 +#define GL_COLOR_BUFFER_BIT4_QCOM 0x00000010 +#define GL_COLOR_BUFFER_BIT5_QCOM 0x00000020 +#define GL_COLOR_BUFFER_BIT6_QCOM 0x00000040 +#define GL_COLOR_BUFFER_BIT7_QCOM 0x00000080 +#define GL_DEPTH_BUFFER_BIT0_QCOM 0x00000100 +#define GL_DEPTH_BUFFER_BIT1_QCOM 0x00000200 +#define GL_DEPTH_BUFFER_BIT2_QCOM 0x00000400 +#define GL_DEPTH_BUFFER_BIT3_QCOM 0x00000800 +#define GL_DEPTH_BUFFER_BIT4_QCOM 0x00001000 +#define GL_DEPTH_BUFFER_BIT5_QCOM 0x00002000 +#define GL_DEPTH_BUFFER_BIT6_QCOM 0x00004000 +#define GL_DEPTH_BUFFER_BIT7_QCOM 0x00008000 +#define GL_STENCIL_BUFFER_BIT0_QCOM 0x00010000 +#define GL_STENCIL_BUFFER_BIT1_QCOM 0x00020000 +#define GL_STENCIL_BUFFER_BIT2_QCOM 0x00040000 +#define GL_STENCIL_BUFFER_BIT3_QCOM 0x00080000 +#define GL_STENCIL_BUFFER_BIT4_QCOM 0x00100000 +#define GL_STENCIL_BUFFER_BIT5_QCOM 0x00200000 +#define GL_STENCIL_BUFFER_BIT6_QCOM 0x00400000 +#define GL_STENCIL_BUFFER_BIT7_QCOM 0x00800000 +#define GL_MULTISAMPLE_BUFFER_BIT0_QCOM 0x01000000 +#define GL_MULTISAMPLE_BUFFER_BIT1_QCOM 0x02000000 +#define GL_MULTISAMPLE_BUFFER_BIT2_QCOM 0x04000000 +#define GL_MULTISAMPLE_BUFFER_BIT3_QCOM 0x08000000 +#define GL_MULTISAMPLE_BUFFER_BIT4_QCOM 0x10000000 +#define GL_MULTISAMPLE_BUFFER_BIT5_QCOM 0x20000000 +#define GL_MULTISAMPLE_BUFFER_BIT6_QCOM 0x40000000 +#define GL_MULTISAMPLE_BUFFER_BIT7_QCOM 0x80000000 +typedef void (GL_APIENTRYP PFNGLSTARTTILINGQCOMPROC) (GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask); +typedef void (GL_APIENTRYP PFNGLENDTILINGQCOMPROC) (GLbitfield preserveMask); +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glStartTilingQCOM (GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask); +GL_API void GL_APIENTRY glEndTilingQCOM (GLbitfield preserveMask); +#endif +#endif /* GL_QCOM_tiled_rendering */ + +#ifndef GL_QCOM_writeonly_rendering +#define GL_QCOM_writeonly_rendering 1 +#define GL_WRITEONLY_RENDERING_QCOM 0x8823 +#endif /* GL_QCOM_writeonly_rendering */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/GLES/glplatform.h b/gfx/angle/checkout/include/GLES/glplatform.h new file mode 100644 index 0000000000..16060a9a73 --- /dev/null +++ b/gfx/angle/checkout/include/GLES/glplatform.h @@ -0,0 +1,38 @@ +#ifndef __glplatform_h_ +#define __glplatform_h_ + +/* +** Copyright (c) 2017 The Khronos Group Inc. +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ + +/* Platform-specific types and definitions for OpenGL ES 1.X gl.h + * + * Adopters may modify khrplatform.h and this file to suit their platform. + * Please contribute modifications back to Khronos as pull requests on the + * public github repository: + * https://github.com/KhronosGroup/OpenGL-Registry + */ + +#include + +#ifndef GL_API +#define GL_API KHRONOS_APICALL +#endif + +#ifndef GL_APIENTRY +#define GL_APIENTRY KHRONOS_APIENTRY +#endif + +#endif /* __glplatform_h_ */ diff --git a/gfx/angle/checkout/include/GLES2/gl2.h b/gfx/angle/checkout/include/GLES2/gl2.h new file mode 100644 index 0000000000..3c5e6d3d6e --- /dev/null +++ b/gfx/angle/checkout/include/GLES2/gl2.h @@ -0,0 +1,656 @@ +#ifndef __gles2_gl2_h_ +#define __gles2_gl2_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright 2013-2020 The Khronos Group Inc. +** SPDX-License-Identifier: MIT +** +** This header is generated from the Khronos OpenGL / OpenGL ES XML +** API Registry. The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** https://github.com/KhronosGroup/OpenGL-Registry +*/ + +#include + +#ifndef GL_APIENTRYP +#define GL_APIENTRYP GL_APIENTRY* +#endif + +#ifndef GL_GLES_PROTOTYPES +#define GL_GLES_PROTOTYPES 1 +#endif + +/* Generated on date 20210107 */ + +/* Generated C header for: + * API: gles2 + * Profile: common + * Versions considered: 2\.[0-9] + * Versions emitted: .* + * Default extensions included: None + * Additional extensions included: _nomatch_^ + * Extensions removed: _nomatch_^ + */ + +#ifndef GL_ES_VERSION_2_0 +#define GL_ES_VERSION_2_0 1 +#include +typedef khronos_int8_t GLbyte; +typedef khronos_float_t GLclampf; +typedef khronos_int32_t GLfixed; +typedef khronos_int16_t GLshort; +typedef khronos_uint16_t GLushort; +typedef void GLvoid; +typedef struct __GLsync *GLsync; +typedef khronos_int64_t GLint64; +typedef khronos_uint64_t GLuint64; +typedef unsigned int GLenum; +typedef unsigned int GLuint; +typedef char GLchar; +typedef khronos_float_t GLfloat; +typedef khronos_ssize_t GLsizeiptr; +typedef khronos_intptr_t GLintptr; +typedef unsigned int GLbitfield; +typedef int GLint; +typedef unsigned char GLboolean; +typedef int GLsizei; +typedef khronos_uint8_t GLubyte; +#define GL_DEPTH_BUFFER_BIT 0x00000100 +#define GL_STENCIL_BUFFER_BIT 0x00000400 +#define GL_COLOR_BUFFER_BIT 0x00004000 +#define GL_FALSE 0 +#define GL_TRUE 1 +#define GL_POINTS 0x0000 +#define GL_LINES 0x0001 +#define GL_LINE_LOOP 0x0002 +#define GL_LINE_STRIP 0x0003 +#define GL_TRIANGLES 0x0004 +#define GL_TRIANGLE_STRIP 0x0005 +#define GL_TRIANGLE_FAN 0x0006 +#define GL_ZERO 0 +#define GL_ONE 1 +#define GL_SRC_COLOR 0x0300 +#define GL_ONE_MINUS_SRC_COLOR 0x0301 +#define GL_SRC_ALPHA 0x0302 +#define GL_ONE_MINUS_SRC_ALPHA 0x0303 +#define GL_DST_ALPHA 0x0304 +#define GL_ONE_MINUS_DST_ALPHA 0x0305 +#define GL_DST_COLOR 0x0306 +#define GL_ONE_MINUS_DST_COLOR 0x0307 +#define GL_SRC_ALPHA_SATURATE 0x0308 +#define GL_FUNC_ADD 0x8006 +#define GL_BLEND_EQUATION 0x8009 +#define GL_BLEND_EQUATION_RGB 0x8009 +#define GL_BLEND_EQUATION_ALPHA 0x883D +#define GL_FUNC_SUBTRACT 0x800A +#define GL_FUNC_REVERSE_SUBTRACT 0x800B +#define GL_BLEND_DST_RGB 0x80C8 +#define GL_BLEND_SRC_RGB 0x80C9 +#define GL_BLEND_DST_ALPHA 0x80CA +#define GL_BLEND_SRC_ALPHA 0x80CB +#define GL_CONSTANT_COLOR 0x8001 +#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002 +#define GL_CONSTANT_ALPHA 0x8003 +#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004 +#define GL_BLEND_COLOR 0x8005 +#define GL_ARRAY_BUFFER 0x8892 +#define GL_ELEMENT_ARRAY_BUFFER 0x8893 +#define GL_ARRAY_BUFFER_BINDING 0x8894 +#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895 +#define GL_STREAM_DRAW 0x88E0 +#define GL_STATIC_DRAW 0x88E4 +#define GL_DYNAMIC_DRAW 0x88E8 +#define GL_BUFFER_SIZE 0x8764 +#define GL_BUFFER_USAGE 0x8765 +#define GL_CURRENT_VERTEX_ATTRIB 0x8626 +#define GL_FRONT 0x0404 +#define GL_BACK 0x0405 +#define GL_FRONT_AND_BACK 0x0408 +#define GL_TEXTURE_2D 0x0DE1 +#define GL_CULL_FACE 0x0B44 +#define GL_BLEND 0x0BE2 +#define GL_DITHER 0x0BD0 +#define GL_STENCIL_TEST 0x0B90 +#define GL_DEPTH_TEST 0x0B71 +#define GL_SCISSOR_TEST 0x0C11 +#define GL_POLYGON_OFFSET_FILL 0x8037 +#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E +#define GL_SAMPLE_COVERAGE 0x80A0 +#define GL_NO_ERROR 0 +#define GL_INVALID_ENUM 0x0500 +#define GL_INVALID_VALUE 0x0501 +#define GL_INVALID_OPERATION 0x0502 +#define GL_OUT_OF_MEMORY 0x0505 +#define GL_CW 0x0900 +#define GL_CCW 0x0901 +#define GL_LINE_WIDTH 0x0B21 +#define GL_ALIASED_POINT_SIZE_RANGE 0x846D +#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E +#define GL_CULL_FACE_MODE 0x0B45 +#define GL_FRONT_FACE 0x0B46 +#define GL_DEPTH_RANGE 0x0B70 +#define GL_DEPTH_WRITEMASK 0x0B72 +#define GL_DEPTH_CLEAR_VALUE 0x0B73 +#define GL_DEPTH_FUNC 0x0B74 +#define GL_STENCIL_CLEAR_VALUE 0x0B91 +#define GL_STENCIL_FUNC 0x0B92 +#define GL_STENCIL_FAIL 0x0B94 +#define GL_STENCIL_PASS_DEPTH_FAIL 0x0B95 +#define GL_STENCIL_PASS_DEPTH_PASS 0x0B96 +#define GL_STENCIL_REF 0x0B97 +#define GL_STENCIL_VALUE_MASK 0x0B93 +#define GL_STENCIL_WRITEMASK 0x0B98 +#define GL_STENCIL_BACK_FUNC 0x8800 +#define GL_STENCIL_BACK_FAIL 0x8801 +#define GL_STENCIL_BACK_PASS_DEPTH_FAIL 0x8802 +#define GL_STENCIL_BACK_PASS_DEPTH_PASS 0x8803 +#define GL_STENCIL_BACK_REF 0x8CA3 +#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4 +#define GL_STENCIL_BACK_WRITEMASK 0x8CA5 +#define GL_VIEWPORT 0x0BA2 +#define GL_SCISSOR_BOX 0x0C10 +#define GL_COLOR_CLEAR_VALUE 0x0C22 +#define GL_COLOR_WRITEMASK 0x0C23 +#define GL_UNPACK_ALIGNMENT 0x0CF5 +#define GL_PACK_ALIGNMENT 0x0D05 +#define GL_MAX_TEXTURE_SIZE 0x0D33 +#define GL_MAX_VIEWPORT_DIMS 0x0D3A +#define GL_SUBPIXEL_BITS 0x0D50 +#define GL_RED_BITS 0x0D52 +#define GL_GREEN_BITS 0x0D53 +#define GL_BLUE_BITS 0x0D54 +#define GL_ALPHA_BITS 0x0D55 +#define GL_DEPTH_BITS 0x0D56 +#define GL_STENCIL_BITS 0x0D57 +#define GL_POLYGON_OFFSET_UNITS 0x2A00 +#define GL_POLYGON_OFFSET_FACTOR 0x8038 +#define GL_TEXTURE_BINDING_2D 0x8069 +#define GL_SAMPLE_BUFFERS 0x80A8 +#define GL_SAMPLES 0x80A9 +#define GL_SAMPLE_COVERAGE_VALUE 0x80AA +#define GL_SAMPLE_COVERAGE_INVERT 0x80AB +#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 +#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 +#define GL_DONT_CARE 0x1100 +#define GL_FASTEST 0x1101 +#define GL_NICEST 0x1102 +#define GL_GENERATE_MIPMAP_HINT 0x8192 +#define GL_BYTE 0x1400 +#define GL_UNSIGNED_BYTE 0x1401 +#define GL_SHORT 0x1402 +#define GL_UNSIGNED_SHORT 0x1403 +#define GL_INT 0x1404 +#define GL_UNSIGNED_INT 0x1405 +#define GL_FLOAT 0x1406 +#define GL_FIXED 0x140C +#define GL_DEPTH_COMPONENT 0x1902 +#define GL_ALPHA 0x1906 +#define GL_RGB 0x1907 +#define GL_RGBA 0x1908 +#define GL_LUMINANCE 0x1909 +#define GL_LUMINANCE_ALPHA 0x190A +#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033 +#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034 +#define GL_UNSIGNED_SHORT_5_6_5 0x8363 +#define GL_FRAGMENT_SHADER 0x8B30 +#define GL_VERTEX_SHADER 0x8B31 +#define GL_MAX_VERTEX_ATTRIBS 0x8869 +#define GL_MAX_VERTEX_UNIFORM_VECTORS 0x8DFB +#define GL_MAX_VARYING_VECTORS 0x8DFC +#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS 0x8B4D +#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS 0x8B4C +#define GL_MAX_TEXTURE_IMAGE_UNITS 0x8872 +#define GL_MAX_FRAGMENT_UNIFORM_VECTORS 0x8DFD +#define GL_SHADER_TYPE 0x8B4F +#define GL_DELETE_STATUS 0x8B80 +#define GL_LINK_STATUS 0x8B82 +#define GL_VALIDATE_STATUS 0x8B83 +#define GL_ATTACHED_SHADERS 0x8B85 +#define GL_ACTIVE_UNIFORMS 0x8B86 +#define GL_ACTIVE_UNIFORM_MAX_LENGTH 0x8B87 +#define GL_ACTIVE_ATTRIBUTES 0x8B89 +#define GL_ACTIVE_ATTRIBUTE_MAX_LENGTH 0x8B8A +#define GL_SHADING_LANGUAGE_VERSION 0x8B8C +#define GL_CURRENT_PROGRAM 0x8B8D +#define GL_NEVER 0x0200 +#define GL_LESS 0x0201 +#define GL_EQUAL 0x0202 +#define GL_LEQUAL 0x0203 +#define GL_GREATER 0x0204 +#define GL_NOTEQUAL 0x0205 +#define GL_GEQUAL 0x0206 +#define GL_ALWAYS 0x0207 +#define GL_KEEP 0x1E00 +#define GL_REPLACE 0x1E01 +#define GL_INCR 0x1E02 +#define GL_DECR 0x1E03 +#define GL_INVERT 0x150A +#define GL_INCR_WRAP 0x8507 +#define GL_DECR_WRAP 0x8508 +#define GL_VENDOR 0x1F00 +#define GL_RENDERER 0x1F01 +#define GL_VERSION 0x1F02 +#define GL_EXTENSIONS 0x1F03 +#define GL_NEAREST 0x2600 +#define GL_LINEAR 0x2601 +#define GL_NEAREST_MIPMAP_NEAREST 0x2700 +#define GL_LINEAR_MIPMAP_NEAREST 0x2701 +#define GL_NEAREST_MIPMAP_LINEAR 0x2702 +#define GL_LINEAR_MIPMAP_LINEAR 0x2703 +#define GL_TEXTURE_MAG_FILTER 0x2800 +#define GL_TEXTURE_MIN_FILTER 0x2801 +#define GL_TEXTURE_WRAP_S 0x2802 +#define GL_TEXTURE_WRAP_T 0x2803 +#define GL_TEXTURE 0x1702 +#define GL_TEXTURE_CUBE_MAP 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C +#define GL_TEXTURE0 0x84C0 +#define GL_TEXTURE1 0x84C1 +#define GL_TEXTURE2 0x84C2 +#define GL_TEXTURE3 0x84C3 +#define GL_TEXTURE4 0x84C4 +#define GL_TEXTURE5 0x84C5 +#define GL_TEXTURE6 0x84C6 +#define GL_TEXTURE7 0x84C7 +#define GL_TEXTURE8 0x84C8 +#define GL_TEXTURE9 0x84C9 +#define GL_TEXTURE10 0x84CA +#define GL_TEXTURE11 0x84CB +#define GL_TEXTURE12 0x84CC +#define GL_TEXTURE13 0x84CD +#define GL_TEXTURE14 0x84CE +#define GL_TEXTURE15 0x84CF +#define GL_TEXTURE16 0x84D0 +#define GL_TEXTURE17 0x84D1 +#define GL_TEXTURE18 0x84D2 +#define GL_TEXTURE19 0x84D3 +#define GL_TEXTURE20 0x84D4 +#define GL_TEXTURE21 0x84D5 +#define GL_TEXTURE22 0x84D6 +#define GL_TEXTURE23 0x84D7 +#define GL_TEXTURE24 0x84D8 +#define GL_TEXTURE25 0x84D9 +#define GL_TEXTURE26 0x84DA +#define GL_TEXTURE27 0x84DB +#define GL_TEXTURE28 0x84DC +#define GL_TEXTURE29 0x84DD +#define GL_TEXTURE30 0x84DE +#define GL_TEXTURE31 0x84DF +#define GL_ACTIVE_TEXTURE 0x84E0 +#define GL_REPEAT 0x2901 +#define GL_CLAMP_TO_EDGE 0x812F +#define GL_MIRRORED_REPEAT 0x8370 +#define GL_FLOAT_VEC2 0x8B50 +#define GL_FLOAT_VEC3 0x8B51 +#define GL_FLOAT_VEC4 0x8B52 +#define GL_INT_VEC2 0x8B53 +#define GL_INT_VEC3 0x8B54 +#define GL_INT_VEC4 0x8B55 +#define GL_BOOL 0x8B56 +#define GL_BOOL_VEC2 0x8B57 +#define GL_BOOL_VEC3 0x8B58 +#define GL_BOOL_VEC4 0x8B59 +#define GL_FLOAT_MAT2 0x8B5A +#define GL_FLOAT_MAT3 0x8B5B +#define GL_FLOAT_MAT4 0x8B5C +#define GL_SAMPLER_2D 0x8B5E +#define GL_SAMPLER_CUBE 0x8B60 +#define GL_VERTEX_ATTRIB_ARRAY_ENABLED 0x8622 +#define GL_VERTEX_ATTRIB_ARRAY_SIZE 0x8623 +#define GL_VERTEX_ATTRIB_ARRAY_STRIDE 0x8624 +#define GL_VERTEX_ATTRIB_ARRAY_TYPE 0x8625 +#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED 0x886A +#define GL_VERTEX_ATTRIB_ARRAY_POINTER 0x8645 +#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 0x889F +#define GL_IMPLEMENTATION_COLOR_READ_TYPE 0x8B9A +#define GL_IMPLEMENTATION_COLOR_READ_FORMAT 0x8B9B +#define GL_COMPILE_STATUS 0x8B81 +#define GL_INFO_LOG_LENGTH 0x8B84 +#define GL_SHADER_SOURCE_LENGTH 0x8B88 +#define GL_SHADER_COMPILER 0x8DFA +#define GL_SHADER_BINARY_FORMATS 0x8DF8 +#define GL_NUM_SHADER_BINARY_FORMATS 0x8DF9 +#define GL_LOW_FLOAT 0x8DF0 +#define GL_MEDIUM_FLOAT 0x8DF1 +#define GL_HIGH_FLOAT 0x8DF2 +#define GL_LOW_INT 0x8DF3 +#define GL_MEDIUM_INT 0x8DF4 +#define GL_HIGH_INT 0x8DF5 +#define GL_FRAMEBUFFER 0x8D40 +#define GL_RENDERBUFFER 0x8D41 +#define GL_RGBA4 0x8056 +#define GL_RGB5_A1 0x8057 +#define GL_RGB565 0x8D62 +#define GL_DEPTH_COMPONENT16 0x81A5 +#define GL_STENCIL_INDEX8 0x8D48 +#define GL_RENDERBUFFER_WIDTH 0x8D42 +#define GL_RENDERBUFFER_HEIGHT 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT 0x8D44 +#define GL_RENDERBUFFER_RED_SIZE 0x8D50 +#define GL_RENDERBUFFER_GREEN_SIZE 0x8D51 +#define GL_RENDERBUFFER_BLUE_SIZE 0x8D52 +#define GL_RENDERBUFFER_ALPHA_SIZE 0x8D53 +#define GL_RENDERBUFFER_DEPTH_SIZE 0x8D54 +#define GL_RENDERBUFFER_STENCIL_SIZE 0x8D55 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE 0x8CD3 +#define GL_COLOR_ATTACHMENT0 0x8CE0 +#define GL_DEPTH_ATTACHMENT 0x8D00 +#define GL_STENCIL_ATTACHMENT 0x8D20 +#define GL_NONE 0 +#define GL_FRAMEBUFFER_COMPLETE 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS 0x8CD9 +#define GL_FRAMEBUFFER_UNSUPPORTED 0x8CDD +#define GL_FRAMEBUFFER_BINDING 0x8CA6 +#define GL_RENDERBUFFER_BINDING 0x8CA7 +#define GL_MAX_RENDERBUFFER_SIZE 0x84E8 +#define GL_INVALID_FRAMEBUFFER_OPERATION 0x0506 +typedef void (GL_APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); +typedef void (GL_APIENTRYP PFNGLATTACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (GL_APIENTRYP PFNGLBINDATTRIBLOCATIONPROC) (GLuint program, GLuint index, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERPROC) (GLenum target, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLBINDFRAMEBUFFERPROC) (GLenum target, GLuint framebuffer); +typedef void (GL_APIENTRYP PFNGLBINDRENDERBUFFERPROC) (GLenum target, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLBINDTEXTUREPROC) (GLenum target, GLuint texture); +typedef void (GL_APIENTRYP PFNGLBLENDCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEPROC) (GLenum modeRGB, GLenum modeAlpha); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCPROC) (GLenum sfactor, GLenum dfactor); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +typedef void (GL_APIENTRYP PFNGLBUFFERDATAPROC) (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +typedef void (GL_APIENTRYP PFNGLBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +typedef GLenum (GL_APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLCLEARPROC) (GLbitfield mask); +typedef void (GL_APIENTRYP PFNGLCLEARCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLCLEARDEPTHFPROC) (GLfloat d); +typedef void (GL_APIENTRYP PFNGLCLEARSTENCILPROC) (GLint s); +typedef void (GL_APIENTRYP PFNGLCOLORMASKPROC) (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +typedef void (GL_APIENTRYP PFNGLCOMPILESHADERPROC) (GLuint shader); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOPYTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef GLuint (GL_APIENTRYP PFNGLCREATEPROGRAMPROC) (void); +typedef GLuint (GL_APIENTRYP PFNGLCREATESHADERPROC) (GLenum type); +typedef void (GL_APIENTRYP PFNGLCULLFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLDELETEBUFFERSPROC) (GLsizei n, const GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLDELETEFRAMEBUFFERSPROC) (GLsizei n, const GLuint *framebuffers); +typedef void (GL_APIENTRYP PFNGLDELETEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLDELETERENDERBUFFERSPROC) (GLsizei n, const GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLDELETESHADERPROC) (GLuint shader); +typedef void (GL_APIENTRYP PFNGLDELETETEXTURESPROC) (GLsizei n, const GLuint *textures); +typedef void (GL_APIENTRYP PFNGLDEPTHFUNCPROC) (GLenum func); +typedef void (GL_APIENTRYP PFNGLDEPTHMASKPROC) (GLboolean flag); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEFPROC) (GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLDETACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (GL_APIENTRYP PFNGLDISABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSPROC) (GLenum mode, GLint first, GLsizei count); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices); +typedef void (GL_APIENTRYP PFNGLENABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (GL_APIENTRYP PFNGLFINISHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFLUSHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFERPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (GL_APIENTRYP PFNGLFRONTFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLGENBUFFERSPROC) (GLsizei n, GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLGENERATEMIPMAPPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGENFRAMEBUFFERSPROC) (GLsizei n, GLuint *framebuffers); +typedef void (GL_APIENTRYP PFNGLGENRENDERBUFFERSPROC) (GLsizei n, GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLGENTEXTURESPROC) (GLsizei n, GLuint *textures); +typedef void (GL_APIENTRYP PFNGLGETACTIVEATTRIBPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETATTACHEDSHADERSPROC) (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *shaders); +typedef GLint (GL_APIENTRYP PFNGLGETATTRIBLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETBOOLEANVPROC) (GLenum pname, GLboolean *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef GLenum (GL_APIENTRYP PFNGLGETERRORPROC) (void); +typedef void (GL_APIENTRYP PFNGLGETFLOATVPROC) (GLenum pname, GLfloat *data); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETINTEGERVPROC) (GLenum pname, GLint *data); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMIVPROC) (GLuint program, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMINFOLOGPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSHADERIVPROC) (GLuint shader, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSHADERINFOLOGPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLGETSHADERPRECISIONFORMATPROC) (GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision); +typedef void (GL_APIENTRYP PFNGLGETSHADERSOURCEPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +typedef const GLubyte *(GL_APIENTRYP PFNGLGETSTRINGPROC) (GLenum name); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMFVPROC) (GLuint program, GLint location, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMIVPROC) (GLuint program, GLint location, GLint *params); +typedef GLint (GL_APIENTRYP PFNGLGETUNIFORMLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBFVPROC) (GLuint index, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVPROC) (GLuint index, GLenum pname, void **pointer); +typedef void (GL_APIENTRYP PFNGLHINTPROC) (GLenum target, GLenum mode); +typedef GLboolean (GL_APIENTRYP PFNGLISBUFFERPROC) (GLuint buffer); +typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDPROC) (GLenum cap); +typedef GLboolean (GL_APIENTRYP PFNGLISFRAMEBUFFERPROC) (GLuint framebuffer); +typedef GLboolean (GL_APIENTRYP PFNGLISPROGRAMPROC) (GLuint program); +typedef GLboolean (GL_APIENTRYP PFNGLISRENDERBUFFERPROC) (GLuint renderbuffer); +typedef GLboolean (GL_APIENTRYP PFNGLISSHADERPROC) (GLuint shader); +typedef GLboolean (GL_APIENTRYP PFNGLISTEXTUREPROC) (GLuint texture); +typedef void (GL_APIENTRYP PFNGLLINEWIDTHPROC) (GLfloat width); +typedef void (GL_APIENTRYP PFNGLLINKPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLPIXELSTOREIPROC) (GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLPOLYGONOFFSETPROC) (GLfloat factor, GLfloat units); +typedef void (GL_APIENTRYP PFNGLREADPIXELSPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +typedef void (GL_APIENTRYP PFNGLRELEASESHADERCOMPILERPROC) (void); +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert); +typedef void (GL_APIENTRYP PFNGLSCISSORPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSHADERBINARYPROC) (GLsizei count, const GLuint *shaders, GLenum binaryFormat, const void *binary, GLsizei length); +typedef void (GL_APIENTRYP PFNGLSHADERSOURCEPROC) (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length); +typedef void (GL_APIENTRYP PFNGLSTENCILFUNCPROC) (GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILFUNCSEPARATEPROC) (GLenum face, GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILMASKPROC) (GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILMASKSEPARATEPROC) (GLenum face, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILOPPROC) (GLenum fail, GLenum zfail, GLenum zpass); +typedef void (GL_APIENTRYP PFNGLSTENCILOPSEPARATEPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE2DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFPROC) (GLenum target, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLUNIFORM1FPROC) (GLint location, GLfloat v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM1FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM1IPROC) (GLint location, GLint v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM1IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2FPROC) (GLint location, GLfloat v0, GLfloat v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM2FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2IPROC) (GLint location, GLint v0, GLint v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM2IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM3FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3IPROC) (GLint location, GLint v0, GLint v1, GLint v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM3IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM4FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4IPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM4IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUSEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLVALIDATEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB1FPROC) (GLuint index, GLfloat x); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB1FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB2FPROC) (GLuint index, GLfloat x, GLfloat y); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB2FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB3FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB3FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBPOINTERPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLVIEWPORTPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glActiveTexture (GLenum texture); +GL_APICALL void GL_APIENTRY glAttachShader (GLuint program, GLuint shader); +GL_APICALL void GL_APIENTRY glBindAttribLocation (GLuint program, GLuint index, const GLchar *name); +GL_APICALL void GL_APIENTRY glBindBuffer (GLenum target, GLuint buffer); +GL_APICALL void GL_APIENTRY glBindFramebuffer (GLenum target, GLuint framebuffer); +GL_APICALL void GL_APIENTRY glBindRenderbuffer (GLenum target, GLuint renderbuffer); +GL_APICALL void GL_APIENTRY glBindTexture (GLenum target, GLuint texture); +GL_APICALL void GL_APIENTRY glBlendColor (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_APICALL void GL_APIENTRY glBlendEquation (GLenum mode); +GL_APICALL void GL_APIENTRY glBlendEquationSeparate (GLenum modeRGB, GLenum modeAlpha); +GL_APICALL void GL_APIENTRY glBlendFunc (GLenum sfactor, GLenum dfactor); +GL_APICALL void GL_APIENTRY glBlendFuncSeparate (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +GL_APICALL void GL_APIENTRY glBufferData (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +GL_APICALL void GL_APIENTRY glBufferSubData (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +GL_APICALL GLenum GL_APIENTRY glCheckFramebufferStatus (GLenum target); +GL_APICALL void GL_APIENTRY glClear (GLbitfield mask); +GL_APICALL void GL_APIENTRY glClearColor (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_APICALL void GL_APIENTRY glClearDepthf (GLfloat d); +GL_APICALL void GL_APIENTRY glClearStencil (GLint s); +GL_APICALL void GL_APIENTRY glColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +GL_APICALL void GL_APIENTRY glCompileShader (GLuint shader); +GL_APICALL void GL_APIENTRY glCompressedTexImage2D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCopyTexImage2D (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +GL_APICALL void GL_APIENTRY glCopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL GLuint GL_APIENTRY glCreateProgram (void); +GL_APICALL GLuint GL_APIENTRY glCreateShader (GLenum type); +GL_APICALL void GL_APIENTRY glCullFace (GLenum mode); +GL_APICALL void GL_APIENTRY glDeleteBuffers (GLsizei n, const GLuint *buffers); +GL_APICALL void GL_APIENTRY glDeleteFramebuffers (GLsizei n, const GLuint *framebuffers); +GL_APICALL void GL_APIENTRY glDeleteProgram (GLuint program); +GL_APICALL void GL_APIENTRY glDeleteRenderbuffers (GLsizei n, const GLuint *renderbuffers); +GL_APICALL void GL_APIENTRY glDeleteShader (GLuint shader); +GL_APICALL void GL_APIENTRY glDeleteTextures (GLsizei n, const GLuint *textures); +GL_APICALL void GL_APIENTRY glDepthFunc (GLenum func); +GL_APICALL void GL_APIENTRY glDepthMask (GLboolean flag); +GL_APICALL void GL_APIENTRY glDepthRangef (GLfloat n, GLfloat f); +GL_APICALL void GL_APIENTRY glDetachShader (GLuint program, GLuint shader); +GL_APICALL void GL_APIENTRY glDisable (GLenum cap); +GL_APICALL void GL_APIENTRY glDisableVertexAttribArray (GLuint index); +GL_APICALL void GL_APIENTRY glDrawArrays (GLenum mode, GLint first, GLsizei count); +GL_APICALL void GL_APIENTRY glDrawElements (GLenum mode, GLsizei count, GLenum type, const void *indices); +GL_APICALL void GL_APIENTRY glEnable (GLenum cap); +GL_APICALL void GL_APIENTRY glEnableVertexAttribArray (GLuint index); +GL_APICALL void GL_APIENTRY glFinish (void); +GL_APICALL void GL_APIENTRY glFlush (void); +GL_APICALL void GL_APIENTRY glFramebufferRenderbuffer (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +GL_APICALL void GL_APIENTRY glFramebufferTexture2D (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +GL_APICALL void GL_APIENTRY glFrontFace (GLenum mode); +GL_APICALL void GL_APIENTRY glGenBuffers (GLsizei n, GLuint *buffers); +GL_APICALL void GL_APIENTRY glGenerateMipmap (GLenum target); +GL_APICALL void GL_APIENTRY glGenFramebuffers (GLsizei n, GLuint *framebuffers); +GL_APICALL void GL_APIENTRY glGenRenderbuffers (GLsizei n, GLuint *renderbuffers); +GL_APICALL void GL_APIENTRY glGenTextures (GLsizei n, GLuint *textures); +GL_APICALL void GL_APIENTRY glGetActiveAttrib (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glGetActiveUniform (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glGetAttachedShaders (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *shaders); +GL_APICALL GLint GL_APIENTRY glGetAttribLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetBooleanv (GLenum pname, GLboolean *data); +GL_APICALL void GL_APIENTRY glGetBufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL GLenum GL_APIENTRY glGetError (void); +GL_APICALL void GL_APIENTRY glGetFloatv (GLenum pname, GLfloat *data); +GL_APICALL void GL_APIENTRY glGetFramebufferAttachmentParameteriv (GLenum target, GLenum attachment, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetIntegerv (GLenum pname, GLint *data); +GL_APICALL void GL_APIENTRY glGetProgramiv (GLuint program, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetProgramInfoLog (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glGetRenderbufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetShaderiv (GLuint shader, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetShaderInfoLog (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glGetShaderPrecisionFormat (GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision); +GL_APICALL void GL_APIENTRY glGetShaderSource (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +GL_APICALL const GLubyte *GL_APIENTRY glGetString (GLenum name); +GL_APICALL void GL_APIENTRY glGetTexParameterfv (GLenum target, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetTexParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetUniformfv (GLuint program, GLint location, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetUniformiv (GLuint program, GLint location, GLint *params); +GL_APICALL GLint GL_APIENTRY glGetUniformLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetVertexAttribfv (GLuint index, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribiv (GLuint index, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribPointerv (GLuint index, GLenum pname, void **pointer); +GL_APICALL void GL_APIENTRY glHint (GLenum target, GLenum mode); +GL_APICALL GLboolean GL_APIENTRY glIsBuffer (GLuint buffer); +GL_APICALL GLboolean GL_APIENTRY glIsEnabled (GLenum cap); +GL_APICALL GLboolean GL_APIENTRY glIsFramebuffer (GLuint framebuffer); +GL_APICALL GLboolean GL_APIENTRY glIsProgram (GLuint program); +GL_APICALL GLboolean GL_APIENTRY glIsRenderbuffer (GLuint renderbuffer); +GL_APICALL GLboolean GL_APIENTRY glIsShader (GLuint shader); +GL_APICALL GLboolean GL_APIENTRY glIsTexture (GLuint texture); +GL_APICALL void GL_APIENTRY glLineWidth (GLfloat width); +GL_APICALL void GL_APIENTRY glLinkProgram (GLuint program); +GL_APICALL void GL_APIENTRY glPixelStorei (GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glPolygonOffset (GLfloat factor, GLfloat units); +GL_APICALL void GL_APIENTRY glReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +GL_APICALL void GL_APIENTRY glReleaseShaderCompiler (void); +GL_APICALL void GL_APIENTRY glRenderbufferStorage (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glSampleCoverage (GLfloat value, GLboolean invert); +GL_APICALL void GL_APIENTRY glScissor (GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glShaderBinary (GLsizei count, const GLuint *shaders, GLenum binaryFormat, const void *binary, GLsizei length); +GL_APICALL void GL_APIENTRY glShaderSource (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length); +GL_APICALL void GL_APIENTRY glStencilFunc (GLenum func, GLint ref, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilFuncSeparate (GLenum face, GLenum func, GLint ref, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilMask (GLuint mask); +GL_APICALL void GL_APIENTRY glStencilMaskSeparate (GLenum face, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilOp (GLenum fail, GLenum zfail, GLenum zpass); +GL_APICALL void GL_APIENTRY glStencilOpSeparate (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +GL_APICALL void GL_APIENTRY glTexImage2D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glTexParameterf (GLenum target, GLenum pname, GLfloat param); +GL_APICALL void GL_APIENTRY glTexParameterfv (GLenum target, GLenum pname, const GLfloat *params); +GL_APICALL void GL_APIENTRY glTexParameteri (GLenum target, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glTexParameteriv (GLenum target, GLenum pname, const GLint *params); +GL_APICALL void GL_APIENTRY glTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glUniform1f (GLint location, GLfloat v0); +GL_APICALL void GL_APIENTRY glUniform1fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform1i (GLint location, GLint v0); +GL_APICALL void GL_APIENTRY glUniform1iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform2f (GLint location, GLfloat v0, GLfloat v1); +GL_APICALL void GL_APIENTRY glUniform2fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform2i (GLint location, GLint v0, GLint v1); +GL_APICALL void GL_APIENTRY glUniform2iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform3f (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +GL_APICALL void GL_APIENTRY glUniform3fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform3i (GLint location, GLint v0, GLint v1, GLint v2); +GL_APICALL void GL_APIENTRY glUniform3iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform4f (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +GL_APICALL void GL_APIENTRY glUniform4fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform4i (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +GL_APICALL void GL_APIENTRY glUniform4iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniformMatrix2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUseProgram (GLuint program); +GL_APICALL void GL_APIENTRY glValidateProgram (GLuint program); +GL_APICALL void GL_APIENTRY glVertexAttrib1f (GLuint index, GLfloat x); +GL_APICALL void GL_APIENTRY glVertexAttrib1fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib2f (GLuint index, GLfloat x, GLfloat y); +GL_APICALL void GL_APIENTRY glVertexAttrib2fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib3f (GLuint index, GLfloat x, GLfloat y, GLfloat z); +GL_APICALL void GL_APIENTRY glVertexAttrib3fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib4f (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +GL_APICALL void GL_APIENTRY glVertexAttrib4fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttribPointer (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer); +GL_APICALL void GL_APIENTRY glViewport (GLint x, GLint y, GLsizei width, GLsizei height); +#endif +#endif /* GL_ES_VERSION_2_0 */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/GLES2/gl2ext.h b/gfx/angle/checkout/include/GLES2/gl2ext.h new file mode 100644 index 0000000000..948cd83541 --- /dev/null +++ b/gfx/angle/checkout/include/GLES2/gl2ext.h @@ -0,0 +1,3949 @@ +#ifndef __gles2_gl2ext_h_ +#define __gles2_gl2ext_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright 2013-2020 The Khronos Group Inc. +** SPDX-License-Identifier: MIT +** +** This header is generated from the Khronos OpenGL / OpenGL ES XML +** API Registry. The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** https://github.com/KhronosGroup/OpenGL-Registry +*/ + +#ifndef GL_APIENTRYP +#define GL_APIENTRYP GL_APIENTRY* +#endif + +/* Generated on date 20210107 */ + +/* Generated C header for: + * API: gles2 + * Profile: common + * Versions considered: 2\.[0-9] + * Versions emitted: _nomatch_^ + * Default extensions included: gles2 + * Additional extensions included: _nomatch_^ + * Extensions removed: _nomatch_^ + */ + +#ifndef GL_KHR_blend_equation_advanced +#define GL_KHR_blend_equation_advanced 1 +#define GL_MULTIPLY_KHR 0x9294 +#define GL_SCREEN_KHR 0x9295 +#define GL_OVERLAY_KHR 0x9296 +#define GL_DARKEN_KHR 0x9297 +#define GL_LIGHTEN_KHR 0x9298 +#define GL_COLORDODGE_KHR 0x9299 +#define GL_COLORBURN_KHR 0x929A +#define GL_HARDLIGHT_KHR 0x929B +#define GL_SOFTLIGHT_KHR 0x929C +#define GL_DIFFERENCE_KHR 0x929E +#define GL_EXCLUSION_KHR 0x92A0 +#define GL_HSL_HUE_KHR 0x92AD +#define GL_HSL_SATURATION_KHR 0x92AE +#define GL_HSL_COLOR_KHR 0x92AF +#define GL_HSL_LUMINOSITY_KHR 0x92B0 +typedef void (GL_APIENTRYP PFNGLBLENDBARRIERKHRPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBlendBarrierKHR (void); +#endif +#endif /* GL_KHR_blend_equation_advanced */ + +#ifndef GL_KHR_blend_equation_advanced_coherent +#define GL_KHR_blend_equation_advanced_coherent 1 +#define GL_BLEND_ADVANCED_COHERENT_KHR 0x9285 +#endif /* GL_KHR_blend_equation_advanced_coherent */ + +#ifndef GL_KHR_context_flush_control +#define GL_KHR_context_flush_control 1 +#define GL_CONTEXT_RELEASE_BEHAVIOR_KHR 0x82FB +#define GL_CONTEXT_RELEASE_BEHAVIOR_FLUSH_KHR 0x82FC +#endif /* GL_KHR_context_flush_control */ + +#ifndef GL_KHR_debug +#define GL_KHR_debug 1 +typedef void (GL_APIENTRY *GLDEBUGPROCKHR)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam); +#define GL_SAMPLER 0x82E6 +#define GL_DEBUG_OUTPUT_SYNCHRONOUS_KHR 0x8242 +#define GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH_KHR 0x8243 +#define GL_DEBUG_CALLBACK_FUNCTION_KHR 0x8244 +#define GL_DEBUG_CALLBACK_USER_PARAM_KHR 0x8245 +#define GL_DEBUG_SOURCE_API_KHR 0x8246 +#define GL_DEBUG_SOURCE_WINDOW_SYSTEM_KHR 0x8247 +#define GL_DEBUG_SOURCE_SHADER_COMPILER_KHR 0x8248 +#define GL_DEBUG_SOURCE_THIRD_PARTY_KHR 0x8249 +#define GL_DEBUG_SOURCE_APPLICATION_KHR 0x824A +#define GL_DEBUG_SOURCE_OTHER_KHR 0x824B +#define GL_DEBUG_TYPE_ERROR_KHR 0x824C +#define GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR_KHR 0x824D +#define GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR_KHR 0x824E +#define GL_DEBUG_TYPE_PORTABILITY_KHR 0x824F +#define GL_DEBUG_TYPE_PERFORMANCE_KHR 0x8250 +#define GL_DEBUG_TYPE_OTHER_KHR 0x8251 +#define GL_DEBUG_TYPE_MARKER_KHR 0x8268 +#define GL_DEBUG_TYPE_PUSH_GROUP_KHR 0x8269 +#define GL_DEBUG_TYPE_POP_GROUP_KHR 0x826A +#define GL_DEBUG_SEVERITY_NOTIFICATION_KHR 0x826B +#define GL_MAX_DEBUG_GROUP_STACK_DEPTH_KHR 0x826C +#define GL_DEBUG_GROUP_STACK_DEPTH_KHR 0x826D +#define GL_BUFFER_KHR 0x82E0 +#define GL_SHADER_KHR 0x82E1 +#define GL_PROGRAM_KHR 0x82E2 +#define GL_VERTEX_ARRAY_KHR 0x8074 +#define GL_QUERY_KHR 0x82E3 +#define GL_PROGRAM_PIPELINE_KHR 0x82E4 +#define GL_SAMPLER_KHR 0x82E6 +#define GL_MAX_LABEL_LENGTH_KHR 0x82E8 +#define GL_MAX_DEBUG_MESSAGE_LENGTH_KHR 0x9143 +#define GL_MAX_DEBUG_LOGGED_MESSAGES_KHR 0x9144 +#define GL_DEBUG_LOGGED_MESSAGES_KHR 0x9145 +#define GL_DEBUG_SEVERITY_HIGH_KHR 0x9146 +#define GL_DEBUG_SEVERITY_MEDIUM_KHR 0x9147 +#define GL_DEBUG_SEVERITY_LOW_KHR 0x9148 +#define GL_DEBUG_OUTPUT_KHR 0x92E0 +#define GL_CONTEXT_FLAG_DEBUG_BIT_KHR 0x00000002 +#define GL_STACK_OVERFLOW_KHR 0x0503 +#define GL_STACK_UNDERFLOW_KHR 0x0504 +typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGECONTROLKHRPROC) (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled); +typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGEINSERTKHRPROC) (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf); +typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGECALLBACKKHRPROC) (GLDEBUGPROCKHR callback, const void *userParam); +typedef GLuint (GL_APIENTRYP PFNGLGETDEBUGMESSAGELOGKHRPROC) (GLuint count, GLsizei bufSize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog); +typedef void (GL_APIENTRYP PFNGLPUSHDEBUGGROUPKHRPROC) (GLenum source, GLuint id, GLsizei length, const GLchar *message); +typedef void (GL_APIENTRYP PFNGLPOPDEBUGGROUPKHRPROC) (void); +typedef void (GL_APIENTRYP PFNGLOBJECTLABELKHRPROC) (GLenum identifier, GLuint name, GLsizei length, const GLchar *label); +typedef void (GL_APIENTRYP PFNGLGETOBJECTLABELKHRPROC) (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label); +typedef void (GL_APIENTRYP PFNGLOBJECTPTRLABELKHRPROC) (const void *ptr, GLsizei length, const GLchar *label); +typedef void (GL_APIENTRYP PFNGLGETOBJECTPTRLABELKHRPROC) (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label); +typedef void (GL_APIENTRYP PFNGLGETPOINTERVKHRPROC) (GLenum pname, void **params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDebugMessageControlKHR (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled); +GL_APICALL void GL_APIENTRY glDebugMessageInsertKHR (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf); +GL_APICALL void GL_APIENTRY glDebugMessageCallbackKHR (GLDEBUGPROCKHR callback, const void *userParam); +GL_APICALL GLuint GL_APIENTRY glGetDebugMessageLogKHR (GLuint count, GLsizei bufSize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog); +GL_APICALL void GL_APIENTRY glPushDebugGroupKHR (GLenum source, GLuint id, GLsizei length, const GLchar *message); +GL_APICALL void GL_APIENTRY glPopDebugGroupKHR (void); +GL_APICALL void GL_APIENTRY glObjectLabelKHR (GLenum identifier, GLuint name, GLsizei length, const GLchar *label); +GL_APICALL void GL_APIENTRY glGetObjectLabelKHR (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label); +GL_APICALL void GL_APIENTRY glObjectPtrLabelKHR (const void *ptr, GLsizei length, const GLchar *label); +GL_APICALL void GL_APIENTRY glGetObjectPtrLabelKHR (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label); +GL_APICALL void GL_APIENTRY glGetPointervKHR (GLenum pname, void **params); +#endif +#endif /* GL_KHR_debug */ + +#ifndef GL_KHR_no_error +#define GL_KHR_no_error 1 +#define GL_CONTEXT_FLAG_NO_ERROR_BIT_KHR 0x00000008 +#endif /* GL_KHR_no_error */ + +#ifndef GL_KHR_parallel_shader_compile +#define GL_KHR_parallel_shader_compile 1 +#define GL_MAX_SHADER_COMPILER_THREADS_KHR 0x91B0 +#define GL_COMPLETION_STATUS_KHR 0x91B1 +typedef void (GL_APIENTRYP PFNGLMAXSHADERCOMPILERTHREADSKHRPROC) (GLuint count); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glMaxShaderCompilerThreadsKHR (GLuint count); +#endif +#endif /* GL_KHR_parallel_shader_compile */ + +#ifndef GL_KHR_robust_buffer_access_behavior +#define GL_KHR_robust_buffer_access_behavior 1 +#endif /* GL_KHR_robust_buffer_access_behavior */ + +#ifndef GL_KHR_robustness +#define GL_KHR_robustness 1 +#define GL_CONTEXT_ROBUST_ACCESS_KHR 0x90F3 +#define GL_LOSE_CONTEXT_ON_RESET_KHR 0x8252 +#define GL_GUILTY_CONTEXT_RESET_KHR 0x8253 +#define GL_INNOCENT_CONTEXT_RESET_KHR 0x8254 +#define GL_UNKNOWN_CONTEXT_RESET_KHR 0x8255 +#define GL_RESET_NOTIFICATION_STRATEGY_KHR 0x8256 +#define GL_NO_RESET_NOTIFICATION_KHR 0x8261 +#define GL_CONTEXT_LOST_KHR 0x0507 +typedef GLenum (GL_APIENTRYP PFNGLGETGRAPHICSRESETSTATUSKHRPROC) (void); +typedef void (GL_APIENTRYP PFNGLREADNPIXELSKHRPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMFVKHRPROC) (GLuint program, GLint location, GLsizei bufSize, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMIVKHRPROC) (GLuint program, GLint location, GLsizei bufSize, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMUIVKHRPROC) (GLuint program, GLint location, GLsizei bufSize, GLuint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL GLenum GL_APIENTRY glGetGraphicsResetStatusKHR (void); +GL_APICALL void GL_APIENTRY glReadnPixelsKHR (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data); +GL_APICALL void GL_APIENTRY glGetnUniformfvKHR (GLuint program, GLint location, GLsizei bufSize, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetnUniformivKHR (GLuint program, GLint location, GLsizei bufSize, GLint *params); +GL_APICALL void GL_APIENTRY glGetnUniformuivKHR (GLuint program, GLint location, GLsizei bufSize, GLuint *params); +#endif +#endif /* GL_KHR_robustness */ + +#ifndef GL_KHR_shader_subgroup +#define GL_KHR_shader_subgroup 1 +#define GL_SUBGROUP_SIZE_KHR 0x9532 +#define GL_SUBGROUP_SUPPORTED_STAGES_KHR 0x9533 +#define GL_SUBGROUP_SUPPORTED_FEATURES_KHR 0x9534 +#define GL_SUBGROUP_QUAD_ALL_STAGES_KHR 0x9535 +#define GL_SUBGROUP_FEATURE_BASIC_BIT_KHR 0x00000001 +#define GL_SUBGROUP_FEATURE_VOTE_BIT_KHR 0x00000002 +#define GL_SUBGROUP_FEATURE_ARITHMETIC_BIT_KHR 0x00000004 +#define GL_SUBGROUP_FEATURE_BALLOT_BIT_KHR 0x00000008 +#define GL_SUBGROUP_FEATURE_SHUFFLE_BIT_KHR 0x00000010 +#define GL_SUBGROUP_FEATURE_SHUFFLE_RELATIVE_BIT_KHR 0x00000020 +#define GL_SUBGROUP_FEATURE_CLUSTERED_BIT_KHR 0x00000040 +#define GL_SUBGROUP_FEATURE_QUAD_BIT_KHR 0x00000080 +#endif /* GL_KHR_shader_subgroup */ + +#ifndef GL_KHR_texture_compression_astc_hdr +#define GL_KHR_texture_compression_astc_hdr 1 +#define GL_COMPRESSED_RGBA_ASTC_4x4_KHR 0x93B0 +#define GL_COMPRESSED_RGBA_ASTC_5x4_KHR 0x93B1 +#define GL_COMPRESSED_RGBA_ASTC_5x5_KHR 0x93B2 +#define GL_COMPRESSED_RGBA_ASTC_6x5_KHR 0x93B3 +#define GL_COMPRESSED_RGBA_ASTC_6x6_KHR 0x93B4 +#define GL_COMPRESSED_RGBA_ASTC_8x5_KHR 0x93B5 +#define GL_COMPRESSED_RGBA_ASTC_8x6_KHR 0x93B6 +#define GL_COMPRESSED_RGBA_ASTC_8x8_KHR 0x93B7 +#define GL_COMPRESSED_RGBA_ASTC_10x5_KHR 0x93B8 +#define GL_COMPRESSED_RGBA_ASTC_10x6_KHR 0x93B9 +#define GL_COMPRESSED_RGBA_ASTC_10x8_KHR 0x93BA +#define GL_COMPRESSED_RGBA_ASTC_10x10_KHR 0x93BB +#define GL_COMPRESSED_RGBA_ASTC_12x10_KHR 0x93BC +#define GL_COMPRESSED_RGBA_ASTC_12x12_KHR 0x93BD +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR 0x93D0 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR 0x93D1 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR 0x93D2 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR 0x93D3 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR 0x93D4 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR 0x93D5 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR 0x93D6 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR 0x93D7 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR 0x93D8 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR 0x93D9 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR 0x93DA +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR 0x93DB +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR 0x93DC +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR 0x93DD +#endif /* GL_KHR_texture_compression_astc_hdr */ + +#ifndef GL_KHR_texture_compression_astc_ldr +#define GL_KHR_texture_compression_astc_ldr 1 +#endif /* GL_KHR_texture_compression_astc_ldr */ + +#ifndef GL_KHR_texture_compression_astc_sliced_3d +#define GL_KHR_texture_compression_astc_sliced_3d 1 +#endif /* GL_KHR_texture_compression_astc_sliced_3d */ + +#ifndef GL_OES_EGL_image +#define GL_OES_EGL_image 1 +typedef void *GLeglImageOES; +typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETTEXTURE2DOESPROC) (GLenum target, GLeglImageOES image); +typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETRENDERBUFFERSTORAGEOESPROC) (GLenum target, GLeglImageOES image); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glEGLImageTargetTexture2DOES (GLenum target, GLeglImageOES image); +GL_APICALL void GL_APIENTRY glEGLImageTargetRenderbufferStorageOES (GLenum target, GLeglImageOES image); +#endif +#endif /* GL_OES_EGL_image */ + +#ifndef GL_OES_EGL_image_external +#define GL_OES_EGL_image_external 1 +#define GL_TEXTURE_EXTERNAL_OES 0x8D65 +#define GL_TEXTURE_BINDING_EXTERNAL_OES 0x8D67 +#define GL_REQUIRED_TEXTURE_IMAGE_UNITS_OES 0x8D68 +#define GL_SAMPLER_EXTERNAL_OES 0x8D66 +#endif /* GL_OES_EGL_image_external */ + +#ifndef GL_OES_EGL_image_external_essl3 +#define GL_OES_EGL_image_external_essl3 1 +#endif /* GL_OES_EGL_image_external_essl3 */ + +#ifndef GL_OES_compressed_ETC1_RGB8_sub_texture +#define GL_OES_compressed_ETC1_RGB8_sub_texture 1 +#endif /* GL_OES_compressed_ETC1_RGB8_sub_texture */ + +#ifndef GL_OES_compressed_ETC1_RGB8_texture +#define GL_OES_compressed_ETC1_RGB8_texture 1 +#define GL_ETC1_RGB8_OES 0x8D64 +#endif /* GL_OES_compressed_ETC1_RGB8_texture */ + +#ifndef GL_OES_compressed_paletted_texture +#define GL_OES_compressed_paletted_texture 1 +#define GL_PALETTE4_RGB8_OES 0x8B90 +#define GL_PALETTE4_RGBA8_OES 0x8B91 +#define GL_PALETTE4_R5_G6_B5_OES 0x8B92 +#define GL_PALETTE4_RGBA4_OES 0x8B93 +#define GL_PALETTE4_RGB5_A1_OES 0x8B94 +#define GL_PALETTE8_RGB8_OES 0x8B95 +#define GL_PALETTE8_RGBA8_OES 0x8B96 +#define GL_PALETTE8_R5_G6_B5_OES 0x8B97 +#define GL_PALETTE8_RGBA4_OES 0x8B98 +#define GL_PALETTE8_RGB5_A1_OES 0x8B99 +#endif /* GL_OES_compressed_paletted_texture */ + +#ifndef GL_OES_copy_image +#define GL_OES_copy_image 1 +typedef void (GL_APIENTRYP PFNGLCOPYIMAGESUBDATAOESPROC) (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCopyImageSubDataOES (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth); +#endif +#endif /* GL_OES_copy_image */ + +#ifndef GL_OES_depth24 +#define GL_OES_depth24 1 +#define GL_DEPTH_COMPONENT24_OES 0x81A6 +#endif /* GL_OES_depth24 */ + +#ifndef GL_OES_depth32 +#define GL_OES_depth32 1 +#define GL_DEPTH_COMPONENT32_OES 0x81A7 +#endif /* GL_OES_depth32 */ + +#ifndef GL_OES_depth_texture +#define GL_OES_depth_texture 1 +#endif /* GL_OES_depth_texture */ + +#ifndef GL_OES_draw_buffers_indexed +#define GL_OES_draw_buffers_indexed 1 +#define GL_MIN 0x8007 +#define GL_MAX 0x8008 +typedef void (GL_APIENTRYP PFNGLENABLEIOESPROC) (GLenum target, GLuint index); +typedef void (GL_APIENTRYP PFNGLDISABLEIOESPROC) (GLenum target, GLuint index); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONIOESPROC) (GLuint buf, GLenum mode); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEIOESPROC) (GLuint buf, GLenum modeRGB, GLenum modeAlpha); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCIOESPROC) (GLuint buf, GLenum src, GLenum dst); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCSEPARATEIOESPROC) (GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha); +typedef void (GL_APIENTRYP PFNGLCOLORMASKIOESPROC) (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); +typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDIOESPROC) (GLenum target, GLuint index); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glEnableiOES (GLenum target, GLuint index); +GL_APICALL void GL_APIENTRY glDisableiOES (GLenum target, GLuint index); +GL_APICALL void GL_APIENTRY glBlendEquationiOES (GLuint buf, GLenum mode); +GL_APICALL void GL_APIENTRY glBlendEquationSeparateiOES (GLuint buf, GLenum modeRGB, GLenum modeAlpha); +GL_APICALL void GL_APIENTRY glBlendFunciOES (GLuint buf, GLenum src, GLenum dst); +GL_APICALL void GL_APIENTRY glBlendFuncSeparateiOES (GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha); +GL_APICALL void GL_APIENTRY glColorMaskiOES (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); +GL_APICALL GLboolean GL_APIENTRY glIsEnablediOES (GLenum target, GLuint index); +#endif +#endif /* GL_OES_draw_buffers_indexed */ + +#ifndef GL_OES_draw_elements_base_vertex +#define GL_OES_draw_elements_base_vertex 1 +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSBASEVERTEXOESPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLint basevertex); +typedef void (GL_APIENTRYP PFNGLDRAWRANGEELEMENTSBASEVERTEXOESPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices, GLint basevertex); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXOESPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSBASEVERTEXEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei drawcount, const GLint *basevertex); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawElementsBaseVertexOES (GLenum mode, GLsizei count, GLenum type, const void *indices, GLint basevertex); +GL_APICALL void GL_APIENTRY glDrawRangeElementsBaseVertexOES (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices, GLint basevertex); +GL_APICALL void GL_APIENTRY glDrawElementsInstancedBaseVertexOES (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex); +GL_APICALL void GL_APIENTRY glMultiDrawElementsBaseVertexEXT (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei drawcount, const GLint *basevertex); +#endif +#endif /* GL_OES_draw_elements_base_vertex */ + +#ifndef GL_OES_element_index_uint +#define GL_OES_element_index_uint 1 +#endif /* GL_OES_element_index_uint */ + +#ifndef GL_OES_fbo_render_mipmap +#define GL_OES_fbo_render_mipmap 1 +#endif /* GL_OES_fbo_render_mipmap */ + +#ifndef GL_OES_fragment_precision_high +#define GL_OES_fragment_precision_high 1 +#endif /* GL_OES_fragment_precision_high */ + +#ifndef GL_OES_geometry_point_size +#define GL_OES_geometry_point_size 1 +#endif /* GL_OES_geometry_point_size */ + +#ifndef GL_OES_geometry_shader +#define GL_OES_geometry_shader 1 +#define GL_GEOMETRY_SHADER_OES 0x8DD9 +#define GL_GEOMETRY_SHADER_BIT_OES 0x00000004 +#define GL_GEOMETRY_LINKED_VERTICES_OUT_OES 0x8916 +#define GL_GEOMETRY_LINKED_INPUT_TYPE_OES 0x8917 +#define GL_GEOMETRY_LINKED_OUTPUT_TYPE_OES 0x8918 +#define GL_GEOMETRY_SHADER_INVOCATIONS_OES 0x887F +#define GL_LAYER_PROVOKING_VERTEX_OES 0x825E +#define GL_LINES_ADJACENCY_OES 0x000A +#define GL_LINE_STRIP_ADJACENCY_OES 0x000B +#define GL_TRIANGLES_ADJACENCY_OES 0x000C +#define GL_TRIANGLE_STRIP_ADJACENCY_OES 0x000D +#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_OES 0x8DDF +#define GL_MAX_GEOMETRY_UNIFORM_BLOCKS_OES 0x8A2C +#define GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS_OES 0x8A32 +#define GL_MAX_GEOMETRY_INPUT_COMPONENTS_OES 0x9123 +#define GL_MAX_GEOMETRY_OUTPUT_COMPONENTS_OES 0x9124 +#define GL_MAX_GEOMETRY_OUTPUT_VERTICES_OES 0x8DE0 +#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_OES 0x8DE1 +#define GL_MAX_GEOMETRY_SHADER_INVOCATIONS_OES 0x8E5A +#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_OES 0x8C29 +#define GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS_OES 0x92CF +#define GL_MAX_GEOMETRY_ATOMIC_COUNTERS_OES 0x92D5 +#define GL_MAX_GEOMETRY_IMAGE_UNIFORMS_OES 0x90CD +#define GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS_OES 0x90D7 +#define GL_FIRST_VERTEX_CONVENTION_OES 0x8E4D +#define GL_LAST_VERTEX_CONVENTION_OES 0x8E4E +#define GL_UNDEFINED_VERTEX_OES 0x8260 +#define GL_PRIMITIVES_GENERATED_OES 0x8C87 +#define GL_FRAMEBUFFER_DEFAULT_LAYERS_OES 0x9312 +#define GL_MAX_FRAMEBUFFER_LAYERS_OES 0x9317 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_OES 0x8DA8 +#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED_OES 0x8DA7 +#define GL_REFERENCED_BY_GEOMETRY_SHADER_OES 0x9309 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTUREOESPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferTextureOES (GLenum target, GLenum attachment, GLuint texture, GLint level); +#endif +#endif /* GL_OES_geometry_shader */ + +#ifndef GL_OES_get_program_binary +#define GL_OES_get_program_binary 1 +#define GL_PROGRAM_BINARY_LENGTH_OES 0x8741 +#define GL_NUM_PROGRAM_BINARY_FORMATS_OES 0x87FE +#define GL_PROGRAM_BINARY_FORMATS_OES 0x87FF +typedef void (GL_APIENTRYP PFNGLGETPROGRAMBINARYOESPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary); +typedef void (GL_APIENTRYP PFNGLPROGRAMBINARYOESPROC) (GLuint program, GLenum binaryFormat, const void *binary, GLint length); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetProgramBinaryOES (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary); +GL_APICALL void GL_APIENTRY glProgramBinaryOES (GLuint program, GLenum binaryFormat, const void *binary, GLint length); +#endif +#endif /* GL_OES_get_program_binary */ + +#ifndef GL_OES_gpu_shader5 +#define GL_OES_gpu_shader5 1 +#endif /* GL_OES_gpu_shader5 */ + +#ifndef GL_OES_mapbuffer +#define GL_OES_mapbuffer 1 +#define GL_WRITE_ONLY_OES 0x88B9 +#define GL_BUFFER_ACCESS_OES 0x88BB +#define GL_BUFFER_MAPPED_OES 0x88BC +#define GL_BUFFER_MAP_POINTER_OES 0x88BD +typedef void *(GL_APIENTRYP PFNGLMAPBUFFEROESPROC) (GLenum target, GLenum access); +typedef GLboolean (GL_APIENTRYP PFNGLUNMAPBUFFEROESPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVOESPROC) (GLenum target, GLenum pname, void **params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void *GL_APIENTRY glMapBufferOES (GLenum target, GLenum access); +GL_APICALL GLboolean GL_APIENTRY glUnmapBufferOES (GLenum target); +GL_APICALL void GL_APIENTRY glGetBufferPointervOES (GLenum target, GLenum pname, void **params); +#endif +#endif /* GL_OES_mapbuffer */ + +#ifndef GL_OES_packed_depth_stencil +#define GL_OES_packed_depth_stencil 1 +#define GL_DEPTH_STENCIL_OES 0x84F9 +#define GL_UNSIGNED_INT_24_8_OES 0x84FA +#define GL_DEPTH24_STENCIL8_OES 0x88F0 +#endif /* GL_OES_packed_depth_stencil */ + +#ifndef GL_OES_primitive_bounding_box +#define GL_OES_primitive_bounding_box 1 +#define GL_PRIMITIVE_BOUNDING_BOX_OES 0x92BE +typedef void (GL_APIENTRYP PFNGLPRIMITIVEBOUNDINGBOXOESPROC) (GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glPrimitiveBoundingBoxOES (GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW); +#endif +#endif /* GL_OES_primitive_bounding_box */ + +#ifndef GL_OES_required_internalformat +#define GL_OES_required_internalformat 1 +#define GL_ALPHA8_OES 0x803C +#define GL_DEPTH_COMPONENT16_OES 0x81A5 +#define GL_LUMINANCE4_ALPHA4_OES 0x8043 +#define GL_LUMINANCE8_ALPHA8_OES 0x8045 +#define GL_LUMINANCE8_OES 0x8040 +#define GL_RGBA4_OES 0x8056 +#define GL_RGB5_A1_OES 0x8057 +#define GL_RGB565_OES 0x8D62 +#define GL_RGB8_OES 0x8051 +#define GL_RGBA8_OES 0x8058 +#define GL_RGB10_EXT 0x8052 +#define GL_RGB10_A2_EXT 0x8059 +#endif /* GL_OES_required_internalformat */ + +#ifndef GL_OES_rgb8_rgba8 +#define GL_OES_rgb8_rgba8 1 +#endif /* GL_OES_rgb8_rgba8 */ + +#ifndef GL_OES_sample_shading +#define GL_OES_sample_shading 1 +#define GL_SAMPLE_SHADING_OES 0x8C36 +#define GL_MIN_SAMPLE_SHADING_VALUE_OES 0x8C37 +typedef void (GL_APIENTRYP PFNGLMINSAMPLESHADINGOESPROC) (GLfloat value); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glMinSampleShadingOES (GLfloat value); +#endif +#endif /* GL_OES_sample_shading */ + +#ifndef GL_OES_sample_variables +#define GL_OES_sample_variables 1 +#endif /* GL_OES_sample_variables */ + +#ifndef GL_OES_shader_image_atomic +#define GL_OES_shader_image_atomic 1 +#endif /* GL_OES_shader_image_atomic */ + +#ifndef GL_OES_shader_io_blocks +#define GL_OES_shader_io_blocks 1 +#endif /* GL_OES_shader_io_blocks */ + +#ifndef GL_OES_shader_multisample_interpolation +#define GL_OES_shader_multisample_interpolation 1 +#define GL_MIN_FRAGMENT_INTERPOLATION_OFFSET_OES 0x8E5B +#define GL_MAX_FRAGMENT_INTERPOLATION_OFFSET_OES 0x8E5C +#define GL_FRAGMENT_INTERPOLATION_OFFSET_BITS_OES 0x8E5D +#endif /* GL_OES_shader_multisample_interpolation */ + +#ifndef GL_OES_standard_derivatives +#define GL_OES_standard_derivatives 1 +#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES 0x8B8B +#endif /* GL_OES_standard_derivatives */ + +#ifndef GL_OES_stencil1 +#define GL_OES_stencil1 1 +#define GL_STENCIL_INDEX1_OES 0x8D46 +#endif /* GL_OES_stencil1 */ + +#ifndef GL_OES_stencil4 +#define GL_OES_stencil4 1 +#define GL_STENCIL_INDEX4_OES 0x8D47 +#endif /* GL_OES_stencil4 */ + +#ifndef GL_OES_surfaceless_context +#define GL_OES_surfaceless_context 1 +#define GL_FRAMEBUFFER_UNDEFINED_OES 0x8219 +#endif /* GL_OES_surfaceless_context */ + +#ifndef GL_OES_tessellation_point_size +#define GL_OES_tessellation_point_size 1 +#endif /* GL_OES_tessellation_point_size */ + +#ifndef GL_OES_tessellation_shader +#define GL_OES_tessellation_shader 1 +#define GL_PATCHES_OES 0x000E +#define GL_PATCH_VERTICES_OES 0x8E72 +#define GL_TESS_CONTROL_OUTPUT_VERTICES_OES 0x8E75 +#define GL_TESS_GEN_MODE_OES 0x8E76 +#define GL_TESS_GEN_SPACING_OES 0x8E77 +#define GL_TESS_GEN_VERTEX_ORDER_OES 0x8E78 +#define GL_TESS_GEN_POINT_MODE_OES 0x8E79 +#define GL_ISOLINES_OES 0x8E7A +#define GL_QUADS_OES 0x0007 +#define GL_FRACTIONAL_ODD_OES 0x8E7B +#define GL_FRACTIONAL_EVEN_OES 0x8E7C +#define GL_MAX_PATCH_VERTICES_OES 0x8E7D +#define GL_MAX_TESS_GEN_LEVEL_OES 0x8E7E +#define GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS_OES 0x8E7F +#define GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS_OES 0x8E80 +#define GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS_OES 0x8E81 +#define GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS_OES 0x8E82 +#define GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS_OES 0x8E83 +#define GL_MAX_TESS_PATCH_COMPONENTS_OES 0x8E84 +#define GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS_OES 0x8E85 +#define GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS_OES 0x8E86 +#define GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS_OES 0x8E89 +#define GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS_OES 0x8E8A +#define GL_MAX_TESS_CONTROL_INPUT_COMPONENTS_OES 0x886C +#define GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS_OES 0x886D +#define GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS_OES 0x8E1E +#define GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS_OES 0x8E1F +#define GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS_OES 0x92CD +#define GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS_OES 0x92CE +#define GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS_OES 0x92D3 +#define GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS_OES 0x92D4 +#define GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS_OES 0x90CB +#define GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS_OES 0x90CC +#define GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS_OES 0x90D8 +#define GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS_OES 0x90D9 +#define GL_PRIMITIVE_RESTART_FOR_PATCHES_SUPPORTED_OES 0x8221 +#define GL_IS_PER_PATCH_OES 0x92E7 +#define GL_REFERENCED_BY_TESS_CONTROL_SHADER_OES 0x9307 +#define GL_REFERENCED_BY_TESS_EVALUATION_SHADER_OES 0x9308 +#define GL_TESS_CONTROL_SHADER_OES 0x8E88 +#define GL_TESS_EVALUATION_SHADER_OES 0x8E87 +#define GL_TESS_CONTROL_SHADER_BIT_OES 0x00000008 +#define GL_TESS_EVALUATION_SHADER_BIT_OES 0x00000010 +typedef void (GL_APIENTRYP PFNGLPATCHPARAMETERIOESPROC) (GLenum pname, GLint value); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glPatchParameteriOES (GLenum pname, GLint value); +#endif +#endif /* GL_OES_tessellation_shader */ + +#ifndef GL_OES_texture_3D +#define GL_OES_texture_3D 1 +#define GL_TEXTURE_WRAP_R_OES 0x8072 +#define GL_TEXTURE_3D_OES 0x806F +#define GL_TEXTURE_BINDING_3D_OES 0x806A +#define GL_MAX_3D_TEXTURE_SIZE_OES 0x8073 +#define GL_SAMPLER_3D_OES 0x8B5F +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_OES 0x8CD4 +typedef void (GL_APIENTRYP PFNGLTEXIMAGE3DOESPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE3DOESPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE3DOESPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DOESPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DOESPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DOESPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexImage3DOES (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glTexSubImage3DOES (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glCopyTexSubImage3DOES (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glCompressedTexImage3DOES (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage3DOES (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glFramebufferTexture3DOES (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); +#endif +#endif /* GL_OES_texture_3D */ + +#ifndef GL_OES_texture_border_clamp +#define GL_OES_texture_border_clamp 1 +#define GL_TEXTURE_BORDER_COLOR_OES 0x1004 +#define GL_CLAMP_TO_BORDER_OES 0x812D +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIIVOESPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIUIVOESPROC) (GLenum target, GLenum pname, const GLuint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIIVOESPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIUIVOESPROC) (GLenum target, GLenum pname, GLuint *params); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIIVOESPROC) (GLuint sampler, GLenum pname, const GLint *param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIUIVOESPROC) (GLuint sampler, GLenum pname, const GLuint *param); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIIVOESPROC) (GLuint sampler, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIUIVOESPROC) (GLuint sampler, GLenum pname, GLuint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexParameterIivOES (GLenum target, GLenum pname, const GLint *params); +GL_APICALL void GL_APIENTRY glTexParameterIuivOES (GLenum target, GLenum pname, const GLuint *params); +GL_APICALL void GL_APIENTRY glGetTexParameterIivOES (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetTexParameterIuivOES (GLenum target, GLenum pname, GLuint *params); +GL_APICALL void GL_APIENTRY glSamplerParameterIivOES (GLuint sampler, GLenum pname, const GLint *param); +GL_APICALL void GL_APIENTRY glSamplerParameterIuivOES (GLuint sampler, GLenum pname, const GLuint *param); +GL_APICALL void GL_APIENTRY glGetSamplerParameterIivOES (GLuint sampler, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetSamplerParameterIuivOES (GLuint sampler, GLenum pname, GLuint *params); +#endif +#endif /* GL_OES_texture_border_clamp */ + +#ifndef GL_OES_texture_buffer +#define GL_OES_texture_buffer 1 +#define GL_TEXTURE_BUFFER_OES 0x8C2A +#define GL_TEXTURE_BUFFER_BINDING_OES 0x8C2A +#define GL_MAX_TEXTURE_BUFFER_SIZE_OES 0x8C2B +#define GL_TEXTURE_BINDING_BUFFER_OES 0x8C2C +#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING_OES 0x8C2D +#define GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT_OES 0x919F +#define GL_SAMPLER_BUFFER_OES 0x8DC2 +#define GL_INT_SAMPLER_BUFFER_OES 0x8DD0 +#define GL_UNSIGNED_INT_SAMPLER_BUFFER_OES 0x8DD8 +#define GL_IMAGE_BUFFER_OES 0x9051 +#define GL_INT_IMAGE_BUFFER_OES 0x905C +#define GL_UNSIGNED_INT_IMAGE_BUFFER_OES 0x9067 +#define GL_TEXTURE_BUFFER_OFFSET_OES 0x919D +#define GL_TEXTURE_BUFFER_SIZE_OES 0x919E +typedef void (GL_APIENTRYP PFNGLTEXBUFFEROESPROC) (GLenum target, GLenum internalformat, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLTEXBUFFERRANGEOESPROC) (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexBufferOES (GLenum target, GLenum internalformat, GLuint buffer); +GL_APICALL void GL_APIENTRY glTexBufferRangeOES (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +#endif +#endif /* GL_OES_texture_buffer */ + +#ifndef GL_OES_texture_compression_astc +#define GL_OES_texture_compression_astc 1 +#define GL_COMPRESSED_RGBA_ASTC_3x3x3_OES 0x93C0 +#define GL_COMPRESSED_RGBA_ASTC_4x3x3_OES 0x93C1 +#define GL_COMPRESSED_RGBA_ASTC_4x4x3_OES 0x93C2 +#define GL_COMPRESSED_RGBA_ASTC_4x4x4_OES 0x93C3 +#define GL_COMPRESSED_RGBA_ASTC_5x4x4_OES 0x93C4 +#define GL_COMPRESSED_RGBA_ASTC_5x5x4_OES 0x93C5 +#define GL_COMPRESSED_RGBA_ASTC_5x5x5_OES 0x93C6 +#define GL_COMPRESSED_RGBA_ASTC_6x5x5_OES 0x93C7 +#define GL_COMPRESSED_RGBA_ASTC_6x6x5_OES 0x93C8 +#define GL_COMPRESSED_RGBA_ASTC_6x6x6_OES 0x93C9 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_3x3x3_OES 0x93E0 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x3x3_OES 0x93E1 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4x3_OES 0x93E2 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4x4_OES 0x93E3 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4x4_OES 0x93E4 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5x4_OES 0x93E5 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5x5_OES 0x93E6 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5x5_OES 0x93E7 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6x5_OES 0x93E8 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6x6_OES 0x93E9 +#endif /* GL_OES_texture_compression_astc */ + +#ifndef GL_OES_texture_cube_map_array +#define GL_OES_texture_cube_map_array 1 +#define GL_TEXTURE_CUBE_MAP_ARRAY_OES 0x9009 +#define GL_TEXTURE_BINDING_CUBE_MAP_ARRAY_OES 0x900A +#define GL_SAMPLER_CUBE_MAP_ARRAY_OES 0x900C +#define GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW_OES 0x900D +#define GL_INT_SAMPLER_CUBE_MAP_ARRAY_OES 0x900E +#define GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY_OES 0x900F +#define GL_IMAGE_CUBE_MAP_ARRAY_OES 0x9054 +#define GL_INT_IMAGE_CUBE_MAP_ARRAY_OES 0x905F +#define GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY_OES 0x906A +#endif /* GL_OES_texture_cube_map_array */ + +#ifndef GL_OES_texture_float +#define GL_OES_texture_float 1 +#endif /* GL_OES_texture_float */ + +#ifndef GL_OES_texture_float_linear +#define GL_OES_texture_float_linear 1 +#endif /* GL_OES_texture_float_linear */ + +#ifndef GL_OES_texture_half_float +#define GL_OES_texture_half_float 1 +#define GL_HALF_FLOAT_OES 0x8D61 +#endif /* GL_OES_texture_half_float */ + +#ifndef GL_OES_texture_half_float_linear +#define GL_OES_texture_half_float_linear 1 +#endif /* GL_OES_texture_half_float_linear */ + +#ifndef GL_OES_texture_npot +#define GL_OES_texture_npot 1 +#endif /* GL_OES_texture_npot */ + +#ifndef GL_OES_texture_stencil8 +#define GL_OES_texture_stencil8 1 +#define GL_STENCIL_INDEX_OES 0x1901 +#define GL_STENCIL_INDEX8_OES 0x8D48 +#endif /* GL_OES_texture_stencil8 */ + +#ifndef GL_OES_texture_storage_multisample_2d_array +#define GL_OES_texture_storage_multisample_2d_array 1 +#define GL_TEXTURE_2D_MULTISAMPLE_ARRAY_OES 0x9102 +#define GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY_OES 0x9105 +#define GL_SAMPLER_2D_MULTISAMPLE_ARRAY_OES 0x910B +#define GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY_OES 0x910C +#define GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY_OES 0x910D +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE3DMULTISAMPLEOESPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexStorage3DMultisampleOES (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations); +#endif +#endif /* GL_OES_texture_storage_multisample_2d_array */ + +#ifndef GL_OES_texture_view +#define GL_OES_texture_view 1 +#define GL_TEXTURE_VIEW_MIN_LEVEL_OES 0x82DB +#define GL_TEXTURE_VIEW_NUM_LEVELS_OES 0x82DC +#define GL_TEXTURE_VIEW_MIN_LAYER_OES 0x82DD +#define GL_TEXTURE_VIEW_NUM_LAYERS_OES 0x82DE +#define GL_TEXTURE_IMMUTABLE_LEVELS 0x82DF +typedef void (GL_APIENTRYP PFNGLTEXTUREVIEWOESPROC) (GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTextureViewOES (GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers); +#endif +#endif /* GL_OES_texture_view */ + +#ifndef GL_OES_vertex_array_object +#define GL_OES_vertex_array_object 1 +#define GL_VERTEX_ARRAY_BINDING_OES 0x85B5 +typedef void (GL_APIENTRYP PFNGLBINDVERTEXARRAYOESPROC) (GLuint array); +typedef void (GL_APIENTRYP PFNGLDELETEVERTEXARRAYSOESPROC) (GLsizei n, const GLuint *arrays); +typedef void (GL_APIENTRYP PFNGLGENVERTEXARRAYSOESPROC) (GLsizei n, GLuint *arrays); +typedef GLboolean (GL_APIENTRYP PFNGLISVERTEXARRAYOESPROC) (GLuint array); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBindVertexArrayOES (GLuint array); +GL_APICALL void GL_APIENTRY glDeleteVertexArraysOES (GLsizei n, const GLuint *arrays); +GL_APICALL void GL_APIENTRY glGenVertexArraysOES (GLsizei n, GLuint *arrays); +GL_APICALL GLboolean GL_APIENTRY glIsVertexArrayOES (GLuint array); +#endif +#endif /* GL_OES_vertex_array_object */ + +#ifndef GL_OES_vertex_half_float +#define GL_OES_vertex_half_float 1 +#endif /* GL_OES_vertex_half_float */ + +#ifndef GL_OES_vertex_type_10_10_10_2 +#define GL_OES_vertex_type_10_10_10_2 1 +#define GL_UNSIGNED_INT_10_10_10_2_OES 0x8DF6 +#define GL_INT_10_10_10_2_OES 0x8DF7 +#endif /* GL_OES_vertex_type_10_10_10_2 */ + +#ifndef GL_OES_viewport_array +#define GL_OES_viewport_array 1 +#define GL_MAX_VIEWPORTS_OES 0x825B +#define GL_VIEWPORT_SUBPIXEL_BITS_OES 0x825C +#define GL_VIEWPORT_BOUNDS_RANGE_OES 0x825D +#define GL_VIEWPORT_INDEX_PROVOKING_VERTEX_OES 0x825F +typedef void (GL_APIENTRYP PFNGLVIEWPORTARRAYVOESPROC) (GLuint first, GLsizei count, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVIEWPORTINDEXEDFOESPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h); +typedef void (GL_APIENTRYP PFNGLVIEWPORTINDEXEDFVOESPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLSCISSORARRAYVOESPROC) (GLuint first, GLsizei count, const GLint *v); +typedef void (GL_APIENTRYP PFNGLSCISSORINDEXEDOESPROC) (GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSCISSORINDEXEDVOESPROC) (GLuint index, const GLint *v); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEARRAYFVOESPROC) (GLuint first, GLsizei count, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEINDEXEDFOESPROC) (GLuint index, GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLGETFLOATI_VOESPROC) (GLenum target, GLuint index, GLfloat *data); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glViewportArrayvOES (GLuint first, GLsizei count, const GLfloat *v); +GL_APICALL void GL_APIENTRY glViewportIndexedfOES (GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h); +GL_APICALL void GL_APIENTRY glViewportIndexedfvOES (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glScissorArrayvOES (GLuint first, GLsizei count, const GLint *v); +GL_APICALL void GL_APIENTRY glScissorIndexedOES (GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glScissorIndexedvOES (GLuint index, const GLint *v); +GL_APICALL void GL_APIENTRY glDepthRangeArrayfvOES (GLuint first, GLsizei count, const GLfloat *v); +GL_APICALL void GL_APIENTRY glDepthRangeIndexedfOES (GLuint index, GLfloat n, GLfloat f); +GL_APICALL void GL_APIENTRY glGetFloati_vOES (GLenum target, GLuint index, GLfloat *data); +#endif +#endif /* GL_OES_viewport_array */ + +#ifndef GL_AMD_compressed_3DC_texture +#define GL_AMD_compressed_3DC_texture 1 +#define GL_3DC_X_AMD 0x87F9 +#define GL_3DC_XY_AMD 0x87FA +#endif /* GL_AMD_compressed_3DC_texture */ + +#ifndef GL_AMD_compressed_ATC_texture +#define GL_AMD_compressed_ATC_texture 1 +#define GL_ATC_RGB_AMD 0x8C92 +#define GL_ATC_RGBA_EXPLICIT_ALPHA_AMD 0x8C93 +#define GL_ATC_RGBA_INTERPOLATED_ALPHA_AMD 0x87EE +#endif /* GL_AMD_compressed_ATC_texture */ + +#ifndef GL_AMD_framebuffer_multisample_advanced +#define GL_AMD_framebuffer_multisample_advanced 1 +#define GL_RENDERBUFFER_STORAGE_SAMPLES_AMD 0x91B2 +#define GL_MAX_COLOR_FRAMEBUFFER_SAMPLES_AMD 0x91B3 +#define GL_MAX_COLOR_FRAMEBUFFER_STORAGE_SAMPLES_AMD 0x91B4 +#define GL_MAX_DEPTH_STENCIL_FRAMEBUFFER_SAMPLES_AMD 0x91B5 +#define GL_NUM_SUPPORTED_MULTISAMPLE_MODES_AMD 0x91B6 +#define GL_SUPPORTED_MULTISAMPLE_MODES_AMD 0x91B7 +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEADVANCEDAMDPROC) (GLenum target, GLsizei samples, GLsizei storageSamples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLNAMEDRENDERBUFFERSTORAGEMULTISAMPLEADVANCEDAMDPROC) (GLuint renderbuffer, GLsizei samples, GLsizei storageSamples, GLenum internalformat, GLsizei width, GLsizei height); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleAdvancedAMD (GLenum target, GLsizei samples, GLsizei storageSamples, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glNamedRenderbufferStorageMultisampleAdvancedAMD (GLuint renderbuffer, GLsizei samples, GLsizei storageSamples, GLenum internalformat, GLsizei width, GLsizei height); +#endif +#endif /* GL_AMD_framebuffer_multisample_advanced */ + +#ifndef GL_AMD_performance_monitor +#define GL_AMD_performance_monitor 1 +#define GL_COUNTER_TYPE_AMD 0x8BC0 +#define GL_COUNTER_RANGE_AMD 0x8BC1 +#define GL_UNSIGNED_INT64_AMD 0x8BC2 +#define GL_PERCENTAGE_AMD 0x8BC3 +#define GL_PERFMON_RESULT_AVAILABLE_AMD 0x8BC4 +#define GL_PERFMON_RESULT_SIZE_AMD 0x8BC5 +#define GL_PERFMON_RESULT_AMD 0x8BC6 +typedef void (GL_APIENTRYP PFNGLGETPERFMONITORGROUPSAMDPROC) (GLint *numGroups, GLsizei groupsSize, GLuint *groups); +typedef void (GL_APIENTRYP PFNGLGETPERFMONITORCOUNTERSAMDPROC) (GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters); +typedef void (GL_APIENTRYP PFNGLGETPERFMONITORGROUPSTRINGAMDPROC) (GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString); +typedef void (GL_APIENTRYP PFNGLGETPERFMONITORCOUNTERSTRINGAMDPROC) (GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString); +typedef void (GL_APIENTRYP PFNGLGETPERFMONITORCOUNTERINFOAMDPROC) (GLuint group, GLuint counter, GLenum pname, void *data); +typedef void (GL_APIENTRYP PFNGLGENPERFMONITORSAMDPROC) (GLsizei n, GLuint *monitors); +typedef void (GL_APIENTRYP PFNGLDELETEPERFMONITORSAMDPROC) (GLsizei n, GLuint *monitors); +typedef void (GL_APIENTRYP PFNGLSELECTPERFMONITORCOUNTERSAMDPROC) (GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *counterList); +typedef void (GL_APIENTRYP PFNGLBEGINPERFMONITORAMDPROC) (GLuint monitor); +typedef void (GL_APIENTRYP PFNGLENDPERFMONITORAMDPROC) (GLuint monitor); +typedef void (GL_APIENTRYP PFNGLGETPERFMONITORCOUNTERDATAAMDPROC) (GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetPerfMonitorGroupsAMD (GLint *numGroups, GLsizei groupsSize, GLuint *groups); +GL_APICALL void GL_APIENTRY glGetPerfMonitorCountersAMD (GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters); +GL_APICALL void GL_APIENTRY glGetPerfMonitorGroupStringAMD (GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString); +GL_APICALL void GL_APIENTRY glGetPerfMonitorCounterStringAMD (GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString); +GL_APICALL void GL_APIENTRY glGetPerfMonitorCounterInfoAMD (GLuint group, GLuint counter, GLenum pname, void *data); +GL_APICALL void GL_APIENTRY glGenPerfMonitorsAMD (GLsizei n, GLuint *monitors); +GL_APICALL void GL_APIENTRY glDeletePerfMonitorsAMD (GLsizei n, GLuint *monitors); +GL_APICALL void GL_APIENTRY glSelectPerfMonitorCountersAMD (GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *counterList); +GL_APICALL void GL_APIENTRY glBeginPerfMonitorAMD (GLuint monitor); +GL_APICALL void GL_APIENTRY glEndPerfMonitorAMD (GLuint monitor); +GL_APICALL void GL_APIENTRY glGetPerfMonitorCounterDataAMD (GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten); +#endif +#endif /* GL_AMD_performance_monitor */ + +#ifndef GL_AMD_program_binary_Z400 +#define GL_AMD_program_binary_Z400 1 +#define GL_Z400_BINARY_AMD 0x8740 +#endif /* GL_AMD_program_binary_Z400 */ + +#ifndef GL_ANDROID_extension_pack_es31a +#define GL_ANDROID_extension_pack_es31a 1 +#endif /* GL_ANDROID_extension_pack_es31a */ + +#ifndef GL_ANGLE_depth_texture +#define GL_ANGLE_depth_texture 1 +#endif /* GL_ANGLE_depth_texture */ + +#ifndef GL_ANGLE_framebuffer_blit +#define GL_ANGLE_framebuffer_blit 1 +#define GL_READ_FRAMEBUFFER_ANGLE 0x8CA8 +#define GL_DRAW_FRAMEBUFFER_ANGLE 0x8CA9 +#define GL_DRAW_FRAMEBUFFER_BINDING_ANGLE 0x8CA6 +#define GL_READ_FRAMEBUFFER_BINDING_ANGLE 0x8CAA +typedef void (GL_APIENTRYP PFNGLBLITFRAMEBUFFERANGLEPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBlitFramebufferANGLE (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +#endif +#endif /* GL_ANGLE_framebuffer_blit */ + +#ifndef GL_ANGLE_framebuffer_multisample +#define GL_ANGLE_framebuffer_multisample 1 +#define GL_RENDERBUFFER_SAMPLES_ANGLE 0x8CAB +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_ANGLE 0x8D56 +#define GL_MAX_SAMPLES_ANGLE 0x8D57 +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEANGLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleANGLE (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +#endif +#endif /* GL_ANGLE_framebuffer_multisample */ + +#ifndef GL_ANGLE_instanced_arrays +#define GL_ANGLE_instanced_arrays 1 +#define GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE 0x88FE +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDANGLEPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDANGLEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISORANGLEPROC) (GLuint index, GLuint divisor); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawArraysInstancedANGLE (GLenum mode, GLint first, GLsizei count, GLsizei primcount); +GL_APICALL void GL_APIENTRY glDrawElementsInstancedANGLE (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount); +GL_APICALL void GL_APIENTRY glVertexAttribDivisorANGLE (GLuint index, GLuint divisor); +#endif +#endif /* GL_ANGLE_instanced_arrays */ + +#ifndef GL_ANGLE_pack_reverse_row_order +#define GL_ANGLE_pack_reverse_row_order 1 +#define GL_PACK_REVERSE_ROW_ORDER_ANGLE 0x93A4 +#endif /* GL_ANGLE_pack_reverse_row_order */ + +#ifndef GL_ANGLE_program_binary +#define GL_ANGLE_program_binary 1 +#define GL_PROGRAM_BINARY_ANGLE 0x93A6 +#endif /* GL_ANGLE_program_binary */ + +#ifndef GL_ANGLE_texture_compression_dxt3 +#define GL_ANGLE_texture_compression_dxt3 1 +#define GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE 0x83F2 +#endif /* GL_ANGLE_texture_compression_dxt3 */ + +#ifndef GL_ANGLE_texture_compression_dxt5 +#define GL_ANGLE_texture_compression_dxt5 1 +#define GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE 0x83F3 +#endif /* GL_ANGLE_texture_compression_dxt5 */ + +#ifndef GL_ANGLE_texture_usage +#define GL_ANGLE_texture_usage 1 +#define GL_TEXTURE_USAGE_ANGLE 0x93A2 +#define GL_FRAMEBUFFER_ATTACHMENT_ANGLE 0x93A3 +#endif /* GL_ANGLE_texture_usage */ + +#ifndef GL_ANGLE_translated_shader_source +#define GL_ANGLE_translated_shader_source 1 +#define GL_TRANSLATED_SHADER_SOURCE_LENGTH_ANGLE 0x93A0 +typedef void (GL_APIENTRYP PFNGLGETTRANSLATEDSHADERSOURCEANGLEPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetTranslatedShaderSourceANGLE (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +#endif +#endif /* GL_ANGLE_translated_shader_source */ + +#ifndef GL_APPLE_clip_distance +#define GL_APPLE_clip_distance 1 +#define GL_MAX_CLIP_DISTANCES_APPLE 0x0D32 +#define GL_CLIP_DISTANCE0_APPLE 0x3000 +#define GL_CLIP_DISTANCE1_APPLE 0x3001 +#define GL_CLIP_DISTANCE2_APPLE 0x3002 +#define GL_CLIP_DISTANCE3_APPLE 0x3003 +#define GL_CLIP_DISTANCE4_APPLE 0x3004 +#define GL_CLIP_DISTANCE5_APPLE 0x3005 +#define GL_CLIP_DISTANCE6_APPLE 0x3006 +#define GL_CLIP_DISTANCE7_APPLE 0x3007 +#endif /* GL_APPLE_clip_distance */ + +#ifndef GL_APPLE_color_buffer_packed_float +#define GL_APPLE_color_buffer_packed_float 1 +#endif /* GL_APPLE_color_buffer_packed_float */ + +#ifndef GL_APPLE_copy_texture_levels +#define GL_APPLE_copy_texture_levels 1 +typedef void (GL_APIENTRYP PFNGLCOPYTEXTURELEVELSAPPLEPROC) (GLuint destinationTexture, GLuint sourceTexture, GLint sourceBaseLevel, GLsizei sourceLevelCount); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCopyTextureLevelsAPPLE (GLuint destinationTexture, GLuint sourceTexture, GLint sourceBaseLevel, GLsizei sourceLevelCount); +#endif +#endif /* GL_APPLE_copy_texture_levels */ + +#ifndef GL_APPLE_framebuffer_multisample +#define GL_APPLE_framebuffer_multisample 1 +#define GL_RENDERBUFFER_SAMPLES_APPLE 0x8CAB +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_APPLE 0x8D56 +#define GL_MAX_SAMPLES_APPLE 0x8D57 +#define GL_READ_FRAMEBUFFER_APPLE 0x8CA8 +#define GL_DRAW_FRAMEBUFFER_APPLE 0x8CA9 +#define GL_DRAW_FRAMEBUFFER_BINDING_APPLE 0x8CA6 +#define GL_READ_FRAMEBUFFER_BINDING_APPLE 0x8CAA +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEAPPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLRESOLVEMULTISAMPLEFRAMEBUFFERAPPLEPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleAPPLE (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glResolveMultisampleFramebufferAPPLE (void); +#endif +#endif /* GL_APPLE_framebuffer_multisample */ + +#ifndef GL_APPLE_rgb_422 +#define GL_APPLE_rgb_422 1 +#define GL_RGB_422_APPLE 0x8A1F +#define GL_UNSIGNED_SHORT_8_8_APPLE 0x85BA +#define GL_UNSIGNED_SHORT_8_8_REV_APPLE 0x85BB +#define GL_RGB_RAW_422_APPLE 0x8A51 +#endif /* GL_APPLE_rgb_422 */ + +#ifndef GL_APPLE_sync +#define GL_APPLE_sync 1 +#define GL_SYNC_OBJECT_APPLE 0x8A53 +#define GL_MAX_SERVER_WAIT_TIMEOUT_APPLE 0x9111 +#define GL_OBJECT_TYPE_APPLE 0x9112 +#define GL_SYNC_CONDITION_APPLE 0x9113 +#define GL_SYNC_STATUS_APPLE 0x9114 +#define GL_SYNC_FLAGS_APPLE 0x9115 +#define GL_SYNC_FENCE_APPLE 0x9116 +#define GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE 0x9117 +#define GL_UNSIGNALED_APPLE 0x9118 +#define GL_SIGNALED_APPLE 0x9119 +#define GL_ALREADY_SIGNALED_APPLE 0x911A +#define GL_TIMEOUT_EXPIRED_APPLE 0x911B +#define GL_CONDITION_SATISFIED_APPLE 0x911C +#define GL_WAIT_FAILED_APPLE 0x911D +#define GL_SYNC_FLUSH_COMMANDS_BIT_APPLE 0x00000001 +#define GL_TIMEOUT_IGNORED_APPLE 0xFFFFFFFFFFFFFFFFull +typedef GLsync (GL_APIENTRYP PFNGLFENCESYNCAPPLEPROC) (GLenum condition, GLbitfield flags); +typedef GLboolean (GL_APIENTRYP PFNGLISSYNCAPPLEPROC) (GLsync sync); +typedef void (GL_APIENTRYP PFNGLDELETESYNCAPPLEPROC) (GLsync sync); +typedef GLenum (GL_APIENTRYP PFNGLCLIENTWAITSYNCAPPLEPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLWAITSYNCAPPLEPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64VAPPLEPROC) (GLenum pname, GLint64 *params); +typedef void (GL_APIENTRYP PFNGLGETSYNCIVAPPLEPROC) (GLsync sync, GLenum pname, GLsizei count, GLsizei *length, GLint *values); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL GLsync GL_APIENTRY glFenceSyncAPPLE (GLenum condition, GLbitfield flags); +GL_APICALL GLboolean GL_APIENTRY glIsSyncAPPLE (GLsync sync); +GL_APICALL void GL_APIENTRY glDeleteSyncAPPLE (GLsync sync); +GL_APICALL GLenum GL_APIENTRY glClientWaitSyncAPPLE (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_APICALL void GL_APIENTRY glWaitSyncAPPLE (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_APICALL void GL_APIENTRY glGetInteger64vAPPLE (GLenum pname, GLint64 *params); +GL_APICALL void GL_APIENTRY glGetSyncivAPPLE (GLsync sync, GLenum pname, GLsizei count, GLsizei *length, GLint *values); +#endif +#endif /* GL_APPLE_sync */ + +#ifndef GL_APPLE_texture_format_BGRA8888 +#define GL_APPLE_texture_format_BGRA8888 1 +#define GL_BGRA_EXT 0x80E1 +#define GL_BGRA8_EXT 0x93A1 +#endif /* GL_APPLE_texture_format_BGRA8888 */ + +#ifndef GL_APPLE_texture_max_level +#define GL_APPLE_texture_max_level 1 +#define GL_TEXTURE_MAX_LEVEL_APPLE 0x813D +#endif /* GL_APPLE_texture_max_level */ + +#ifndef GL_APPLE_texture_packed_float +#define GL_APPLE_texture_packed_float 1 +#define GL_UNSIGNED_INT_10F_11F_11F_REV_APPLE 0x8C3B +#define GL_UNSIGNED_INT_5_9_9_9_REV_APPLE 0x8C3E +#define GL_R11F_G11F_B10F_APPLE 0x8C3A +#define GL_RGB9_E5_APPLE 0x8C3D +#endif /* GL_APPLE_texture_packed_float */ + +#ifndef GL_ARM_mali_program_binary +#define GL_ARM_mali_program_binary 1 +#define GL_MALI_PROGRAM_BINARY_ARM 0x8F61 +#endif /* GL_ARM_mali_program_binary */ + +#ifndef GL_ARM_mali_shader_binary +#define GL_ARM_mali_shader_binary 1 +#define GL_MALI_SHADER_BINARY_ARM 0x8F60 +#endif /* GL_ARM_mali_shader_binary */ + +#ifndef GL_ARM_rgba8 +#define GL_ARM_rgba8 1 +#endif /* GL_ARM_rgba8 */ + +#ifndef GL_ARM_shader_framebuffer_fetch +#define GL_ARM_shader_framebuffer_fetch 1 +#define GL_FETCH_PER_SAMPLE_ARM 0x8F65 +#define GL_FRAGMENT_SHADER_FRAMEBUFFER_FETCH_MRT_ARM 0x8F66 +#endif /* GL_ARM_shader_framebuffer_fetch */ + +#ifndef GL_ARM_shader_framebuffer_fetch_depth_stencil +#define GL_ARM_shader_framebuffer_fetch_depth_stencil 1 +#endif /* GL_ARM_shader_framebuffer_fetch_depth_stencil */ + +#ifndef GL_ARM_texture_unnormalized_coordinates +#define GL_ARM_texture_unnormalized_coordinates 1 +#define GL_TEXTURE_UNNORMALIZED_COORDINATES_ARM 0x8F6A +#endif /* GL_ARM_texture_unnormalized_coordinates */ + +#ifndef GL_DMP_program_binary +#define GL_DMP_program_binary 1 +#define GL_SMAPHS30_PROGRAM_BINARY_DMP 0x9251 +#define GL_SMAPHS_PROGRAM_BINARY_DMP 0x9252 +#define GL_DMP_PROGRAM_BINARY_DMP 0x9253 +#endif /* GL_DMP_program_binary */ + +#ifndef GL_DMP_shader_binary +#define GL_DMP_shader_binary 1 +#define GL_SHADER_BINARY_DMP 0x9250 +#endif /* GL_DMP_shader_binary */ + +#ifndef GL_EXT_EGL_image_array +#define GL_EXT_EGL_image_array 1 +#endif /* GL_EXT_EGL_image_array */ + +#ifndef GL_EXT_EGL_image_storage +#define GL_EXT_EGL_image_storage 1 +typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETTEXSTORAGEEXTPROC) (GLenum target, GLeglImageOES image, const GLint* attrib_list); +typedef void (GL_APIENTRYP PFNGLEGLIMAGETARGETTEXTURESTORAGEEXTPROC) (GLuint texture, GLeglImageOES image, const GLint* attrib_list); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glEGLImageTargetTexStorageEXT (GLenum target, GLeglImageOES image, const GLint* attrib_list); +GL_APICALL void GL_APIENTRY glEGLImageTargetTextureStorageEXT (GLuint texture, GLeglImageOES image, const GLint* attrib_list); +#endif +#endif /* GL_EXT_EGL_image_storage */ + +#ifndef GL_EXT_YUV_target +#define GL_EXT_YUV_target 1 +#define GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT 0x8BE7 +#endif /* GL_EXT_YUV_target */ + +#ifndef GL_EXT_base_instance +#define GL_EXT_base_instance 1 +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDBASEINSTANCEEXTPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEINSTANCEEXTPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEEXTPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawArraysInstancedBaseInstanceEXT (GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance); +GL_APICALL void GL_APIENTRY glDrawElementsInstancedBaseInstanceEXT (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance); +GL_APICALL void GL_APIENTRY glDrawElementsInstancedBaseVertexBaseInstanceEXT (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance); +#endif +#endif /* GL_EXT_base_instance */ + +#ifndef GL_EXT_blend_func_extended +#define GL_EXT_blend_func_extended 1 +#define GL_SRC1_COLOR_EXT 0x88F9 +#define GL_SRC1_ALPHA_EXT 0x8589 +#define GL_ONE_MINUS_SRC1_COLOR_EXT 0x88FA +#define GL_ONE_MINUS_SRC1_ALPHA_EXT 0x88FB +#define GL_SRC_ALPHA_SATURATE_EXT 0x0308 +#define GL_LOCATION_INDEX_EXT 0x930F +#define GL_MAX_DUAL_SOURCE_DRAW_BUFFERS_EXT 0x88FC +typedef void (GL_APIENTRYP PFNGLBINDFRAGDATALOCATIONINDEXEDEXTPROC) (GLuint program, GLuint colorNumber, GLuint index, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLBINDFRAGDATALOCATIONEXTPROC) (GLuint program, GLuint color, const GLchar *name); +typedef GLint (GL_APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONINDEXEXTPROC) (GLuint program, GLenum programInterface, const GLchar *name); +typedef GLint (GL_APIENTRYP PFNGLGETFRAGDATAINDEXEXTPROC) (GLuint program, const GLchar *name); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBindFragDataLocationIndexedEXT (GLuint program, GLuint colorNumber, GLuint index, const GLchar *name); +GL_APICALL void GL_APIENTRY glBindFragDataLocationEXT (GLuint program, GLuint color, const GLchar *name); +GL_APICALL GLint GL_APIENTRY glGetProgramResourceLocationIndexEXT (GLuint program, GLenum programInterface, const GLchar *name); +GL_APICALL GLint GL_APIENTRY glGetFragDataIndexEXT (GLuint program, const GLchar *name); +#endif +#endif /* GL_EXT_blend_func_extended */ + +#ifndef GL_EXT_blend_minmax +#define GL_EXT_blend_minmax 1 +#define GL_MIN_EXT 0x8007 +#define GL_MAX_EXT 0x8008 +#endif /* GL_EXT_blend_minmax */ + +#ifndef GL_EXT_buffer_storage +#define GL_EXT_buffer_storage 1 +#define GL_MAP_READ_BIT 0x0001 +#define GL_MAP_WRITE_BIT 0x0002 +#define GL_MAP_PERSISTENT_BIT_EXT 0x0040 +#define GL_MAP_COHERENT_BIT_EXT 0x0080 +#define GL_DYNAMIC_STORAGE_BIT_EXT 0x0100 +#define GL_CLIENT_STORAGE_BIT_EXT 0x0200 +#define GL_CLIENT_MAPPED_BUFFER_BARRIER_BIT_EXT 0x00004000 +#define GL_BUFFER_IMMUTABLE_STORAGE_EXT 0x821F +#define GL_BUFFER_STORAGE_FLAGS_EXT 0x8220 +typedef void (GL_APIENTRYP PFNGLBUFFERSTORAGEEXTPROC) (GLenum target, GLsizeiptr size, const void *data, GLbitfield flags); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBufferStorageEXT (GLenum target, GLsizeiptr size, const void *data, GLbitfield flags); +#endif +#endif /* GL_EXT_buffer_storage */ + +#ifndef GL_EXT_clear_texture +#define GL_EXT_clear_texture 1 +typedef void (GL_APIENTRYP PFNGLCLEARTEXIMAGEEXTPROC) (GLuint texture, GLint level, GLenum format, GLenum type, const void *data); +typedef void (GL_APIENTRYP PFNGLCLEARTEXSUBIMAGEEXTPROC) (GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *data); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glClearTexImageEXT (GLuint texture, GLint level, GLenum format, GLenum type, const void *data); +GL_APICALL void GL_APIENTRY glClearTexSubImageEXT (GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *data); +#endif +#endif /* GL_EXT_clear_texture */ + +#ifndef GL_EXT_clip_control +#define GL_EXT_clip_control 1 +#define GL_LOWER_LEFT_EXT 0x8CA1 +#define GL_UPPER_LEFT_EXT 0x8CA2 +#define GL_NEGATIVE_ONE_TO_ONE_EXT 0x935E +#define GL_ZERO_TO_ONE_EXT 0x935F +#define GL_CLIP_ORIGIN_EXT 0x935C +#define GL_CLIP_DEPTH_MODE_EXT 0x935D +typedef void (GL_APIENTRYP PFNGLCLIPCONTROLEXTPROC) (GLenum origin, GLenum depth); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glClipControlEXT (GLenum origin, GLenum depth); +#endif +#endif /* GL_EXT_clip_control */ + +#ifndef GL_EXT_clip_cull_distance +#define GL_EXT_clip_cull_distance 1 +#define GL_MAX_CLIP_DISTANCES_EXT 0x0D32 +#define GL_MAX_CULL_DISTANCES_EXT 0x82F9 +#define GL_MAX_COMBINED_CLIP_AND_CULL_DISTANCES_EXT 0x82FA +#define GL_CLIP_DISTANCE0_EXT 0x3000 +#define GL_CLIP_DISTANCE1_EXT 0x3001 +#define GL_CLIP_DISTANCE2_EXT 0x3002 +#define GL_CLIP_DISTANCE3_EXT 0x3003 +#define GL_CLIP_DISTANCE4_EXT 0x3004 +#define GL_CLIP_DISTANCE5_EXT 0x3005 +#define GL_CLIP_DISTANCE6_EXT 0x3006 +#define GL_CLIP_DISTANCE7_EXT 0x3007 +#endif /* GL_EXT_clip_cull_distance */ + +#ifndef GL_EXT_color_buffer_float +#define GL_EXT_color_buffer_float 1 +#endif /* GL_EXT_color_buffer_float */ + +#ifndef GL_EXT_color_buffer_half_float +#define GL_EXT_color_buffer_half_float 1 +#define GL_RGBA16F_EXT 0x881A +#define GL_RGB16F_EXT 0x881B +#define GL_RG16F_EXT 0x822F +#define GL_R16F_EXT 0x822D +#define GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE_EXT 0x8211 +#define GL_UNSIGNED_NORMALIZED_EXT 0x8C17 +#endif /* GL_EXT_color_buffer_half_float */ + +#ifndef GL_EXT_conservative_depth +#define GL_EXT_conservative_depth 1 +#endif /* GL_EXT_conservative_depth */ + +#ifndef GL_EXT_copy_image +#define GL_EXT_copy_image 1 +typedef void (GL_APIENTRYP PFNGLCOPYIMAGESUBDATAEXTPROC) (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCopyImageSubDataEXT (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth); +#endif +#endif /* GL_EXT_copy_image */ + +#ifndef GL_EXT_debug_label +#define GL_EXT_debug_label 1 +#define GL_PROGRAM_PIPELINE_OBJECT_EXT 0x8A4F +#define GL_PROGRAM_OBJECT_EXT 0x8B40 +#define GL_SHADER_OBJECT_EXT 0x8B48 +#define GL_BUFFER_OBJECT_EXT 0x9151 +#define GL_QUERY_OBJECT_EXT 0x9153 +#define GL_VERTEX_ARRAY_OBJECT_EXT 0x9154 +#define GL_TRANSFORM_FEEDBACK 0x8E22 +typedef void (GL_APIENTRYP PFNGLLABELOBJECTEXTPROC) (GLenum type, GLuint object, GLsizei length, const GLchar *label); +typedef void (GL_APIENTRYP PFNGLGETOBJECTLABELEXTPROC) (GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glLabelObjectEXT (GLenum type, GLuint object, GLsizei length, const GLchar *label); +GL_APICALL void GL_APIENTRY glGetObjectLabelEXT (GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label); +#endif +#endif /* GL_EXT_debug_label */ + +#ifndef GL_EXT_debug_marker +#define GL_EXT_debug_marker 1 +typedef void (GL_APIENTRYP PFNGLINSERTEVENTMARKEREXTPROC) (GLsizei length, const GLchar *marker); +typedef void (GL_APIENTRYP PFNGLPUSHGROUPMARKEREXTPROC) (GLsizei length, const GLchar *marker); +typedef void (GL_APIENTRYP PFNGLPOPGROUPMARKEREXTPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glInsertEventMarkerEXT (GLsizei length, const GLchar *marker); +GL_APICALL void GL_APIENTRY glPushGroupMarkerEXT (GLsizei length, const GLchar *marker); +GL_APICALL void GL_APIENTRY glPopGroupMarkerEXT (void); +#endif +#endif /* GL_EXT_debug_marker */ + +#ifndef GL_EXT_depth_clamp +#define GL_EXT_depth_clamp 1 +#define GL_DEPTH_CLAMP_EXT 0x864F +#endif /* GL_EXT_depth_clamp */ + +#ifndef GL_EXT_discard_framebuffer +#define GL_EXT_discard_framebuffer 1 +#define GL_COLOR_EXT 0x1800 +#define GL_DEPTH_EXT 0x1801 +#define GL_STENCIL_EXT 0x1802 +typedef void (GL_APIENTRYP PFNGLDISCARDFRAMEBUFFEREXTPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDiscardFramebufferEXT (GLenum target, GLsizei numAttachments, const GLenum *attachments); +#endif +#endif /* GL_EXT_discard_framebuffer */ + +#ifndef GL_EXT_disjoint_timer_query +#define GL_EXT_disjoint_timer_query 1 +#define GL_QUERY_COUNTER_BITS_EXT 0x8864 +#define GL_CURRENT_QUERY_EXT 0x8865 +#define GL_QUERY_RESULT_EXT 0x8866 +#define GL_QUERY_RESULT_AVAILABLE_EXT 0x8867 +#define GL_TIME_ELAPSED_EXT 0x88BF +#define GL_TIMESTAMP_EXT 0x8E28 +#define GL_GPU_DISJOINT_EXT 0x8FBB +typedef void (GL_APIENTRYP PFNGLGENQUERIESEXTPROC) (GLsizei n, GLuint *ids); +typedef void (GL_APIENTRYP PFNGLDELETEQUERIESEXTPROC) (GLsizei n, const GLuint *ids); +typedef GLboolean (GL_APIENTRYP PFNGLISQUERYEXTPROC) (GLuint id); +typedef void (GL_APIENTRYP PFNGLBEGINQUERYEXTPROC) (GLenum target, GLuint id); +typedef void (GL_APIENTRYP PFNGLENDQUERYEXTPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLQUERYCOUNTEREXTPROC) (GLuint id, GLenum target); +typedef void (GL_APIENTRYP PFNGLGETQUERYIVEXTPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTIVEXTPROC) (GLuint id, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUIVEXTPROC) (GLuint id, GLenum pname, GLuint *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTI64VEXTPROC) (GLuint id, GLenum pname, GLint64 *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUI64VEXTPROC) (GLuint id, GLenum pname, GLuint64 *params); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64VEXTPROC) (GLenum pname, GLint64 *data); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGenQueriesEXT (GLsizei n, GLuint *ids); +GL_APICALL void GL_APIENTRY glDeleteQueriesEXT (GLsizei n, const GLuint *ids); +GL_APICALL GLboolean GL_APIENTRY glIsQueryEXT (GLuint id); +GL_APICALL void GL_APIENTRY glBeginQueryEXT (GLenum target, GLuint id); +GL_APICALL void GL_APIENTRY glEndQueryEXT (GLenum target); +GL_APICALL void GL_APIENTRY glQueryCounterEXT (GLuint id, GLenum target); +GL_APICALL void GL_APIENTRY glGetQueryivEXT (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetQueryObjectivEXT (GLuint id, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetQueryObjectuivEXT (GLuint id, GLenum pname, GLuint *params); +GL_APICALL void GL_APIENTRY glGetQueryObjecti64vEXT (GLuint id, GLenum pname, GLint64 *params); +GL_APICALL void GL_APIENTRY glGetQueryObjectui64vEXT (GLuint id, GLenum pname, GLuint64 *params); +GL_APICALL void GL_APIENTRY glGetInteger64vEXT (GLenum pname, GLint64 *data); +#endif +#endif /* GL_EXT_disjoint_timer_query */ + +#ifndef GL_EXT_draw_buffers +#define GL_EXT_draw_buffers 1 +#define GL_MAX_COLOR_ATTACHMENTS_EXT 0x8CDF +#define GL_MAX_DRAW_BUFFERS_EXT 0x8824 +#define GL_DRAW_BUFFER0_EXT 0x8825 +#define GL_DRAW_BUFFER1_EXT 0x8826 +#define GL_DRAW_BUFFER2_EXT 0x8827 +#define GL_DRAW_BUFFER3_EXT 0x8828 +#define GL_DRAW_BUFFER4_EXT 0x8829 +#define GL_DRAW_BUFFER5_EXT 0x882A +#define GL_DRAW_BUFFER6_EXT 0x882B +#define GL_DRAW_BUFFER7_EXT 0x882C +#define GL_DRAW_BUFFER8_EXT 0x882D +#define GL_DRAW_BUFFER9_EXT 0x882E +#define GL_DRAW_BUFFER10_EXT 0x882F +#define GL_DRAW_BUFFER11_EXT 0x8830 +#define GL_DRAW_BUFFER12_EXT 0x8831 +#define GL_DRAW_BUFFER13_EXT 0x8832 +#define GL_DRAW_BUFFER14_EXT 0x8833 +#define GL_DRAW_BUFFER15_EXT 0x8834 +#define GL_COLOR_ATTACHMENT0_EXT 0x8CE0 +#define GL_COLOR_ATTACHMENT1_EXT 0x8CE1 +#define GL_COLOR_ATTACHMENT2_EXT 0x8CE2 +#define GL_COLOR_ATTACHMENT3_EXT 0x8CE3 +#define GL_COLOR_ATTACHMENT4_EXT 0x8CE4 +#define GL_COLOR_ATTACHMENT5_EXT 0x8CE5 +#define GL_COLOR_ATTACHMENT6_EXT 0x8CE6 +#define GL_COLOR_ATTACHMENT7_EXT 0x8CE7 +#define GL_COLOR_ATTACHMENT8_EXT 0x8CE8 +#define GL_COLOR_ATTACHMENT9_EXT 0x8CE9 +#define GL_COLOR_ATTACHMENT10_EXT 0x8CEA +#define GL_COLOR_ATTACHMENT11_EXT 0x8CEB +#define GL_COLOR_ATTACHMENT12_EXT 0x8CEC +#define GL_COLOR_ATTACHMENT13_EXT 0x8CED +#define GL_COLOR_ATTACHMENT14_EXT 0x8CEE +#define GL_COLOR_ATTACHMENT15_EXT 0x8CEF +typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSEXTPROC) (GLsizei n, const GLenum *bufs); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawBuffersEXT (GLsizei n, const GLenum *bufs); +#endif +#endif /* GL_EXT_draw_buffers */ + +#ifndef GL_EXT_draw_buffers_indexed +#define GL_EXT_draw_buffers_indexed 1 +typedef void (GL_APIENTRYP PFNGLENABLEIEXTPROC) (GLenum target, GLuint index); +typedef void (GL_APIENTRYP PFNGLDISABLEIEXTPROC) (GLenum target, GLuint index); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONIEXTPROC) (GLuint buf, GLenum mode); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEIEXTPROC) (GLuint buf, GLenum modeRGB, GLenum modeAlpha); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCIEXTPROC) (GLuint buf, GLenum src, GLenum dst); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCSEPARATEIEXTPROC) (GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha); +typedef void (GL_APIENTRYP PFNGLCOLORMASKIEXTPROC) (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); +typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDIEXTPROC) (GLenum target, GLuint index); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glEnableiEXT (GLenum target, GLuint index); +GL_APICALL void GL_APIENTRY glDisableiEXT (GLenum target, GLuint index); +GL_APICALL void GL_APIENTRY glBlendEquationiEXT (GLuint buf, GLenum mode); +GL_APICALL void GL_APIENTRY glBlendEquationSeparateiEXT (GLuint buf, GLenum modeRGB, GLenum modeAlpha); +GL_APICALL void GL_APIENTRY glBlendFunciEXT (GLuint buf, GLenum src, GLenum dst); +GL_APICALL void GL_APIENTRY glBlendFuncSeparateiEXT (GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha); +GL_APICALL void GL_APIENTRY glColorMaskiEXT (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); +GL_APICALL GLboolean GL_APIENTRY glIsEnablediEXT (GLenum target, GLuint index); +#endif +#endif /* GL_EXT_draw_buffers_indexed */ + +#ifndef GL_EXT_draw_elements_base_vertex +#define GL_EXT_draw_elements_base_vertex 1 +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSBASEVERTEXEXTPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLint basevertex); +typedef void (GL_APIENTRYP PFNGLDRAWRANGEELEMENTSBASEVERTEXEXTPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices, GLint basevertex); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXEXTPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawElementsBaseVertexEXT (GLenum mode, GLsizei count, GLenum type, const void *indices, GLint basevertex); +GL_APICALL void GL_APIENTRY glDrawRangeElementsBaseVertexEXT (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices, GLint basevertex); +GL_APICALL void GL_APIENTRY glDrawElementsInstancedBaseVertexEXT (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex); +#endif +#endif /* GL_EXT_draw_elements_base_vertex */ + +#ifndef GL_EXT_draw_instanced +#define GL_EXT_draw_instanced 1 +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDEXTPROC) (GLenum mode, GLint start, GLsizei count, GLsizei primcount); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDEXTPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawArraysInstancedEXT (GLenum mode, GLint start, GLsizei count, GLsizei primcount); +GL_APICALL void GL_APIENTRY glDrawElementsInstancedEXT (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount); +#endif +#endif /* GL_EXT_draw_instanced */ + +#ifndef GL_EXT_draw_transform_feedback +#define GL_EXT_draw_transform_feedback 1 +typedef void (GL_APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKEXTPROC) (GLenum mode, GLuint id); +typedef void (GL_APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKINSTANCEDEXTPROC) (GLenum mode, GLuint id, GLsizei instancecount); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawTransformFeedbackEXT (GLenum mode, GLuint id); +GL_APICALL void GL_APIENTRY glDrawTransformFeedbackInstancedEXT (GLenum mode, GLuint id, GLsizei instancecount); +#endif +#endif /* GL_EXT_draw_transform_feedback */ + +#ifndef GL_EXT_external_buffer +#define GL_EXT_external_buffer 1 +typedef void *GLeglClientBufferEXT; +typedef void (GL_APIENTRYP PFNGLBUFFERSTORAGEEXTERNALEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr size, GLeglClientBufferEXT clientBuffer, GLbitfield flags); +typedef void (GL_APIENTRYP PFNGLNAMEDBUFFERSTORAGEEXTERNALEXTPROC) (GLuint buffer, GLintptr offset, GLsizeiptr size, GLeglClientBufferEXT clientBuffer, GLbitfield flags); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBufferStorageExternalEXT (GLenum target, GLintptr offset, GLsizeiptr size, GLeglClientBufferEXT clientBuffer, GLbitfield flags); +GL_APICALL void GL_APIENTRY glNamedBufferStorageExternalEXT (GLuint buffer, GLintptr offset, GLsizeiptr size, GLeglClientBufferEXT clientBuffer, GLbitfield flags); +#endif +#endif /* GL_EXT_external_buffer */ + +#ifndef GL_EXT_float_blend +#define GL_EXT_float_blend 1 +#endif /* GL_EXT_float_blend */ + +#ifndef GL_EXT_geometry_point_size +#define GL_EXT_geometry_point_size 1 +#endif /* GL_EXT_geometry_point_size */ + +#ifndef GL_EXT_geometry_shader +#define GL_EXT_geometry_shader 1 +#define GL_GEOMETRY_SHADER_EXT 0x8DD9 +#define GL_GEOMETRY_SHADER_BIT_EXT 0x00000004 +#define GL_GEOMETRY_LINKED_VERTICES_OUT_EXT 0x8916 +#define GL_GEOMETRY_LINKED_INPUT_TYPE_EXT 0x8917 +#define GL_GEOMETRY_LINKED_OUTPUT_TYPE_EXT 0x8918 +#define GL_GEOMETRY_SHADER_INVOCATIONS_EXT 0x887F +#define GL_LAYER_PROVOKING_VERTEX_EXT 0x825E +#define GL_LINES_ADJACENCY_EXT 0x000A +#define GL_LINE_STRIP_ADJACENCY_EXT 0x000B +#define GL_TRIANGLES_ADJACENCY_EXT 0x000C +#define GL_TRIANGLE_STRIP_ADJACENCY_EXT 0x000D +#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_EXT 0x8DDF +#define GL_MAX_GEOMETRY_UNIFORM_BLOCKS_EXT 0x8A2C +#define GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS_EXT 0x8A32 +#define GL_MAX_GEOMETRY_INPUT_COMPONENTS_EXT 0x9123 +#define GL_MAX_GEOMETRY_OUTPUT_COMPONENTS_EXT 0x9124 +#define GL_MAX_GEOMETRY_OUTPUT_VERTICES_EXT 0x8DE0 +#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_EXT 0x8DE1 +#define GL_MAX_GEOMETRY_SHADER_INVOCATIONS_EXT 0x8E5A +#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT 0x8C29 +#define GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS_EXT 0x92CF +#define GL_MAX_GEOMETRY_ATOMIC_COUNTERS_EXT 0x92D5 +#define GL_MAX_GEOMETRY_IMAGE_UNIFORMS_EXT 0x90CD +#define GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS_EXT 0x90D7 +#define GL_FIRST_VERTEX_CONVENTION_EXT 0x8E4D +#define GL_LAST_VERTEX_CONVENTION_EXT 0x8E4E +#define GL_UNDEFINED_VERTEX_EXT 0x8260 +#define GL_PRIMITIVES_GENERATED_EXT 0x8C87 +#define GL_FRAMEBUFFER_DEFAULT_LAYERS_EXT 0x9312 +#define GL_MAX_FRAMEBUFFER_LAYERS_EXT 0x9317 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT 0x8DA8 +#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT 0x8DA7 +#define GL_REFERENCED_BY_GEOMETRY_SHADER_EXT 0x9309 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTUREEXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferTextureEXT (GLenum target, GLenum attachment, GLuint texture, GLint level); +#endif +#endif /* GL_EXT_geometry_shader */ + +#ifndef GL_EXT_gpu_shader5 +#define GL_EXT_gpu_shader5 1 +#endif /* GL_EXT_gpu_shader5 */ + +#ifndef GL_EXT_instanced_arrays +#define GL_EXT_instanced_arrays 1 +#define GL_VERTEX_ATTRIB_ARRAY_DIVISOR_EXT 0x88FE +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISOREXTPROC) (GLuint index, GLuint divisor); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glVertexAttribDivisorEXT (GLuint index, GLuint divisor); +#endif +#endif /* GL_EXT_instanced_arrays */ + +#ifndef GL_EXT_map_buffer_range +#define GL_EXT_map_buffer_range 1 +#define GL_MAP_READ_BIT_EXT 0x0001 +#define GL_MAP_WRITE_BIT_EXT 0x0002 +#define GL_MAP_INVALIDATE_RANGE_BIT_EXT 0x0004 +#define GL_MAP_INVALIDATE_BUFFER_BIT_EXT 0x0008 +#define GL_MAP_FLUSH_EXPLICIT_BIT_EXT 0x0010 +#define GL_MAP_UNSYNCHRONIZED_BIT_EXT 0x0020 +typedef void *(GL_APIENTRYP PFNGLMAPBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +typedef void (GL_APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void *GL_APIENTRY glMapBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +GL_APICALL void GL_APIENTRY glFlushMappedBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length); +#endif +#endif /* GL_EXT_map_buffer_range */ + +#ifndef GL_EXT_memory_object +#define GL_EXT_memory_object 1 +#define GL_TEXTURE_TILING_EXT 0x9580 +#define GL_DEDICATED_MEMORY_OBJECT_EXT 0x9581 +#define GL_PROTECTED_MEMORY_OBJECT_EXT 0x959B +#define GL_NUM_TILING_TYPES_EXT 0x9582 +#define GL_TILING_TYPES_EXT 0x9583 +#define GL_OPTIMAL_TILING_EXT 0x9584 +#define GL_LINEAR_TILING_EXT 0x9585 +#define GL_NUM_DEVICE_UUIDS_EXT 0x9596 +#define GL_DEVICE_UUID_EXT 0x9597 +#define GL_DRIVER_UUID_EXT 0x9598 +#define GL_UUID_SIZE_EXT 16 +typedef void (GL_APIENTRYP PFNGLGETUNSIGNEDBYTEVEXTPROC) (GLenum pname, GLubyte *data); +typedef void (GL_APIENTRYP PFNGLGETUNSIGNEDBYTEI_VEXTPROC) (GLenum target, GLuint index, GLubyte *data); +typedef void (GL_APIENTRYP PFNGLDELETEMEMORYOBJECTSEXTPROC) (GLsizei n, const GLuint *memoryObjects); +typedef GLboolean (GL_APIENTRYP PFNGLISMEMORYOBJECTEXTPROC) (GLuint memoryObject); +typedef void (GL_APIENTRYP PFNGLCREATEMEMORYOBJECTSEXTPROC) (GLsizei n, GLuint *memoryObjects); +typedef void (GL_APIENTRYP PFNGLMEMORYOBJECTPARAMETERIVEXTPROC) (GLuint memoryObject, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLGETMEMORYOBJECTPARAMETERIVEXTPROC) (GLuint memoryObject, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEM2DEXTPROC) (GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEM2DMULTISAMPLEEXTPROC) (GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEM3DEXTPROC) (GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEM3DMULTISAMPLEEXTPROC) (GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLBUFFERSTORAGEMEMEXTPROC) (GLenum target, GLsizeiptr size, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGEMEM2DEXTPROC) (GLuint texture, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGEMEM2DMULTISAMPLEEXTPROC) (GLuint texture, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGEMEM3DEXTPROC) (GLuint texture, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGEMEM3DMULTISAMPLEEXTPROC) (GLuint texture, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLNAMEDBUFFERSTORAGEMEMEXTPROC) (GLuint buffer, GLsizeiptr size, GLuint memory, GLuint64 offset); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetUnsignedBytevEXT (GLenum pname, GLubyte *data); +GL_APICALL void GL_APIENTRY glGetUnsignedBytei_vEXT (GLenum target, GLuint index, GLubyte *data); +GL_APICALL void GL_APIENTRY glDeleteMemoryObjectsEXT (GLsizei n, const GLuint *memoryObjects); +GL_APICALL GLboolean GL_APIENTRY glIsMemoryObjectEXT (GLuint memoryObject); +GL_APICALL void GL_APIENTRY glCreateMemoryObjectsEXT (GLsizei n, GLuint *memoryObjects); +GL_APICALL void GL_APIENTRY glMemoryObjectParameterivEXT (GLuint memoryObject, GLenum pname, const GLint *params); +GL_APICALL void GL_APIENTRY glGetMemoryObjectParameterivEXT (GLuint memoryObject, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glTexStorageMem2DEXT (GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glTexStorageMem2DMultisampleEXT (GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glTexStorageMem3DEXT (GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glTexStorageMem3DMultisampleEXT (GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glBufferStorageMemEXT (GLenum target, GLsizeiptr size, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glTextureStorageMem2DEXT (GLuint texture, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glTextureStorageMem2DMultisampleEXT (GLuint texture, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glTextureStorageMem3DEXT (GLuint texture, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glTextureStorageMem3DMultisampleEXT (GLuint texture, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glNamedBufferStorageMemEXT (GLuint buffer, GLsizeiptr size, GLuint memory, GLuint64 offset); +#endif +#endif /* GL_EXT_memory_object */ + +#ifndef GL_EXT_memory_object_fd +#define GL_EXT_memory_object_fd 1 +#define GL_HANDLE_TYPE_OPAQUE_FD_EXT 0x9586 +typedef void (GL_APIENTRYP PFNGLIMPORTMEMORYFDEXTPROC) (GLuint memory, GLuint64 size, GLenum handleType, GLint fd); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glImportMemoryFdEXT (GLuint memory, GLuint64 size, GLenum handleType, GLint fd); +#endif +#endif /* GL_EXT_memory_object_fd */ + +#ifndef GL_EXT_memory_object_win32 +#define GL_EXT_memory_object_win32 1 +#define GL_HANDLE_TYPE_OPAQUE_WIN32_EXT 0x9587 +#define GL_HANDLE_TYPE_OPAQUE_WIN32_KMT_EXT 0x9588 +#define GL_DEVICE_LUID_EXT 0x9599 +#define GL_DEVICE_NODE_MASK_EXT 0x959A +#define GL_LUID_SIZE_EXT 8 +#define GL_HANDLE_TYPE_D3D12_TILEPOOL_EXT 0x9589 +#define GL_HANDLE_TYPE_D3D12_RESOURCE_EXT 0x958A +#define GL_HANDLE_TYPE_D3D11_IMAGE_EXT 0x958B +#define GL_HANDLE_TYPE_D3D11_IMAGE_KMT_EXT 0x958C +typedef void (GL_APIENTRYP PFNGLIMPORTMEMORYWIN32HANDLEEXTPROC) (GLuint memory, GLuint64 size, GLenum handleType, void *handle); +typedef void (GL_APIENTRYP PFNGLIMPORTMEMORYWIN32NAMEEXTPROC) (GLuint memory, GLuint64 size, GLenum handleType, const void *name); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glImportMemoryWin32HandleEXT (GLuint memory, GLuint64 size, GLenum handleType, void *handle); +GL_APICALL void GL_APIENTRY glImportMemoryWin32NameEXT (GLuint memory, GLuint64 size, GLenum handleType, const void *name); +#endif +#endif /* GL_EXT_memory_object_win32 */ + +#ifndef GL_EXT_multi_draw_arrays +#define GL_EXT_multi_draw_arrays 1 +typedef void (GL_APIENTRYP PFNGLMULTIDRAWARRAYSEXTPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei primcount); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glMultiDrawArraysEXT (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount); +GL_APICALL void GL_APIENTRY glMultiDrawElementsEXT (GLenum mode, const GLsizei *count, GLenum type, const void *const*indices, GLsizei primcount); +#endif +#endif /* GL_EXT_multi_draw_arrays */ + +#ifndef GL_EXT_multi_draw_indirect +#define GL_EXT_multi_draw_indirect 1 +typedef void (GL_APIENTRYP PFNGLMULTIDRAWARRAYSINDIRECTEXTPROC) (GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSINDIRECTEXTPROC) (GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glMultiDrawArraysIndirectEXT (GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride); +GL_APICALL void GL_APIENTRY glMultiDrawElementsIndirectEXT (GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride); +#endif +#endif /* GL_EXT_multi_draw_indirect */ + +#ifndef GL_EXT_multisampled_compatibility +#define GL_EXT_multisampled_compatibility 1 +#define GL_MULTISAMPLE_EXT 0x809D +#define GL_SAMPLE_ALPHA_TO_ONE_EXT 0x809F +#endif /* GL_EXT_multisampled_compatibility */ + +#ifndef GL_EXT_multisampled_render_to_texture +#define GL_EXT_multisampled_render_to_texture 1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_SAMPLES_EXT 0x8D6C +#define GL_RENDERBUFFER_SAMPLES_EXT 0x8CAB +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT 0x8D56 +#define GL_MAX_SAMPLES_EXT 0x8D57 +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEEXTPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleEXT (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glFramebufferTexture2DMultisampleEXT (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); +#endif +#endif /* GL_EXT_multisampled_render_to_texture */ + +#ifndef GL_EXT_multisampled_render_to_texture2 +#define GL_EXT_multisampled_render_to_texture2 1 +#endif /* GL_EXT_multisampled_render_to_texture2 */ + +#ifndef GL_EXT_multiview_draw_buffers +#define GL_EXT_multiview_draw_buffers 1 +#define GL_COLOR_ATTACHMENT_EXT 0x90F0 +#define GL_MULTIVIEW_EXT 0x90F1 +#define GL_DRAW_BUFFER_EXT 0x0C01 +#define GL_READ_BUFFER_EXT 0x0C02 +#define GL_MAX_MULTIVIEW_BUFFERS_EXT 0x90F2 +typedef void (GL_APIENTRYP PFNGLREADBUFFERINDEXEDEXTPROC) (GLenum src, GLint index); +typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSINDEXEDEXTPROC) (GLint n, const GLenum *location, const GLint *indices); +typedef void (GL_APIENTRYP PFNGLGETINTEGERI_VEXTPROC) (GLenum target, GLuint index, GLint *data); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glReadBufferIndexedEXT (GLenum src, GLint index); +GL_APICALL void GL_APIENTRY glDrawBuffersIndexedEXT (GLint n, const GLenum *location, const GLint *indices); +GL_APICALL void GL_APIENTRY glGetIntegeri_vEXT (GLenum target, GLuint index, GLint *data); +#endif +#endif /* GL_EXT_multiview_draw_buffers */ + +#ifndef GL_EXT_multiview_tessellation_geometry_shader +#define GL_EXT_multiview_tessellation_geometry_shader 1 +#endif /* GL_EXT_multiview_tessellation_geometry_shader */ + +#ifndef GL_EXT_multiview_texture_multisample +#define GL_EXT_multiview_texture_multisample 1 +#endif /* GL_EXT_multiview_texture_multisample */ + +#ifndef GL_EXT_multiview_timer_query +#define GL_EXT_multiview_timer_query 1 +#endif /* GL_EXT_multiview_timer_query */ + +#ifndef GL_EXT_occlusion_query_boolean +#define GL_EXT_occlusion_query_boolean 1 +#define GL_ANY_SAMPLES_PASSED_EXT 0x8C2F +#define GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT 0x8D6A +#endif /* GL_EXT_occlusion_query_boolean */ + +#ifndef GL_EXT_polygon_offset_clamp +#define GL_EXT_polygon_offset_clamp 1 +#define GL_POLYGON_OFFSET_CLAMP_EXT 0x8E1B +typedef void (GL_APIENTRYP PFNGLPOLYGONOFFSETCLAMPEXTPROC) (GLfloat factor, GLfloat units, GLfloat clamp); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glPolygonOffsetClampEXT (GLfloat factor, GLfloat units, GLfloat clamp); +#endif +#endif /* GL_EXT_polygon_offset_clamp */ + +#ifndef GL_EXT_post_depth_coverage +#define GL_EXT_post_depth_coverage 1 +#endif /* GL_EXT_post_depth_coverage */ + +#ifndef GL_EXT_primitive_bounding_box +#define GL_EXT_primitive_bounding_box 1 +#define GL_PRIMITIVE_BOUNDING_BOX_EXT 0x92BE +typedef void (GL_APIENTRYP PFNGLPRIMITIVEBOUNDINGBOXEXTPROC) (GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glPrimitiveBoundingBoxEXT (GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW); +#endif +#endif /* GL_EXT_primitive_bounding_box */ + +#ifndef GL_EXT_protected_textures +#define GL_EXT_protected_textures 1 +#define GL_CONTEXT_FLAG_PROTECTED_CONTENT_BIT_EXT 0x00000010 +#define GL_TEXTURE_PROTECTED_EXT 0x8BFA +#endif /* GL_EXT_protected_textures */ + +#ifndef GL_EXT_pvrtc_sRGB +#define GL_EXT_pvrtc_sRGB 1 +#define GL_COMPRESSED_SRGB_PVRTC_2BPPV1_EXT 0x8A54 +#define GL_COMPRESSED_SRGB_PVRTC_4BPPV1_EXT 0x8A55 +#define GL_COMPRESSED_SRGB_ALPHA_PVRTC_2BPPV1_EXT 0x8A56 +#define GL_COMPRESSED_SRGB_ALPHA_PVRTC_4BPPV1_EXT 0x8A57 +#define GL_COMPRESSED_SRGB_ALPHA_PVRTC_2BPPV2_IMG 0x93F0 +#define GL_COMPRESSED_SRGB_ALPHA_PVRTC_4BPPV2_IMG 0x93F1 +#endif /* GL_EXT_pvrtc_sRGB */ + +#ifndef GL_EXT_raster_multisample +#define GL_EXT_raster_multisample 1 +#define GL_RASTER_MULTISAMPLE_EXT 0x9327 +#define GL_RASTER_SAMPLES_EXT 0x9328 +#define GL_MAX_RASTER_SAMPLES_EXT 0x9329 +#define GL_RASTER_FIXED_SAMPLE_LOCATIONS_EXT 0x932A +#define GL_MULTISAMPLE_RASTERIZATION_ALLOWED_EXT 0x932B +#define GL_EFFECTIVE_RASTER_SAMPLES_EXT 0x932C +typedef void (GL_APIENTRYP PFNGLRASTERSAMPLESEXTPROC) (GLuint samples, GLboolean fixedsamplelocations); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glRasterSamplesEXT (GLuint samples, GLboolean fixedsamplelocations); +#endif +#endif /* GL_EXT_raster_multisample */ + +#ifndef GL_EXT_read_format_bgra +#define GL_EXT_read_format_bgra 1 +#define GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT 0x8365 +#define GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT 0x8366 +#endif /* GL_EXT_read_format_bgra */ + +#ifndef GL_EXT_render_snorm +#define GL_EXT_render_snorm 1 +#define GL_R8_SNORM 0x8F94 +#define GL_RG8_SNORM 0x8F95 +#define GL_RGBA8_SNORM 0x8F97 +#define GL_R16_SNORM_EXT 0x8F98 +#define GL_RG16_SNORM_EXT 0x8F99 +#define GL_RGBA16_SNORM_EXT 0x8F9B +#endif /* GL_EXT_render_snorm */ + +#ifndef GL_EXT_robustness +#define GL_EXT_robustness 1 +#define GL_GUILTY_CONTEXT_RESET_EXT 0x8253 +#define GL_INNOCENT_CONTEXT_RESET_EXT 0x8254 +#define GL_UNKNOWN_CONTEXT_RESET_EXT 0x8255 +#define GL_CONTEXT_ROBUST_ACCESS_EXT 0x90F3 +#define GL_RESET_NOTIFICATION_STRATEGY_EXT 0x8256 +#define GL_LOSE_CONTEXT_ON_RESET_EXT 0x8252 +#define GL_NO_RESET_NOTIFICATION_EXT 0x8261 +typedef GLenum (GL_APIENTRYP PFNGLGETGRAPHICSRESETSTATUSEXTPROC) (void); +typedef void (GL_APIENTRYP PFNGLREADNPIXELSEXTPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMFVEXTPROC) (GLuint program, GLint location, GLsizei bufSize, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMIVEXTPROC) (GLuint program, GLint location, GLsizei bufSize, GLint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL GLenum GL_APIENTRY glGetGraphicsResetStatusEXT (void); +GL_APICALL void GL_APIENTRY glReadnPixelsEXT (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data); +GL_APICALL void GL_APIENTRY glGetnUniformfvEXT (GLuint program, GLint location, GLsizei bufSize, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetnUniformivEXT (GLuint program, GLint location, GLsizei bufSize, GLint *params); +#endif +#endif /* GL_EXT_robustness */ + +#ifndef GL_EXT_sRGB +#define GL_EXT_sRGB 1 +#define GL_SRGB_EXT 0x8C40 +#define GL_SRGB_ALPHA_EXT 0x8C42 +#define GL_SRGB8_ALPHA8_EXT 0x8C43 +#define GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING_EXT 0x8210 +#endif /* GL_EXT_sRGB */ + +#ifndef GL_EXT_sRGB_write_control +#define GL_EXT_sRGB_write_control 1 +#define GL_FRAMEBUFFER_SRGB_EXT 0x8DB9 +#endif /* GL_EXT_sRGB_write_control */ + +#ifndef GL_EXT_semaphore +#define GL_EXT_semaphore 1 +#define GL_LAYOUT_GENERAL_EXT 0x958D +#define GL_LAYOUT_COLOR_ATTACHMENT_EXT 0x958E +#define GL_LAYOUT_DEPTH_STENCIL_ATTACHMENT_EXT 0x958F +#define GL_LAYOUT_DEPTH_STENCIL_READ_ONLY_EXT 0x9590 +#define GL_LAYOUT_SHADER_READ_ONLY_EXT 0x9591 +#define GL_LAYOUT_TRANSFER_SRC_EXT 0x9592 +#define GL_LAYOUT_TRANSFER_DST_EXT 0x9593 +#define GL_LAYOUT_DEPTH_READ_ONLY_STENCIL_ATTACHMENT_EXT 0x9530 +#define GL_LAYOUT_DEPTH_ATTACHMENT_STENCIL_READ_ONLY_EXT 0x9531 +typedef void (GL_APIENTRYP PFNGLGENSEMAPHORESEXTPROC) (GLsizei n, GLuint *semaphores); +typedef void (GL_APIENTRYP PFNGLDELETESEMAPHORESEXTPROC) (GLsizei n, const GLuint *semaphores); +typedef GLboolean (GL_APIENTRYP PFNGLISSEMAPHOREEXTPROC) (GLuint semaphore); +typedef void (GL_APIENTRYP PFNGLSEMAPHOREPARAMETERUI64VEXTPROC) (GLuint semaphore, GLenum pname, const GLuint64 *params); +typedef void (GL_APIENTRYP PFNGLGETSEMAPHOREPARAMETERUI64VEXTPROC) (GLuint semaphore, GLenum pname, GLuint64 *params); +typedef void (GL_APIENTRYP PFNGLWAITSEMAPHOREEXTPROC) (GLuint semaphore, GLuint numBufferBarriers, const GLuint *buffers, GLuint numTextureBarriers, const GLuint *textures, const GLenum *srcLayouts); +typedef void (GL_APIENTRYP PFNGLSIGNALSEMAPHOREEXTPROC) (GLuint semaphore, GLuint numBufferBarriers, const GLuint *buffers, GLuint numTextureBarriers, const GLuint *textures, const GLenum *dstLayouts); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGenSemaphoresEXT (GLsizei n, GLuint *semaphores); +GL_APICALL void GL_APIENTRY glDeleteSemaphoresEXT (GLsizei n, const GLuint *semaphores); +GL_APICALL GLboolean GL_APIENTRY glIsSemaphoreEXT (GLuint semaphore); +GL_APICALL void GL_APIENTRY glSemaphoreParameterui64vEXT (GLuint semaphore, GLenum pname, const GLuint64 *params); +GL_APICALL void GL_APIENTRY glGetSemaphoreParameterui64vEXT (GLuint semaphore, GLenum pname, GLuint64 *params); +GL_APICALL void GL_APIENTRY glWaitSemaphoreEXT (GLuint semaphore, GLuint numBufferBarriers, const GLuint *buffers, GLuint numTextureBarriers, const GLuint *textures, const GLenum *srcLayouts); +GL_APICALL void GL_APIENTRY glSignalSemaphoreEXT (GLuint semaphore, GLuint numBufferBarriers, const GLuint *buffers, GLuint numTextureBarriers, const GLuint *textures, const GLenum *dstLayouts); +#endif +#endif /* GL_EXT_semaphore */ + +#ifndef GL_EXT_semaphore_fd +#define GL_EXT_semaphore_fd 1 +typedef void (GL_APIENTRYP PFNGLIMPORTSEMAPHOREFDEXTPROC) (GLuint semaphore, GLenum handleType, GLint fd); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glImportSemaphoreFdEXT (GLuint semaphore, GLenum handleType, GLint fd); +#endif +#endif /* GL_EXT_semaphore_fd */ + +#ifndef GL_EXT_semaphore_win32 +#define GL_EXT_semaphore_win32 1 +#define GL_HANDLE_TYPE_D3D12_FENCE_EXT 0x9594 +#define GL_D3D12_FENCE_VALUE_EXT 0x9595 +typedef void (GL_APIENTRYP PFNGLIMPORTSEMAPHOREWIN32HANDLEEXTPROC) (GLuint semaphore, GLenum handleType, void *handle); +typedef void (GL_APIENTRYP PFNGLIMPORTSEMAPHOREWIN32NAMEEXTPROC) (GLuint semaphore, GLenum handleType, const void *name); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glImportSemaphoreWin32HandleEXT (GLuint semaphore, GLenum handleType, void *handle); +GL_APICALL void GL_APIENTRY glImportSemaphoreWin32NameEXT (GLuint semaphore, GLenum handleType, const void *name); +#endif +#endif /* GL_EXT_semaphore_win32 */ + +#ifndef GL_EXT_separate_shader_objects +#define GL_EXT_separate_shader_objects 1 +#define GL_ACTIVE_PROGRAM_EXT 0x8259 +#define GL_VERTEX_SHADER_BIT_EXT 0x00000001 +#define GL_FRAGMENT_SHADER_BIT_EXT 0x00000002 +#define GL_ALL_SHADER_BITS_EXT 0xFFFFFFFF +#define GL_PROGRAM_SEPARABLE_EXT 0x8258 +#define GL_PROGRAM_PIPELINE_BINDING_EXT 0x825A +typedef void (GL_APIENTRYP PFNGLACTIVESHADERPROGRAMEXTPROC) (GLuint pipeline, GLuint program); +typedef void (GL_APIENTRYP PFNGLBINDPROGRAMPIPELINEEXTPROC) (GLuint pipeline); +typedef GLuint (GL_APIENTRYP PFNGLCREATESHADERPROGRAMVEXTPROC) (GLenum type, GLsizei count, const GLchar **strings); +typedef void (GL_APIENTRYP PFNGLDELETEPROGRAMPIPELINESEXTPROC) (GLsizei n, const GLuint *pipelines); +typedef void (GL_APIENTRYP PFNGLGENPROGRAMPIPELINESEXTPROC) (GLsizei n, GLuint *pipelines); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMPIPELINEINFOLOGEXTPROC) (GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMPIPELINEIVEXTPROC) (GLuint pipeline, GLenum pname, GLint *params); +typedef GLboolean (GL_APIENTRYP PFNGLISPROGRAMPIPELINEEXTPROC) (GLuint pipeline); +typedef void (GL_APIENTRYP PFNGLPROGRAMPARAMETERIEXTPROC) (GLuint program, GLenum pname, GLint value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1FEXTPROC) (GLuint program, GLint location, GLfloat v0); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1IEXTPROC) (GLuint program, GLint location, GLint v0); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2FEXTPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2IEXTPROC) (GLuint program, GLint location, GLint v0, GLint v1); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3FEXTPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3IEXTPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4FEXTPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4FVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4IEXTPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4IVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUSEPROGRAMSTAGESEXTPROC) (GLuint pipeline, GLbitfield stages, GLuint program); +typedef void (GL_APIENTRYP PFNGLVALIDATEPROGRAMPIPELINEEXTPROC) (GLuint pipeline); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UIEXTPROC) (GLuint program, GLint location, GLuint v0); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UIEXTPROC) (GLuint program, GLint location, GLuint v0, GLuint v1); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UIEXTPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UIEXTPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UIVEXTPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X3FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X2FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X4FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X2FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X4FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X3FVEXTPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glActiveShaderProgramEXT (GLuint pipeline, GLuint program); +GL_APICALL void GL_APIENTRY glBindProgramPipelineEXT (GLuint pipeline); +GL_APICALL GLuint GL_APIENTRY glCreateShaderProgramvEXT (GLenum type, GLsizei count, const GLchar **strings); +GL_APICALL void GL_APIENTRY glDeleteProgramPipelinesEXT (GLsizei n, const GLuint *pipelines); +GL_APICALL void GL_APIENTRY glGenProgramPipelinesEXT (GLsizei n, GLuint *pipelines); +GL_APICALL void GL_APIENTRY glGetProgramPipelineInfoLogEXT (GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glGetProgramPipelineivEXT (GLuint pipeline, GLenum pname, GLint *params); +GL_APICALL GLboolean GL_APIENTRY glIsProgramPipelineEXT (GLuint pipeline); +GL_APICALL void GL_APIENTRY glProgramParameteriEXT (GLuint program, GLenum pname, GLint value); +GL_APICALL void GL_APIENTRY glProgramUniform1fEXT (GLuint program, GLint location, GLfloat v0); +GL_APICALL void GL_APIENTRY glProgramUniform1fvEXT (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform1iEXT (GLuint program, GLint location, GLint v0); +GL_APICALL void GL_APIENTRY glProgramUniform1ivEXT (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform2fEXT (GLuint program, GLint location, GLfloat v0, GLfloat v1); +GL_APICALL void GL_APIENTRY glProgramUniform2fvEXT (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform2iEXT (GLuint program, GLint location, GLint v0, GLint v1); +GL_APICALL void GL_APIENTRY glProgramUniform2ivEXT (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform3fEXT (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +GL_APICALL void GL_APIENTRY glProgramUniform3fvEXT (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform3iEXT (GLuint program, GLint location, GLint v0, GLint v1, GLint v2); +GL_APICALL void GL_APIENTRY glProgramUniform3ivEXT (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform4fEXT (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +GL_APICALL void GL_APIENTRY glProgramUniform4fvEXT (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform4iEXT (GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +GL_APICALL void GL_APIENTRY glProgramUniform4ivEXT (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix2fvEXT (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix3fvEXT (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix4fvEXT (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUseProgramStagesEXT (GLuint pipeline, GLbitfield stages, GLuint program); +GL_APICALL void GL_APIENTRY glValidateProgramPipelineEXT (GLuint pipeline); +GL_APICALL void GL_APIENTRY glProgramUniform1uiEXT (GLuint program, GLint location, GLuint v0); +GL_APICALL void GL_APIENTRY glProgramUniform2uiEXT (GLuint program, GLint location, GLuint v0, GLuint v1); +GL_APICALL void GL_APIENTRY glProgramUniform3uiEXT (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2); +GL_APICALL void GL_APIENTRY glProgramUniform4uiEXT (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +GL_APICALL void GL_APIENTRY glProgramUniform1uivEXT (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform2uivEXT (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform3uivEXT (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform4uivEXT (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix2x3fvEXT (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix3x2fvEXT (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix2x4fvEXT (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix4x2fvEXT (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix3x4fvEXT (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix4x3fvEXT (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +#endif +#endif /* GL_EXT_separate_shader_objects */ + +#ifndef GL_EXT_shader_framebuffer_fetch +#define GL_EXT_shader_framebuffer_fetch 1 +#define GL_FRAGMENT_SHADER_DISCARDS_SAMPLES_EXT 0x8A52 +#endif /* GL_EXT_shader_framebuffer_fetch */ + +#ifndef GL_EXT_shader_framebuffer_fetch_non_coherent +#define GL_EXT_shader_framebuffer_fetch_non_coherent 1 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERFETCHBARRIEREXTPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferFetchBarrierEXT (void); +#endif +#endif /* GL_EXT_shader_framebuffer_fetch_non_coherent */ + +#ifndef GL_EXT_shader_group_vote +#define GL_EXT_shader_group_vote 1 +#endif /* GL_EXT_shader_group_vote */ + +#ifndef GL_EXT_shader_implicit_conversions +#define GL_EXT_shader_implicit_conversions 1 +#endif /* GL_EXT_shader_implicit_conversions */ + +#ifndef GL_EXT_shader_integer_mix +#define GL_EXT_shader_integer_mix 1 +#endif /* GL_EXT_shader_integer_mix */ + +#ifndef GL_EXT_shader_io_blocks +#define GL_EXT_shader_io_blocks 1 +#endif /* GL_EXT_shader_io_blocks */ + +#ifndef GL_EXT_shader_non_constant_global_initializers +#define GL_EXT_shader_non_constant_global_initializers 1 +#endif /* GL_EXT_shader_non_constant_global_initializers */ + +#ifndef GL_EXT_shader_pixel_local_storage +#define GL_EXT_shader_pixel_local_storage 1 +#define GL_MAX_SHADER_PIXEL_LOCAL_STORAGE_FAST_SIZE_EXT 0x8F63 +#define GL_MAX_SHADER_PIXEL_LOCAL_STORAGE_SIZE_EXT 0x8F67 +#define GL_SHADER_PIXEL_LOCAL_STORAGE_EXT 0x8F64 +#endif /* GL_EXT_shader_pixel_local_storage */ + +#ifndef GL_EXT_shader_pixel_local_storage2 +#define GL_EXT_shader_pixel_local_storage2 1 +#define GL_MAX_SHADER_COMBINED_LOCAL_STORAGE_FAST_SIZE_EXT 0x9650 +#define GL_MAX_SHADER_COMBINED_LOCAL_STORAGE_SIZE_EXT 0x9651 +#define GL_FRAMEBUFFER_INCOMPLETE_INSUFFICIENT_SHADER_COMBINED_LOCAL_STORAGE_EXT 0x9652 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERPIXELLOCALSTORAGESIZEEXTPROC) (GLuint target, GLsizei size); +typedef GLsizei (GL_APIENTRYP PFNGLGETFRAMEBUFFERPIXELLOCALSTORAGESIZEEXTPROC) (GLuint target); +typedef void (GL_APIENTRYP PFNGLCLEARPIXELLOCALSTORAGEUIEXTPROC) (GLsizei offset, GLsizei n, const GLuint *values); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferPixelLocalStorageSizeEXT (GLuint target, GLsizei size); +GL_APICALL GLsizei GL_APIENTRY glGetFramebufferPixelLocalStorageSizeEXT (GLuint target); +GL_APICALL void GL_APIENTRY glClearPixelLocalStorageuiEXT (GLsizei offset, GLsizei n, const GLuint *values); +#endif +#endif /* GL_EXT_shader_pixel_local_storage2 */ + +#ifndef GL_EXT_shader_texture_lod +#define GL_EXT_shader_texture_lod 1 +#endif /* GL_EXT_shader_texture_lod */ + +#ifndef GL_EXT_shadow_samplers +#define GL_EXT_shadow_samplers 1 +#define GL_TEXTURE_COMPARE_MODE_EXT 0x884C +#define GL_TEXTURE_COMPARE_FUNC_EXT 0x884D +#define GL_COMPARE_REF_TO_TEXTURE_EXT 0x884E +#define GL_SAMPLER_2D_SHADOW_EXT 0x8B62 +#endif /* GL_EXT_shadow_samplers */ + +#ifndef GL_EXT_sparse_texture +#define GL_EXT_sparse_texture 1 +#define GL_TEXTURE_SPARSE_EXT 0x91A6 +#define GL_VIRTUAL_PAGE_SIZE_INDEX_EXT 0x91A7 +#define GL_NUM_SPARSE_LEVELS_EXT 0x91AA +#define GL_NUM_VIRTUAL_PAGE_SIZES_EXT 0x91A8 +#define GL_VIRTUAL_PAGE_SIZE_X_EXT 0x9195 +#define GL_VIRTUAL_PAGE_SIZE_Y_EXT 0x9196 +#define GL_VIRTUAL_PAGE_SIZE_Z_EXT 0x9197 +#define GL_TEXTURE_2D_ARRAY 0x8C1A +#define GL_TEXTURE_3D 0x806F +#define GL_MAX_SPARSE_TEXTURE_SIZE_EXT 0x9198 +#define GL_MAX_SPARSE_3D_TEXTURE_SIZE_EXT 0x9199 +#define GL_MAX_SPARSE_ARRAY_TEXTURE_LAYERS_EXT 0x919A +#define GL_SPARSE_TEXTURE_FULL_ARRAY_CUBE_MIPMAPS_EXT 0x91A9 +typedef void (GL_APIENTRYP PFNGLTEXPAGECOMMITMENTEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLboolean commit); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexPageCommitmentEXT (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLboolean commit); +#endif +#endif /* GL_EXT_sparse_texture */ + +#ifndef GL_EXT_sparse_texture2 +#define GL_EXT_sparse_texture2 1 +#endif /* GL_EXT_sparse_texture2 */ + +#ifndef GL_EXT_tessellation_point_size +#define GL_EXT_tessellation_point_size 1 +#endif /* GL_EXT_tessellation_point_size */ + +#ifndef GL_EXT_tessellation_shader +#define GL_EXT_tessellation_shader 1 +#define GL_PATCHES_EXT 0x000E +#define GL_PATCH_VERTICES_EXT 0x8E72 +#define GL_TESS_CONTROL_OUTPUT_VERTICES_EXT 0x8E75 +#define GL_TESS_GEN_MODE_EXT 0x8E76 +#define GL_TESS_GEN_SPACING_EXT 0x8E77 +#define GL_TESS_GEN_VERTEX_ORDER_EXT 0x8E78 +#define GL_TESS_GEN_POINT_MODE_EXT 0x8E79 +#define GL_ISOLINES_EXT 0x8E7A +#define GL_QUADS_EXT 0x0007 +#define GL_FRACTIONAL_ODD_EXT 0x8E7B +#define GL_FRACTIONAL_EVEN_EXT 0x8E7C +#define GL_MAX_PATCH_VERTICES_EXT 0x8E7D +#define GL_MAX_TESS_GEN_LEVEL_EXT 0x8E7E +#define GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS_EXT 0x8E7F +#define GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS_EXT 0x8E80 +#define GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS_EXT 0x8E81 +#define GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS_EXT 0x8E82 +#define GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS_EXT 0x8E83 +#define GL_MAX_TESS_PATCH_COMPONENTS_EXT 0x8E84 +#define GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS_EXT 0x8E85 +#define GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS_EXT 0x8E86 +#define GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS_EXT 0x8E89 +#define GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS_EXT 0x8E8A +#define GL_MAX_TESS_CONTROL_INPUT_COMPONENTS_EXT 0x886C +#define GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS_EXT 0x886D +#define GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS_EXT 0x8E1E +#define GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS_EXT 0x8E1F +#define GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS_EXT 0x92CD +#define GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS_EXT 0x92CE +#define GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS_EXT 0x92D3 +#define GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS_EXT 0x92D4 +#define GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS_EXT 0x90CB +#define GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS_EXT 0x90CC +#define GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS_EXT 0x90D8 +#define GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS_EXT 0x90D9 +#define GL_PRIMITIVE_RESTART_FOR_PATCHES_SUPPORTED 0x8221 +#define GL_IS_PER_PATCH_EXT 0x92E7 +#define GL_REFERENCED_BY_TESS_CONTROL_SHADER_EXT 0x9307 +#define GL_REFERENCED_BY_TESS_EVALUATION_SHADER_EXT 0x9308 +#define GL_TESS_CONTROL_SHADER_EXT 0x8E88 +#define GL_TESS_EVALUATION_SHADER_EXT 0x8E87 +#define GL_TESS_CONTROL_SHADER_BIT_EXT 0x00000008 +#define GL_TESS_EVALUATION_SHADER_BIT_EXT 0x00000010 +typedef void (GL_APIENTRYP PFNGLPATCHPARAMETERIEXTPROC) (GLenum pname, GLint value); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glPatchParameteriEXT (GLenum pname, GLint value); +#endif +#endif /* GL_EXT_tessellation_shader */ + +#ifndef GL_EXT_texture_border_clamp +#define GL_EXT_texture_border_clamp 1 +#define GL_TEXTURE_BORDER_COLOR_EXT 0x1004 +#define GL_CLAMP_TO_BORDER_EXT 0x812D +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIUIVEXTPROC) (GLenum target, GLenum pname, const GLuint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIIVEXTPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIUIVEXTPROC) (GLenum target, GLenum pname, GLuint *params); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIIVEXTPROC) (GLuint sampler, GLenum pname, const GLint *param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIUIVEXTPROC) (GLuint sampler, GLenum pname, const GLuint *param); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIIVEXTPROC) (GLuint sampler, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIUIVEXTPROC) (GLuint sampler, GLenum pname, GLuint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexParameterIivEXT (GLenum target, GLenum pname, const GLint *params); +GL_APICALL void GL_APIENTRY glTexParameterIuivEXT (GLenum target, GLenum pname, const GLuint *params); +GL_APICALL void GL_APIENTRY glGetTexParameterIivEXT (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetTexParameterIuivEXT (GLenum target, GLenum pname, GLuint *params); +GL_APICALL void GL_APIENTRY glSamplerParameterIivEXT (GLuint sampler, GLenum pname, const GLint *param); +GL_APICALL void GL_APIENTRY glSamplerParameterIuivEXT (GLuint sampler, GLenum pname, const GLuint *param); +GL_APICALL void GL_APIENTRY glGetSamplerParameterIivEXT (GLuint sampler, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetSamplerParameterIuivEXT (GLuint sampler, GLenum pname, GLuint *params); +#endif +#endif /* GL_EXT_texture_border_clamp */ + +#ifndef GL_EXT_texture_buffer +#define GL_EXT_texture_buffer 1 +#define GL_TEXTURE_BUFFER_EXT 0x8C2A +#define GL_TEXTURE_BUFFER_BINDING_EXT 0x8C2A +#define GL_MAX_TEXTURE_BUFFER_SIZE_EXT 0x8C2B +#define GL_TEXTURE_BINDING_BUFFER_EXT 0x8C2C +#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING_EXT 0x8C2D +#define GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT_EXT 0x919F +#define GL_SAMPLER_BUFFER_EXT 0x8DC2 +#define GL_INT_SAMPLER_BUFFER_EXT 0x8DD0 +#define GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT 0x8DD8 +#define GL_IMAGE_BUFFER_EXT 0x9051 +#define GL_INT_IMAGE_BUFFER_EXT 0x905C +#define GL_UNSIGNED_INT_IMAGE_BUFFER_EXT 0x9067 +#define GL_TEXTURE_BUFFER_OFFSET_EXT 0x919D +#define GL_TEXTURE_BUFFER_SIZE_EXT 0x919E +typedef void (GL_APIENTRYP PFNGLTEXBUFFEREXTPROC) (GLenum target, GLenum internalformat, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLTEXBUFFERRANGEEXTPROC) (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexBufferEXT (GLenum target, GLenum internalformat, GLuint buffer); +GL_APICALL void GL_APIENTRY glTexBufferRangeEXT (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +#endif +#endif /* GL_EXT_texture_buffer */ + +#ifndef GL_EXT_texture_compression_astc_decode_mode +#define GL_EXT_texture_compression_astc_decode_mode 1 +#define GL_TEXTURE_ASTC_DECODE_PRECISION_EXT 0x8F69 +#endif /* GL_EXT_texture_compression_astc_decode_mode */ + +#ifndef GL_EXT_texture_compression_bptc +#define GL_EXT_texture_compression_bptc 1 +#define GL_COMPRESSED_RGBA_BPTC_UNORM_EXT 0x8E8C +#define GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM_EXT 0x8E8D +#define GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT_EXT 0x8E8E +#define GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_EXT 0x8E8F +#endif /* GL_EXT_texture_compression_bptc */ + +#ifndef GL_EXT_texture_compression_dxt1 +#define GL_EXT_texture_compression_dxt1 1 +#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0 +#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1 +#endif /* GL_EXT_texture_compression_dxt1 */ + +#ifndef GL_EXT_texture_compression_rgtc +#define GL_EXT_texture_compression_rgtc 1 +#define GL_COMPRESSED_RED_RGTC1_EXT 0x8DBB +#define GL_COMPRESSED_SIGNED_RED_RGTC1_EXT 0x8DBC +#define GL_COMPRESSED_RED_GREEN_RGTC2_EXT 0x8DBD +#define GL_COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT 0x8DBE +#endif /* GL_EXT_texture_compression_rgtc */ + +#ifndef GL_EXT_texture_compression_s3tc +#define GL_EXT_texture_compression_s3tc 1 +#define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT 0x83F2 +#define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3 +#endif /* GL_EXT_texture_compression_s3tc */ + +#ifndef GL_EXT_texture_compression_s3tc_srgb +#define GL_EXT_texture_compression_s3tc_srgb 1 +#define GL_COMPRESSED_SRGB_S3TC_DXT1_EXT 0x8C4C +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT 0x8C4D +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT 0x8C4E +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT 0x8C4F +#endif /* GL_EXT_texture_compression_s3tc_srgb */ + +#ifndef GL_EXT_texture_cube_map_array +#define GL_EXT_texture_cube_map_array 1 +#define GL_TEXTURE_CUBE_MAP_ARRAY_EXT 0x9009 +#define GL_TEXTURE_BINDING_CUBE_MAP_ARRAY_EXT 0x900A +#define GL_SAMPLER_CUBE_MAP_ARRAY_EXT 0x900C +#define GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW_EXT 0x900D +#define GL_INT_SAMPLER_CUBE_MAP_ARRAY_EXT 0x900E +#define GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY_EXT 0x900F +#define GL_IMAGE_CUBE_MAP_ARRAY_EXT 0x9054 +#define GL_INT_IMAGE_CUBE_MAP_ARRAY_EXT 0x905F +#define GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY_EXT 0x906A +#endif /* GL_EXT_texture_cube_map_array */ + +#ifndef GL_EXT_texture_filter_anisotropic +#define GL_EXT_texture_filter_anisotropic 1 +#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE +#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF +#endif /* GL_EXT_texture_filter_anisotropic */ + +#ifndef GL_EXT_texture_filter_minmax +#define GL_EXT_texture_filter_minmax 1 +#define GL_TEXTURE_REDUCTION_MODE_EXT 0x9366 +#define GL_WEIGHTED_AVERAGE_EXT 0x9367 +#endif /* GL_EXT_texture_filter_minmax */ + +#ifndef GL_EXT_texture_format_BGRA8888 +#define GL_EXT_texture_format_BGRA8888 1 +#endif /* GL_EXT_texture_format_BGRA8888 */ + +#ifndef GL_EXT_texture_format_sRGB_override +#define GL_EXT_texture_format_sRGB_override 1 +#define GL_TEXTURE_FORMAT_SRGB_OVERRIDE_EXT 0x8FBF +#endif /* GL_EXT_texture_format_sRGB_override */ + +#ifndef GL_EXT_texture_mirror_clamp_to_edge +#define GL_EXT_texture_mirror_clamp_to_edge 1 +#define GL_MIRROR_CLAMP_TO_EDGE_EXT 0x8743 +#endif /* GL_EXT_texture_mirror_clamp_to_edge */ + +#ifndef GL_EXT_texture_norm16 +#define GL_EXT_texture_norm16 1 +#define GL_R16_EXT 0x822A +#define GL_RG16_EXT 0x822C +#define GL_RGBA16_EXT 0x805B +#define GL_RGB16_EXT 0x8054 +#define GL_RGB16_SNORM_EXT 0x8F9A +#endif /* GL_EXT_texture_norm16 */ + +#ifndef GL_EXT_texture_query_lod +#define GL_EXT_texture_query_lod 1 +#endif /* GL_EXT_texture_query_lod */ + +#ifndef GL_EXT_texture_rg +#define GL_EXT_texture_rg 1 +#define GL_RED_EXT 0x1903 +#define GL_RG_EXT 0x8227 +#define GL_R8_EXT 0x8229 +#define GL_RG8_EXT 0x822B +#endif /* GL_EXT_texture_rg */ + +#ifndef GL_EXT_texture_sRGB_R8 +#define GL_EXT_texture_sRGB_R8 1 +#define GL_SR8_EXT 0x8FBD +#endif /* GL_EXT_texture_sRGB_R8 */ + +#ifndef GL_EXT_texture_sRGB_RG8 +#define GL_EXT_texture_sRGB_RG8 1 +#define GL_SRG8_EXT 0x8FBE +#endif /* GL_EXT_texture_sRGB_RG8 */ + +#ifndef GL_EXT_texture_sRGB_decode +#define GL_EXT_texture_sRGB_decode 1 +#define GL_TEXTURE_SRGB_DECODE_EXT 0x8A48 +#define GL_DECODE_EXT 0x8A49 +#define GL_SKIP_DECODE_EXT 0x8A4A +#endif /* GL_EXT_texture_sRGB_decode */ + +#ifndef GL_EXT_texture_shadow_lod +#define GL_EXT_texture_shadow_lod 1 +#endif /* GL_EXT_texture_shadow_lod */ + +#ifndef GL_EXT_texture_storage +#define GL_EXT_texture_storage 1 +#define GL_TEXTURE_IMMUTABLE_FORMAT_EXT 0x912F +#define GL_ALPHA8_EXT 0x803C +#define GL_LUMINANCE8_EXT 0x8040 +#define GL_LUMINANCE8_ALPHA8_EXT 0x8045 +#define GL_RGBA32F_EXT 0x8814 +#define GL_RGB32F_EXT 0x8815 +#define GL_ALPHA32F_EXT 0x8816 +#define GL_LUMINANCE32F_EXT 0x8818 +#define GL_LUMINANCE_ALPHA32F_EXT 0x8819 +#define GL_ALPHA16F_EXT 0x881C +#define GL_LUMINANCE16F_EXT 0x881E +#define GL_LUMINANCE_ALPHA16F_EXT 0x881F +#define GL_R32F_EXT 0x822E +#define GL_RG32F_EXT 0x8230 +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE1DEXTPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DEXTPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE3DEXTPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGE1DEXTPROC) (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGE2DEXTPROC) (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGE3DEXTPROC) (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexStorage1DEXT (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width); +GL_APICALL void GL_APIENTRY glTexStorage2DEXT (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glTexStorage3DEXT (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +GL_APICALL void GL_APIENTRY glTextureStorage1DEXT (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width); +GL_APICALL void GL_APIENTRY glTextureStorage2DEXT (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glTextureStorage3DEXT (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +#endif +#endif /* GL_EXT_texture_storage */ + +#ifndef GL_EXT_texture_type_2_10_10_10_REV +#define GL_EXT_texture_type_2_10_10_10_REV 1 +#define GL_UNSIGNED_INT_2_10_10_10_REV_EXT 0x8368 +#endif /* GL_EXT_texture_type_2_10_10_10_REV */ + +#ifndef GL_EXT_texture_view +#define GL_EXT_texture_view 1 +#define GL_TEXTURE_VIEW_MIN_LEVEL_EXT 0x82DB +#define GL_TEXTURE_VIEW_NUM_LEVELS_EXT 0x82DC +#define GL_TEXTURE_VIEW_MIN_LAYER_EXT 0x82DD +#define GL_TEXTURE_VIEW_NUM_LAYERS_EXT 0x82DE +typedef void (GL_APIENTRYP PFNGLTEXTUREVIEWEXTPROC) (GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTextureViewEXT (GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers); +#endif +#endif /* GL_EXT_texture_view */ + +#ifndef GL_EXT_unpack_subimage +#define GL_EXT_unpack_subimage 1 +#define GL_UNPACK_ROW_LENGTH_EXT 0x0CF2 +#define GL_UNPACK_SKIP_ROWS_EXT 0x0CF3 +#define GL_UNPACK_SKIP_PIXELS_EXT 0x0CF4 +#endif /* GL_EXT_unpack_subimage */ + +#ifndef GL_EXT_win32_keyed_mutex +#define GL_EXT_win32_keyed_mutex 1 +typedef GLboolean (GL_APIENTRYP PFNGLACQUIREKEYEDMUTEXWIN32EXTPROC) (GLuint memory, GLuint64 key, GLuint timeout); +typedef GLboolean (GL_APIENTRYP PFNGLRELEASEKEYEDMUTEXWIN32EXTPROC) (GLuint memory, GLuint64 key); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL GLboolean GL_APIENTRY glAcquireKeyedMutexWin32EXT (GLuint memory, GLuint64 key, GLuint timeout); +GL_APICALL GLboolean GL_APIENTRY glReleaseKeyedMutexWin32EXT (GLuint memory, GLuint64 key); +#endif +#endif /* GL_EXT_win32_keyed_mutex */ + +#ifndef GL_EXT_window_rectangles +#define GL_EXT_window_rectangles 1 +#define GL_INCLUSIVE_EXT 0x8F10 +#define GL_EXCLUSIVE_EXT 0x8F11 +#define GL_WINDOW_RECTANGLE_EXT 0x8F12 +#define GL_WINDOW_RECTANGLE_MODE_EXT 0x8F13 +#define GL_MAX_WINDOW_RECTANGLES_EXT 0x8F14 +#define GL_NUM_WINDOW_RECTANGLES_EXT 0x8F15 +typedef void (GL_APIENTRYP PFNGLWINDOWRECTANGLESEXTPROC) (GLenum mode, GLsizei count, const GLint *box); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glWindowRectanglesEXT (GLenum mode, GLsizei count, const GLint *box); +#endif +#endif /* GL_EXT_window_rectangles */ + +#ifndef GL_FJ_shader_binary_GCCSO +#define GL_FJ_shader_binary_GCCSO 1 +#define GL_GCCSO_SHADER_BINARY_FJ 0x9260 +#endif /* GL_FJ_shader_binary_GCCSO */ + +#ifndef GL_IMG_bindless_texture +#define GL_IMG_bindless_texture 1 +typedef GLuint64 (GL_APIENTRYP PFNGLGETTEXTUREHANDLEIMGPROC) (GLuint texture); +typedef GLuint64 (GL_APIENTRYP PFNGLGETTEXTURESAMPLERHANDLEIMGPROC) (GLuint texture, GLuint sampler); +typedef void (GL_APIENTRYP PFNGLUNIFORMHANDLEUI64IMGPROC) (GLint location, GLuint64 value); +typedef void (GL_APIENTRYP PFNGLUNIFORMHANDLEUI64VIMGPROC) (GLint location, GLsizei count, const GLuint64 *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMHANDLEUI64IMGPROC) (GLuint program, GLint location, GLuint64 value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMHANDLEUI64VIMGPROC) (GLuint program, GLint location, GLsizei count, const GLuint64 *values); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL GLuint64 GL_APIENTRY glGetTextureHandleIMG (GLuint texture); +GL_APICALL GLuint64 GL_APIENTRY glGetTextureSamplerHandleIMG (GLuint texture, GLuint sampler); +GL_APICALL void GL_APIENTRY glUniformHandleui64IMG (GLint location, GLuint64 value); +GL_APICALL void GL_APIENTRY glUniformHandleui64vIMG (GLint location, GLsizei count, const GLuint64 *value); +GL_APICALL void GL_APIENTRY glProgramUniformHandleui64IMG (GLuint program, GLint location, GLuint64 value); +GL_APICALL void GL_APIENTRY glProgramUniformHandleui64vIMG (GLuint program, GLint location, GLsizei count, const GLuint64 *values); +#endif +#endif /* GL_IMG_bindless_texture */ + +#ifndef GL_IMG_framebuffer_downsample +#define GL_IMG_framebuffer_downsample 1 +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_AND_DOWNSAMPLE_IMG 0x913C +#define GL_NUM_DOWNSAMPLE_SCALES_IMG 0x913D +#define GL_DOWNSAMPLE_SCALES_IMG 0x913E +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_SCALE_IMG 0x913F +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DDOWNSAMPLEIMGPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint xscale, GLint yscale); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYERDOWNSAMPLEIMGPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer, GLint xscale, GLint yscale); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferTexture2DDownsampleIMG (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint xscale, GLint yscale); +GL_APICALL void GL_APIENTRY glFramebufferTextureLayerDownsampleIMG (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer, GLint xscale, GLint yscale); +#endif +#endif /* GL_IMG_framebuffer_downsample */ + +#ifndef GL_IMG_multisampled_render_to_texture +#define GL_IMG_multisampled_render_to_texture 1 +#define GL_RENDERBUFFER_SAMPLES_IMG 0x9133 +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_IMG 0x9134 +#define GL_MAX_SAMPLES_IMG 0x9135 +#define GL_TEXTURE_SAMPLES_IMG 0x9136 +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEIMGPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEIMGPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleIMG (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glFramebufferTexture2DMultisampleIMG (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); +#endif +#endif /* GL_IMG_multisampled_render_to_texture */ + +#ifndef GL_IMG_program_binary +#define GL_IMG_program_binary 1 +#define GL_SGX_PROGRAM_BINARY_IMG 0x9130 +#endif /* GL_IMG_program_binary */ + +#ifndef GL_IMG_read_format +#define GL_IMG_read_format 1 +#define GL_BGRA_IMG 0x80E1 +#define GL_UNSIGNED_SHORT_4_4_4_4_REV_IMG 0x8365 +#endif /* GL_IMG_read_format */ + +#ifndef GL_IMG_shader_binary +#define GL_IMG_shader_binary 1 +#define GL_SGX_BINARY_IMG 0x8C0A +#endif /* GL_IMG_shader_binary */ + +#ifndef GL_IMG_texture_compression_pvrtc +#define GL_IMG_texture_compression_pvrtc 1 +#define GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG 0x8C00 +#define GL_COMPRESSED_RGB_PVRTC_2BPPV1_IMG 0x8C01 +#define GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG 0x8C02 +#define GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG 0x8C03 +#endif /* GL_IMG_texture_compression_pvrtc */ + +#ifndef GL_IMG_texture_compression_pvrtc2 +#define GL_IMG_texture_compression_pvrtc2 1 +#define GL_COMPRESSED_RGBA_PVRTC_2BPPV2_IMG 0x9137 +#define GL_COMPRESSED_RGBA_PVRTC_4BPPV2_IMG 0x9138 +#endif /* GL_IMG_texture_compression_pvrtc2 */ + +#ifndef GL_IMG_texture_filter_cubic +#define GL_IMG_texture_filter_cubic 1 +#define GL_CUBIC_IMG 0x9139 +#define GL_CUBIC_MIPMAP_NEAREST_IMG 0x913A +#define GL_CUBIC_MIPMAP_LINEAR_IMG 0x913B +#endif /* GL_IMG_texture_filter_cubic */ + +#ifndef GL_INTEL_blackhole_render +#define GL_INTEL_blackhole_render 1 +#define GL_BLACKHOLE_RENDER_INTEL 0x83FC +#endif /* GL_INTEL_blackhole_render */ + +#ifndef GL_INTEL_conservative_rasterization +#define GL_INTEL_conservative_rasterization 1 +#define GL_CONSERVATIVE_RASTERIZATION_INTEL 0x83FE +#endif /* GL_INTEL_conservative_rasterization */ + +#ifndef GL_INTEL_framebuffer_CMAA +#define GL_INTEL_framebuffer_CMAA 1 +typedef void (GL_APIENTRYP PFNGLAPPLYFRAMEBUFFERATTACHMENTCMAAINTELPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glApplyFramebufferAttachmentCMAAINTEL (void); +#endif +#endif /* GL_INTEL_framebuffer_CMAA */ + +#ifndef GL_INTEL_performance_query +#define GL_INTEL_performance_query 1 +#define GL_PERFQUERY_SINGLE_CONTEXT_INTEL 0x00000000 +#define GL_PERFQUERY_GLOBAL_CONTEXT_INTEL 0x00000001 +#define GL_PERFQUERY_WAIT_INTEL 0x83FB +#define GL_PERFQUERY_FLUSH_INTEL 0x83FA +#define GL_PERFQUERY_DONOT_FLUSH_INTEL 0x83F9 +#define GL_PERFQUERY_COUNTER_EVENT_INTEL 0x94F0 +#define GL_PERFQUERY_COUNTER_DURATION_NORM_INTEL 0x94F1 +#define GL_PERFQUERY_COUNTER_DURATION_RAW_INTEL 0x94F2 +#define GL_PERFQUERY_COUNTER_THROUGHPUT_INTEL 0x94F3 +#define GL_PERFQUERY_COUNTER_RAW_INTEL 0x94F4 +#define GL_PERFQUERY_COUNTER_TIMESTAMP_INTEL 0x94F5 +#define GL_PERFQUERY_COUNTER_DATA_UINT32_INTEL 0x94F8 +#define GL_PERFQUERY_COUNTER_DATA_UINT64_INTEL 0x94F9 +#define GL_PERFQUERY_COUNTER_DATA_FLOAT_INTEL 0x94FA +#define GL_PERFQUERY_COUNTER_DATA_DOUBLE_INTEL 0x94FB +#define GL_PERFQUERY_COUNTER_DATA_BOOL32_INTEL 0x94FC +#define GL_PERFQUERY_QUERY_NAME_LENGTH_MAX_INTEL 0x94FD +#define GL_PERFQUERY_COUNTER_NAME_LENGTH_MAX_INTEL 0x94FE +#define GL_PERFQUERY_COUNTER_DESC_LENGTH_MAX_INTEL 0x94FF +#define GL_PERFQUERY_GPA_EXTENDED_COUNTERS_INTEL 0x9500 +typedef void (GL_APIENTRYP PFNGLBEGINPERFQUERYINTELPROC) (GLuint queryHandle); +typedef void (GL_APIENTRYP PFNGLCREATEPERFQUERYINTELPROC) (GLuint queryId, GLuint *queryHandle); +typedef void (GL_APIENTRYP PFNGLDELETEPERFQUERYINTELPROC) (GLuint queryHandle); +typedef void (GL_APIENTRYP PFNGLENDPERFQUERYINTELPROC) (GLuint queryHandle); +typedef void (GL_APIENTRYP PFNGLGETFIRSTPERFQUERYIDINTELPROC) (GLuint *queryId); +typedef void (GL_APIENTRYP PFNGLGETNEXTPERFQUERYIDINTELPROC) (GLuint queryId, GLuint *nextQueryId); +typedef void (GL_APIENTRYP PFNGLGETPERFCOUNTERINFOINTELPROC) (GLuint queryId, GLuint counterId, GLuint counterNameLength, GLchar *counterName, GLuint counterDescLength, GLchar *counterDesc, GLuint *counterOffset, GLuint *counterDataSize, GLuint *counterTypeEnum, GLuint *counterDataTypeEnum, GLuint64 *rawCounterMaxValue); +typedef void (GL_APIENTRYP PFNGLGETPERFQUERYDATAINTELPROC) (GLuint queryHandle, GLuint flags, GLsizei dataSize, void *data, GLuint *bytesWritten); +typedef void (GL_APIENTRYP PFNGLGETPERFQUERYIDBYNAMEINTELPROC) (GLchar *queryName, GLuint *queryId); +typedef void (GL_APIENTRYP PFNGLGETPERFQUERYINFOINTELPROC) (GLuint queryId, GLuint queryNameLength, GLchar *queryName, GLuint *dataSize, GLuint *noCounters, GLuint *noInstances, GLuint *capsMask); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBeginPerfQueryINTEL (GLuint queryHandle); +GL_APICALL void GL_APIENTRY glCreatePerfQueryINTEL (GLuint queryId, GLuint *queryHandle); +GL_APICALL void GL_APIENTRY glDeletePerfQueryINTEL (GLuint queryHandle); +GL_APICALL void GL_APIENTRY glEndPerfQueryINTEL (GLuint queryHandle); +GL_APICALL void GL_APIENTRY glGetFirstPerfQueryIdINTEL (GLuint *queryId); +GL_APICALL void GL_APIENTRY glGetNextPerfQueryIdINTEL (GLuint queryId, GLuint *nextQueryId); +GL_APICALL void GL_APIENTRY glGetPerfCounterInfoINTEL (GLuint queryId, GLuint counterId, GLuint counterNameLength, GLchar *counterName, GLuint counterDescLength, GLchar *counterDesc, GLuint *counterOffset, GLuint *counterDataSize, GLuint *counterTypeEnum, GLuint *counterDataTypeEnum, GLuint64 *rawCounterMaxValue); +GL_APICALL void GL_APIENTRY glGetPerfQueryDataINTEL (GLuint queryHandle, GLuint flags, GLsizei dataSize, void *data, GLuint *bytesWritten); +GL_APICALL void GL_APIENTRY glGetPerfQueryIdByNameINTEL (GLchar *queryName, GLuint *queryId); +GL_APICALL void GL_APIENTRY glGetPerfQueryInfoINTEL (GLuint queryId, GLuint queryNameLength, GLchar *queryName, GLuint *dataSize, GLuint *noCounters, GLuint *noInstances, GLuint *capsMask); +#endif +#endif /* GL_INTEL_performance_query */ + +#ifndef GL_MESA_framebuffer_flip_x +#define GL_MESA_framebuffer_flip_x 1 +#define GL_FRAMEBUFFER_FLIP_X_MESA 0x8BBC +#endif /* GL_MESA_framebuffer_flip_x */ + +#ifndef GL_MESA_framebuffer_flip_y +#define GL_MESA_framebuffer_flip_y 1 +#define GL_FRAMEBUFFER_FLIP_Y_MESA 0x8BBB +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERPARAMETERIMESAPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVMESAPROC) (GLenum target, GLenum pname, GLint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferParameteriMESA (GLenum target, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glGetFramebufferParameterivMESA (GLenum target, GLenum pname, GLint *params); +#endif +#endif /* GL_MESA_framebuffer_flip_y */ + +#ifndef GL_MESA_framebuffer_swap_xy +#define GL_MESA_framebuffer_swap_xy 1 +#define GL_FRAMEBUFFER_SWAP_XY_MESA 0x8BBD +#endif /* GL_MESA_framebuffer_swap_xy */ + +#ifndef GL_MESA_program_binary_formats +#define GL_MESA_program_binary_formats 1 +#define GL_PROGRAM_BINARY_FORMAT_MESA 0x875F +#endif /* GL_MESA_program_binary_formats */ + +#ifndef GL_MESA_shader_integer_functions +#define GL_MESA_shader_integer_functions 1 +#endif /* GL_MESA_shader_integer_functions */ + +#ifndef GL_NVX_blend_equation_advanced_multi_draw_buffers +#define GL_NVX_blend_equation_advanced_multi_draw_buffers 1 +#endif /* GL_NVX_blend_equation_advanced_multi_draw_buffers */ + +#ifndef GL_NV_bindless_texture +#define GL_NV_bindless_texture 1 +typedef GLuint64 (GL_APIENTRYP PFNGLGETTEXTUREHANDLENVPROC) (GLuint texture); +typedef GLuint64 (GL_APIENTRYP PFNGLGETTEXTURESAMPLERHANDLENVPROC) (GLuint texture, GLuint sampler); +typedef void (GL_APIENTRYP PFNGLMAKETEXTUREHANDLERESIDENTNVPROC) (GLuint64 handle); +typedef void (GL_APIENTRYP PFNGLMAKETEXTUREHANDLENONRESIDENTNVPROC) (GLuint64 handle); +typedef GLuint64 (GL_APIENTRYP PFNGLGETIMAGEHANDLENVPROC) (GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum format); +typedef void (GL_APIENTRYP PFNGLMAKEIMAGEHANDLERESIDENTNVPROC) (GLuint64 handle, GLenum access); +typedef void (GL_APIENTRYP PFNGLMAKEIMAGEHANDLENONRESIDENTNVPROC) (GLuint64 handle); +typedef void (GL_APIENTRYP PFNGLUNIFORMHANDLEUI64NVPROC) (GLint location, GLuint64 value); +typedef void (GL_APIENTRYP PFNGLUNIFORMHANDLEUI64VNVPROC) (GLint location, GLsizei count, const GLuint64 *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMHANDLEUI64NVPROC) (GLuint program, GLint location, GLuint64 value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMHANDLEUI64VNVPROC) (GLuint program, GLint location, GLsizei count, const GLuint64 *values); +typedef GLboolean (GL_APIENTRYP PFNGLISTEXTUREHANDLERESIDENTNVPROC) (GLuint64 handle); +typedef GLboolean (GL_APIENTRYP PFNGLISIMAGEHANDLERESIDENTNVPROC) (GLuint64 handle); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL GLuint64 GL_APIENTRY glGetTextureHandleNV (GLuint texture); +GL_APICALL GLuint64 GL_APIENTRY glGetTextureSamplerHandleNV (GLuint texture, GLuint sampler); +GL_APICALL void GL_APIENTRY glMakeTextureHandleResidentNV (GLuint64 handle); +GL_APICALL void GL_APIENTRY glMakeTextureHandleNonResidentNV (GLuint64 handle); +GL_APICALL GLuint64 GL_APIENTRY glGetImageHandleNV (GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum format); +GL_APICALL void GL_APIENTRY glMakeImageHandleResidentNV (GLuint64 handle, GLenum access); +GL_APICALL void GL_APIENTRY glMakeImageHandleNonResidentNV (GLuint64 handle); +GL_APICALL void GL_APIENTRY glUniformHandleui64NV (GLint location, GLuint64 value); +GL_APICALL void GL_APIENTRY glUniformHandleui64vNV (GLint location, GLsizei count, const GLuint64 *value); +GL_APICALL void GL_APIENTRY glProgramUniformHandleui64NV (GLuint program, GLint location, GLuint64 value); +GL_APICALL void GL_APIENTRY glProgramUniformHandleui64vNV (GLuint program, GLint location, GLsizei count, const GLuint64 *values); +GL_APICALL GLboolean GL_APIENTRY glIsTextureHandleResidentNV (GLuint64 handle); +GL_APICALL GLboolean GL_APIENTRY glIsImageHandleResidentNV (GLuint64 handle); +#endif +#endif /* GL_NV_bindless_texture */ + +#ifndef GL_NV_blend_equation_advanced +#define GL_NV_blend_equation_advanced 1 +#define GL_BLEND_OVERLAP_NV 0x9281 +#define GL_BLEND_PREMULTIPLIED_SRC_NV 0x9280 +#define GL_BLUE_NV 0x1905 +#define GL_COLORBURN_NV 0x929A +#define GL_COLORDODGE_NV 0x9299 +#define GL_CONJOINT_NV 0x9284 +#define GL_CONTRAST_NV 0x92A1 +#define GL_DARKEN_NV 0x9297 +#define GL_DIFFERENCE_NV 0x929E +#define GL_DISJOINT_NV 0x9283 +#define GL_DST_ATOP_NV 0x928F +#define GL_DST_IN_NV 0x928B +#define GL_DST_NV 0x9287 +#define GL_DST_OUT_NV 0x928D +#define GL_DST_OVER_NV 0x9289 +#define GL_EXCLUSION_NV 0x92A0 +#define GL_GREEN_NV 0x1904 +#define GL_HARDLIGHT_NV 0x929B +#define GL_HARDMIX_NV 0x92A9 +#define GL_HSL_COLOR_NV 0x92AF +#define GL_HSL_HUE_NV 0x92AD +#define GL_HSL_LUMINOSITY_NV 0x92B0 +#define GL_HSL_SATURATION_NV 0x92AE +#define GL_INVERT_OVG_NV 0x92B4 +#define GL_INVERT_RGB_NV 0x92A3 +#define GL_LIGHTEN_NV 0x9298 +#define GL_LINEARBURN_NV 0x92A5 +#define GL_LINEARDODGE_NV 0x92A4 +#define GL_LINEARLIGHT_NV 0x92A7 +#define GL_MINUS_CLAMPED_NV 0x92B3 +#define GL_MINUS_NV 0x929F +#define GL_MULTIPLY_NV 0x9294 +#define GL_OVERLAY_NV 0x9296 +#define GL_PINLIGHT_NV 0x92A8 +#define GL_PLUS_CLAMPED_ALPHA_NV 0x92B2 +#define GL_PLUS_CLAMPED_NV 0x92B1 +#define GL_PLUS_DARKER_NV 0x9292 +#define GL_PLUS_NV 0x9291 +#define GL_RED_NV 0x1903 +#define GL_SCREEN_NV 0x9295 +#define GL_SOFTLIGHT_NV 0x929C +#define GL_SRC_ATOP_NV 0x928E +#define GL_SRC_IN_NV 0x928A +#define GL_SRC_NV 0x9286 +#define GL_SRC_OUT_NV 0x928C +#define GL_SRC_OVER_NV 0x9288 +#define GL_UNCORRELATED_NV 0x9282 +#define GL_VIVIDLIGHT_NV 0x92A6 +#define GL_XOR_NV 0x1506 +typedef void (GL_APIENTRYP PFNGLBLENDPARAMETERINVPROC) (GLenum pname, GLint value); +typedef void (GL_APIENTRYP PFNGLBLENDBARRIERNVPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBlendParameteriNV (GLenum pname, GLint value); +GL_APICALL void GL_APIENTRY glBlendBarrierNV (void); +#endif +#endif /* GL_NV_blend_equation_advanced */ + +#ifndef GL_NV_blend_equation_advanced_coherent +#define GL_NV_blend_equation_advanced_coherent 1 +#define GL_BLEND_ADVANCED_COHERENT_NV 0x9285 +#endif /* GL_NV_blend_equation_advanced_coherent */ + +#ifndef GL_NV_blend_minmax_factor +#define GL_NV_blend_minmax_factor 1 +#define GL_FACTOR_MIN_AMD 0x901C +#define GL_FACTOR_MAX_AMD 0x901D +#endif /* GL_NV_blend_minmax_factor */ + +#ifndef GL_NV_clip_space_w_scaling +#define GL_NV_clip_space_w_scaling 1 +#define GL_VIEWPORT_POSITION_W_SCALE_NV 0x937C +#define GL_VIEWPORT_POSITION_W_SCALE_X_COEFF_NV 0x937D +#define GL_VIEWPORT_POSITION_W_SCALE_Y_COEFF_NV 0x937E +typedef void (GL_APIENTRYP PFNGLVIEWPORTPOSITIONWSCALENVPROC) (GLuint index, GLfloat xcoeff, GLfloat ycoeff); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glViewportPositionWScaleNV (GLuint index, GLfloat xcoeff, GLfloat ycoeff); +#endif +#endif /* GL_NV_clip_space_w_scaling */ + +#ifndef GL_NV_compute_shader_derivatives +#define GL_NV_compute_shader_derivatives 1 +#endif /* GL_NV_compute_shader_derivatives */ + +#ifndef GL_NV_conditional_render +#define GL_NV_conditional_render 1 +#define GL_QUERY_WAIT_NV 0x8E13 +#define GL_QUERY_NO_WAIT_NV 0x8E14 +#define GL_QUERY_BY_REGION_WAIT_NV 0x8E15 +#define GL_QUERY_BY_REGION_NO_WAIT_NV 0x8E16 +typedef void (GL_APIENTRYP PFNGLBEGINCONDITIONALRENDERNVPROC) (GLuint id, GLenum mode); +typedef void (GL_APIENTRYP PFNGLENDCONDITIONALRENDERNVPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBeginConditionalRenderNV (GLuint id, GLenum mode); +GL_APICALL void GL_APIENTRY glEndConditionalRenderNV (void); +#endif +#endif /* GL_NV_conditional_render */ + +#ifndef GL_NV_conservative_raster +#define GL_NV_conservative_raster 1 +#define GL_CONSERVATIVE_RASTERIZATION_NV 0x9346 +#define GL_SUBPIXEL_PRECISION_BIAS_X_BITS_NV 0x9347 +#define GL_SUBPIXEL_PRECISION_BIAS_Y_BITS_NV 0x9348 +#define GL_MAX_SUBPIXEL_PRECISION_BIAS_BITS_NV 0x9349 +typedef void (GL_APIENTRYP PFNGLSUBPIXELPRECISIONBIASNVPROC) (GLuint xbits, GLuint ybits); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glSubpixelPrecisionBiasNV (GLuint xbits, GLuint ybits); +#endif +#endif /* GL_NV_conservative_raster */ + +#ifndef GL_NV_conservative_raster_pre_snap +#define GL_NV_conservative_raster_pre_snap 1 +#define GL_CONSERVATIVE_RASTER_MODE_PRE_SNAP_NV 0x9550 +#endif /* GL_NV_conservative_raster_pre_snap */ + +#ifndef GL_NV_conservative_raster_pre_snap_triangles +#define GL_NV_conservative_raster_pre_snap_triangles 1 +#define GL_CONSERVATIVE_RASTER_MODE_NV 0x954D +#define GL_CONSERVATIVE_RASTER_MODE_POST_SNAP_NV 0x954E +#define GL_CONSERVATIVE_RASTER_MODE_PRE_SNAP_TRIANGLES_NV 0x954F +typedef void (GL_APIENTRYP PFNGLCONSERVATIVERASTERPARAMETERINVPROC) (GLenum pname, GLint param); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glConservativeRasterParameteriNV (GLenum pname, GLint param); +#endif +#endif /* GL_NV_conservative_raster_pre_snap_triangles */ + +#ifndef GL_NV_copy_buffer +#define GL_NV_copy_buffer 1 +#define GL_COPY_READ_BUFFER_NV 0x8F36 +#define GL_COPY_WRITE_BUFFER_NV 0x8F37 +typedef void (GL_APIENTRYP PFNGLCOPYBUFFERSUBDATANVPROC) (GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCopyBufferSubDataNV (GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +#endif +#endif /* GL_NV_copy_buffer */ + +#ifndef GL_NV_coverage_sample +#define GL_NV_coverage_sample 1 +#define GL_COVERAGE_COMPONENT_NV 0x8ED0 +#define GL_COVERAGE_COMPONENT4_NV 0x8ED1 +#define GL_COVERAGE_ATTACHMENT_NV 0x8ED2 +#define GL_COVERAGE_BUFFERS_NV 0x8ED3 +#define GL_COVERAGE_SAMPLES_NV 0x8ED4 +#define GL_COVERAGE_ALL_FRAGMENTS_NV 0x8ED5 +#define GL_COVERAGE_EDGE_FRAGMENTS_NV 0x8ED6 +#define GL_COVERAGE_AUTOMATIC_NV 0x8ED7 +#define GL_COVERAGE_BUFFER_BIT_NV 0x00008000 +typedef void (GL_APIENTRYP PFNGLCOVERAGEMASKNVPROC) (GLboolean mask); +typedef void (GL_APIENTRYP PFNGLCOVERAGEOPERATIONNVPROC) (GLenum operation); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCoverageMaskNV (GLboolean mask); +GL_APICALL void GL_APIENTRY glCoverageOperationNV (GLenum operation); +#endif +#endif /* GL_NV_coverage_sample */ + +#ifndef GL_NV_depth_nonlinear +#define GL_NV_depth_nonlinear 1 +#define GL_DEPTH_COMPONENT16_NONLINEAR_NV 0x8E2C +#endif /* GL_NV_depth_nonlinear */ + +#ifndef GL_NV_draw_buffers +#define GL_NV_draw_buffers 1 +#define GL_MAX_DRAW_BUFFERS_NV 0x8824 +#define GL_DRAW_BUFFER0_NV 0x8825 +#define GL_DRAW_BUFFER1_NV 0x8826 +#define GL_DRAW_BUFFER2_NV 0x8827 +#define GL_DRAW_BUFFER3_NV 0x8828 +#define GL_DRAW_BUFFER4_NV 0x8829 +#define GL_DRAW_BUFFER5_NV 0x882A +#define GL_DRAW_BUFFER6_NV 0x882B +#define GL_DRAW_BUFFER7_NV 0x882C +#define GL_DRAW_BUFFER8_NV 0x882D +#define GL_DRAW_BUFFER9_NV 0x882E +#define GL_DRAW_BUFFER10_NV 0x882F +#define GL_DRAW_BUFFER11_NV 0x8830 +#define GL_DRAW_BUFFER12_NV 0x8831 +#define GL_DRAW_BUFFER13_NV 0x8832 +#define GL_DRAW_BUFFER14_NV 0x8833 +#define GL_DRAW_BUFFER15_NV 0x8834 +#define GL_COLOR_ATTACHMENT0_NV 0x8CE0 +#define GL_COLOR_ATTACHMENT1_NV 0x8CE1 +#define GL_COLOR_ATTACHMENT2_NV 0x8CE2 +#define GL_COLOR_ATTACHMENT3_NV 0x8CE3 +#define GL_COLOR_ATTACHMENT4_NV 0x8CE4 +#define GL_COLOR_ATTACHMENT5_NV 0x8CE5 +#define GL_COLOR_ATTACHMENT6_NV 0x8CE6 +#define GL_COLOR_ATTACHMENT7_NV 0x8CE7 +#define GL_COLOR_ATTACHMENT8_NV 0x8CE8 +#define GL_COLOR_ATTACHMENT9_NV 0x8CE9 +#define GL_COLOR_ATTACHMENT10_NV 0x8CEA +#define GL_COLOR_ATTACHMENT11_NV 0x8CEB +#define GL_COLOR_ATTACHMENT12_NV 0x8CEC +#define GL_COLOR_ATTACHMENT13_NV 0x8CED +#define GL_COLOR_ATTACHMENT14_NV 0x8CEE +#define GL_COLOR_ATTACHMENT15_NV 0x8CEF +typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSNVPROC) (GLsizei n, const GLenum *bufs); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawBuffersNV (GLsizei n, const GLenum *bufs); +#endif +#endif /* GL_NV_draw_buffers */ + +#ifndef GL_NV_draw_instanced +#define GL_NV_draw_instanced 1 +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDNVPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDNVPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawArraysInstancedNV (GLenum mode, GLint first, GLsizei count, GLsizei primcount); +GL_APICALL void GL_APIENTRY glDrawElementsInstancedNV (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount); +#endif +#endif /* GL_NV_draw_instanced */ + +#ifndef GL_NV_draw_vulkan_image +#define GL_NV_draw_vulkan_image 1 +typedef void (GL_APIENTRY *GLVULKANPROCNV)(void); +typedef void (GL_APIENTRYP PFNGLDRAWVKIMAGENVPROC) (GLuint64 vkImage, GLuint sampler, GLfloat x0, GLfloat y0, GLfloat x1, GLfloat y1, GLfloat z, GLfloat s0, GLfloat t0, GLfloat s1, GLfloat t1); +typedef GLVULKANPROCNV (GL_APIENTRYP PFNGLGETVKPROCADDRNVPROC) (const GLchar *name); +typedef void (GL_APIENTRYP PFNGLWAITVKSEMAPHORENVPROC) (GLuint64 vkSemaphore); +typedef void (GL_APIENTRYP PFNGLSIGNALVKSEMAPHORENVPROC) (GLuint64 vkSemaphore); +typedef void (GL_APIENTRYP PFNGLSIGNALVKFENCENVPROC) (GLuint64 vkFence); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawVkImageNV (GLuint64 vkImage, GLuint sampler, GLfloat x0, GLfloat y0, GLfloat x1, GLfloat y1, GLfloat z, GLfloat s0, GLfloat t0, GLfloat s1, GLfloat t1); +GL_APICALL GLVULKANPROCNV GL_APIENTRY glGetVkProcAddrNV (const GLchar *name); +GL_APICALL void GL_APIENTRY glWaitVkSemaphoreNV (GLuint64 vkSemaphore); +GL_APICALL void GL_APIENTRY glSignalVkSemaphoreNV (GLuint64 vkSemaphore); +GL_APICALL void GL_APIENTRY glSignalVkFenceNV (GLuint64 vkFence); +#endif +#endif /* GL_NV_draw_vulkan_image */ + +#ifndef GL_NV_explicit_attrib_location +#define GL_NV_explicit_attrib_location 1 +#endif /* GL_NV_explicit_attrib_location */ + +#ifndef GL_NV_fbo_color_attachments +#define GL_NV_fbo_color_attachments 1 +#define GL_MAX_COLOR_ATTACHMENTS_NV 0x8CDF +#endif /* GL_NV_fbo_color_attachments */ + +#ifndef GL_NV_fence +#define GL_NV_fence 1 +#define GL_ALL_COMPLETED_NV 0x84F2 +#define GL_FENCE_STATUS_NV 0x84F3 +#define GL_FENCE_CONDITION_NV 0x84F4 +typedef void (GL_APIENTRYP PFNGLDELETEFENCESNVPROC) (GLsizei n, const GLuint *fences); +typedef void (GL_APIENTRYP PFNGLGENFENCESNVPROC) (GLsizei n, GLuint *fences); +typedef GLboolean (GL_APIENTRYP PFNGLISFENCENVPROC) (GLuint fence); +typedef GLboolean (GL_APIENTRYP PFNGLTESTFENCENVPROC) (GLuint fence); +typedef void (GL_APIENTRYP PFNGLGETFENCEIVNVPROC) (GLuint fence, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLFINISHFENCENVPROC) (GLuint fence); +typedef void (GL_APIENTRYP PFNGLSETFENCENVPROC) (GLuint fence, GLenum condition); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDeleteFencesNV (GLsizei n, const GLuint *fences); +GL_APICALL void GL_APIENTRY glGenFencesNV (GLsizei n, GLuint *fences); +GL_APICALL GLboolean GL_APIENTRY glIsFenceNV (GLuint fence); +GL_APICALL GLboolean GL_APIENTRY glTestFenceNV (GLuint fence); +GL_APICALL void GL_APIENTRY glGetFenceivNV (GLuint fence, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glFinishFenceNV (GLuint fence); +GL_APICALL void GL_APIENTRY glSetFenceNV (GLuint fence, GLenum condition); +#endif +#endif /* GL_NV_fence */ + +#ifndef GL_NV_fill_rectangle +#define GL_NV_fill_rectangle 1 +#define GL_FILL_RECTANGLE_NV 0x933C +#endif /* GL_NV_fill_rectangle */ + +#ifndef GL_NV_fragment_coverage_to_color +#define GL_NV_fragment_coverage_to_color 1 +#define GL_FRAGMENT_COVERAGE_TO_COLOR_NV 0x92DD +#define GL_FRAGMENT_COVERAGE_COLOR_NV 0x92DE +typedef void (GL_APIENTRYP PFNGLFRAGMENTCOVERAGECOLORNVPROC) (GLuint color); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFragmentCoverageColorNV (GLuint color); +#endif +#endif /* GL_NV_fragment_coverage_to_color */ + +#ifndef GL_NV_fragment_shader_barycentric +#define GL_NV_fragment_shader_barycentric 1 +#endif /* GL_NV_fragment_shader_barycentric */ + +#ifndef GL_NV_fragment_shader_interlock +#define GL_NV_fragment_shader_interlock 1 +#endif /* GL_NV_fragment_shader_interlock */ + +#ifndef GL_NV_framebuffer_blit +#define GL_NV_framebuffer_blit 1 +#define GL_READ_FRAMEBUFFER_NV 0x8CA8 +#define GL_DRAW_FRAMEBUFFER_NV 0x8CA9 +#define GL_DRAW_FRAMEBUFFER_BINDING_NV 0x8CA6 +#define GL_READ_FRAMEBUFFER_BINDING_NV 0x8CAA +typedef void (GL_APIENTRYP PFNGLBLITFRAMEBUFFERNVPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBlitFramebufferNV (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +#endif +#endif /* GL_NV_framebuffer_blit */ + +#ifndef GL_NV_framebuffer_mixed_samples +#define GL_NV_framebuffer_mixed_samples 1 +#define GL_COVERAGE_MODULATION_TABLE_NV 0x9331 +#define GL_COLOR_SAMPLES_NV 0x8E20 +#define GL_DEPTH_SAMPLES_NV 0x932D +#define GL_STENCIL_SAMPLES_NV 0x932E +#define GL_MIXED_DEPTH_SAMPLES_SUPPORTED_NV 0x932F +#define GL_MIXED_STENCIL_SAMPLES_SUPPORTED_NV 0x9330 +#define GL_COVERAGE_MODULATION_NV 0x9332 +#define GL_COVERAGE_MODULATION_TABLE_SIZE_NV 0x9333 +typedef void (GL_APIENTRYP PFNGLCOVERAGEMODULATIONTABLENVPROC) (GLsizei n, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLGETCOVERAGEMODULATIONTABLENVPROC) (GLsizei bufSize, GLfloat *v); +typedef void (GL_APIENTRYP PFNGLCOVERAGEMODULATIONNVPROC) (GLenum components); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCoverageModulationTableNV (GLsizei n, const GLfloat *v); +GL_APICALL void GL_APIENTRY glGetCoverageModulationTableNV (GLsizei bufSize, GLfloat *v); +GL_APICALL void GL_APIENTRY glCoverageModulationNV (GLenum components); +#endif +#endif /* GL_NV_framebuffer_mixed_samples */ + +#ifndef GL_NV_framebuffer_multisample +#define GL_NV_framebuffer_multisample 1 +#define GL_RENDERBUFFER_SAMPLES_NV 0x8CAB +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_NV 0x8D56 +#define GL_MAX_SAMPLES_NV 0x8D57 +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLENVPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleNV (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +#endif +#endif /* GL_NV_framebuffer_multisample */ + +#ifndef GL_NV_generate_mipmap_sRGB +#define GL_NV_generate_mipmap_sRGB 1 +#endif /* GL_NV_generate_mipmap_sRGB */ + +#ifndef GL_NV_geometry_shader_passthrough +#define GL_NV_geometry_shader_passthrough 1 +#endif /* GL_NV_geometry_shader_passthrough */ + +#ifndef GL_NV_gpu_shader5 +#define GL_NV_gpu_shader5 1 +typedef khronos_int64_t GLint64EXT; +typedef khronos_uint64_t GLuint64EXT; +#define GL_INT64_NV 0x140E +#define GL_UNSIGNED_INT64_NV 0x140F +#define GL_INT8_NV 0x8FE0 +#define GL_INT8_VEC2_NV 0x8FE1 +#define GL_INT8_VEC3_NV 0x8FE2 +#define GL_INT8_VEC4_NV 0x8FE3 +#define GL_INT16_NV 0x8FE4 +#define GL_INT16_VEC2_NV 0x8FE5 +#define GL_INT16_VEC3_NV 0x8FE6 +#define GL_INT16_VEC4_NV 0x8FE7 +#define GL_INT64_VEC2_NV 0x8FE9 +#define GL_INT64_VEC3_NV 0x8FEA +#define GL_INT64_VEC4_NV 0x8FEB +#define GL_UNSIGNED_INT8_NV 0x8FEC +#define GL_UNSIGNED_INT8_VEC2_NV 0x8FED +#define GL_UNSIGNED_INT8_VEC3_NV 0x8FEE +#define GL_UNSIGNED_INT8_VEC4_NV 0x8FEF +#define GL_UNSIGNED_INT16_NV 0x8FF0 +#define GL_UNSIGNED_INT16_VEC2_NV 0x8FF1 +#define GL_UNSIGNED_INT16_VEC3_NV 0x8FF2 +#define GL_UNSIGNED_INT16_VEC4_NV 0x8FF3 +#define GL_UNSIGNED_INT64_VEC2_NV 0x8FF5 +#define GL_UNSIGNED_INT64_VEC3_NV 0x8FF6 +#define GL_UNSIGNED_INT64_VEC4_NV 0x8FF7 +#define GL_FLOAT16_NV 0x8FF8 +#define GL_FLOAT16_VEC2_NV 0x8FF9 +#define GL_FLOAT16_VEC3_NV 0x8FFA +#define GL_FLOAT16_VEC4_NV 0x8FFB +#define GL_PATCHES 0x000E +typedef void (GL_APIENTRYP PFNGLUNIFORM1I64NVPROC) (GLint location, GLint64EXT x); +typedef void (GL_APIENTRYP PFNGLUNIFORM2I64NVPROC) (GLint location, GLint64EXT x, GLint64EXT y); +typedef void (GL_APIENTRYP PFNGLUNIFORM3I64NVPROC) (GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z); +typedef void (GL_APIENTRYP PFNGLUNIFORM4I64NVPROC) (GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w); +typedef void (GL_APIENTRYP PFNGLUNIFORM1I64VNVPROC) (GLint location, GLsizei count, const GLint64EXT *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2I64VNVPROC) (GLint location, GLsizei count, const GLint64EXT *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3I64VNVPROC) (GLint location, GLsizei count, const GLint64EXT *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4I64VNVPROC) (GLint location, GLsizei count, const GLint64EXT *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM1UI64NVPROC) (GLint location, GLuint64EXT x); +typedef void (GL_APIENTRYP PFNGLUNIFORM2UI64NVPROC) (GLint location, GLuint64EXT x, GLuint64EXT y); +typedef void (GL_APIENTRYP PFNGLUNIFORM3UI64NVPROC) (GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z); +typedef void (GL_APIENTRYP PFNGLUNIFORM4UI64NVPROC) (GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w); +typedef void (GL_APIENTRYP PFNGLUNIFORM1UI64VNVPROC) (GLint location, GLsizei count, const GLuint64EXT *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2UI64VNVPROC) (GLint location, GLsizei count, const GLuint64EXT *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3UI64VNVPROC) (GLint location, GLsizei count, const GLuint64EXT *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4UI64VNVPROC) (GLint location, GLsizei count, const GLuint64EXT *value); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMI64VNVPROC) (GLuint program, GLint location, GLint64EXT *params); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1I64NVPROC) (GLuint program, GLint location, GLint64EXT x); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2I64NVPROC) (GLuint program, GLint location, GLint64EXT x, GLint64EXT y); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3I64NVPROC) (GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4I64NVPROC) (GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1I64VNVPROC) (GLuint program, GLint location, GLsizei count, const GLint64EXT *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2I64VNVPROC) (GLuint program, GLint location, GLsizei count, const GLint64EXT *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3I64VNVPROC) (GLuint program, GLint location, GLsizei count, const GLint64EXT *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4I64VNVPROC) (GLuint program, GLint location, GLsizei count, const GLint64EXT *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UI64NVPROC) (GLuint program, GLint location, GLuint64EXT x); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UI64NVPROC) (GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UI64NVPROC) (GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UI64NVPROC) (GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UI64VNVPROC) (GLuint program, GLint location, GLsizei count, const GLuint64EXT *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UI64VNVPROC) (GLuint program, GLint location, GLsizei count, const GLuint64EXT *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UI64VNVPROC) (GLuint program, GLint location, GLsizei count, const GLuint64EXT *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UI64VNVPROC) (GLuint program, GLint location, GLsizei count, const GLuint64EXT *value); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glUniform1i64NV (GLint location, GLint64EXT x); +GL_APICALL void GL_APIENTRY glUniform2i64NV (GLint location, GLint64EXT x, GLint64EXT y); +GL_APICALL void GL_APIENTRY glUniform3i64NV (GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z); +GL_APICALL void GL_APIENTRY glUniform4i64NV (GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w); +GL_APICALL void GL_APIENTRY glUniform1i64vNV (GLint location, GLsizei count, const GLint64EXT *value); +GL_APICALL void GL_APIENTRY glUniform2i64vNV (GLint location, GLsizei count, const GLint64EXT *value); +GL_APICALL void GL_APIENTRY glUniform3i64vNV (GLint location, GLsizei count, const GLint64EXT *value); +GL_APICALL void GL_APIENTRY glUniform4i64vNV (GLint location, GLsizei count, const GLint64EXT *value); +GL_APICALL void GL_APIENTRY glUniform1ui64NV (GLint location, GLuint64EXT x); +GL_APICALL void GL_APIENTRY glUniform2ui64NV (GLint location, GLuint64EXT x, GLuint64EXT y); +GL_APICALL void GL_APIENTRY glUniform3ui64NV (GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z); +GL_APICALL void GL_APIENTRY glUniform4ui64NV (GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w); +GL_APICALL void GL_APIENTRY glUniform1ui64vNV (GLint location, GLsizei count, const GLuint64EXT *value); +GL_APICALL void GL_APIENTRY glUniform2ui64vNV (GLint location, GLsizei count, const GLuint64EXT *value); +GL_APICALL void GL_APIENTRY glUniform3ui64vNV (GLint location, GLsizei count, const GLuint64EXT *value); +GL_APICALL void GL_APIENTRY glUniform4ui64vNV (GLint location, GLsizei count, const GLuint64EXT *value); +GL_APICALL void GL_APIENTRY glGetUniformi64vNV (GLuint program, GLint location, GLint64EXT *params); +GL_APICALL void GL_APIENTRY glProgramUniform1i64NV (GLuint program, GLint location, GLint64EXT x); +GL_APICALL void GL_APIENTRY glProgramUniform2i64NV (GLuint program, GLint location, GLint64EXT x, GLint64EXT y); +GL_APICALL void GL_APIENTRY glProgramUniform3i64NV (GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z); +GL_APICALL void GL_APIENTRY glProgramUniform4i64NV (GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w); +GL_APICALL void GL_APIENTRY glProgramUniform1i64vNV (GLuint program, GLint location, GLsizei count, const GLint64EXT *value); +GL_APICALL void GL_APIENTRY glProgramUniform2i64vNV (GLuint program, GLint location, GLsizei count, const GLint64EXT *value); +GL_APICALL void GL_APIENTRY glProgramUniform3i64vNV (GLuint program, GLint location, GLsizei count, const GLint64EXT *value); +GL_APICALL void GL_APIENTRY glProgramUniform4i64vNV (GLuint program, GLint location, GLsizei count, const GLint64EXT *value); +GL_APICALL void GL_APIENTRY glProgramUniform1ui64NV (GLuint program, GLint location, GLuint64EXT x); +GL_APICALL void GL_APIENTRY glProgramUniform2ui64NV (GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y); +GL_APICALL void GL_APIENTRY glProgramUniform3ui64NV (GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z); +GL_APICALL void GL_APIENTRY glProgramUniform4ui64NV (GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w); +GL_APICALL void GL_APIENTRY glProgramUniform1ui64vNV (GLuint program, GLint location, GLsizei count, const GLuint64EXT *value); +GL_APICALL void GL_APIENTRY glProgramUniform2ui64vNV (GLuint program, GLint location, GLsizei count, const GLuint64EXT *value); +GL_APICALL void GL_APIENTRY glProgramUniform3ui64vNV (GLuint program, GLint location, GLsizei count, const GLuint64EXT *value); +GL_APICALL void GL_APIENTRY glProgramUniform4ui64vNV (GLuint program, GLint location, GLsizei count, const GLuint64EXT *value); +#endif +#endif /* GL_NV_gpu_shader5 */ + +#ifndef GL_NV_image_formats +#define GL_NV_image_formats 1 +#endif /* GL_NV_image_formats */ + +#ifndef GL_NV_instanced_arrays +#define GL_NV_instanced_arrays 1 +#define GL_VERTEX_ATTRIB_ARRAY_DIVISOR_NV 0x88FE +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISORNVPROC) (GLuint index, GLuint divisor); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glVertexAttribDivisorNV (GLuint index, GLuint divisor); +#endif +#endif /* GL_NV_instanced_arrays */ + +#ifndef GL_NV_internalformat_sample_query +#define GL_NV_internalformat_sample_query 1 +#define GL_TEXTURE_2D_MULTISAMPLE 0x9100 +#define GL_TEXTURE_2D_MULTISAMPLE_ARRAY 0x9102 +#define GL_MULTISAMPLES_NV 0x9371 +#define GL_SUPERSAMPLE_SCALE_X_NV 0x9372 +#define GL_SUPERSAMPLE_SCALE_Y_NV 0x9373 +#define GL_CONFORMANT_NV 0x9374 +typedef void (GL_APIENTRYP PFNGLGETINTERNALFORMATSAMPLEIVNVPROC) (GLenum target, GLenum internalformat, GLsizei samples, GLenum pname, GLsizei count, GLint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetInternalformatSampleivNV (GLenum target, GLenum internalformat, GLsizei samples, GLenum pname, GLsizei count, GLint *params); +#endif +#endif /* GL_NV_internalformat_sample_query */ + +#ifndef GL_NV_memory_attachment +#define GL_NV_memory_attachment 1 +#define GL_ATTACHED_MEMORY_OBJECT_NV 0x95A4 +#define GL_ATTACHED_MEMORY_OFFSET_NV 0x95A5 +#define GL_MEMORY_ATTACHABLE_ALIGNMENT_NV 0x95A6 +#define GL_MEMORY_ATTACHABLE_SIZE_NV 0x95A7 +#define GL_MEMORY_ATTACHABLE_NV 0x95A8 +#define GL_DETACHED_MEMORY_INCARNATION_NV 0x95A9 +#define GL_DETACHED_TEXTURES_NV 0x95AA +#define GL_DETACHED_BUFFERS_NV 0x95AB +#define GL_MAX_DETACHED_TEXTURES_NV 0x95AC +#define GL_MAX_DETACHED_BUFFERS_NV 0x95AD +typedef void (GL_APIENTRYP PFNGLGETMEMORYOBJECTDETACHEDRESOURCESUIVNVPROC) (GLuint memory, GLenum pname, GLint first, GLsizei count, GLuint *params); +typedef void (GL_APIENTRYP PFNGLRESETMEMORYOBJECTPARAMETERNVPROC) (GLuint memory, GLenum pname); +typedef void (GL_APIENTRYP PFNGLTEXATTACHMEMORYNVPROC) (GLenum target, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLBUFFERATTACHMEMORYNVPROC) (GLenum target, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLTEXTUREATTACHMEMORYNVPROC) (GLuint texture, GLuint memory, GLuint64 offset); +typedef void (GL_APIENTRYP PFNGLNAMEDBUFFERATTACHMEMORYNVPROC) (GLuint buffer, GLuint memory, GLuint64 offset); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetMemoryObjectDetachedResourcesuivNV (GLuint memory, GLenum pname, GLint first, GLsizei count, GLuint *params); +GL_APICALL void GL_APIENTRY glResetMemoryObjectParameterNV (GLuint memory, GLenum pname); +GL_APICALL void GL_APIENTRY glTexAttachMemoryNV (GLenum target, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glBufferAttachMemoryNV (GLenum target, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glTextureAttachMemoryNV (GLuint texture, GLuint memory, GLuint64 offset); +GL_APICALL void GL_APIENTRY glNamedBufferAttachMemoryNV (GLuint buffer, GLuint memory, GLuint64 offset); +#endif +#endif /* GL_NV_memory_attachment */ + +#ifndef GL_NV_memory_object_sparse +#define GL_NV_memory_object_sparse 1 +typedef void (GL_APIENTRYP PFNGLBUFFERPAGECOMMITMENTMEMNVPROC) (GLenum target, GLintptr offset, GLsizeiptr size, GLuint memory, GLuint64 memOffset, GLboolean commit); +typedef void (GL_APIENTRYP PFNGLTEXPAGECOMMITMENTMEMNVPROC) (GLenum target, GLint layer, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLboolean commit); +typedef void (GL_APIENTRYP PFNGLNAMEDBUFFERPAGECOMMITMENTMEMNVPROC) (GLuint buffer, GLintptr offset, GLsizeiptr size, GLuint memory, GLuint64 memOffset, GLboolean commit); +typedef void (GL_APIENTRYP PFNGLTEXTUREPAGECOMMITMENTMEMNVPROC) (GLuint texture, GLint layer, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLboolean commit); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBufferPageCommitmentMemNV (GLenum target, GLintptr offset, GLsizeiptr size, GLuint memory, GLuint64 memOffset, GLboolean commit); +GL_APICALL void GL_APIENTRY glTexPageCommitmentMemNV (GLenum target, GLint layer, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLboolean commit); +GL_APICALL void GL_APIENTRY glNamedBufferPageCommitmentMemNV (GLuint buffer, GLintptr offset, GLsizeiptr size, GLuint memory, GLuint64 memOffset, GLboolean commit); +GL_APICALL void GL_APIENTRY glTexturePageCommitmentMemNV (GLuint texture, GLint layer, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLboolean commit); +#endif +#endif /* GL_NV_memory_object_sparse */ + +#ifndef GL_NV_mesh_shader +#define GL_NV_mesh_shader 1 +#define GL_MESH_SHADER_NV 0x9559 +#define GL_TASK_SHADER_NV 0x955A +#define GL_MAX_MESH_UNIFORM_BLOCKS_NV 0x8E60 +#define GL_MAX_MESH_TEXTURE_IMAGE_UNITS_NV 0x8E61 +#define GL_MAX_MESH_IMAGE_UNIFORMS_NV 0x8E62 +#define GL_MAX_MESH_UNIFORM_COMPONENTS_NV 0x8E63 +#define GL_MAX_MESH_ATOMIC_COUNTER_BUFFERS_NV 0x8E64 +#define GL_MAX_MESH_ATOMIC_COUNTERS_NV 0x8E65 +#define GL_MAX_MESH_SHADER_STORAGE_BLOCKS_NV 0x8E66 +#define GL_MAX_COMBINED_MESH_UNIFORM_COMPONENTS_NV 0x8E67 +#define GL_MAX_TASK_UNIFORM_BLOCKS_NV 0x8E68 +#define GL_MAX_TASK_TEXTURE_IMAGE_UNITS_NV 0x8E69 +#define GL_MAX_TASK_IMAGE_UNIFORMS_NV 0x8E6A +#define GL_MAX_TASK_UNIFORM_COMPONENTS_NV 0x8E6B +#define GL_MAX_TASK_ATOMIC_COUNTER_BUFFERS_NV 0x8E6C +#define GL_MAX_TASK_ATOMIC_COUNTERS_NV 0x8E6D +#define GL_MAX_TASK_SHADER_STORAGE_BLOCKS_NV 0x8E6E +#define GL_MAX_COMBINED_TASK_UNIFORM_COMPONENTS_NV 0x8E6F +#define GL_MAX_MESH_WORK_GROUP_INVOCATIONS_NV 0x95A2 +#define GL_MAX_TASK_WORK_GROUP_INVOCATIONS_NV 0x95A3 +#define GL_MAX_MESH_TOTAL_MEMORY_SIZE_NV 0x9536 +#define GL_MAX_TASK_TOTAL_MEMORY_SIZE_NV 0x9537 +#define GL_MAX_MESH_OUTPUT_VERTICES_NV 0x9538 +#define GL_MAX_MESH_OUTPUT_PRIMITIVES_NV 0x9539 +#define GL_MAX_TASK_OUTPUT_COUNT_NV 0x953A +#define GL_MAX_DRAW_MESH_TASKS_COUNT_NV 0x953D +#define GL_MAX_MESH_VIEWS_NV 0x9557 +#define GL_MESH_OUTPUT_PER_VERTEX_GRANULARITY_NV 0x92DF +#define GL_MESH_OUTPUT_PER_PRIMITIVE_GRANULARITY_NV 0x9543 +#define GL_MAX_MESH_WORK_GROUP_SIZE_NV 0x953B +#define GL_MAX_TASK_WORK_GROUP_SIZE_NV 0x953C +#define GL_MESH_WORK_GROUP_SIZE_NV 0x953E +#define GL_TASK_WORK_GROUP_SIZE_NV 0x953F +#define GL_MESH_VERTICES_OUT_NV 0x9579 +#define GL_MESH_PRIMITIVES_OUT_NV 0x957A +#define GL_MESH_OUTPUT_TYPE_NV 0x957B +#define GL_UNIFORM_BLOCK_REFERENCED_BY_MESH_SHADER_NV 0x959C +#define GL_UNIFORM_BLOCK_REFERENCED_BY_TASK_SHADER_NV 0x959D +#define GL_REFERENCED_BY_MESH_SHADER_NV 0x95A0 +#define GL_REFERENCED_BY_TASK_SHADER_NV 0x95A1 +#define GL_MESH_SHADER_BIT_NV 0x00000040 +#define GL_TASK_SHADER_BIT_NV 0x00000080 +#define GL_MESH_SUBROUTINE_NV 0x957C +#define GL_TASK_SUBROUTINE_NV 0x957D +#define GL_MESH_SUBROUTINE_UNIFORM_NV 0x957E +#define GL_TASK_SUBROUTINE_UNIFORM_NV 0x957F +#define GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_MESH_SHADER_NV 0x959E +#define GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TASK_SHADER_NV 0x959F +typedef void (GL_APIENTRYP PFNGLDRAWMESHTASKSNVPROC) (GLuint first, GLuint count); +typedef void (GL_APIENTRYP PFNGLDRAWMESHTASKSINDIRECTNVPROC) (GLintptr indirect); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWMESHTASKSINDIRECTNVPROC) (GLintptr indirect, GLsizei drawcount, GLsizei stride); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWMESHTASKSINDIRECTCOUNTNVPROC) (GLintptr indirect, GLintptr drawcount, GLsizei maxdrawcount, GLsizei stride); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawMeshTasksNV (GLuint first, GLuint count); +GL_APICALL void GL_APIENTRY glDrawMeshTasksIndirectNV (GLintptr indirect); +GL_APICALL void GL_APIENTRY glMultiDrawMeshTasksIndirectNV (GLintptr indirect, GLsizei drawcount, GLsizei stride); +GL_APICALL void GL_APIENTRY glMultiDrawMeshTasksIndirectCountNV (GLintptr indirect, GLintptr drawcount, GLsizei maxdrawcount, GLsizei stride); +#endif +#endif /* GL_NV_mesh_shader */ + +#ifndef GL_NV_non_square_matrices +#define GL_NV_non_square_matrices 1 +#define GL_FLOAT_MAT2x3_NV 0x8B65 +#define GL_FLOAT_MAT2x4_NV 0x8B66 +#define GL_FLOAT_MAT3x2_NV 0x8B67 +#define GL_FLOAT_MAT3x4_NV 0x8B68 +#define GL_FLOAT_MAT4x2_NV 0x8B69 +#define GL_FLOAT_MAT4x3_NV 0x8B6A +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2X3FVNVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3X2FVNVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2X4FVNVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4X2FVNVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3X4FVNVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4X3FVNVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glUniformMatrix2x3fvNV (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3x2fvNV (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix2x4fvNV (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4x2fvNV (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3x4fvNV (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4x3fvNV (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +#endif +#endif /* GL_NV_non_square_matrices */ + +#ifndef GL_NV_path_rendering +#define GL_NV_path_rendering 1 +typedef double GLdouble; +#define GL_PATH_FORMAT_SVG_NV 0x9070 +#define GL_PATH_FORMAT_PS_NV 0x9071 +#define GL_STANDARD_FONT_NAME_NV 0x9072 +#define GL_SYSTEM_FONT_NAME_NV 0x9073 +#define GL_FILE_NAME_NV 0x9074 +#define GL_PATH_STROKE_WIDTH_NV 0x9075 +#define GL_PATH_END_CAPS_NV 0x9076 +#define GL_PATH_INITIAL_END_CAP_NV 0x9077 +#define GL_PATH_TERMINAL_END_CAP_NV 0x9078 +#define GL_PATH_JOIN_STYLE_NV 0x9079 +#define GL_PATH_MITER_LIMIT_NV 0x907A +#define GL_PATH_DASH_CAPS_NV 0x907B +#define GL_PATH_INITIAL_DASH_CAP_NV 0x907C +#define GL_PATH_TERMINAL_DASH_CAP_NV 0x907D +#define GL_PATH_DASH_OFFSET_NV 0x907E +#define GL_PATH_CLIENT_LENGTH_NV 0x907F +#define GL_PATH_FILL_MODE_NV 0x9080 +#define GL_PATH_FILL_MASK_NV 0x9081 +#define GL_PATH_FILL_COVER_MODE_NV 0x9082 +#define GL_PATH_STROKE_COVER_MODE_NV 0x9083 +#define GL_PATH_STROKE_MASK_NV 0x9084 +#define GL_COUNT_UP_NV 0x9088 +#define GL_COUNT_DOWN_NV 0x9089 +#define GL_PATH_OBJECT_BOUNDING_BOX_NV 0x908A +#define GL_CONVEX_HULL_NV 0x908B +#define GL_BOUNDING_BOX_NV 0x908D +#define GL_TRANSLATE_X_NV 0x908E +#define GL_TRANSLATE_Y_NV 0x908F +#define GL_TRANSLATE_2D_NV 0x9090 +#define GL_TRANSLATE_3D_NV 0x9091 +#define GL_AFFINE_2D_NV 0x9092 +#define GL_AFFINE_3D_NV 0x9094 +#define GL_TRANSPOSE_AFFINE_2D_NV 0x9096 +#define GL_TRANSPOSE_AFFINE_3D_NV 0x9098 +#define GL_UTF8_NV 0x909A +#define GL_UTF16_NV 0x909B +#define GL_BOUNDING_BOX_OF_BOUNDING_BOXES_NV 0x909C +#define GL_PATH_COMMAND_COUNT_NV 0x909D +#define GL_PATH_COORD_COUNT_NV 0x909E +#define GL_PATH_DASH_ARRAY_COUNT_NV 0x909F +#define GL_PATH_COMPUTED_LENGTH_NV 0x90A0 +#define GL_PATH_FILL_BOUNDING_BOX_NV 0x90A1 +#define GL_PATH_STROKE_BOUNDING_BOX_NV 0x90A2 +#define GL_SQUARE_NV 0x90A3 +#define GL_ROUND_NV 0x90A4 +#define GL_TRIANGULAR_NV 0x90A5 +#define GL_BEVEL_NV 0x90A6 +#define GL_MITER_REVERT_NV 0x90A7 +#define GL_MITER_TRUNCATE_NV 0x90A8 +#define GL_SKIP_MISSING_GLYPH_NV 0x90A9 +#define GL_USE_MISSING_GLYPH_NV 0x90AA +#define GL_PATH_ERROR_POSITION_NV 0x90AB +#define GL_ACCUM_ADJACENT_PAIRS_NV 0x90AD +#define GL_ADJACENT_PAIRS_NV 0x90AE +#define GL_FIRST_TO_REST_NV 0x90AF +#define GL_PATH_GEN_MODE_NV 0x90B0 +#define GL_PATH_GEN_COEFF_NV 0x90B1 +#define GL_PATH_GEN_COMPONENTS_NV 0x90B3 +#define GL_PATH_STENCIL_FUNC_NV 0x90B7 +#define GL_PATH_STENCIL_REF_NV 0x90B8 +#define GL_PATH_STENCIL_VALUE_MASK_NV 0x90B9 +#define GL_PATH_STENCIL_DEPTH_OFFSET_FACTOR_NV 0x90BD +#define GL_PATH_STENCIL_DEPTH_OFFSET_UNITS_NV 0x90BE +#define GL_PATH_COVER_DEPTH_FUNC_NV 0x90BF +#define GL_PATH_DASH_OFFSET_RESET_NV 0x90B4 +#define GL_MOVE_TO_RESETS_NV 0x90B5 +#define GL_MOVE_TO_CONTINUES_NV 0x90B6 +#define GL_CLOSE_PATH_NV 0x00 +#define GL_MOVE_TO_NV 0x02 +#define GL_RELATIVE_MOVE_TO_NV 0x03 +#define GL_LINE_TO_NV 0x04 +#define GL_RELATIVE_LINE_TO_NV 0x05 +#define GL_HORIZONTAL_LINE_TO_NV 0x06 +#define GL_RELATIVE_HORIZONTAL_LINE_TO_NV 0x07 +#define GL_VERTICAL_LINE_TO_NV 0x08 +#define GL_RELATIVE_VERTICAL_LINE_TO_NV 0x09 +#define GL_QUADRATIC_CURVE_TO_NV 0x0A +#define GL_RELATIVE_QUADRATIC_CURVE_TO_NV 0x0B +#define GL_CUBIC_CURVE_TO_NV 0x0C +#define GL_RELATIVE_CUBIC_CURVE_TO_NV 0x0D +#define GL_SMOOTH_QUADRATIC_CURVE_TO_NV 0x0E +#define GL_RELATIVE_SMOOTH_QUADRATIC_CURVE_TO_NV 0x0F +#define GL_SMOOTH_CUBIC_CURVE_TO_NV 0x10 +#define GL_RELATIVE_SMOOTH_CUBIC_CURVE_TO_NV 0x11 +#define GL_SMALL_CCW_ARC_TO_NV 0x12 +#define GL_RELATIVE_SMALL_CCW_ARC_TO_NV 0x13 +#define GL_SMALL_CW_ARC_TO_NV 0x14 +#define GL_RELATIVE_SMALL_CW_ARC_TO_NV 0x15 +#define GL_LARGE_CCW_ARC_TO_NV 0x16 +#define GL_RELATIVE_LARGE_CCW_ARC_TO_NV 0x17 +#define GL_LARGE_CW_ARC_TO_NV 0x18 +#define GL_RELATIVE_LARGE_CW_ARC_TO_NV 0x19 +#define GL_RESTART_PATH_NV 0xF0 +#define GL_DUP_FIRST_CUBIC_CURVE_TO_NV 0xF2 +#define GL_DUP_LAST_CUBIC_CURVE_TO_NV 0xF4 +#define GL_RECT_NV 0xF6 +#define GL_CIRCULAR_CCW_ARC_TO_NV 0xF8 +#define GL_CIRCULAR_CW_ARC_TO_NV 0xFA +#define GL_CIRCULAR_TANGENT_ARC_TO_NV 0xFC +#define GL_ARC_TO_NV 0xFE +#define GL_RELATIVE_ARC_TO_NV 0xFF +#define GL_BOLD_BIT_NV 0x01 +#define GL_ITALIC_BIT_NV 0x02 +#define GL_GLYPH_WIDTH_BIT_NV 0x01 +#define GL_GLYPH_HEIGHT_BIT_NV 0x02 +#define GL_GLYPH_HORIZONTAL_BEARING_X_BIT_NV 0x04 +#define GL_GLYPH_HORIZONTAL_BEARING_Y_BIT_NV 0x08 +#define GL_GLYPH_HORIZONTAL_BEARING_ADVANCE_BIT_NV 0x10 +#define GL_GLYPH_VERTICAL_BEARING_X_BIT_NV 0x20 +#define GL_GLYPH_VERTICAL_BEARING_Y_BIT_NV 0x40 +#define GL_GLYPH_VERTICAL_BEARING_ADVANCE_BIT_NV 0x80 +#define GL_GLYPH_HAS_KERNING_BIT_NV 0x100 +#define GL_FONT_X_MIN_BOUNDS_BIT_NV 0x00010000 +#define GL_FONT_Y_MIN_BOUNDS_BIT_NV 0x00020000 +#define GL_FONT_X_MAX_BOUNDS_BIT_NV 0x00040000 +#define GL_FONT_Y_MAX_BOUNDS_BIT_NV 0x00080000 +#define GL_FONT_UNITS_PER_EM_BIT_NV 0x00100000 +#define GL_FONT_ASCENDER_BIT_NV 0x00200000 +#define GL_FONT_DESCENDER_BIT_NV 0x00400000 +#define GL_FONT_HEIGHT_BIT_NV 0x00800000 +#define GL_FONT_MAX_ADVANCE_WIDTH_BIT_NV 0x01000000 +#define GL_FONT_MAX_ADVANCE_HEIGHT_BIT_NV 0x02000000 +#define GL_FONT_UNDERLINE_POSITION_BIT_NV 0x04000000 +#define GL_FONT_UNDERLINE_THICKNESS_BIT_NV 0x08000000 +#define GL_FONT_HAS_KERNING_BIT_NV 0x10000000 +#define GL_ROUNDED_RECT_NV 0xE8 +#define GL_RELATIVE_ROUNDED_RECT_NV 0xE9 +#define GL_ROUNDED_RECT2_NV 0xEA +#define GL_RELATIVE_ROUNDED_RECT2_NV 0xEB +#define GL_ROUNDED_RECT4_NV 0xEC +#define GL_RELATIVE_ROUNDED_RECT4_NV 0xED +#define GL_ROUNDED_RECT8_NV 0xEE +#define GL_RELATIVE_ROUNDED_RECT8_NV 0xEF +#define GL_RELATIVE_RECT_NV 0xF7 +#define GL_FONT_GLYPHS_AVAILABLE_NV 0x9368 +#define GL_FONT_TARGET_UNAVAILABLE_NV 0x9369 +#define GL_FONT_UNAVAILABLE_NV 0x936A +#define GL_FONT_UNINTELLIGIBLE_NV 0x936B +#define GL_CONIC_CURVE_TO_NV 0x1A +#define GL_RELATIVE_CONIC_CURVE_TO_NV 0x1B +#define GL_FONT_NUM_GLYPH_INDICES_BIT_NV 0x20000000 +#define GL_STANDARD_FONT_FORMAT_NV 0x936C +#define GL_PATH_PROJECTION_NV 0x1701 +#define GL_PATH_MODELVIEW_NV 0x1700 +#define GL_PATH_MODELVIEW_STACK_DEPTH_NV 0x0BA3 +#define GL_PATH_MODELVIEW_MATRIX_NV 0x0BA6 +#define GL_PATH_MAX_MODELVIEW_STACK_DEPTH_NV 0x0D36 +#define GL_PATH_TRANSPOSE_MODELVIEW_MATRIX_NV 0x84E3 +#define GL_PATH_PROJECTION_STACK_DEPTH_NV 0x0BA4 +#define GL_PATH_PROJECTION_MATRIX_NV 0x0BA7 +#define GL_PATH_MAX_PROJECTION_STACK_DEPTH_NV 0x0D38 +#define GL_PATH_TRANSPOSE_PROJECTION_MATRIX_NV 0x84E4 +#define GL_FRAGMENT_INPUT_NV 0x936D +typedef GLuint (GL_APIENTRYP PFNGLGENPATHSNVPROC) (GLsizei range); +typedef void (GL_APIENTRYP PFNGLDELETEPATHSNVPROC) (GLuint path, GLsizei range); +typedef GLboolean (GL_APIENTRYP PFNGLISPATHNVPROC) (GLuint path); +typedef void (GL_APIENTRYP PFNGLPATHCOMMANDSNVPROC) (GLuint path, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const void *coords); +typedef void (GL_APIENTRYP PFNGLPATHCOORDSNVPROC) (GLuint path, GLsizei numCoords, GLenum coordType, const void *coords); +typedef void (GL_APIENTRYP PFNGLPATHSUBCOMMANDSNVPROC) (GLuint path, GLsizei commandStart, GLsizei commandsToDelete, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const void *coords); +typedef void (GL_APIENTRYP PFNGLPATHSUBCOORDSNVPROC) (GLuint path, GLsizei coordStart, GLsizei numCoords, GLenum coordType, const void *coords); +typedef void (GL_APIENTRYP PFNGLPATHSTRINGNVPROC) (GLuint path, GLenum format, GLsizei length, const void *pathString); +typedef void (GL_APIENTRYP PFNGLPATHGLYPHSNVPROC) (GLuint firstPathName, GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLsizei numGlyphs, GLenum type, const void *charcodes, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale); +typedef void (GL_APIENTRYP PFNGLPATHGLYPHRANGENVPROC) (GLuint firstPathName, GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLuint firstGlyph, GLsizei numGlyphs, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale); +typedef void (GL_APIENTRYP PFNGLWEIGHTPATHSNVPROC) (GLuint resultPath, GLsizei numPaths, const GLuint *paths, const GLfloat *weights); +typedef void (GL_APIENTRYP PFNGLCOPYPATHNVPROC) (GLuint resultPath, GLuint srcPath); +typedef void (GL_APIENTRYP PFNGLINTERPOLATEPATHSNVPROC) (GLuint resultPath, GLuint pathA, GLuint pathB, GLfloat weight); +typedef void (GL_APIENTRYP PFNGLTRANSFORMPATHNVPROC) (GLuint resultPath, GLuint srcPath, GLenum transformType, const GLfloat *transformValues); +typedef void (GL_APIENTRYP PFNGLPATHPARAMETERIVNVPROC) (GLuint path, GLenum pname, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPATHPARAMETERINVPROC) (GLuint path, GLenum pname, GLint value); +typedef void (GL_APIENTRYP PFNGLPATHPARAMETERFVNVPROC) (GLuint path, GLenum pname, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPATHPARAMETERFNVPROC) (GLuint path, GLenum pname, GLfloat value); +typedef void (GL_APIENTRYP PFNGLPATHDASHARRAYNVPROC) (GLuint path, GLsizei dashCount, const GLfloat *dashArray); +typedef void (GL_APIENTRYP PFNGLPATHSTENCILFUNCNVPROC) (GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLPATHSTENCILDEPTHOFFSETNVPROC) (GLfloat factor, GLfloat units); +typedef void (GL_APIENTRYP PFNGLSTENCILFILLPATHNVPROC) (GLuint path, GLenum fillMode, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILSTROKEPATHNVPROC) (GLuint path, GLint reference, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILFILLPATHINSTANCEDNVPROC) (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLenum fillMode, GLuint mask, GLenum transformType, const GLfloat *transformValues); +typedef void (GL_APIENTRYP PFNGLSTENCILSTROKEPATHINSTANCEDNVPROC) (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLint reference, GLuint mask, GLenum transformType, const GLfloat *transformValues); +typedef void (GL_APIENTRYP PFNGLPATHCOVERDEPTHFUNCNVPROC) (GLenum func); +typedef void (GL_APIENTRYP PFNGLCOVERFILLPATHNVPROC) (GLuint path, GLenum coverMode); +typedef void (GL_APIENTRYP PFNGLCOVERSTROKEPATHNVPROC) (GLuint path, GLenum coverMode); +typedef void (GL_APIENTRYP PFNGLCOVERFILLPATHINSTANCEDNVPROC) (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues); +typedef void (GL_APIENTRYP PFNGLCOVERSTROKEPATHINSTANCEDNVPROC) (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues); +typedef void (GL_APIENTRYP PFNGLGETPATHPARAMETERIVNVPROC) (GLuint path, GLenum pname, GLint *value); +typedef void (GL_APIENTRYP PFNGLGETPATHPARAMETERFVNVPROC) (GLuint path, GLenum pname, GLfloat *value); +typedef void (GL_APIENTRYP PFNGLGETPATHCOMMANDSNVPROC) (GLuint path, GLubyte *commands); +typedef void (GL_APIENTRYP PFNGLGETPATHCOORDSNVPROC) (GLuint path, GLfloat *coords); +typedef void (GL_APIENTRYP PFNGLGETPATHDASHARRAYNVPROC) (GLuint path, GLfloat *dashArray); +typedef void (GL_APIENTRYP PFNGLGETPATHMETRICSNVPROC) (GLbitfield metricQueryMask, GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLsizei stride, GLfloat *metrics); +typedef void (GL_APIENTRYP PFNGLGETPATHMETRICRANGENVPROC) (GLbitfield metricQueryMask, GLuint firstPathName, GLsizei numPaths, GLsizei stride, GLfloat *metrics); +typedef void (GL_APIENTRYP PFNGLGETPATHSPACINGNVPROC) (GLenum pathListMode, GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLfloat advanceScale, GLfloat kerningScale, GLenum transformType, GLfloat *returnedSpacing); +typedef GLboolean (GL_APIENTRYP PFNGLISPOINTINFILLPATHNVPROC) (GLuint path, GLuint mask, GLfloat x, GLfloat y); +typedef GLboolean (GL_APIENTRYP PFNGLISPOINTINSTROKEPATHNVPROC) (GLuint path, GLfloat x, GLfloat y); +typedef GLfloat (GL_APIENTRYP PFNGLGETPATHLENGTHNVPROC) (GLuint path, GLsizei startSegment, GLsizei numSegments); +typedef GLboolean (GL_APIENTRYP PFNGLPOINTALONGPATHNVPROC) (GLuint path, GLsizei startSegment, GLsizei numSegments, GLfloat distance, GLfloat *x, GLfloat *y, GLfloat *tangentX, GLfloat *tangentY); +typedef void (GL_APIENTRYP PFNGLMATRIXLOAD3X2FNVPROC) (GLenum matrixMode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATRIXLOAD3X3FNVPROC) (GLenum matrixMode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATRIXLOADTRANSPOSE3X3FNVPROC) (GLenum matrixMode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATRIXMULT3X2FNVPROC) (GLenum matrixMode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATRIXMULT3X3FNVPROC) (GLenum matrixMode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATRIXMULTTRANSPOSE3X3FNVPROC) (GLenum matrixMode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLSTENCILTHENCOVERFILLPATHNVPROC) (GLuint path, GLenum fillMode, GLuint mask, GLenum coverMode); +typedef void (GL_APIENTRYP PFNGLSTENCILTHENCOVERSTROKEPATHNVPROC) (GLuint path, GLint reference, GLuint mask, GLenum coverMode); +typedef void (GL_APIENTRYP PFNGLSTENCILTHENCOVERFILLPATHINSTANCEDNVPROC) (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLenum fillMode, GLuint mask, GLenum coverMode, GLenum transformType, const GLfloat *transformValues); +typedef void (GL_APIENTRYP PFNGLSTENCILTHENCOVERSTROKEPATHINSTANCEDNVPROC) (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLint reference, GLuint mask, GLenum coverMode, GLenum transformType, const GLfloat *transformValues); +typedef GLenum (GL_APIENTRYP PFNGLPATHGLYPHINDEXRANGENVPROC) (GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLuint pathParameterTemplate, GLfloat emScale, GLuint baseAndCount[2]); +typedef GLenum (GL_APIENTRYP PFNGLPATHGLYPHINDEXARRAYNVPROC) (GLuint firstPathName, GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLuint firstGlyphIndex, GLsizei numGlyphs, GLuint pathParameterTemplate, GLfloat emScale); +typedef GLenum (GL_APIENTRYP PFNGLPATHMEMORYGLYPHINDEXARRAYNVPROC) (GLuint firstPathName, GLenum fontTarget, GLsizeiptr fontSize, const void *fontData, GLsizei faceIndex, GLuint firstGlyphIndex, GLsizei numGlyphs, GLuint pathParameterTemplate, GLfloat emScale); +typedef void (GL_APIENTRYP PFNGLPROGRAMPATHFRAGMENTINPUTGENNVPROC) (GLuint program, GLint location, GLenum genMode, GLint components, const GLfloat *coeffs); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMRESOURCEFVNVPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei count, GLsizei *length, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLMATRIXFRUSTUMEXTPROC) (GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); +typedef void (GL_APIENTRYP PFNGLMATRIXLOADIDENTITYEXTPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLMATRIXLOADTRANSPOSEFEXTPROC) (GLenum mode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATRIXLOADTRANSPOSEDEXTPROC) (GLenum mode, const GLdouble *m); +typedef void (GL_APIENTRYP PFNGLMATRIXLOADFEXTPROC) (GLenum mode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATRIXLOADDEXTPROC) (GLenum mode, const GLdouble *m); +typedef void (GL_APIENTRYP PFNGLMATRIXMULTTRANSPOSEFEXTPROC) (GLenum mode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATRIXMULTTRANSPOSEDEXTPROC) (GLenum mode, const GLdouble *m); +typedef void (GL_APIENTRYP PFNGLMATRIXMULTFEXTPROC) (GLenum mode, const GLfloat *m); +typedef void (GL_APIENTRYP PFNGLMATRIXMULTDEXTPROC) (GLenum mode, const GLdouble *m); +typedef void (GL_APIENTRYP PFNGLMATRIXORTHOEXTPROC) (GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); +typedef void (GL_APIENTRYP PFNGLMATRIXPOPEXTPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLMATRIXPUSHEXTPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLMATRIXROTATEFEXTPROC) (GLenum mode, GLfloat angle, GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLMATRIXROTATEDEXTPROC) (GLenum mode, GLdouble angle, GLdouble x, GLdouble y, GLdouble z); +typedef void (GL_APIENTRYP PFNGLMATRIXSCALEFEXTPROC) (GLenum mode, GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLMATRIXSCALEDEXTPROC) (GLenum mode, GLdouble x, GLdouble y, GLdouble z); +typedef void (GL_APIENTRYP PFNGLMATRIXTRANSLATEFEXTPROC) (GLenum mode, GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLMATRIXTRANSLATEDEXTPROC) (GLenum mode, GLdouble x, GLdouble y, GLdouble z); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL GLuint GL_APIENTRY glGenPathsNV (GLsizei range); +GL_APICALL void GL_APIENTRY glDeletePathsNV (GLuint path, GLsizei range); +GL_APICALL GLboolean GL_APIENTRY glIsPathNV (GLuint path); +GL_APICALL void GL_APIENTRY glPathCommandsNV (GLuint path, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const void *coords); +GL_APICALL void GL_APIENTRY glPathCoordsNV (GLuint path, GLsizei numCoords, GLenum coordType, const void *coords); +GL_APICALL void GL_APIENTRY glPathSubCommandsNV (GLuint path, GLsizei commandStart, GLsizei commandsToDelete, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const void *coords); +GL_APICALL void GL_APIENTRY glPathSubCoordsNV (GLuint path, GLsizei coordStart, GLsizei numCoords, GLenum coordType, const void *coords); +GL_APICALL void GL_APIENTRY glPathStringNV (GLuint path, GLenum format, GLsizei length, const void *pathString); +GL_APICALL void GL_APIENTRY glPathGlyphsNV (GLuint firstPathName, GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLsizei numGlyphs, GLenum type, const void *charcodes, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale); +GL_APICALL void GL_APIENTRY glPathGlyphRangeNV (GLuint firstPathName, GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLuint firstGlyph, GLsizei numGlyphs, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale); +GL_APICALL void GL_APIENTRY glWeightPathsNV (GLuint resultPath, GLsizei numPaths, const GLuint *paths, const GLfloat *weights); +GL_APICALL void GL_APIENTRY glCopyPathNV (GLuint resultPath, GLuint srcPath); +GL_APICALL void GL_APIENTRY glInterpolatePathsNV (GLuint resultPath, GLuint pathA, GLuint pathB, GLfloat weight); +GL_APICALL void GL_APIENTRY glTransformPathNV (GLuint resultPath, GLuint srcPath, GLenum transformType, const GLfloat *transformValues); +GL_APICALL void GL_APIENTRY glPathParameterivNV (GLuint path, GLenum pname, const GLint *value); +GL_APICALL void GL_APIENTRY glPathParameteriNV (GLuint path, GLenum pname, GLint value); +GL_APICALL void GL_APIENTRY glPathParameterfvNV (GLuint path, GLenum pname, const GLfloat *value); +GL_APICALL void GL_APIENTRY glPathParameterfNV (GLuint path, GLenum pname, GLfloat value); +GL_APICALL void GL_APIENTRY glPathDashArrayNV (GLuint path, GLsizei dashCount, const GLfloat *dashArray); +GL_APICALL void GL_APIENTRY glPathStencilFuncNV (GLenum func, GLint ref, GLuint mask); +GL_APICALL void GL_APIENTRY glPathStencilDepthOffsetNV (GLfloat factor, GLfloat units); +GL_APICALL void GL_APIENTRY glStencilFillPathNV (GLuint path, GLenum fillMode, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilStrokePathNV (GLuint path, GLint reference, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilFillPathInstancedNV (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLenum fillMode, GLuint mask, GLenum transformType, const GLfloat *transformValues); +GL_APICALL void GL_APIENTRY glStencilStrokePathInstancedNV (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLint reference, GLuint mask, GLenum transformType, const GLfloat *transformValues); +GL_APICALL void GL_APIENTRY glPathCoverDepthFuncNV (GLenum func); +GL_APICALL void GL_APIENTRY glCoverFillPathNV (GLuint path, GLenum coverMode); +GL_APICALL void GL_APIENTRY glCoverStrokePathNV (GLuint path, GLenum coverMode); +GL_APICALL void GL_APIENTRY glCoverFillPathInstancedNV (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues); +GL_APICALL void GL_APIENTRY glCoverStrokePathInstancedNV (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues); +GL_APICALL void GL_APIENTRY glGetPathParameterivNV (GLuint path, GLenum pname, GLint *value); +GL_APICALL void GL_APIENTRY glGetPathParameterfvNV (GLuint path, GLenum pname, GLfloat *value); +GL_APICALL void GL_APIENTRY glGetPathCommandsNV (GLuint path, GLubyte *commands); +GL_APICALL void GL_APIENTRY glGetPathCoordsNV (GLuint path, GLfloat *coords); +GL_APICALL void GL_APIENTRY glGetPathDashArrayNV (GLuint path, GLfloat *dashArray); +GL_APICALL void GL_APIENTRY glGetPathMetricsNV (GLbitfield metricQueryMask, GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLsizei stride, GLfloat *metrics); +GL_APICALL void GL_APIENTRY glGetPathMetricRangeNV (GLbitfield metricQueryMask, GLuint firstPathName, GLsizei numPaths, GLsizei stride, GLfloat *metrics); +GL_APICALL void GL_APIENTRY glGetPathSpacingNV (GLenum pathListMode, GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLfloat advanceScale, GLfloat kerningScale, GLenum transformType, GLfloat *returnedSpacing); +GL_APICALL GLboolean GL_APIENTRY glIsPointInFillPathNV (GLuint path, GLuint mask, GLfloat x, GLfloat y); +GL_APICALL GLboolean GL_APIENTRY glIsPointInStrokePathNV (GLuint path, GLfloat x, GLfloat y); +GL_APICALL GLfloat GL_APIENTRY glGetPathLengthNV (GLuint path, GLsizei startSegment, GLsizei numSegments); +GL_APICALL GLboolean GL_APIENTRY glPointAlongPathNV (GLuint path, GLsizei startSegment, GLsizei numSegments, GLfloat distance, GLfloat *x, GLfloat *y, GLfloat *tangentX, GLfloat *tangentY); +GL_APICALL void GL_APIENTRY glMatrixLoad3x2fNV (GLenum matrixMode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixLoad3x3fNV (GLenum matrixMode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixLoadTranspose3x3fNV (GLenum matrixMode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixMult3x2fNV (GLenum matrixMode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixMult3x3fNV (GLenum matrixMode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixMultTranspose3x3fNV (GLenum matrixMode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glStencilThenCoverFillPathNV (GLuint path, GLenum fillMode, GLuint mask, GLenum coverMode); +GL_APICALL void GL_APIENTRY glStencilThenCoverStrokePathNV (GLuint path, GLint reference, GLuint mask, GLenum coverMode); +GL_APICALL void GL_APIENTRY glStencilThenCoverFillPathInstancedNV (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLenum fillMode, GLuint mask, GLenum coverMode, GLenum transformType, const GLfloat *transformValues); +GL_APICALL void GL_APIENTRY glStencilThenCoverStrokePathInstancedNV (GLsizei numPaths, GLenum pathNameType, const void *paths, GLuint pathBase, GLint reference, GLuint mask, GLenum coverMode, GLenum transformType, const GLfloat *transformValues); +GL_APICALL GLenum GL_APIENTRY glPathGlyphIndexRangeNV (GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLuint pathParameterTemplate, GLfloat emScale, GLuint baseAndCount[2]); +GL_APICALL GLenum GL_APIENTRY glPathGlyphIndexArrayNV (GLuint firstPathName, GLenum fontTarget, const void *fontName, GLbitfield fontStyle, GLuint firstGlyphIndex, GLsizei numGlyphs, GLuint pathParameterTemplate, GLfloat emScale); +GL_APICALL GLenum GL_APIENTRY glPathMemoryGlyphIndexArrayNV (GLuint firstPathName, GLenum fontTarget, GLsizeiptr fontSize, const void *fontData, GLsizei faceIndex, GLuint firstGlyphIndex, GLsizei numGlyphs, GLuint pathParameterTemplate, GLfloat emScale); +GL_APICALL void GL_APIENTRY glProgramPathFragmentInputGenNV (GLuint program, GLint location, GLenum genMode, GLint components, const GLfloat *coeffs); +GL_APICALL void GL_APIENTRY glGetProgramResourcefvNV (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei count, GLsizei *length, GLfloat *params); +GL_APICALL void GL_APIENTRY glMatrixFrustumEXT (GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); +GL_APICALL void GL_APIENTRY glMatrixLoadIdentityEXT (GLenum mode); +GL_APICALL void GL_APIENTRY glMatrixLoadTransposefEXT (GLenum mode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixLoadTransposedEXT (GLenum mode, const GLdouble *m); +GL_APICALL void GL_APIENTRY glMatrixLoadfEXT (GLenum mode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixLoaddEXT (GLenum mode, const GLdouble *m); +GL_APICALL void GL_APIENTRY glMatrixMultTransposefEXT (GLenum mode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixMultTransposedEXT (GLenum mode, const GLdouble *m); +GL_APICALL void GL_APIENTRY glMatrixMultfEXT (GLenum mode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixMultdEXT (GLenum mode, const GLdouble *m); +GL_APICALL void GL_APIENTRY glMatrixOrthoEXT (GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar); +GL_APICALL void GL_APIENTRY glMatrixPopEXT (GLenum mode); +GL_APICALL void GL_APIENTRY glMatrixPushEXT (GLenum mode); +GL_APICALL void GL_APIENTRY glMatrixRotatefEXT (GLenum mode, GLfloat angle, GLfloat x, GLfloat y, GLfloat z); +GL_APICALL void GL_APIENTRY glMatrixRotatedEXT (GLenum mode, GLdouble angle, GLdouble x, GLdouble y, GLdouble z); +GL_APICALL void GL_APIENTRY glMatrixScalefEXT (GLenum mode, GLfloat x, GLfloat y, GLfloat z); +GL_APICALL void GL_APIENTRY glMatrixScaledEXT (GLenum mode, GLdouble x, GLdouble y, GLdouble z); +GL_APICALL void GL_APIENTRY glMatrixTranslatefEXT (GLenum mode, GLfloat x, GLfloat y, GLfloat z); +GL_APICALL void GL_APIENTRY glMatrixTranslatedEXT (GLenum mode, GLdouble x, GLdouble y, GLdouble z); +#endif +#endif /* GL_NV_path_rendering */ + +#ifndef GL_NV_path_rendering_shared_edge +#define GL_NV_path_rendering_shared_edge 1 +#define GL_SHARED_EDGE_NV 0xC0 +#endif /* GL_NV_path_rendering_shared_edge */ + +#ifndef GL_NV_pixel_buffer_object +#define GL_NV_pixel_buffer_object 1 +#define GL_PIXEL_PACK_BUFFER_NV 0x88EB +#define GL_PIXEL_UNPACK_BUFFER_NV 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING_NV 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING_NV 0x88EF +#endif /* GL_NV_pixel_buffer_object */ + +#ifndef GL_NV_polygon_mode +#define GL_NV_polygon_mode 1 +#define GL_POLYGON_MODE_NV 0x0B40 +#define GL_POLYGON_OFFSET_POINT_NV 0x2A01 +#define GL_POLYGON_OFFSET_LINE_NV 0x2A02 +#define GL_POINT_NV 0x1B00 +#define GL_LINE_NV 0x1B01 +#define GL_FILL_NV 0x1B02 +typedef void (GL_APIENTRYP PFNGLPOLYGONMODENVPROC) (GLenum face, GLenum mode); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glPolygonModeNV (GLenum face, GLenum mode); +#endif +#endif /* GL_NV_polygon_mode */ + +#ifndef GL_NV_primitive_shading_rate +#define GL_NV_primitive_shading_rate 1 +#define GL_SHADING_RATE_IMAGE_PER_PRIMITIVE_NV 0x95B1 +#define GL_SHADING_RATE_IMAGE_PALETTE_COUNT_NV 0x95B2 +#endif /* GL_NV_primitive_shading_rate */ + +#ifndef GL_NV_read_buffer +#define GL_NV_read_buffer 1 +#define GL_READ_BUFFER_NV 0x0C02 +typedef void (GL_APIENTRYP PFNGLREADBUFFERNVPROC) (GLenum mode); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glReadBufferNV (GLenum mode); +#endif +#endif /* GL_NV_read_buffer */ + +#ifndef GL_NV_read_buffer_front +#define GL_NV_read_buffer_front 1 +#endif /* GL_NV_read_buffer_front */ + +#ifndef GL_NV_read_depth +#define GL_NV_read_depth 1 +#endif /* GL_NV_read_depth */ + +#ifndef GL_NV_read_depth_stencil +#define GL_NV_read_depth_stencil 1 +#endif /* GL_NV_read_depth_stencil */ + +#ifndef GL_NV_read_stencil +#define GL_NV_read_stencil 1 +#endif /* GL_NV_read_stencil */ + +#ifndef GL_NV_representative_fragment_test +#define GL_NV_representative_fragment_test 1 +#define GL_REPRESENTATIVE_FRAGMENT_TEST_NV 0x937F +#endif /* GL_NV_representative_fragment_test */ + +#ifndef GL_NV_sRGB_formats +#define GL_NV_sRGB_formats 1 +#define GL_SLUMINANCE_NV 0x8C46 +#define GL_SLUMINANCE_ALPHA_NV 0x8C44 +#define GL_SRGB8_NV 0x8C41 +#define GL_SLUMINANCE8_NV 0x8C47 +#define GL_SLUMINANCE8_ALPHA8_NV 0x8C45 +#define GL_COMPRESSED_SRGB_S3TC_DXT1_NV 0x8C4C +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_NV 0x8C4D +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_NV 0x8C4E +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_NV 0x8C4F +#define GL_ETC1_SRGB8_NV 0x88EE +#endif /* GL_NV_sRGB_formats */ + +#ifndef GL_NV_sample_locations +#define GL_NV_sample_locations 1 +#define GL_SAMPLE_LOCATION_SUBPIXEL_BITS_NV 0x933D +#define GL_SAMPLE_LOCATION_PIXEL_GRID_WIDTH_NV 0x933E +#define GL_SAMPLE_LOCATION_PIXEL_GRID_HEIGHT_NV 0x933F +#define GL_PROGRAMMABLE_SAMPLE_LOCATION_TABLE_SIZE_NV 0x9340 +#define GL_SAMPLE_LOCATION_NV 0x8E50 +#define GL_PROGRAMMABLE_SAMPLE_LOCATION_NV 0x9341 +#define GL_FRAMEBUFFER_PROGRAMMABLE_SAMPLE_LOCATIONS_NV 0x9342 +#define GL_FRAMEBUFFER_SAMPLE_LOCATION_PIXEL_GRID_NV 0x9343 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERSAMPLELOCATIONSFVNVPROC) (GLenum target, GLuint start, GLsizei count, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLNAMEDFRAMEBUFFERSAMPLELOCATIONSFVNVPROC) (GLuint framebuffer, GLuint start, GLsizei count, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLRESOLVEDEPTHVALUESNVPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferSampleLocationsfvNV (GLenum target, GLuint start, GLsizei count, const GLfloat *v); +GL_APICALL void GL_APIENTRY glNamedFramebufferSampleLocationsfvNV (GLuint framebuffer, GLuint start, GLsizei count, const GLfloat *v); +GL_APICALL void GL_APIENTRY glResolveDepthValuesNV (void); +#endif +#endif /* GL_NV_sample_locations */ + +#ifndef GL_NV_sample_mask_override_coverage +#define GL_NV_sample_mask_override_coverage 1 +#endif /* GL_NV_sample_mask_override_coverage */ + +#ifndef GL_NV_scissor_exclusive +#define GL_NV_scissor_exclusive 1 +#define GL_SCISSOR_TEST_EXCLUSIVE_NV 0x9555 +#define GL_SCISSOR_BOX_EXCLUSIVE_NV 0x9556 +typedef void (GL_APIENTRYP PFNGLSCISSOREXCLUSIVENVPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSCISSOREXCLUSIVEARRAYVNVPROC) (GLuint first, GLsizei count, const GLint *v); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glScissorExclusiveNV (GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glScissorExclusiveArrayvNV (GLuint first, GLsizei count, const GLint *v); +#endif +#endif /* GL_NV_scissor_exclusive */ + +#ifndef GL_NV_shader_atomic_fp16_vector +#define GL_NV_shader_atomic_fp16_vector 1 +#endif /* GL_NV_shader_atomic_fp16_vector */ + +#ifndef GL_NV_shader_noperspective_interpolation +#define GL_NV_shader_noperspective_interpolation 1 +#endif /* GL_NV_shader_noperspective_interpolation */ + +#ifndef GL_NV_shader_subgroup_partitioned +#define GL_NV_shader_subgroup_partitioned 1 +#define GL_SUBGROUP_FEATURE_PARTITIONED_BIT_NV 0x00000100 +#endif /* GL_NV_shader_subgroup_partitioned */ + +#ifndef GL_NV_shader_texture_footprint +#define GL_NV_shader_texture_footprint 1 +#endif /* GL_NV_shader_texture_footprint */ + +#ifndef GL_NV_shading_rate_image +#define GL_NV_shading_rate_image 1 +#define GL_SHADING_RATE_IMAGE_NV 0x9563 +#define GL_SHADING_RATE_NO_INVOCATIONS_NV 0x9564 +#define GL_SHADING_RATE_1_INVOCATION_PER_PIXEL_NV 0x9565 +#define GL_SHADING_RATE_1_INVOCATION_PER_1X2_PIXELS_NV 0x9566 +#define GL_SHADING_RATE_1_INVOCATION_PER_2X1_PIXELS_NV 0x9567 +#define GL_SHADING_RATE_1_INVOCATION_PER_2X2_PIXELS_NV 0x9568 +#define GL_SHADING_RATE_1_INVOCATION_PER_2X4_PIXELS_NV 0x9569 +#define GL_SHADING_RATE_1_INVOCATION_PER_4X2_PIXELS_NV 0x956A +#define GL_SHADING_RATE_1_INVOCATION_PER_4X4_PIXELS_NV 0x956B +#define GL_SHADING_RATE_2_INVOCATIONS_PER_PIXEL_NV 0x956C +#define GL_SHADING_RATE_4_INVOCATIONS_PER_PIXEL_NV 0x956D +#define GL_SHADING_RATE_8_INVOCATIONS_PER_PIXEL_NV 0x956E +#define GL_SHADING_RATE_16_INVOCATIONS_PER_PIXEL_NV 0x956F +#define GL_SHADING_RATE_IMAGE_BINDING_NV 0x955B +#define GL_SHADING_RATE_IMAGE_TEXEL_WIDTH_NV 0x955C +#define GL_SHADING_RATE_IMAGE_TEXEL_HEIGHT_NV 0x955D +#define GL_SHADING_RATE_IMAGE_PALETTE_SIZE_NV 0x955E +#define GL_MAX_COARSE_FRAGMENT_SAMPLES_NV 0x955F +#define GL_SHADING_RATE_SAMPLE_ORDER_DEFAULT_NV 0x95AE +#define GL_SHADING_RATE_SAMPLE_ORDER_PIXEL_MAJOR_NV 0x95AF +#define GL_SHADING_RATE_SAMPLE_ORDER_SAMPLE_MAJOR_NV 0x95B0 +typedef void (GL_APIENTRYP PFNGLBINDSHADINGRATEIMAGENVPROC) (GLuint texture); +typedef void (GL_APIENTRYP PFNGLGETSHADINGRATEIMAGEPALETTENVPROC) (GLuint viewport, GLuint entry, GLenum *rate); +typedef void (GL_APIENTRYP PFNGLGETSHADINGRATESAMPLELOCATIONIVNVPROC) (GLenum rate, GLuint samples, GLuint index, GLint *location); +typedef void (GL_APIENTRYP PFNGLSHADINGRATEIMAGEBARRIERNVPROC) (GLboolean synchronize); +typedef void (GL_APIENTRYP PFNGLSHADINGRATEIMAGEPALETTENVPROC) (GLuint viewport, GLuint first, GLsizei count, const GLenum *rates); +typedef void (GL_APIENTRYP PFNGLSHADINGRATESAMPLEORDERNVPROC) (GLenum order); +typedef void (GL_APIENTRYP PFNGLSHADINGRATESAMPLEORDERCUSTOMNVPROC) (GLenum rate, GLuint samples, const GLint *locations); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBindShadingRateImageNV (GLuint texture); +GL_APICALL void GL_APIENTRY glGetShadingRateImagePaletteNV (GLuint viewport, GLuint entry, GLenum *rate); +GL_APICALL void GL_APIENTRY glGetShadingRateSampleLocationivNV (GLenum rate, GLuint samples, GLuint index, GLint *location); +GL_APICALL void GL_APIENTRY glShadingRateImageBarrierNV (GLboolean synchronize); +GL_APICALL void GL_APIENTRY glShadingRateImagePaletteNV (GLuint viewport, GLuint first, GLsizei count, const GLenum *rates); +GL_APICALL void GL_APIENTRY glShadingRateSampleOrderNV (GLenum order); +GL_APICALL void GL_APIENTRY glShadingRateSampleOrderCustomNV (GLenum rate, GLuint samples, const GLint *locations); +#endif +#endif /* GL_NV_shading_rate_image */ + +#ifndef GL_NV_shadow_samplers_array +#define GL_NV_shadow_samplers_array 1 +#define GL_SAMPLER_2D_ARRAY_SHADOW_NV 0x8DC4 +#endif /* GL_NV_shadow_samplers_array */ + +#ifndef GL_NV_shadow_samplers_cube +#define GL_NV_shadow_samplers_cube 1 +#define GL_SAMPLER_CUBE_SHADOW_NV 0x8DC5 +#endif /* GL_NV_shadow_samplers_cube */ + +#ifndef GL_NV_stereo_view_rendering +#define GL_NV_stereo_view_rendering 1 +#endif /* GL_NV_stereo_view_rendering */ + +#ifndef GL_NV_texture_border_clamp +#define GL_NV_texture_border_clamp 1 +#define GL_TEXTURE_BORDER_COLOR_NV 0x1004 +#define GL_CLAMP_TO_BORDER_NV 0x812D +#endif /* GL_NV_texture_border_clamp */ + +#ifndef GL_NV_texture_compression_s3tc_update +#define GL_NV_texture_compression_s3tc_update 1 +#endif /* GL_NV_texture_compression_s3tc_update */ + +#ifndef GL_NV_texture_npot_2D_mipmap +#define GL_NV_texture_npot_2D_mipmap 1 +#endif /* GL_NV_texture_npot_2D_mipmap */ + +#ifndef GL_NV_timeline_semaphore +#define GL_NV_timeline_semaphore 1 +#define GL_TIMELINE_SEMAPHORE_VALUE_NV 0x9595 +#define GL_SEMAPHORE_TYPE_NV 0x95B3 +#define GL_SEMAPHORE_TYPE_BINARY_NV 0x95B4 +#define GL_SEMAPHORE_TYPE_TIMELINE_NV 0x95B5 +#define GL_MAX_TIMELINE_SEMAPHORE_VALUE_DIFFERENCE_NV 0x95B6 +typedef void (GL_APIENTRYP PFNGLCREATESEMAPHORESNVPROC) (GLsizei n, GLuint *semaphores); +typedef void (GL_APIENTRYP PFNGLSEMAPHOREPARAMETERIVNVPROC) (GLuint semaphore, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSEMAPHOREPARAMETERIVNVPROC) (GLuint semaphore, GLenum pname, GLint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCreateSemaphoresNV (GLsizei n, GLuint *semaphores); +GL_APICALL void GL_APIENTRY glSemaphoreParameterivNV (GLuint semaphore, GLenum pname, const GLint *params); +GL_APICALL void GL_APIENTRY glGetSemaphoreParameterivNV (GLuint semaphore, GLenum pname, GLint *params); +#endif +#endif /* GL_NV_timeline_semaphore */ + +#ifndef GL_NV_viewport_array +#define GL_NV_viewport_array 1 +#define GL_MAX_VIEWPORTS_NV 0x825B +#define GL_VIEWPORT_SUBPIXEL_BITS_NV 0x825C +#define GL_VIEWPORT_BOUNDS_RANGE_NV 0x825D +#define GL_VIEWPORT_INDEX_PROVOKING_VERTEX_NV 0x825F +typedef void (GL_APIENTRYP PFNGLVIEWPORTARRAYVNVPROC) (GLuint first, GLsizei count, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVIEWPORTINDEXEDFNVPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h); +typedef void (GL_APIENTRYP PFNGLVIEWPORTINDEXEDFVNVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLSCISSORARRAYVNVPROC) (GLuint first, GLsizei count, const GLint *v); +typedef void (GL_APIENTRYP PFNGLSCISSORINDEXEDNVPROC) (GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSCISSORINDEXEDVNVPROC) (GLuint index, const GLint *v); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEARRAYFVNVPROC) (GLuint first, GLsizei count, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEINDEXEDFNVPROC) (GLuint index, GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLGETFLOATI_VNVPROC) (GLenum target, GLuint index, GLfloat *data); +typedef void (GL_APIENTRYP PFNGLENABLEINVPROC) (GLenum target, GLuint index); +typedef void (GL_APIENTRYP PFNGLDISABLEINVPROC) (GLenum target, GLuint index); +typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDINVPROC) (GLenum target, GLuint index); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glViewportArrayvNV (GLuint first, GLsizei count, const GLfloat *v); +GL_APICALL void GL_APIENTRY glViewportIndexedfNV (GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h); +GL_APICALL void GL_APIENTRY glViewportIndexedfvNV (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glScissorArrayvNV (GLuint first, GLsizei count, const GLint *v); +GL_APICALL void GL_APIENTRY glScissorIndexedNV (GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glScissorIndexedvNV (GLuint index, const GLint *v); +GL_APICALL void GL_APIENTRY glDepthRangeArrayfvNV (GLuint first, GLsizei count, const GLfloat *v); +GL_APICALL void GL_APIENTRY glDepthRangeIndexedfNV (GLuint index, GLfloat n, GLfloat f); +GL_APICALL void GL_APIENTRY glGetFloati_vNV (GLenum target, GLuint index, GLfloat *data); +GL_APICALL void GL_APIENTRY glEnableiNV (GLenum target, GLuint index); +GL_APICALL void GL_APIENTRY glDisableiNV (GLenum target, GLuint index); +GL_APICALL GLboolean GL_APIENTRY glIsEnablediNV (GLenum target, GLuint index); +#endif +#endif /* GL_NV_viewport_array */ + +#ifndef GL_NV_viewport_array2 +#define GL_NV_viewport_array2 1 +#endif /* GL_NV_viewport_array2 */ + +#ifndef GL_NV_viewport_swizzle +#define GL_NV_viewport_swizzle 1 +#define GL_VIEWPORT_SWIZZLE_POSITIVE_X_NV 0x9350 +#define GL_VIEWPORT_SWIZZLE_NEGATIVE_X_NV 0x9351 +#define GL_VIEWPORT_SWIZZLE_POSITIVE_Y_NV 0x9352 +#define GL_VIEWPORT_SWIZZLE_NEGATIVE_Y_NV 0x9353 +#define GL_VIEWPORT_SWIZZLE_POSITIVE_Z_NV 0x9354 +#define GL_VIEWPORT_SWIZZLE_NEGATIVE_Z_NV 0x9355 +#define GL_VIEWPORT_SWIZZLE_POSITIVE_W_NV 0x9356 +#define GL_VIEWPORT_SWIZZLE_NEGATIVE_W_NV 0x9357 +#define GL_VIEWPORT_SWIZZLE_X_NV 0x9358 +#define GL_VIEWPORT_SWIZZLE_Y_NV 0x9359 +#define GL_VIEWPORT_SWIZZLE_Z_NV 0x935A +#define GL_VIEWPORT_SWIZZLE_W_NV 0x935B +typedef void (GL_APIENTRYP PFNGLVIEWPORTSWIZZLENVPROC) (GLuint index, GLenum swizzlex, GLenum swizzley, GLenum swizzlez, GLenum swizzlew); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glViewportSwizzleNV (GLuint index, GLenum swizzlex, GLenum swizzley, GLenum swizzlez, GLenum swizzlew); +#endif +#endif /* GL_NV_viewport_swizzle */ + +#ifndef GL_OVR_multiview +#define GL_OVR_multiview 1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_NUM_VIEWS_OVR 0x9630 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_BASE_VIEW_INDEX_OVR 0x9632 +#define GL_MAX_VIEWS_OVR 0x9631 +#define GL_FRAMEBUFFER_INCOMPLETE_VIEW_TARGETS_OVR 0x9633 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTUREMULTIVIEWOVRPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint baseViewIndex, GLsizei numViews); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferTextureMultiviewOVR (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint baseViewIndex, GLsizei numViews); +#endif +#endif /* GL_OVR_multiview */ + +#ifndef GL_OVR_multiview2 +#define GL_OVR_multiview2 1 +#endif /* GL_OVR_multiview2 */ + +#ifndef GL_OVR_multiview_multisampled_render_to_texture +#define GL_OVR_multiview_multisampled_render_to_texture 1 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTUREMULTISAMPLEMULTIVIEWOVRPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLsizei samples, GLint baseViewIndex, GLsizei numViews); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferTextureMultisampleMultiviewOVR (GLenum target, GLenum attachment, GLuint texture, GLint level, GLsizei samples, GLint baseViewIndex, GLsizei numViews); +#endif +#endif /* GL_OVR_multiview_multisampled_render_to_texture */ + +#ifndef GL_QCOM_YUV_texture_gather +#define GL_QCOM_YUV_texture_gather 1 +#endif /* GL_QCOM_YUV_texture_gather */ + +#ifndef GL_QCOM_alpha_test +#define GL_QCOM_alpha_test 1 +#define GL_ALPHA_TEST_QCOM 0x0BC0 +#define GL_ALPHA_TEST_FUNC_QCOM 0x0BC1 +#define GL_ALPHA_TEST_REF_QCOM 0x0BC2 +typedef void (GL_APIENTRYP PFNGLALPHAFUNCQCOMPROC) (GLenum func, GLclampf ref); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glAlphaFuncQCOM (GLenum func, GLclampf ref); +#endif +#endif /* GL_QCOM_alpha_test */ + +#ifndef GL_QCOM_binning_control +#define GL_QCOM_binning_control 1 +#define GL_BINNING_CONTROL_HINT_QCOM 0x8FB0 +#define GL_CPU_OPTIMIZED_QCOM 0x8FB1 +#define GL_GPU_OPTIMIZED_QCOM 0x8FB2 +#define GL_RENDER_DIRECT_TO_FRAMEBUFFER_QCOM 0x8FB3 +#endif /* GL_QCOM_binning_control */ + +#ifndef GL_QCOM_driver_control +#define GL_QCOM_driver_control 1 +typedef void (GL_APIENTRYP PFNGLGETDRIVERCONTROLSQCOMPROC) (GLint *num, GLsizei size, GLuint *driverControls); +typedef void (GL_APIENTRYP PFNGLGETDRIVERCONTROLSTRINGQCOMPROC) (GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString); +typedef void (GL_APIENTRYP PFNGLENABLEDRIVERCONTROLQCOMPROC) (GLuint driverControl); +typedef void (GL_APIENTRYP PFNGLDISABLEDRIVERCONTROLQCOMPROC) (GLuint driverControl); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetDriverControlsQCOM (GLint *num, GLsizei size, GLuint *driverControls); +GL_APICALL void GL_APIENTRY glGetDriverControlStringQCOM (GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString); +GL_APICALL void GL_APIENTRY glEnableDriverControlQCOM (GLuint driverControl); +GL_APICALL void GL_APIENTRY glDisableDriverControlQCOM (GLuint driverControl); +#endif +#endif /* GL_QCOM_driver_control */ + +#ifndef GL_QCOM_extended_get +#define GL_QCOM_extended_get 1 +#define GL_TEXTURE_WIDTH_QCOM 0x8BD2 +#define GL_TEXTURE_HEIGHT_QCOM 0x8BD3 +#define GL_TEXTURE_DEPTH_QCOM 0x8BD4 +#define GL_TEXTURE_INTERNAL_FORMAT_QCOM 0x8BD5 +#define GL_TEXTURE_FORMAT_QCOM 0x8BD6 +#define GL_TEXTURE_TYPE_QCOM 0x8BD7 +#define GL_TEXTURE_IMAGE_VALID_QCOM 0x8BD8 +#define GL_TEXTURE_NUM_LEVELS_QCOM 0x8BD9 +#define GL_TEXTURE_TARGET_QCOM 0x8BDA +#define GL_TEXTURE_OBJECT_VALID_QCOM 0x8BDB +#define GL_STATE_RESTORE 0x8BDC +typedef void (GL_APIENTRYP PFNGLEXTGETTEXTURESQCOMPROC) (GLuint *textures, GLint maxTextures, GLint *numTextures); +typedef void (GL_APIENTRYP PFNGLEXTGETBUFFERSQCOMPROC) (GLuint *buffers, GLint maxBuffers, GLint *numBuffers); +typedef void (GL_APIENTRYP PFNGLEXTGETRENDERBUFFERSQCOMPROC) (GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers); +typedef void (GL_APIENTRYP PFNGLEXTGETFRAMEBUFFERSQCOMPROC) (GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers); +typedef void (GL_APIENTRYP PFNGLEXTGETTEXLEVELPARAMETERIVQCOMPROC) (GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLEXTTEXOBJECTSTATEOVERRIDEIQCOMPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLEXTGETTEXSUBIMAGEQCOMPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, void *texels); +typedef void (GL_APIENTRYP PFNGLEXTGETBUFFERPOINTERVQCOMPROC) (GLenum target, void **params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glExtGetTexturesQCOM (GLuint *textures, GLint maxTextures, GLint *numTextures); +GL_APICALL void GL_APIENTRY glExtGetBuffersQCOM (GLuint *buffers, GLint maxBuffers, GLint *numBuffers); +GL_APICALL void GL_APIENTRY glExtGetRenderbuffersQCOM (GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers); +GL_APICALL void GL_APIENTRY glExtGetFramebuffersQCOM (GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers); +GL_APICALL void GL_APIENTRY glExtGetTexLevelParameterivQCOM (GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glExtTexObjectStateOverrideiQCOM (GLenum target, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glExtGetTexSubImageQCOM (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, void *texels); +GL_APICALL void GL_APIENTRY glExtGetBufferPointervQCOM (GLenum target, void **params); +#endif +#endif /* GL_QCOM_extended_get */ + +#ifndef GL_QCOM_extended_get2 +#define GL_QCOM_extended_get2 1 +typedef void (GL_APIENTRYP PFNGLEXTGETSHADERSQCOMPROC) (GLuint *shaders, GLint maxShaders, GLint *numShaders); +typedef void (GL_APIENTRYP PFNGLEXTGETPROGRAMSQCOMPROC) (GLuint *programs, GLint maxPrograms, GLint *numPrograms); +typedef GLboolean (GL_APIENTRYP PFNGLEXTISPROGRAMBINARYQCOMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLEXTGETPROGRAMBINARYSOURCEQCOMPROC) (GLuint program, GLenum shadertype, GLchar *source, GLint *length); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glExtGetShadersQCOM (GLuint *shaders, GLint maxShaders, GLint *numShaders); +GL_APICALL void GL_APIENTRY glExtGetProgramsQCOM (GLuint *programs, GLint maxPrograms, GLint *numPrograms); +GL_APICALL GLboolean GL_APIENTRY glExtIsProgramBinaryQCOM (GLuint program); +GL_APICALL void GL_APIENTRY glExtGetProgramBinarySourceQCOM (GLuint program, GLenum shadertype, GLchar *source, GLint *length); +#endif +#endif /* GL_QCOM_extended_get2 */ + +#ifndef GL_QCOM_frame_extrapolation +#define GL_QCOM_frame_extrapolation 1 +typedef void (GL_APIENTRYP PFNGLEXTRAPOLATETEX2DQCOMPROC) (GLuint src1, GLuint src2, GLuint output, GLfloat scaleFactor); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glExtrapolateTex2DQCOM (GLuint src1, GLuint src2, GLuint output, GLfloat scaleFactor); +#endif +#endif /* GL_QCOM_frame_extrapolation */ + +#ifndef GL_QCOM_framebuffer_foveated +#define GL_QCOM_framebuffer_foveated 1 +#define GL_FOVEATION_ENABLE_BIT_QCOM 0x00000001 +#define GL_FOVEATION_SCALED_BIN_METHOD_BIT_QCOM 0x00000002 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERFOVEATIONCONFIGQCOMPROC) (GLuint framebuffer, GLuint numLayers, GLuint focalPointsPerLayer, GLuint requestedFeatures, GLuint *providedFeatures); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERFOVEATIONPARAMETERSQCOMPROC) (GLuint framebuffer, GLuint layer, GLuint focalPoint, GLfloat focalX, GLfloat focalY, GLfloat gainX, GLfloat gainY, GLfloat foveaArea); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferFoveationConfigQCOM (GLuint framebuffer, GLuint numLayers, GLuint focalPointsPerLayer, GLuint requestedFeatures, GLuint *providedFeatures); +GL_APICALL void GL_APIENTRY glFramebufferFoveationParametersQCOM (GLuint framebuffer, GLuint layer, GLuint focalPoint, GLfloat focalX, GLfloat focalY, GLfloat gainX, GLfloat gainY, GLfloat foveaArea); +#endif +#endif /* GL_QCOM_framebuffer_foveated */ + +#ifndef GL_QCOM_motion_estimation +#define GL_QCOM_motion_estimation 1 +#define GL_MOTION_ESTIMATION_SEARCH_BLOCK_X_QCOM 0x8C90 +#define GL_MOTION_ESTIMATION_SEARCH_BLOCK_Y_QCOM 0x8C91 +typedef void (GL_APIENTRYP PFNGLTEXESTIMATEMOTIONQCOMPROC) (GLuint ref, GLuint target, GLuint output); +typedef void (GL_APIENTRYP PFNGLTEXESTIMATEMOTIONREGIONSQCOMPROC) (GLuint ref, GLuint target, GLuint output, GLuint mask); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexEstimateMotionQCOM (GLuint ref, GLuint target, GLuint output); +GL_APICALL void GL_APIENTRY glTexEstimateMotionRegionsQCOM (GLuint ref, GLuint target, GLuint output, GLuint mask); +#endif +#endif /* GL_QCOM_motion_estimation */ + +#ifndef GL_QCOM_perfmon_global_mode +#define GL_QCOM_perfmon_global_mode 1 +#define GL_PERFMON_GLOBAL_MODE_QCOM 0x8FA0 +#endif /* GL_QCOM_perfmon_global_mode */ + +#ifndef GL_QCOM_shader_framebuffer_fetch_noncoherent +#define GL_QCOM_shader_framebuffer_fetch_noncoherent 1 +#define GL_FRAMEBUFFER_FETCH_NONCOHERENT_QCOM 0x96A2 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERFETCHBARRIERQCOMPROC) (void); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferFetchBarrierQCOM (void); +#endif +#endif /* GL_QCOM_shader_framebuffer_fetch_noncoherent */ + +#ifndef GL_QCOM_shader_framebuffer_fetch_rate +#define GL_QCOM_shader_framebuffer_fetch_rate 1 +#endif /* GL_QCOM_shader_framebuffer_fetch_rate */ + +#ifndef GL_QCOM_shading_rate +#define GL_QCOM_shading_rate 1 +#define GL_SHADING_RATE_QCOM 0x96A4 +#define GL_SHADING_RATE_PRESERVE_ASPECT_RATIO_QCOM 0x96A5 +#define GL_SHADING_RATE_1X1_PIXELS_QCOM 0x96A6 +#define GL_SHADING_RATE_1X2_PIXELS_QCOM 0x96A7 +#define GL_SHADING_RATE_2X1_PIXELS_QCOM 0x96A8 +#define GL_SHADING_RATE_2X2_PIXELS_QCOM 0x96A9 +#define GL_SHADING_RATE_4X2_PIXELS_QCOM 0x96AC +#define GL_SHADING_RATE_4X4_PIXELS_QCOM 0x96AE +typedef void (GL_APIENTRYP PFNGLSHADINGRATEQCOMPROC) (GLenum rate); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glShadingRateQCOM (GLenum rate); +#endif +#endif /* GL_QCOM_shading_rate */ + +#ifndef GL_QCOM_texture_foveated +#define GL_QCOM_texture_foveated 1 +#define GL_TEXTURE_FOVEATED_FEATURE_BITS_QCOM 0x8BFB +#define GL_TEXTURE_FOVEATED_MIN_PIXEL_DENSITY_QCOM 0x8BFC +#define GL_TEXTURE_FOVEATED_FEATURE_QUERY_QCOM 0x8BFD +#define GL_TEXTURE_FOVEATED_NUM_FOCAL_POINTS_QUERY_QCOM 0x8BFE +#define GL_FRAMEBUFFER_INCOMPLETE_FOVEATION_QCOM 0x8BFF +typedef void (GL_APIENTRYP PFNGLTEXTUREFOVEATIONPARAMETERSQCOMPROC) (GLuint texture, GLuint layer, GLuint focalPoint, GLfloat focalX, GLfloat focalY, GLfloat gainX, GLfloat gainY, GLfloat foveaArea); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTextureFoveationParametersQCOM (GLuint texture, GLuint layer, GLuint focalPoint, GLfloat focalX, GLfloat focalY, GLfloat gainX, GLfloat gainY, GLfloat foveaArea); +#endif +#endif /* GL_QCOM_texture_foveated */ + +#ifndef GL_QCOM_texture_foveated2 +#define GL_QCOM_texture_foveated2 1 +#define GL_TEXTURE_FOVEATED_CUTOFF_DENSITY_QCOM 0x96A0 +#endif /* GL_QCOM_texture_foveated2 */ + +#ifndef GL_QCOM_texture_foveated_subsampled_layout +#define GL_QCOM_texture_foveated_subsampled_layout 1 +#define GL_FOVEATION_SUBSAMPLED_LAYOUT_METHOD_BIT_QCOM 0x00000004 +#define GL_MAX_SHADER_SUBSAMPLED_IMAGE_UNITS_QCOM 0x8FA1 +#endif /* GL_QCOM_texture_foveated_subsampled_layout */ + +#ifndef GL_QCOM_tiled_rendering +#define GL_QCOM_tiled_rendering 1 +#define GL_COLOR_BUFFER_BIT0_QCOM 0x00000001 +#define GL_COLOR_BUFFER_BIT1_QCOM 0x00000002 +#define GL_COLOR_BUFFER_BIT2_QCOM 0x00000004 +#define GL_COLOR_BUFFER_BIT3_QCOM 0x00000008 +#define GL_COLOR_BUFFER_BIT4_QCOM 0x00000010 +#define GL_COLOR_BUFFER_BIT5_QCOM 0x00000020 +#define GL_COLOR_BUFFER_BIT6_QCOM 0x00000040 +#define GL_COLOR_BUFFER_BIT7_QCOM 0x00000080 +#define GL_DEPTH_BUFFER_BIT0_QCOM 0x00000100 +#define GL_DEPTH_BUFFER_BIT1_QCOM 0x00000200 +#define GL_DEPTH_BUFFER_BIT2_QCOM 0x00000400 +#define GL_DEPTH_BUFFER_BIT3_QCOM 0x00000800 +#define GL_DEPTH_BUFFER_BIT4_QCOM 0x00001000 +#define GL_DEPTH_BUFFER_BIT5_QCOM 0x00002000 +#define GL_DEPTH_BUFFER_BIT6_QCOM 0x00004000 +#define GL_DEPTH_BUFFER_BIT7_QCOM 0x00008000 +#define GL_STENCIL_BUFFER_BIT0_QCOM 0x00010000 +#define GL_STENCIL_BUFFER_BIT1_QCOM 0x00020000 +#define GL_STENCIL_BUFFER_BIT2_QCOM 0x00040000 +#define GL_STENCIL_BUFFER_BIT3_QCOM 0x00080000 +#define GL_STENCIL_BUFFER_BIT4_QCOM 0x00100000 +#define GL_STENCIL_BUFFER_BIT5_QCOM 0x00200000 +#define GL_STENCIL_BUFFER_BIT6_QCOM 0x00400000 +#define GL_STENCIL_BUFFER_BIT7_QCOM 0x00800000 +#define GL_MULTISAMPLE_BUFFER_BIT0_QCOM 0x01000000 +#define GL_MULTISAMPLE_BUFFER_BIT1_QCOM 0x02000000 +#define GL_MULTISAMPLE_BUFFER_BIT2_QCOM 0x04000000 +#define GL_MULTISAMPLE_BUFFER_BIT3_QCOM 0x08000000 +#define GL_MULTISAMPLE_BUFFER_BIT4_QCOM 0x10000000 +#define GL_MULTISAMPLE_BUFFER_BIT5_QCOM 0x20000000 +#define GL_MULTISAMPLE_BUFFER_BIT6_QCOM 0x40000000 +#define GL_MULTISAMPLE_BUFFER_BIT7_QCOM 0x80000000 +typedef void (GL_APIENTRYP PFNGLSTARTTILINGQCOMPROC) (GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask); +typedef void (GL_APIENTRYP PFNGLENDTILINGQCOMPROC) (GLbitfield preserveMask); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glStartTilingQCOM (GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask); +GL_APICALL void GL_APIENTRY glEndTilingQCOM (GLbitfield preserveMask); +#endif +#endif /* GL_QCOM_tiled_rendering */ + +#ifndef GL_QCOM_writeonly_rendering +#define GL_QCOM_writeonly_rendering 1 +#define GL_WRITEONLY_RENDERING_QCOM 0x8823 +#endif /* GL_QCOM_writeonly_rendering */ + +#ifndef GL_VIV_shader_binary +#define GL_VIV_shader_binary 1 +#define GL_SHADER_BINARY_VIV 0x8FC4 +#endif /* GL_VIV_shader_binary */ + +/* ANGLE GLES2 extensions */ +#include "gl2ext_angle.h" + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/GLES2/gl2ext_angle.h b/gfx/angle/checkout/include/GLES2/gl2ext_angle.h new file mode 100644 index 0000000000..4d701a39c7 --- /dev/null +++ b/gfx/angle/checkout/include/GLES2/gl2ext_angle.h @@ -0,0 +1,667 @@ +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// gl2ext_angle.h: ANGLE modifications to the gl2ext.h header file. +// Currently we don't include this file directly, we patch gl2ext.h +// to include it implicitly so it is visible throughout our code. + +#ifndef INCLUDE_GLES2_GL2EXT_ANGLE_H_ +#define INCLUDE_GLES2_GL2EXT_ANGLE_H_ + +// clang-format off + +#ifndef GL_ANGLE_client_arrays +#define GL_ANGLE_client_arrays 1 +#define GL_CLIENT_ARRAYS_ANGLE 0x93AA +#endif /* GL_ANGLE_client_arrays */ + +#ifndef GL_ANGLE_request_extension +#define GL_ANGLE_request_extension 1 +#define GL_REQUESTABLE_EXTENSIONS_ANGLE 0x93A8 +#define GL_NUM_REQUESTABLE_EXTENSIONS_ANGLE 0x93A9 +typedef void (GL_APIENTRYP PFNGLREQUESTEXTENSIONANGLEPROC) (const GLchar *name); +typedef void (GL_APIENTRYP PFNGLDISABLEEXTENSIONANGLEPROC) (const GLchar *name); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glRequestExtensionANGLE (const GLchar *name); +#endif +#endif /* GL_ANGLE_webgl_compatibility */ + +#ifndef GL_ANGLE_robust_resource_initialization +#define GL_ANGLE_robust_resource_initialization 1 +#define GL_ROBUST_RESOURCE_INITIALIZATION_ANGLE 0x93AB +#define GL_RESOURCE_INITIALIZED_ANGLE 0x969F +#endif /* GL_ANGLE_robust_resource_initialization */ + +#ifndef GL_ANGLE_provoking_vertex +#define GL_ANGLE_provoking_vertex 1 +#define GL_FIRST_VERTEX_CONVENTION 0x8E4D +#define GL_LAST_VERTEX_CONVENTION 0x8E4E +#define GL_PROVOKING_VERTEX 0x8E4F +typedef void (GL_APIENTRYP PFNGLPROVOKINGVERTEXANGLEPROC) (GLenum); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glProvokingVertexANGLE(GLenum mode); +#endif +#endif /* GL_ANGLE_provoking_vertex */ + +#ifndef GL_CHROMIUM_framebuffer_mixed_samples +#define GL_CHROMIUM_frambuffer_mixed_samples 1 +#define GL_COVERAGE_MODULATION_CHROMIUM 0x9332 +typedef void (GL_APIENTRYP PFNGLCOVERAGEMODULATIONCHROMIUMPROC) (GLenum components); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCoverageModulationCHROMIUM(GLenum components); +#endif +#endif /* GL_CHROMIUM_framebuffer_mixed_samples */ + +#ifndef GL_CHROMIUM_bind_generates_resource +#define GL_CHROMIUM_bind_generates_resource 1 +#define GL_BIND_GENERATES_RESOURCE_CHROMIUM 0x9244 +#endif /* GL_CHROMIUM_bind_generates_resource */ + +#ifndef GL_ANGLE_memory_size +#define GL_ANGLE_memory_size +#define GL_MEMORY_SIZE_ANGLE 0x93AD +#endif /* GL_ANGLE_memory_size */ + +// needed by NV_path_rendering (and thus CHROMIUM_path_rendering) +// but CHROMIUM_path_rendering only needs MatrixLoadfEXT, MatrixLoadIdentityEXT +#ifndef GL_EXT_direct_state_access +#define GL_EXT_direct_state_access 1 +typedef void(GL_APIENTRYP PFNGLMATRIXLOADFEXTPROC)(GLenum matrixMode, const GLfloat *m); +typedef void(GL_APIENTRYP PFNGLMATRIXLOADIDENTITYEXTPROC)(GLenum matrixMode); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glMatrixLoadfEXT(GLenum matrixMode, const GLfloat *m); +GL_APICALL void GL_APIENTRY glMatrixLoadIdentityEXT(GLenum matrixMode); +#endif +#endif /* GL_EXT_direct_state_access */ + +#ifndef GL_CHROMIUM_copy_texture +#define GL_CHROMIUM_copy_texture 1 +typedef void(GL_APIENTRYP PFNGLCOPYTEXTURECHROMIUMPROC)(GLuint sourceId, + GLint sourceLevel, + GLenum destTarget, + GLuint destId, + GLint destLevel, + GLint internalFormat, + GLenum destType, + GLboolean unpackFlipY, + GLboolean unpackPremultiplyAlpha, + GLboolean unpackUnmultiplyAlpha); +typedef void(GL_APIENTRYP PFNGLCOPYSUBTEXTURECHROMIUMPROC)(GLuint sourceId, + GLint sourceLevel, + GLenum destTarget, + GLuint destId, + GLint destLevel, + GLint xoffset, + GLint yoffset, + GLint x, + GLint y, + GLsizei width, + GLsizei height, + GLboolean unpackFlipY, + GLboolean unpackPremultiplyAlpha, + GLboolean unpackUnmultiplyAlpha); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCopyTextureCHROMIUM(GLuint sourceId, + GLint sourceLevel, + GLenum destTarget, + GLuint destId, + GLint destLevel, + GLint internalFormat, + GLenum destType, + GLboolean unpackFlipY, + GLboolean unpackPremultiplyAlpha, + GLboolean unpackUnmultiplyAlpha); +GL_APICALL void GL_APIENTRY glCopySubTextureCHROMIUM(GLuint sourceId, + GLint sourceLevel, + GLenum destTarget, + GLuint destId, + GLint destLevel, + GLint xoffset, + GLint yoffset, + GLint x, + GLint y, + GLsizei width, + GLsizei height, + GLboolean unpackFlipY, + GLboolean unpackPremultiplyAlpha, + GLboolean unpackUnmultiplyAlpha); +#endif +#endif /* GL_CHROMIUM_copy_texture */ + +#ifndef GL_CHROMIUM_compressed_copy_texture +#define GL_CHROMIUM_compressed_copy_texture 1 +typedef void(GL_APIENTRYP PFNGLCOMPRESSEDCOPYTEXTURECHROMIUMPROC)(GLuint sourceId, GLuint destId); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCompressedCopyTextureCHROMIUM(GLuint sourceId, GLuint destId); +#endif +#endif /* GL_CHROMIUM_compressed_copy_texture */ + + +#ifndef GL_ANGLE_copy_texture_3d +#define GL_ANGLE_copy_texture_3d 1 +typedef void(GL_APIENTRYP PFNGLCOPYTEXTURE3DANGLEPROC)(GLuint sourceId, + GLint sourceLevel, + GLenum destTarget, + GLuint destId, + GLint destLevel, + GLint internalFormat, + GLenum destType, + GLboolean unpackFlipY, + GLboolean unpackPremultiplyAlpha, + GLboolean unpackUnmultiplyAlpha); +typedef void(GL_APIENTRYP PFNGLCOPYSUBTEXTURE3DANGLEPROC)(GLuint sourceId, + GLint sourceLevel, + GLenum destTarget, + GLuint destId, + GLint destLevel, + GLint xoffset, + GLint yoffset, + GLint zoffset, + GLint x, + GLint y, + GLint z, + GLsizei width, + GLsizei height, + GLsizei depth, + GLboolean unpackFlipY, + GLboolean unpackPremultiplyAlpha, + GLboolean unpackUnmultiplyAlpha); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glCopyTexture3DANGLE(GLuint sourceId, + GLint sourceLevel, + GLenum destTarget, + GLuint destId, + GLint destLevel, + GLint internalFormat, + GLenum destType, + GLboolean unpackFlipY, + GLboolean unpackPremultiplyAlpha, + GLboolean unpackUnmultiplyAlpha); +GL_APICALL void GL_APIENTRY glCopySubTexture3DANGLE(GLuint sourceId, + GLint sourceLevel, + GLenum destTarget, + GLuint destId, + GLint destLevel, + GLint xoffset, + GLint yoffset, + GLint zoffset, + GLint x, + GLint y, + GLint z, + GLsizei width, + GLsizei height, + GLsizei depth, + GLboolean unpackFlipY, + GLboolean unpackPremultiplyAlpha, + GLboolean unpackUnmultiplyAlpha); +#endif +#endif /* GL_ANGLE_copy_texture_3d */ + +#ifndef GL_CHROMIUM_sync_query +#define GL_CHROMIUM_sync_query 1 +#define GL_COMMANDS_COMPLETED_CHROMIUM 0x84F7 +#endif /* GL_CHROMIUM_sync_query */ + +#ifndef GL_EXT_texture_compression_s3tc_srgb +#define GL_EXT_texture_compression_s3tc_srgb 1 +#define GL_COMPRESSED_SRGB_S3TC_DXT1_EXT 0x8C4C +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT 0x8C4D +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT 0x8C4E +#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT 0x8C4F +#endif /* GL_EXT_texture_compression_s3tc_srgb */ + +#ifndef GL_ANGLE_lossy_etc_decode +#define GL_ANGLE_lossy_etc_decode 1 +#define GL_ETC1_RGB8_LOSSY_DECODE_ANGLE 0x9690 +#define GL_COMPRESSED_R11_LOSSY_DECODE_EAC_ANGLE 0x9691 +#define GL_COMPRESSED_SIGNED_R11_LOSSY_DECODE_EAC_ANGLE 0x9692 +#define GL_COMPRESSED_RG11_LOSSY_DECODE_EAC_ANGLE 0x9693 +#define GL_COMPRESSED_SIGNED_RG11_LOSSY_DECODE_EAC_ANGLE 0x9694 +#define GL_COMPRESSED_RGB8_LOSSY_DECODE_ETC2_ANGLE 0x9695 +#define GL_COMPRESSED_SRGB8_LOSSY_DECODE_ETC2_ANGLE 0x9696 +#define GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_LOSSY_DECODE_ETC2_ANGLE 0x9697 +#define GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_LOSSY_DECODE_ETC2_ANGLE 0x9698 +#define GL_COMPRESSED_RGBA8_LOSSY_DECODE_ETC2_EAC_ANGLE 0x9699 +#define GL_COMPRESSED_SRGB8_ALPHA8_LOSSY_DECODE_ETC2_EAC_ANGLE 0x969A +#endif /* GL_ANGLE_lossy_etc_decode */ + +#ifndef GL_ANGLE_robust_client_memory +#define GL_ANGLE_robust_client_memory 1 +typedef void (GL_APIENTRYP PFNGLGETBOOLEANVROBUSTANGLEPROC) (GLenum pname, GLsizei bufSize, GLsizei *length, GLboolean *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETFLOATVROBUSTANGLEPROC) (GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *data); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVROBUSTANGLEPROC) (GLenum target, GLenum attachment, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETINTEGERVROBUSTANGLEPROC) (GLenum pname, GLsizei bufSize, GLsizei *length, GLint *data); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMIVROBUSTANGLEPROC) (GLuint program, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSHADERIVROBUSTANGLEPROC) (GLuint shader, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERFVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMFVROBUSTANGLEPROC) (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMIVROBUSTANGLEPROC) (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBFVROBUSTANGLEPROC) (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIVROBUSTANGLEPROC) (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVROBUSTANGLEPROC) (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, void **pointer); +typedef void (GL_APIENTRYP PFNGLREADPIXELSROBUSTANGLEPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, GLsizei *length, GLsizei *columns, GLsizei *rows, void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE2DROBUSTANGLEPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, GLsizei bufSize, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE2DROBUSTANGLEPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE3DROBUSTANGLEPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, GLsizei bufSize, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE3DROBUSTANGLEPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLsizei bufSize, const void *pixels); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DROBUSTANGLEPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, GLsizei bufSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DROBUSTANGLEPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, GLsizei bufSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DROBUSTANGLEPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, GLsizei bufSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DROBUSTANGLEPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, GLsizei bufSize, const void *data); +typedef void (GL_APIENTRYP PFNGLGETQUERYIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUIVROBUSTANGLEPROC) (GLuint id, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint *params); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, void **params); +typedef void (GL_APIENTRYP PFNGLGETINTEGERI_VROBUSTANGLEPROC) (GLenum target, GLuint index, GLsizei bufSize, GLsizei *length, GLint *data); +typedef void (GL_APIENTRYP PFNGLGETINTERNALFORMATIVROBUSTANGLEPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIIVROBUSTANGLEPROC) (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIUIVROBUSTANGLEPROC) (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMUIVROBUSTANGLEPROC) (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLuint *params); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMBLOCKIVROBUSTANGLEPROC) (GLuint program, GLuint uniformBlockIndex, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64VROBUSTANGLEPROC) (GLenum pname, GLsizei bufSize, GLsizei *length, GLint64 *data); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64I_VROBUSTANGLEPROC) (GLenum target, GLuint index, GLsizei bufSize, GLsizei *length, GLint64 *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERI64VROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint64 *params); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIVROBUSTANGLEPROC) (GLuint sampler, GLenum pname, GLsizei bufSize, const GLint *param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERFVROBUSTANGLEPROC) (GLuint sampler, GLenum pname, GLsizei bufSize, const GLfloat *param); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIVROBUSTANGLEPROC) (GLuint sampler, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERFVROBUSTANGLEPROC) (GLuint sampler, GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMINTERFACEIVROBUSTANGLEPROC) (GLuint program, GLenum programInterface, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETBOOLEANI_VROBUSTANGLEPROC) (GLenum target, GLuint index, GLsizei bufSize, GLsizei *length, GLboolean *data); +typedef void (GL_APIENTRYP PFNGLGETMULTISAMPLEFVROBUSTANGLEPROC) (GLenum pname, GLuint index, GLsizei bufSize, GLsizei *length, GLfloat *val); +typedef void (GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERIVROBUSTANGLEPROC) (GLenum target, GLint level, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERFVROBUSTANGLEPROC) (GLenum target, GLint level, GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETPOINTERVROBUSTANGLEROBUSTANGLEPROC) (GLenum pname, GLsizei bufSize, GLsizei *length, void **params); +typedef void (GL_APIENTRYP PFNGLREADNPIXELSROBUSTANGLEPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, GLsizei *length, GLsizei *columns, GLsizei *rows, void *data); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMFVROBUSTANGLEPROC) (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMIVROBUSTANGLEPROC) (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMUIVROBUSTANGLEPROC) (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLuint *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIUIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, const GLuint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIUIVROBUSTANGLEPROC) (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint *params); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIIVROBUSTANGLEPROC) (GLuint sampler, GLenum pname, GLsizei bufSize, const GLint *param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIUIVROBUSTANGLEPROC) (GLuint sampler, GLenum pname, GLsizei bufSize, const GLuint *param); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIIVROBUSTANGLEPROC) (GLuint sampler, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIUIVROBUSTANGLEPROC) (GLuint sampler, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTIVROBUSTANGLEPROC)(GLuint id, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTI64VROBUSTANGLEPROC)(GLuint id, GLenum pname, GLsizei bufSize, GLsizei *length, GLint64 *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUI64VROBUSTANGLEPROC)(GLuint id, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint64 *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetBooleanvRobustANGLE (GLenum pname, GLsizei bufSize, GLsizei *length, GLboolean *data); +GL_APICALL void GL_APIENTRY glGetBufferParameterivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetFloatvRobustANGLE (GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *data); +GL_APICALL void GL_APIENTRY glGetFramebufferAttachmentParameterivRobustANGLE (GLenum target, GLenum attachment, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetIntegervRobustANGLE (GLenum pname, GLsizei bufSize, GLsizei *length, GLint *data); +GL_APICALL void GL_APIENTRY glGetProgramivRobustANGLE (GLuint program, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetRenderbufferParameterivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetShaderivRobustANGLE (GLuint shader, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetTexParameterfvRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetTexParameterivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetUniformfvRobustANGLE (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetUniformivRobustANGLE (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribfvRobustANGLE (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribivRobustANGLE (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribPointervRobustANGLE (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, void **pointer); +GL_APICALL void GL_APIENTRY glReadPixelsRobustANGLE (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, GLsizei *length, GLsizei *columns, GLsizei *rows, void *pixels); +GL_APICALL void GL_APIENTRY glTexImage2DRobustANGLE (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, GLsizei bufSize, const void *pixels); +GL_APICALL void GL_APIENTRY glTexParameterfvRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, const GLfloat *params); +GL_APICALL void GL_APIENTRY glTexParameterivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, const GLint *params); +GL_APICALL void GL_APIENTRY glTexSubImage2DRobustANGLE (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, const void *pixels); +GL_APICALL void GL_APIENTRY glTexImage3DRobustANGLE (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, GLsizei bufSize, const void *pixels); +GL_APICALL void GL_APIENTRY glTexSubImage3DRobustANGLE (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLsizei bufSize, const void *pixels); +GL_APICALL void GL_APIENTRY glCompressedTexImage2DRobustANGLE(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, GLsizei bufSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage2DRobustANGLE(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, GLsizei bufSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexImage3DRobustANGLE(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, GLsizei bufSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage3DRobustANGLE(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, GLsizei bufSize, const void *data); +GL_APICALL void GL_APIENTRY glGetQueryivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetQueryObjectuivRobustANGLE (GLuint id, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint *params); +GL_APICALL void GL_APIENTRY glGetBufferPointervRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, void **params); +GL_APICALL void GL_APIENTRY glGetIntegeri_vRobustANGLE (GLenum target, GLuint index, GLsizei bufSize, GLsizei *length, GLint *data); +GL_APICALL void GL_APIENTRY glGetInternalformativRobustANGLE (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribIivRobustANGLE (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribIuivRobustANGLE (GLuint index, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint *params); +GL_APICALL void GL_APIENTRY glGetUniformuivRobustANGLE (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLuint *params); +GL_APICALL void GL_APIENTRY glGetActiveUniformBlockivRobustANGLE (GLuint program, GLuint uniformBlockIndex, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetInteger64vRobustANGLE (GLenum pname, GLsizei bufSize, GLsizei *length, GLint64 *data); +GL_APICALL void GL_APIENTRY glGetInteger64i_vRobustANGLE (GLenum target, GLuint index, GLsizei bufSize, GLsizei *length, GLint64 *data); +GL_APICALL void GL_APIENTRY glGetBufferParameteri64vRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint64 *params); +GL_APICALL void GL_APIENTRY glSamplerParameterivRobustANGLE (GLuint sampler, GLenum pname, GLsizei bufSize, const GLint *param); +GL_APICALL void GL_APIENTRY glSamplerParameterfvRobustANGLE (GLuint sampler, GLenum pname, GLsizei bufSize, const GLfloat *param); +GL_APICALL void GL_APIENTRY glGetSamplerParameterivRobustANGLE (GLuint sampler, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetSamplerParameterfvRobustANGLE (GLuint sampler, GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetFramebufferParameterivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetProgramInterfaceivRobustANGLE (GLuint program, GLenum programInterface, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetBooleani_vRobustANGLE (GLenum target, GLuint index, GLsizei bufSize, GLsizei *length, GLboolean *data); +GL_APICALL void GL_APIENTRY glGetMultisamplefvRobustANGLE (GLenum pname, GLuint index, GLsizei bufSize, GLsizei *length, GLfloat *val); +GL_APICALL void GL_APIENTRY glGetTexLevelParameterivRobustANGLE (GLenum target, GLint level, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetTexLevelParameterfvRobustANGLE (GLenum target, GLint level, GLenum pname, GLsizei bufSize, GLsizei *length, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetPointervRobustANGLERobustANGLE (GLenum pname, GLsizei bufSize, GLsizei *length, void **params); +GL_APICALL void GL_APIENTRY glReadnPixelsRobustANGLE (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, GLsizei *length, GLsizei *columns, GLsizei *rows, void *data); +GL_APICALL void GL_APIENTRY glGetnUniformfvRobustANGLE (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetnUniformivRobustANGLE (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetnUniformuivRobustANGLE (GLuint program, GLint location, GLsizei bufSize, GLsizei *length, GLuint *params); +GL_APICALL void GL_APIENTRY glTexParameterIivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, const GLint *params); +GL_APICALL void GL_APIENTRY glTexParameterIuivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, const GLuint *params); +GL_APICALL void GL_APIENTRY glGetTexParameterIivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetTexParameterIuivRobustANGLE (GLenum target, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint *params); +GL_APICALL void GL_APIENTRY glSamplerParameterIivRobustANGLE (GLuint sampler, GLenum pname, GLsizei bufSize, const GLint *param); +GL_APICALL void GL_APIENTRY glSamplerParameterIuivRobustANGLE (GLuint sampler, GLenum pname, GLsizei bufSize, const GLuint *param); +GL_APICALL void GL_APIENTRY glGetSamplerParameterIivRobustANGLE (GLuint sampler, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetSamplerParameterIuivRobustANGLE (GLuint sampler, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint *params); +GL_APICALL void GL_APIENTRY glGetQueryObjectivRobustANGLE(GLuint id, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL void GL_APIENTRY glGetQueryObjecti64vRobustANGLE(GLuint id, GLenum pname, GLsizei bufSize, GLsizei *length, GLint64 *params); +GL_APICALL void GL_APIENTRY glGetQueryObjectui64vRobustANGLE(GLuint id, GLenum pname, GLsizei bufSize, GLsizei *length, GLuint64 *params); +#endif +#endif /* GL_ANGLE_robust_client_memory */ + +#ifndef GL_ANGLE_program_cache_control +#define GL_ANGLE_program_cache_control 1 +#define GL_PROGRAM_CACHE_ENABLED_ANGLE 0x93AC +#endif /* GL_ANGLE_program_cache_control */ + +#ifndef GL_ANGLE_texture_rectangle +#define GL_ANGLE_texture_rectangle 1 +#define GL_MAX_RECTANGLE_TEXTURE_SIZE_ANGLE 0x84F8 +#define GL_TEXTURE_RECTANGLE_ANGLE 0x84F5 +#define GL_TEXTURE_BINDING_RECTANGLE_ANGLE 0x84F6 +#define GL_SAMPLER_2D_RECT_ANGLE 0x8B63 +#endif /* GL_ANGLE_texture_rectangle */ + +#ifndef GL_ANGLE_texture_multisample +#define GL_ANGLE_texture_multisample 1 +#define GL_SAMPLE_POSITION_ANGLE 0x8E50 +#define GL_SAMPLE_MASK_ANGLE 0x8E51 +#define GL_SAMPLE_MASK_VALUE_ANGLE 0x8E52 +#define GL_TEXTURE_2D_MULTISAMPLE_ANGLE 0x9100 +#define GL_MAX_SAMPLE_MASK_WORDS_ANGLE 0x8E59 +#define GL_MAX_COLOR_TEXTURE_SAMPLES_ANGLE 0x910E +#define GL_MAX_DEPTH_TEXTURE_SAMPLES_ANGLE 0x910F +#define GL_MAX_INTEGER_SAMPLES_ANGLE 0x9110 +#define GL_TEXTURE_BINDING_2D_MULTISAMPLE_ANGLE 0x9104 +#define GL_TEXTURE_SAMPLES_ANGLE 0x9106 +#define GL_TEXTURE_FIXED_SAMPLE_LOCATIONS_ANGLE 0x9107 +typedef void(GL_APIENTRYP PFNGLTEXSTORAGE2DMULTISAMPLEANGLEPROC)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +typedef void(GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERFVANGLEPROC)(GLenum target, GLint level, GLenum pname, GLfloat *params); +typedef void(GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERIVANGLEPROC)(GLenum target, GLint level, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETMULTISAMPLEFVANGLEPROC)(GLenum pname, GLuint index, GLfloat *val); +typedef void (GL_APIENTRYP PFNGLSAMPLEMASKIANGLEPROC)(GLuint maskNumber, GLbitfield mask); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexStorage2DMultisampleANGLE(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +GL_APICALL void GL_APIENTRY glGetTexLevelParameterfvANGLE(GLenum target, GLint level, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetTexLevelParameterivANGLE(GLenum target, GLint level, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetMultisamplefvANGLE(GLenum pname, GLuint index, GLfloat *val); +GL_APICALL void GL_APIENTRY glSampleMaskiANGLE(GLuint maskNumber, GLbitfield mask); +#endif +#endif // !GL_ANGLE_texture_multisample + +#ifndef GL_ANGLE_get_tex_level_parameter +#define GL_ANGLE_get_tex_level_parameter 1 +typedef void(GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERFVANGLEPROC)(GLenum target, GLint level, GLenum pname, GLfloat *params); +typedef void(GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERIVANGLEPROC)(GLenum target, GLint level, GLenum pname, GLint *params); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetTexLevelParameterfvANGLE(GLenum target, GLint level, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetTexLevelParameterivANGLE(GLenum target, GLint level, GLenum pname, GLint *params); +#endif +#endif /* GL_ANGLE_get_tex_level_parameter */ + +#ifndef GL_ANGLE_multi_draw +#define GL_ANGLE_multi_draw 1 +typedef void (GL_APIENTRYP PFNGLMULTIDRAWARRAYSANGLEPROC) (GLenum mode, const GLint *firsts, const GLsizei *counts, GLsizei drawcount); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWARRAYSINSTANCEDANGLEPROC) (GLenum mode, const GLint *firsts, const GLsizei *counts, const GLsizei *instanceCounts, GLsizei drawcount); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSANGLEPROC) (GLenum mode, const GLsizei *counts, GLenum type, const GLvoid* const *indices, GLsizei drawcount); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSINSTANCEDANGLEPROC) (GLenum mode, const GLsizei *counts, GLenum type, const GLvoid* const *indices, const GLsizei *instanceCounts, GLsizei drawcount); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glMultiDrawArraysANGLE (GLenum mode, const GLint *firsts, const GLsizei *counts, GLsizei drawcount); +GL_APICALL void GL_APIENTRY glMultiDrawArraysInstancedANGLE (GLenum mode, const GLint *firsts, const GLsizei *counts, const GLsizei *instanceCounts, GLsizei drawcount); +GL_APICALL void GL_APIENTRY glMultiDrawElementsANGLE (GLenum mode, const GLsizei *counts, GLenum type, const GLvoid* const *indices, GLsizei drawcount); +GL_APICALL void GL_APIENTRY glMultiDrawElementsInstancedANGLE (GLenum mode, const GLsizei *counts, GLenum type, const GLvoid* const *indices, const GLsizei *instanceCounts, GLsizei drawcount); +#endif +#endif /* GL_ANGLE_multi_draw */ + +#ifndef GL_ANGLE_base_vertex_base_instance +#define GL_ANGLE_base_vertex_base_instance 1 +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDBASEINSTANCEANGLEPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instanceCount, GLuint baseInstance); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEANGLEPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instanceCount, GLint baseVertex, GLuint baseInstance); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWARRAYSINSTANCEDBASEINSTANCEANGLEPROC) (GLenum mode, const GLsizei *firsts, const GLsizei *counts, const GLsizei *instanceCounts, const GLuint *baseInstances, GLsizei drawCount); +typedef void (GL_APIENTRYP PFNGLMULTIDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEANGLEPROC) (GLenum mode, const GLsizei *counts, GLenum type, const GLvoid* const *indices, const GLsizei *instanceCounts, const GLint *baseVertices, const GLuint *baseInstances, GLsizei drawCount); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glDrawArraysInstancedBaseInstanceANGLE (GLenum mode, GLint first, GLsizei count, GLsizei instanceCount, GLuint baseInstance); +GL_APICALL void GL_APIENTRY glDrawElementsInstancedBaseVertexBaseInstanceANGLE (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instanceCount, GLint baseVertex, GLuint baseInstance); +GL_APICALL void GL_APIENTRY glMultiDrawArraysInstancedBaseInstanceANGLE (GLenum mode, const GLsizei *firsts, const GLsizei *counts, const GLsizei *instanceCounts, const GLuint *baseInstances, GLsizei drawCount); +GL_APICALL void GL_APIENTRY glMultiDrawElementsInstancedBaseVertexBaseInstanceANGLE (GLenum mode, const GLsizei *counts, GLenum type, const GLvoid* const *indices, const GLsizei *instanceCounts, const GLint *baseVertices, const GLuint *baseInstances, GLsizei drawCount); +#endif +#endif + +#ifndef GL_CHROMIUM_bind_uniform_location +#define GL_CHROMIUM_bind_uniform_location 1 +typedef void (GL_APIENTRYP PFNGLBINDUNIFORMLOCATIONCHROMIUMPROC)(GLuint program, GLint location, const GLchar *name); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glBindUniformLocationCHROMIUM(GLuint program, GLint location, const GLchar *name); +#endif +#endif /* GL_CHROMIUM_bind_uniform_location */ + +/* GL_CHROMIUM_lose_context */ +#ifndef GL_CHROMIUM_lose_context +#define GL_CHROMIUM_lose_context 1 +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glLoseContextCHROMIUM(GLenum current, GLenum other); +#endif +typedef void (GL_APIENTRYP PFNGLLOSECONTEXTCHROMIUMPROC) (GLenum current, GLenum other); +#endif /* GL_CHROMIUM_lose_context */ + +#ifndef GL_ANGLE_texture_external_update +#define GL_ANGLE_texture_external_update 1 +#define GL_TEXTURE_NATIVE_ID_ANGLE 0x3481 +typedef void (GL_APIENTRYP PFNGLTEXIMAGE2DEXTERNALANGLEPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type); +typedef void (GL_APIENTRYP PFNGLINVALIDATETEXTUREANGLEPROC) (GLenum target); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexImage2DExternalANGLE (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type); +GL_APICALL void GL_APIENTRY glInvalidateTextureANGLE (GLenum target); +#endif +#endif /* GL_ANGLE_texture_external_update */ + +#ifndef GL_ANGLE_get_image +#define GL_ANGLE_get_image +typedef void (GL_APIENTRYP PFNGLGETTEXIMAGEANGLEPROC) (GLenum target, GLint level, GLenum format, GLenum type, void *pixels); +typedef void (GL_APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEANGLEPROC) (GLenum target, GLint level, void *pixels); +typedef void (GL_APIENTRYP PFNGLGETRENDERBUFFERIMAGEANGLEPROC) (GLenum target, GLenum format, GLenum type, void *pixels); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glGetTexImageANGLE (GLenum target, GLint level, GLenum format, GLenum type, void *pixels); +GL_APICALL void GL_APIENTRY glGetCompressedTexImageANGLE (GLenum target, GLint level, void *pixels); +GL_APICALL void GL_APIENTRY glGetRenderbufferImageANGLE (GLenum target, GLenum format, GLenum type, void *pixels); +#endif +#endif /* GL_ANGLE_get_image */ + +#ifndef GL_WEBGL_video_texture +#define GL_WEBGL_video_texture 1 +#define GL_TEXTURE_VIDEO_IMAGE_WEBGL 0x9248 +#define GL_SAMPLER_VIDEO_IMAGE_WEBGL 0x9249 +#endif /* GL_WEBGL_video_texture */ + +#ifndef GL_ANGLE_memory_object_flags +#define GL_ANGLE_memory_object_flags 1 +#define GL_CREATE_SPARSE_BINDING_BIT_ANGLE 0x00000001 +#define GL_CREATE_SPARSE_RESIDENCY_BIT_ANGLE 0x00000002 +#define GL_CREATE_SPARSE_ALIASED_BIT_ANGLE 0x00000004 +#define GL_CREATE_MUTABLE_FORMAT_BIT_ANGLE 0x00000008 +#define GL_CREATE_CUBE_COMPATIBLE_BIT_ANGLE 0x00000010 +#define GL_CREATE_ALIAS_BIT_ANGLE 0x00000400 +#define GL_CREATE_SPLIT_INSTANCE_BIND_REGIONS_BIT_ANGLE 0x00000040 +#define GL_CREATE_2D_ARRAY_COMPATIBLE_BIT_ANGLE 0x00000020 +#define GL_CREATE_BLOCK_TEXEL_VIEW_COMPATIBLE_BIT_ANGLE 0x00000080 +#define GL_CREATE_EXTENDED_USAGE_BIT_ANGLE 0x00000100 +#define GL_CREATE_PROTECTED_BIT_ANGLE 0x00000800 +#define GL_CREATE_DISJOINT_BIT_ANGLE 0x00000200 +#define GL_CREATE_CORNER_SAMPLED_BIT_ANGLE 0x00002000 +#define GL_CREATE_SAMPLE_LOCATIONS_COMPATIBLE_DEPTH_BIT_ANGLE 0x00001000 +#define GL_CREATE_SUBSAMPLED_BIT_ANGLE 0x00004000 +#define GL_USAGE_TRANSFER_SRC_BIT_ANGLE 0x00000001 +#define GL_USAGE_TRANSFER_DST_BIT_ANGLE 0x00000002 +#define GL_USAGE_SAMPLED_BIT_ANGLE 0x00000004 +#define GL_USAGE_STORAGE_BIT_ANGLE 0x00000008 +#define GL_USAGE_COLOR_ATTACHMENT_BIT_ANGLE 0x00000010 +#define GL_USAGE_DEPTH_STENCIL_ATTACHMENT_BIT_ANGLE 0x00000020 +#define GL_USAGE_TRANSIENT_ATTACHMENT_BIT_ANGLE 0x00000040 +#define GL_USAGE_INPUT_ATTACHMENT_BIT_ANGLE 0x00000080 +#define GL_USAGE_SHADING_RATE_IMAGE_BIT_ANGLE 0x00000100 +#define GL_USAGE_FRAGMENT_DENSITY_MAP_BIT_ANGLE 0x00000200 +typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEMFLAGS2DANGLEPROC) (GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLuint memory, GLuint64 offset, GLbitfield createFlags, GLbitfield usageFlags, const void *imageCreateInfoPNext); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEMFLAGS2DMULTISAMPLEANGLEPROC) (GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset, GLbitfield createFlags, GLbitfield usageFlags, const void *imageCreateInfoPNext); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEMFLAGS3DANGLEPROC) (GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLbitfield createFlags, GLbitfield usageFlags, const void *imageCreateInfoPNext); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGEMEMFLAGS3DMULTISAMPLEANGLEPROC) (GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset, GLbitfield createFlags, GLbitfield usageFlags, const void *imageCreateInfoPNext); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glTexStorageMemFlags2DANGLE (GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLuint memory, GLuint64 offset, GLbitfield createFlags, GLbitfield usageFlags, const void *imageCreateInfoPNext); +GL_APICALL void GL_APIENTRY glTexStorageMemFlags2DMultisampleANGLE (GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset, GLbitfield createFlags, GLbitfield usageFlags, const void *imageCreateInfoPNext); +GL_APICALL void GL_APIENTRY glTexStorageMemFlags3DANGLE (GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLuint memory, GLuint64 offset, GLbitfield createFlags, GLbitfield usageFlags, const void *imageCreateInfoPNext); +GL_APICALL void GL_APIENTRY glTexStorageMemFlags3DMultisampleANGLE (GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations, GLuint memory, GLuint64 offset, GLbitfield createFlags, GLbitfield usageFlags, const void *imageCreateInfoPNext); +#endif +#endif /* GL_ANGLE_memory_object_flags */ + +#ifndef GL_ANGLE_memory_object_fuchsia +#define GL_ANGLE_memory_object_fuchsia 1 +#define GL_HANDLE_TYPE_ZIRCON_VMO_ANGLE 0x93AE +typedef void(GL_APIENTRYP PFNGLIMPORTMEMORYZIRCONHANDLEANGLEPROC)(GLuint memory, + GLuint64 size, + GLenum handleType, + GLuint handle); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glImportMemoryZirconHandleANGLE(GLuint memory, + GLuint64 size, + GLenum handleType, + GLuint handle); +#endif +#endif /* GL_ANGLE_memory_object_fuchsia */ + +#ifndef GL_ANGLE_semaphore_fuchsia +#define GL_ANGLE_semaphore_fuchsia 1 +#define GL_HANDLE_TYPE_ZIRCON_EVENT_ANGLE 0x93AF +typedef void(GL_APIENTRYP PFNGLIMPORTSEMAPHOREZIRCONHANDLEANGLEPROC)(GLuint semaphore, + GLenum handleType, + GLuint handle); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glImportSemaphoreZirconHandleANGLE(GLuint memory, + GLenum handleType, + GLuint handle); +#endif +#endif /* GL_ANGLE_semaphore_fuchsia */ + +#ifndef GL_ANGLE_vulkan_image +#define GL_ANGLE_vulkan_image 1 +typedef void(GL_APIENTRYP PFNGLACQUIRETEXTURESANGLEPROC)(GLuint numTexture, const GLuint *textures, const GLenum *layouts); +typedef void(GL_APIENTRYP PFNGLRELEASETEXTURESANGLEPROC)(GLuint numTexture, const GLuint *textures, GLenum *layouts); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glAcquireTexturesANGLE(GLuint numTexture, const GLuint *textures, const GLenum *layouts); +GL_APICALL void GL_APIENTRY glReleaseTexturesANGLE(GLuint numTexture, const GLuint *textures, GLenum *layouts); +#endif +#endif /* GL_ANGLE_vulkan_image */ + +#ifndef GL_CHROMIUM_texture_filtering_hint +#define GL_CHROMIUM_texture_filtering_hint +#define GL_TEXTURE_FILTERING_HINT_CHROMIUM 0x8AF0 +#endif /* GL_CHROMIUM_texture_filtering_hint */ + +#ifndef GL_NV_robustness_video_memory +#define GL_NV_robustness_video_memory +#define GL_PURGED_CONTEXT_RESET_NV 0x92BB +#endif /* GL_NV_robustness_video_memory */ + +#ifndef GL_ANGLE_get_serialized_context_string +#define GL_ANGLE_get_serialized_context_string +#define GL_SERIALIZED_CONTEXT_STRING_ANGLE 0x96B0 +#endif /* GL_ANGLE_get_serialized_context_string */ + +#ifndef GL_ANGLE_robust_fragment_shader_output +#define GL_ANGLE_robust_fragment_shader_output +#define GL_ROBUST_FRAGMENT_SHADER_OUTPUT_ANGLE 0x96B9 +#endif /* GL_ANGLE_robust_fragment_shader_output */ + +#ifndef GL_ANGLE_shader_pixel_local_storage +#define GL_ANGLE_shader_pixel_local_storage 1 +#define GL_MAX_PIXEL_LOCAL_STORAGE_PLANES_ANGLE 0x96E0 +#define GL_MAX_COLOR_ATTACHMENTS_WITH_ACTIVE_PIXEL_LOCAL_STORAGE_ANGLE 0x96E1 +#define GL_MAX_COMBINED_DRAW_BUFFERS_AND_PIXEL_LOCAL_STORAGE_PLANES_ANGLE 0x96E2 +#define GL_PIXEL_LOCAL_STORAGE_ACTIVE_ANGLE 0x96E3 +#define GL_PIXEL_LOCAL_FORMAT_ANGLE 0x96E4 +#define GL_PIXEL_LOCAL_TEXTURE_NAME_ANGLE 0x96E5 +#define GL_PIXEL_LOCAL_TEXTURE_LEVEL_ANGLE 0x96E6 +#define GL_PIXEL_LOCAL_TEXTURE_LAYER_ANGLE 0x96E7 +#define GL_CLEAR_ANGLE 0x96E8 +#define GL_DISABLE_ANGLE 0x96E9 +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERMEMORYLESSPIXELLOCALSTORAGEANGLEPROC) (GLint plane, GLenum internalformat); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTUREPIXELLOCALSTORAGEANGLEPROC) (GLint plane, GLuint backingtexture, GLint level, GLint layer); +typedef void (GL_APIENTRYP PFNGLBEGINPIXELLOCALSTORAGEANGLEPROC) (GLsizei planes, const GLenum loadops[], const void *cleardata); +typedef void (GL_APIENTRYP PFNGLENDPIXELLOCALSTORAGEANGLEPROC) (); +typedef void (GL_APIENTRYP PFNGLPIXELLOCALSTORAGEBARRIERANGLEPROC) (); +#ifdef GL_GLEXT_PROTOTYPES +GL_APICALL void GL_APIENTRY glFramebufferMemorylessPixelLocalStorageANGLE (GLint plane, GLenum internalformat); +GL_APICALL void GL_APIENTRY glFramebufferTexturePixelLocalStorageANGLE (GLint plane, GLuint backingtexture, GLint level, GLint layer); +GL_APICALL void GL_APIENTRY glBeginPixelLocalStorageANGLE (GLsizei planes, const GLenum loadops[], const void *cleardata); +GL_APICALL void GL_APIENTRY glEndPixelLocalStorageANGLE (); +GL_APICALL void GL_APIENTRY glPixelLocalStorageBarrierANGLE (); +#endif +#endif /* GL_ANGLE_shader_pixel_local_storage */ + +// clang-format on + +#ifndef GL_ANGLE_yuv_internal_format +#define GL_ANGLE_yuv_internal_format + +// YUV formats introduced by GL_ANGLE_yuv_internal_format +// 8-bit YUV formats +#define GL_G8_B8R8_2PLANE_420_UNORM_ANGLE 0x96B1 +#define GL_G8_B8_R8_3PLANE_420_UNORM_ANGLE 0x96B2 + +// 10-bit YUV formats +#define GL_G10X6_B10X6R10X6_2PLANE_420_UNORM_3PACK16_ANGLE 0x96B3 +#define GL_G10X6_B10X6_R10X6_3PLANE_420_UNORM_3PACK16_ANGLE 0x96B4 + +// 12-bit YUV formats +#define GL_G12X4_B12X4R12X4_2PLANE_420_UNORM_3PACK16_ANGLE 0x96B5 +#define GL_G12X4_B12X4_R12X4_3PLANE_420_UNORM_3PACK16_ANGLE 0x96B6 + +// 16-bit YUV formats +#define GL_G16_B16R16_2PLANE_420_UNORM_ANGLE 0x96B7 +#define GL_G16_B16_R16_3PLANE_420_UNORM_ANGLE 0x96B8 + +#endif /* GL_ANGLE_yuv_internal_format */ + +#ifndef GL_ANGLE_rgbx_internal_format +#define GL_ANGLE_rgbx_internal_format + +#define GL_RGBX8_ANGLE 0x96BA + +#endif /* GL_ANGLE_rgbx_internal_format */ + +#ifndef GL_ANGLE_logic_op +#define GL_ANGLE_logic_op + +// Enums identical to GLES1 and desktop GL +#define GL_COLOR_LOGIC_OP_ANGLE 0x0BF2 +#define GL_LOGIC_OP_CLEAR_ANGLE 0x1500 +#define GL_LOGIC_OP_AND_ANGLE 0x1501 +#define GL_LOGIC_OP_AND_REVERSE_ANGLE 0x1502 +#define GL_LOGIC_OP_COPY_ANGLE 0x1503 +#define GL_LOGIC_OP_AND_INVERTED_ANGLE 0x1504 +#define GL_LOGIC_OP_NOOP_ANGLE 0x1505 +#define GL_LOGIC_OP_XOR_ANGLE 0x1506 +#define GL_LOGIC_OP_OR_ANGLE 0x1507 +#define GL_LOGIC_OP_NOR_ANGLE 0x1508 +#define GL_LOGIC_OP_EQUIV_ANGLE 0x1509 +#define GL_LOGIC_OP_INVERT_ANGLE 0x150A +#define GL_LOGIC_OP_OR_REVERSE_ANGLE 0x150B +#define GL_LOGIC_OP_COPY_INVERTED_ANGLE 0x150C +#define GL_LOGIC_OP_OR_INVERTED_ANGLE 0x150D +#define GL_LOGIC_OP_NAND_ANGLE 0x150E +#define GL_LOGIC_OP_SET_ANGLE 0x150F +typedef void (GL_APIENTRYP PFNGLLOGICOPANGLEPROC) (GLenum); + +#endif /* GL_ANGLE_logic_op */ + +#endif // INCLUDE_GLES2_GL2EXT_ANGLE_H_ diff --git a/gfx/angle/checkout/include/GLES2/gl2platform.h b/gfx/angle/checkout/include/GLES2/gl2platform.h new file mode 100644 index 0000000000..5bcce6d89e --- /dev/null +++ b/gfx/angle/checkout/include/GLES2/gl2platform.h @@ -0,0 +1,27 @@ +#ifndef __gl2platform_h_ +#define __gl2platform_h_ + +/* +** Copyright 2017-2020 The Khronos Group Inc. +** SPDX-License-Identifier: Apache-2.0 +*/ + +/* Platform-specific types and definitions for OpenGL ES 2.X gl2.h + * + * Adopters may modify khrplatform.h and this file to suit their platform. + * Please contribute modifications back to Khronos as pull requests on the + * public github repository: + * https://github.com/KhronosGroup/OpenGL-Registry + */ + +#include + +#ifndef GL_APICALL +#define GL_APICALL KHRONOS_APICALL +#endif + +#ifndef GL_APIENTRY +#define GL_APIENTRY KHRONOS_APIENTRY +#endif + +#endif /* __gl2platform_h_ */ diff --git a/gfx/angle/checkout/include/GLES3/gl3.h b/gfx/angle/checkout/include/GLES3/gl3.h new file mode 100644 index 0000000000..6bb4d8f919 --- /dev/null +++ b/gfx/angle/checkout/include/GLES3/gl3.h @@ -0,0 +1,1192 @@ +#ifndef __gles2_gl3_h_ +#define __gles2_gl3_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright 2013-2020 The Khronos Group Inc. +** SPDX-License-Identifier: MIT +** +** This header is generated from the Khronos OpenGL / OpenGL ES XML +** API Registry. The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** https://github.com/KhronosGroup/OpenGL-Registry +*/ + +#include + +#ifndef GL_APIENTRYP +#define GL_APIENTRYP GL_APIENTRY* +#endif + +#ifndef GL_GLES_PROTOTYPES +#define GL_GLES_PROTOTYPES 1 +#endif + +/* Generated on date 20210107 */ + +/* Generated C header for: + * API: gles2 + * Profile: common + * Versions considered: 2\.[0-9]|3\.0 + * Versions emitted: .* + * Default extensions included: None + * Additional extensions included: _nomatch_^ + * Extensions removed: _nomatch_^ + */ + +#ifndef GL_ES_VERSION_2_0 +#define GL_ES_VERSION_2_0 1 +#include +typedef khronos_int8_t GLbyte; +typedef khronos_float_t GLclampf; +typedef khronos_int32_t GLfixed; +typedef khronos_int16_t GLshort; +typedef khronos_uint16_t GLushort; +typedef void GLvoid; +typedef struct __GLsync *GLsync; +typedef khronos_int64_t GLint64; +typedef khronos_uint64_t GLuint64; +typedef unsigned int GLenum; +typedef unsigned int GLuint; +typedef char GLchar; +typedef khronos_float_t GLfloat; +typedef khronos_ssize_t GLsizeiptr; +typedef khronos_intptr_t GLintptr; +typedef unsigned int GLbitfield; +typedef int GLint; +typedef unsigned char GLboolean; +typedef int GLsizei; +typedef khronos_uint8_t GLubyte; +#define GL_DEPTH_BUFFER_BIT 0x00000100 +#define GL_STENCIL_BUFFER_BIT 0x00000400 +#define GL_COLOR_BUFFER_BIT 0x00004000 +#define GL_FALSE 0 +#define GL_TRUE 1 +#define GL_POINTS 0x0000 +#define GL_LINES 0x0001 +#define GL_LINE_LOOP 0x0002 +#define GL_LINE_STRIP 0x0003 +#define GL_TRIANGLES 0x0004 +#define GL_TRIANGLE_STRIP 0x0005 +#define GL_TRIANGLE_FAN 0x0006 +#define GL_ZERO 0 +#define GL_ONE 1 +#define GL_SRC_COLOR 0x0300 +#define GL_ONE_MINUS_SRC_COLOR 0x0301 +#define GL_SRC_ALPHA 0x0302 +#define GL_ONE_MINUS_SRC_ALPHA 0x0303 +#define GL_DST_ALPHA 0x0304 +#define GL_ONE_MINUS_DST_ALPHA 0x0305 +#define GL_DST_COLOR 0x0306 +#define GL_ONE_MINUS_DST_COLOR 0x0307 +#define GL_SRC_ALPHA_SATURATE 0x0308 +#define GL_FUNC_ADD 0x8006 +#define GL_BLEND_EQUATION 0x8009 +#define GL_BLEND_EQUATION_RGB 0x8009 +#define GL_BLEND_EQUATION_ALPHA 0x883D +#define GL_FUNC_SUBTRACT 0x800A +#define GL_FUNC_REVERSE_SUBTRACT 0x800B +#define GL_BLEND_DST_RGB 0x80C8 +#define GL_BLEND_SRC_RGB 0x80C9 +#define GL_BLEND_DST_ALPHA 0x80CA +#define GL_BLEND_SRC_ALPHA 0x80CB +#define GL_CONSTANT_COLOR 0x8001 +#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002 +#define GL_CONSTANT_ALPHA 0x8003 +#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004 +#define GL_BLEND_COLOR 0x8005 +#define GL_ARRAY_BUFFER 0x8892 +#define GL_ELEMENT_ARRAY_BUFFER 0x8893 +#define GL_ARRAY_BUFFER_BINDING 0x8894 +#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895 +#define GL_STREAM_DRAW 0x88E0 +#define GL_STATIC_DRAW 0x88E4 +#define GL_DYNAMIC_DRAW 0x88E8 +#define GL_BUFFER_SIZE 0x8764 +#define GL_BUFFER_USAGE 0x8765 +#define GL_CURRENT_VERTEX_ATTRIB 0x8626 +#define GL_FRONT 0x0404 +#define GL_BACK 0x0405 +#define GL_FRONT_AND_BACK 0x0408 +#define GL_TEXTURE_2D 0x0DE1 +#define GL_CULL_FACE 0x0B44 +#define GL_BLEND 0x0BE2 +#define GL_DITHER 0x0BD0 +#define GL_STENCIL_TEST 0x0B90 +#define GL_DEPTH_TEST 0x0B71 +#define GL_SCISSOR_TEST 0x0C11 +#define GL_POLYGON_OFFSET_FILL 0x8037 +#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E +#define GL_SAMPLE_COVERAGE 0x80A0 +#define GL_NO_ERROR 0 +#define GL_INVALID_ENUM 0x0500 +#define GL_INVALID_VALUE 0x0501 +#define GL_INVALID_OPERATION 0x0502 +#define GL_OUT_OF_MEMORY 0x0505 +#define GL_CW 0x0900 +#define GL_CCW 0x0901 +#define GL_LINE_WIDTH 0x0B21 +#define GL_ALIASED_POINT_SIZE_RANGE 0x846D +#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E +#define GL_CULL_FACE_MODE 0x0B45 +#define GL_FRONT_FACE 0x0B46 +#define GL_DEPTH_RANGE 0x0B70 +#define GL_DEPTH_WRITEMASK 0x0B72 +#define GL_DEPTH_CLEAR_VALUE 0x0B73 +#define GL_DEPTH_FUNC 0x0B74 +#define GL_STENCIL_CLEAR_VALUE 0x0B91 +#define GL_STENCIL_FUNC 0x0B92 +#define GL_STENCIL_FAIL 0x0B94 +#define GL_STENCIL_PASS_DEPTH_FAIL 0x0B95 +#define GL_STENCIL_PASS_DEPTH_PASS 0x0B96 +#define GL_STENCIL_REF 0x0B97 +#define GL_STENCIL_VALUE_MASK 0x0B93 +#define GL_STENCIL_WRITEMASK 0x0B98 +#define GL_STENCIL_BACK_FUNC 0x8800 +#define GL_STENCIL_BACK_FAIL 0x8801 +#define GL_STENCIL_BACK_PASS_DEPTH_FAIL 0x8802 +#define GL_STENCIL_BACK_PASS_DEPTH_PASS 0x8803 +#define GL_STENCIL_BACK_REF 0x8CA3 +#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4 +#define GL_STENCIL_BACK_WRITEMASK 0x8CA5 +#define GL_VIEWPORT 0x0BA2 +#define GL_SCISSOR_BOX 0x0C10 +#define GL_COLOR_CLEAR_VALUE 0x0C22 +#define GL_COLOR_WRITEMASK 0x0C23 +#define GL_UNPACK_ALIGNMENT 0x0CF5 +#define GL_PACK_ALIGNMENT 0x0D05 +#define GL_MAX_TEXTURE_SIZE 0x0D33 +#define GL_MAX_VIEWPORT_DIMS 0x0D3A +#define GL_SUBPIXEL_BITS 0x0D50 +#define GL_RED_BITS 0x0D52 +#define GL_GREEN_BITS 0x0D53 +#define GL_BLUE_BITS 0x0D54 +#define GL_ALPHA_BITS 0x0D55 +#define GL_DEPTH_BITS 0x0D56 +#define GL_STENCIL_BITS 0x0D57 +#define GL_POLYGON_OFFSET_UNITS 0x2A00 +#define GL_POLYGON_OFFSET_FACTOR 0x8038 +#define GL_TEXTURE_BINDING_2D 0x8069 +#define GL_SAMPLE_BUFFERS 0x80A8 +#define GL_SAMPLES 0x80A9 +#define GL_SAMPLE_COVERAGE_VALUE 0x80AA +#define GL_SAMPLE_COVERAGE_INVERT 0x80AB +#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 +#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 +#define GL_DONT_CARE 0x1100 +#define GL_FASTEST 0x1101 +#define GL_NICEST 0x1102 +#define GL_GENERATE_MIPMAP_HINT 0x8192 +#define GL_BYTE 0x1400 +#define GL_UNSIGNED_BYTE 0x1401 +#define GL_SHORT 0x1402 +#define GL_UNSIGNED_SHORT 0x1403 +#define GL_INT 0x1404 +#define GL_UNSIGNED_INT 0x1405 +#define GL_FLOAT 0x1406 +#define GL_FIXED 0x140C +#define GL_DEPTH_COMPONENT 0x1902 +#define GL_ALPHA 0x1906 +#define GL_RGB 0x1907 +#define GL_RGBA 0x1908 +#define GL_LUMINANCE 0x1909 +#define GL_LUMINANCE_ALPHA 0x190A +#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033 +#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034 +#define GL_UNSIGNED_SHORT_5_6_5 0x8363 +#define GL_FRAGMENT_SHADER 0x8B30 +#define GL_VERTEX_SHADER 0x8B31 +#define GL_MAX_VERTEX_ATTRIBS 0x8869 +#define GL_MAX_VERTEX_UNIFORM_VECTORS 0x8DFB +#define GL_MAX_VARYING_VECTORS 0x8DFC +#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS 0x8B4D +#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS 0x8B4C +#define GL_MAX_TEXTURE_IMAGE_UNITS 0x8872 +#define GL_MAX_FRAGMENT_UNIFORM_VECTORS 0x8DFD +#define GL_SHADER_TYPE 0x8B4F +#define GL_DELETE_STATUS 0x8B80 +#define GL_LINK_STATUS 0x8B82 +#define GL_VALIDATE_STATUS 0x8B83 +#define GL_ATTACHED_SHADERS 0x8B85 +#define GL_ACTIVE_UNIFORMS 0x8B86 +#define GL_ACTIVE_UNIFORM_MAX_LENGTH 0x8B87 +#define GL_ACTIVE_ATTRIBUTES 0x8B89 +#define GL_ACTIVE_ATTRIBUTE_MAX_LENGTH 0x8B8A +#define GL_SHADING_LANGUAGE_VERSION 0x8B8C +#define GL_CURRENT_PROGRAM 0x8B8D +#define GL_NEVER 0x0200 +#define GL_LESS 0x0201 +#define GL_EQUAL 0x0202 +#define GL_LEQUAL 0x0203 +#define GL_GREATER 0x0204 +#define GL_NOTEQUAL 0x0205 +#define GL_GEQUAL 0x0206 +#define GL_ALWAYS 0x0207 +#define GL_KEEP 0x1E00 +#define GL_REPLACE 0x1E01 +#define GL_INCR 0x1E02 +#define GL_DECR 0x1E03 +#define GL_INVERT 0x150A +#define GL_INCR_WRAP 0x8507 +#define GL_DECR_WRAP 0x8508 +#define GL_VENDOR 0x1F00 +#define GL_RENDERER 0x1F01 +#define GL_VERSION 0x1F02 +#define GL_EXTENSIONS 0x1F03 +#define GL_NEAREST 0x2600 +#define GL_LINEAR 0x2601 +#define GL_NEAREST_MIPMAP_NEAREST 0x2700 +#define GL_LINEAR_MIPMAP_NEAREST 0x2701 +#define GL_NEAREST_MIPMAP_LINEAR 0x2702 +#define GL_LINEAR_MIPMAP_LINEAR 0x2703 +#define GL_TEXTURE_MAG_FILTER 0x2800 +#define GL_TEXTURE_MIN_FILTER 0x2801 +#define GL_TEXTURE_WRAP_S 0x2802 +#define GL_TEXTURE_WRAP_T 0x2803 +#define GL_TEXTURE 0x1702 +#define GL_TEXTURE_CUBE_MAP 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C +#define GL_TEXTURE0 0x84C0 +#define GL_TEXTURE1 0x84C1 +#define GL_TEXTURE2 0x84C2 +#define GL_TEXTURE3 0x84C3 +#define GL_TEXTURE4 0x84C4 +#define GL_TEXTURE5 0x84C5 +#define GL_TEXTURE6 0x84C6 +#define GL_TEXTURE7 0x84C7 +#define GL_TEXTURE8 0x84C8 +#define GL_TEXTURE9 0x84C9 +#define GL_TEXTURE10 0x84CA +#define GL_TEXTURE11 0x84CB +#define GL_TEXTURE12 0x84CC +#define GL_TEXTURE13 0x84CD +#define GL_TEXTURE14 0x84CE +#define GL_TEXTURE15 0x84CF +#define GL_TEXTURE16 0x84D0 +#define GL_TEXTURE17 0x84D1 +#define GL_TEXTURE18 0x84D2 +#define GL_TEXTURE19 0x84D3 +#define GL_TEXTURE20 0x84D4 +#define GL_TEXTURE21 0x84D5 +#define GL_TEXTURE22 0x84D6 +#define GL_TEXTURE23 0x84D7 +#define GL_TEXTURE24 0x84D8 +#define GL_TEXTURE25 0x84D9 +#define GL_TEXTURE26 0x84DA +#define GL_TEXTURE27 0x84DB +#define GL_TEXTURE28 0x84DC +#define GL_TEXTURE29 0x84DD +#define GL_TEXTURE30 0x84DE +#define GL_TEXTURE31 0x84DF +#define GL_ACTIVE_TEXTURE 0x84E0 +#define GL_REPEAT 0x2901 +#define GL_CLAMP_TO_EDGE 0x812F +#define GL_MIRRORED_REPEAT 0x8370 +#define GL_FLOAT_VEC2 0x8B50 +#define GL_FLOAT_VEC3 0x8B51 +#define GL_FLOAT_VEC4 0x8B52 +#define GL_INT_VEC2 0x8B53 +#define GL_INT_VEC3 0x8B54 +#define GL_INT_VEC4 0x8B55 +#define GL_BOOL 0x8B56 +#define GL_BOOL_VEC2 0x8B57 +#define GL_BOOL_VEC3 0x8B58 +#define GL_BOOL_VEC4 0x8B59 +#define GL_FLOAT_MAT2 0x8B5A +#define GL_FLOAT_MAT3 0x8B5B +#define GL_FLOAT_MAT4 0x8B5C +#define GL_SAMPLER_2D 0x8B5E +#define GL_SAMPLER_CUBE 0x8B60 +#define GL_VERTEX_ATTRIB_ARRAY_ENABLED 0x8622 +#define GL_VERTEX_ATTRIB_ARRAY_SIZE 0x8623 +#define GL_VERTEX_ATTRIB_ARRAY_STRIDE 0x8624 +#define GL_VERTEX_ATTRIB_ARRAY_TYPE 0x8625 +#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED 0x886A +#define GL_VERTEX_ATTRIB_ARRAY_POINTER 0x8645 +#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 0x889F +#define GL_IMPLEMENTATION_COLOR_READ_TYPE 0x8B9A +#define GL_IMPLEMENTATION_COLOR_READ_FORMAT 0x8B9B +#define GL_COMPILE_STATUS 0x8B81 +#define GL_INFO_LOG_LENGTH 0x8B84 +#define GL_SHADER_SOURCE_LENGTH 0x8B88 +#define GL_SHADER_COMPILER 0x8DFA +#define GL_SHADER_BINARY_FORMATS 0x8DF8 +#define GL_NUM_SHADER_BINARY_FORMATS 0x8DF9 +#define GL_LOW_FLOAT 0x8DF0 +#define GL_MEDIUM_FLOAT 0x8DF1 +#define GL_HIGH_FLOAT 0x8DF2 +#define GL_LOW_INT 0x8DF3 +#define GL_MEDIUM_INT 0x8DF4 +#define GL_HIGH_INT 0x8DF5 +#define GL_FRAMEBUFFER 0x8D40 +#define GL_RENDERBUFFER 0x8D41 +#define GL_RGBA4 0x8056 +#define GL_RGB5_A1 0x8057 +#define GL_RGB565 0x8D62 +#define GL_DEPTH_COMPONENT16 0x81A5 +#define GL_STENCIL_INDEX8 0x8D48 +#define GL_RENDERBUFFER_WIDTH 0x8D42 +#define GL_RENDERBUFFER_HEIGHT 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT 0x8D44 +#define GL_RENDERBUFFER_RED_SIZE 0x8D50 +#define GL_RENDERBUFFER_GREEN_SIZE 0x8D51 +#define GL_RENDERBUFFER_BLUE_SIZE 0x8D52 +#define GL_RENDERBUFFER_ALPHA_SIZE 0x8D53 +#define GL_RENDERBUFFER_DEPTH_SIZE 0x8D54 +#define GL_RENDERBUFFER_STENCIL_SIZE 0x8D55 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE 0x8CD3 +#define GL_COLOR_ATTACHMENT0 0x8CE0 +#define GL_DEPTH_ATTACHMENT 0x8D00 +#define GL_STENCIL_ATTACHMENT 0x8D20 +#define GL_NONE 0 +#define GL_FRAMEBUFFER_COMPLETE 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS 0x8CD9 +#define GL_FRAMEBUFFER_UNSUPPORTED 0x8CDD +#define GL_FRAMEBUFFER_BINDING 0x8CA6 +#define GL_RENDERBUFFER_BINDING 0x8CA7 +#define GL_MAX_RENDERBUFFER_SIZE 0x84E8 +#define GL_INVALID_FRAMEBUFFER_OPERATION 0x0506 +typedef void (GL_APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); +typedef void (GL_APIENTRYP PFNGLATTACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (GL_APIENTRYP PFNGLBINDATTRIBLOCATIONPROC) (GLuint program, GLuint index, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERPROC) (GLenum target, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLBINDFRAMEBUFFERPROC) (GLenum target, GLuint framebuffer); +typedef void (GL_APIENTRYP PFNGLBINDRENDERBUFFERPROC) (GLenum target, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLBINDTEXTUREPROC) (GLenum target, GLuint texture); +typedef void (GL_APIENTRYP PFNGLBLENDCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEPROC) (GLenum modeRGB, GLenum modeAlpha); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCPROC) (GLenum sfactor, GLenum dfactor); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +typedef void (GL_APIENTRYP PFNGLBUFFERDATAPROC) (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +typedef void (GL_APIENTRYP PFNGLBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +typedef GLenum (GL_APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLCLEARPROC) (GLbitfield mask); +typedef void (GL_APIENTRYP PFNGLCLEARCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLCLEARDEPTHFPROC) (GLfloat d); +typedef void (GL_APIENTRYP PFNGLCLEARSTENCILPROC) (GLint s); +typedef void (GL_APIENTRYP PFNGLCOLORMASKPROC) (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +typedef void (GL_APIENTRYP PFNGLCOMPILESHADERPROC) (GLuint shader); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOPYTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef GLuint (GL_APIENTRYP PFNGLCREATEPROGRAMPROC) (void); +typedef GLuint (GL_APIENTRYP PFNGLCREATESHADERPROC) (GLenum type); +typedef void (GL_APIENTRYP PFNGLCULLFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLDELETEBUFFERSPROC) (GLsizei n, const GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLDELETEFRAMEBUFFERSPROC) (GLsizei n, const GLuint *framebuffers); +typedef void (GL_APIENTRYP PFNGLDELETEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLDELETERENDERBUFFERSPROC) (GLsizei n, const GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLDELETESHADERPROC) (GLuint shader); +typedef void (GL_APIENTRYP PFNGLDELETETEXTURESPROC) (GLsizei n, const GLuint *textures); +typedef void (GL_APIENTRYP PFNGLDEPTHFUNCPROC) (GLenum func); +typedef void (GL_APIENTRYP PFNGLDEPTHMASKPROC) (GLboolean flag); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEFPROC) (GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLDETACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (GL_APIENTRYP PFNGLDISABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSPROC) (GLenum mode, GLint first, GLsizei count); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices); +typedef void (GL_APIENTRYP PFNGLENABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (GL_APIENTRYP PFNGLFINISHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFLUSHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFERPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (GL_APIENTRYP PFNGLFRONTFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLGENBUFFERSPROC) (GLsizei n, GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLGENERATEMIPMAPPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGENFRAMEBUFFERSPROC) (GLsizei n, GLuint *framebuffers); +typedef void (GL_APIENTRYP PFNGLGENRENDERBUFFERSPROC) (GLsizei n, GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLGENTEXTURESPROC) (GLsizei n, GLuint *textures); +typedef void (GL_APIENTRYP PFNGLGETACTIVEATTRIBPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETATTACHEDSHADERSPROC) (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *shaders); +typedef GLint (GL_APIENTRYP PFNGLGETATTRIBLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETBOOLEANVPROC) (GLenum pname, GLboolean *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef GLenum (GL_APIENTRYP PFNGLGETERRORPROC) (void); +typedef void (GL_APIENTRYP PFNGLGETFLOATVPROC) (GLenum pname, GLfloat *data); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETINTEGERVPROC) (GLenum pname, GLint *data); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMIVPROC) (GLuint program, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMINFOLOGPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSHADERIVPROC) (GLuint shader, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSHADERINFOLOGPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLGETSHADERPRECISIONFORMATPROC) (GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision); +typedef void (GL_APIENTRYP PFNGLGETSHADERSOURCEPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +typedef const GLubyte *(GL_APIENTRYP PFNGLGETSTRINGPROC) (GLenum name); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMFVPROC) (GLuint program, GLint location, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMIVPROC) (GLuint program, GLint location, GLint *params); +typedef GLint (GL_APIENTRYP PFNGLGETUNIFORMLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBFVPROC) (GLuint index, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVPROC) (GLuint index, GLenum pname, void **pointer); +typedef void (GL_APIENTRYP PFNGLHINTPROC) (GLenum target, GLenum mode); +typedef GLboolean (GL_APIENTRYP PFNGLISBUFFERPROC) (GLuint buffer); +typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDPROC) (GLenum cap); +typedef GLboolean (GL_APIENTRYP PFNGLISFRAMEBUFFERPROC) (GLuint framebuffer); +typedef GLboolean (GL_APIENTRYP PFNGLISPROGRAMPROC) (GLuint program); +typedef GLboolean (GL_APIENTRYP PFNGLISRENDERBUFFERPROC) (GLuint renderbuffer); +typedef GLboolean (GL_APIENTRYP PFNGLISSHADERPROC) (GLuint shader); +typedef GLboolean (GL_APIENTRYP PFNGLISTEXTUREPROC) (GLuint texture); +typedef void (GL_APIENTRYP PFNGLLINEWIDTHPROC) (GLfloat width); +typedef void (GL_APIENTRYP PFNGLLINKPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLPIXELSTOREIPROC) (GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLPOLYGONOFFSETPROC) (GLfloat factor, GLfloat units); +typedef void (GL_APIENTRYP PFNGLREADPIXELSPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +typedef void (GL_APIENTRYP PFNGLRELEASESHADERCOMPILERPROC) (void); +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert); +typedef void (GL_APIENTRYP PFNGLSCISSORPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSHADERBINARYPROC) (GLsizei count, const GLuint *shaders, GLenum binaryFormat, const void *binary, GLsizei length); +typedef void (GL_APIENTRYP PFNGLSHADERSOURCEPROC) (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length); +typedef void (GL_APIENTRYP PFNGLSTENCILFUNCPROC) (GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILFUNCSEPARATEPROC) (GLenum face, GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILMASKPROC) (GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILMASKSEPARATEPROC) (GLenum face, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILOPPROC) (GLenum fail, GLenum zfail, GLenum zpass); +typedef void (GL_APIENTRYP PFNGLSTENCILOPSEPARATEPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE2DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFPROC) (GLenum target, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLUNIFORM1FPROC) (GLint location, GLfloat v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM1FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM1IPROC) (GLint location, GLint v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM1IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2FPROC) (GLint location, GLfloat v0, GLfloat v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM2FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2IPROC) (GLint location, GLint v0, GLint v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM2IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM3FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3IPROC) (GLint location, GLint v0, GLint v1, GLint v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM3IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM4FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4IPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM4IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUSEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLVALIDATEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB1FPROC) (GLuint index, GLfloat x); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB1FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB2FPROC) (GLuint index, GLfloat x, GLfloat y); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB2FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB3FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB3FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBPOINTERPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLVIEWPORTPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glActiveTexture (GLenum texture); +GL_APICALL void GL_APIENTRY glAttachShader (GLuint program, GLuint shader); +GL_APICALL void GL_APIENTRY glBindAttribLocation (GLuint program, GLuint index, const GLchar *name); +GL_APICALL void GL_APIENTRY glBindBuffer (GLenum target, GLuint buffer); +GL_APICALL void GL_APIENTRY glBindFramebuffer (GLenum target, GLuint framebuffer); +GL_APICALL void GL_APIENTRY glBindRenderbuffer (GLenum target, GLuint renderbuffer); +GL_APICALL void GL_APIENTRY glBindTexture (GLenum target, GLuint texture); +GL_APICALL void GL_APIENTRY glBlendColor (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_APICALL void GL_APIENTRY glBlendEquation (GLenum mode); +GL_APICALL void GL_APIENTRY glBlendEquationSeparate (GLenum modeRGB, GLenum modeAlpha); +GL_APICALL void GL_APIENTRY glBlendFunc (GLenum sfactor, GLenum dfactor); +GL_APICALL void GL_APIENTRY glBlendFuncSeparate (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +GL_APICALL void GL_APIENTRY glBufferData (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +GL_APICALL void GL_APIENTRY glBufferSubData (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +GL_APICALL GLenum GL_APIENTRY glCheckFramebufferStatus (GLenum target); +GL_APICALL void GL_APIENTRY glClear (GLbitfield mask); +GL_APICALL void GL_APIENTRY glClearColor (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_APICALL void GL_APIENTRY glClearDepthf (GLfloat d); +GL_APICALL void GL_APIENTRY glClearStencil (GLint s); +GL_APICALL void GL_APIENTRY glColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +GL_APICALL void GL_APIENTRY glCompileShader (GLuint shader); +GL_APICALL void GL_APIENTRY glCompressedTexImage2D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCopyTexImage2D (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +GL_APICALL void GL_APIENTRY glCopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL GLuint GL_APIENTRY glCreateProgram (void); +GL_APICALL GLuint GL_APIENTRY glCreateShader (GLenum type); +GL_APICALL void GL_APIENTRY glCullFace (GLenum mode); +GL_APICALL void GL_APIENTRY glDeleteBuffers (GLsizei n, const GLuint *buffers); +GL_APICALL void GL_APIENTRY glDeleteFramebuffers (GLsizei n, const GLuint *framebuffers); +GL_APICALL void GL_APIENTRY glDeleteProgram (GLuint program); +GL_APICALL void GL_APIENTRY glDeleteRenderbuffers (GLsizei n, const GLuint *renderbuffers); +GL_APICALL void GL_APIENTRY glDeleteShader (GLuint shader); +GL_APICALL void GL_APIENTRY glDeleteTextures (GLsizei n, const GLuint *textures); +GL_APICALL void GL_APIENTRY glDepthFunc (GLenum func); +GL_APICALL void GL_APIENTRY glDepthMask (GLboolean flag); +GL_APICALL void GL_APIENTRY glDepthRangef (GLfloat n, GLfloat f); +GL_APICALL void GL_APIENTRY glDetachShader (GLuint program, GLuint shader); +GL_APICALL void GL_APIENTRY glDisable (GLenum cap); +GL_APICALL void GL_APIENTRY glDisableVertexAttribArray (GLuint index); +GL_APICALL void GL_APIENTRY glDrawArrays (GLenum mode, GLint first, GLsizei count); +GL_APICALL void GL_APIENTRY glDrawElements (GLenum mode, GLsizei count, GLenum type, const void *indices); +GL_APICALL void GL_APIENTRY glEnable (GLenum cap); +GL_APICALL void GL_APIENTRY glEnableVertexAttribArray (GLuint index); +GL_APICALL void GL_APIENTRY glFinish (void); +GL_APICALL void GL_APIENTRY glFlush (void); +GL_APICALL void GL_APIENTRY glFramebufferRenderbuffer (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +GL_APICALL void GL_APIENTRY glFramebufferTexture2D (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +GL_APICALL void GL_APIENTRY glFrontFace (GLenum mode); +GL_APICALL void GL_APIENTRY glGenBuffers (GLsizei n, GLuint *buffers); +GL_APICALL void GL_APIENTRY glGenerateMipmap (GLenum target); +GL_APICALL void GL_APIENTRY glGenFramebuffers (GLsizei n, GLuint *framebuffers); +GL_APICALL void GL_APIENTRY glGenRenderbuffers (GLsizei n, GLuint *renderbuffers); +GL_APICALL void GL_APIENTRY glGenTextures (GLsizei n, GLuint *textures); +GL_APICALL void GL_APIENTRY glGetActiveAttrib (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glGetActiveUniform (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glGetAttachedShaders (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *shaders); +GL_APICALL GLint GL_APIENTRY glGetAttribLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetBooleanv (GLenum pname, GLboolean *data); +GL_APICALL void GL_APIENTRY glGetBufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL GLenum GL_APIENTRY glGetError (void); +GL_APICALL void GL_APIENTRY glGetFloatv (GLenum pname, GLfloat *data); +GL_APICALL void GL_APIENTRY glGetFramebufferAttachmentParameteriv (GLenum target, GLenum attachment, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetIntegerv (GLenum pname, GLint *data); +GL_APICALL void GL_APIENTRY glGetProgramiv (GLuint program, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetProgramInfoLog (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glGetRenderbufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetShaderiv (GLuint shader, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetShaderInfoLog (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glGetShaderPrecisionFormat (GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision); +GL_APICALL void GL_APIENTRY glGetShaderSource (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +GL_APICALL const GLubyte *GL_APIENTRY glGetString (GLenum name); +GL_APICALL void GL_APIENTRY glGetTexParameterfv (GLenum target, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetTexParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetUniformfv (GLuint program, GLint location, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetUniformiv (GLuint program, GLint location, GLint *params); +GL_APICALL GLint GL_APIENTRY glGetUniformLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetVertexAttribfv (GLuint index, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribiv (GLuint index, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribPointerv (GLuint index, GLenum pname, void **pointer); +GL_APICALL void GL_APIENTRY glHint (GLenum target, GLenum mode); +GL_APICALL GLboolean GL_APIENTRY glIsBuffer (GLuint buffer); +GL_APICALL GLboolean GL_APIENTRY glIsEnabled (GLenum cap); +GL_APICALL GLboolean GL_APIENTRY glIsFramebuffer (GLuint framebuffer); +GL_APICALL GLboolean GL_APIENTRY glIsProgram (GLuint program); +GL_APICALL GLboolean GL_APIENTRY glIsRenderbuffer (GLuint renderbuffer); +GL_APICALL GLboolean GL_APIENTRY glIsShader (GLuint shader); +GL_APICALL GLboolean GL_APIENTRY glIsTexture (GLuint texture); +GL_APICALL void GL_APIENTRY glLineWidth (GLfloat width); +GL_APICALL void GL_APIENTRY glLinkProgram (GLuint program); +GL_APICALL void GL_APIENTRY glPixelStorei (GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glPolygonOffset (GLfloat factor, GLfloat units); +GL_APICALL void GL_APIENTRY glReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +GL_APICALL void GL_APIENTRY glReleaseShaderCompiler (void); +GL_APICALL void GL_APIENTRY glRenderbufferStorage (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glSampleCoverage (GLfloat value, GLboolean invert); +GL_APICALL void GL_APIENTRY glScissor (GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glShaderBinary (GLsizei count, const GLuint *shaders, GLenum binaryFormat, const void *binary, GLsizei length); +GL_APICALL void GL_APIENTRY glShaderSource (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length); +GL_APICALL void GL_APIENTRY glStencilFunc (GLenum func, GLint ref, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilFuncSeparate (GLenum face, GLenum func, GLint ref, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilMask (GLuint mask); +GL_APICALL void GL_APIENTRY glStencilMaskSeparate (GLenum face, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilOp (GLenum fail, GLenum zfail, GLenum zpass); +GL_APICALL void GL_APIENTRY glStencilOpSeparate (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +GL_APICALL void GL_APIENTRY glTexImage2D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glTexParameterf (GLenum target, GLenum pname, GLfloat param); +GL_APICALL void GL_APIENTRY glTexParameterfv (GLenum target, GLenum pname, const GLfloat *params); +GL_APICALL void GL_APIENTRY glTexParameteri (GLenum target, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glTexParameteriv (GLenum target, GLenum pname, const GLint *params); +GL_APICALL void GL_APIENTRY glTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glUniform1f (GLint location, GLfloat v0); +GL_APICALL void GL_APIENTRY glUniform1fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform1i (GLint location, GLint v0); +GL_APICALL void GL_APIENTRY glUniform1iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform2f (GLint location, GLfloat v0, GLfloat v1); +GL_APICALL void GL_APIENTRY glUniform2fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform2i (GLint location, GLint v0, GLint v1); +GL_APICALL void GL_APIENTRY glUniform2iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform3f (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +GL_APICALL void GL_APIENTRY glUniform3fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform3i (GLint location, GLint v0, GLint v1, GLint v2); +GL_APICALL void GL_APIENTRY glUniform3iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform4f (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +GL_APICALL void GL_APIENTRY glUniform4fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform4i (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +GL_APICALL void GL_APIENTRY glUniform4iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniformMatrix2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUseProgram (GLuint program); +GL_APICALL void GL_APIENTRY glValidateProgram (GLuint program); +GL_APICALL void GL_APIENTRY glVertexAttrib1f (GLuint index, GLfloat x); +GL_APICALL void GL_APIENTRY glVertexAttrib1fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib2f (GLuint index, GLfloat x, GLfloat y); +GL_APICALL void GL_APIENTRY glVertexAttrib2fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib3f (GLuint index, GLfloat x, GLfloat y, GLfloat z); +GL_APICALL void GL_APIENTRY glVertexAttrib3fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib4f (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +GL_APICALL void GL_APIENTRY glVertexAttrib4fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttribPointer (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer); +GL_APICALL void GL_APIENTRY glViewport (GLint x, GLint y, GLsizei width, GLsizei height); +#endif +#endif /* GL_ES_VERSION_2_0 */ + +#ifndef GL_ES_VERSION_3_0 +#define GL_ES_VERSION_3_0 1 +typedef khronos_uint16_t GLhalf; +#define GL_READ_BUFFER 0x0C02 +#define GL_UNPACK_ROW_LENGTH 0x0CF2 +#define GL_UNPACK_SKIP_ROWS 0x0CF3 +#define GL_UNPACK_SKIP_PIXELS 0x0CF4 +#define GL_PACK_ROW_LENGTH 0x0D02 +#define GL_PACK_SKIP_ROWS 0x0D03 +#define GL_PACK_SKIP_PIXELS 0x0D04 +#define GL_COLOR 0x1800 +#define GL_DEPTH 0x1801 +#define GL_STENCIL 0x1802 +#define GL_RED 0x1903 +#define GL_RGB8 0x8051 +#define GL_RGBA8 0x8058 +#define GL_RGB10_A2 0x8059 +#define GL_TEXTURE_BINDING_3D 0x806A +#define GL_UNPACK_SKIP_IMAGES 0x806D +#define GL_UNPACK_IMAGE_HEIGHT 0x806E +#define GL_TEXTURE_3D 0x806F +#define GL_TEXTURE_WRAP_R 0x8072 +#define GL_MAX_3D_TEXTURE_SIZE 0x8073 +#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368 +#define GL_MAX_ELEMENTS_VERTICES 0x80E8 +#define GL_MAX_ELEMENTS_INDICES 0x80E9 +#define GL_TEXTURE_MIN_LOD 0x813A +#define GL_TEXTURE_MAX_LOD 0x813B +#define GL_TEXTURE_BASE_LEVEL 0x813C +#define GL_TEXTURE_MAX_LEVEL 0x813D +#define GL_MIN 0x8007 +#define GL_MAX 0x8008 +#define GL_DEPTH_COMPONENT24 0x81A6 +#define GL_MAX_TEXTURE_LOD_BIAS 0x84FD +#define GL_TEXTURE_COMPARE_MODE 0x884C +#define GL_TEXTURE_COMPARE_FUNC 0x884D +#define GL_CURRENT_QUERY 0x8865 +#define GL_QUERY_RESULT 0x8866 +#define GL_QUERY_RESULT_AVAILABLE 0x8867 +#define GL_BUFFER_MAPPED 0x88BC +#define GL_BUFFER_MAP_POINTER 0x88BD +#define GL_STREAM_READ 0x88E1 +#define GL_STREAM_COPY 0x88E2 +#define GL_STATIC_READ 0x88E5 +#define GL_STATIC_COPY 0x88E6 +#define GL_DYNAMIC_READ 0x88E9 +#define GL_DYNAMIC_COPY 0x88EA +#define GL_MAX_DRAW_BUFFERS 0x8824 +#define GL_DRAW_BUFFER0 0x8825 +#define GL_DRAW_BUFFER1 0x8826 +#define GL_DRAW_BUFFER2 0x8827 +#define GL_DRAW_BUFFER3 0x8828 +#define GL_DRAW_BUFFER4 0x8829 +#define GL_DRAW_BUFFER5 0x882A +#define GL_DRAW_BUFFER6 0x882B +#define GL_DRAW_BUFFER7 0x882C +#define GL_DRAW_BUFFER8 0x882D +#define GL_DRAW_BUFFER9 0x882E +#define GL_DRAW_BUFFER10 0x882F +#define GL_DRAW_BUFFER11 0x8830 +#define GL_DRAW_BUFFER12 0x8831 +#define GL_DRAW_BUFFER13 0x8832 +#define GL_DRAW_BUFFER14 0x8833 +#define GL_DRAW_BUFFER15 0x8834 +#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS 0x8B49 +#define GL_MAX_VERTEX_UNIFORM_COMPONENTS 0x8B4A +#define GL_SAMPLER_3D 0x8B5F +#define GL_SAMPLER_2D_SHADOW 0x8B62 +#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT 0x8B8B +#define GL_PIXEL_PACK_BUFFER 0x88EB +#define GL_PIXEL_UNPACK_BUFFER 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING 0x88EF +#define GL_FLOAT_MAT2x3 0x8B65 +#define GL_FLOAT_MAT2x4 0x8B66 +#define GL_FLOAT_MAT3x2 0x8B67 +#define GL_FLOAT_MAT3x4 0x8B68 +#define GL_FLOAT_MAT4x2 0x8B69 +#define GL_FLOAT_MAT4x3 0x8B6A +#define GL_SRGB 0x8C40 +#define GL_SRGB8 0x8C41 +#define GL_SRGB8_ALPHA8 0x8C43 +#define GL_COMPARE_REF_TO_TEXTURE 0x884E +#define GL_MAJOR_VERSION 0x821B +#define GL_MINOR_VERSION 0x821C +#define GL_NUM_EXTENSIONS 0x821D +#define GL_RGBA32F 0x8814 +#define GL_RGB32F 0x8815 +#define GL_RGBA16F 0x881A +#define GL_RGB16F 0x881B +#define GL_VERTEX_ATTRIB_ARRAY_INTEGER 0x88FD +#define GL_MAX_ARRAY_TEXTURE_LAYERS 0x88FF +#define GL_MIN_PROGRAM_TEXEL_OFFSET 0x8904 +#define GL_MAX_PROGRAM_TEXEL_OFFSET 0x8905 +#define GL_MAX_VARYING_COMPONENTS 0x8B4B +#define GL_TEXTURE_2D_ARRAY 0x8C1A +#define GL_TEXTURE_BINDING_2D_ARRAY 0x8C1D +#define GL_R11F_G11F_B10F 0x8C3A +#define GL_UNSIGNED_INT_10F_11F_11F_REV 0x8C3B +#define GL_RGB9_E5 0x8C3D +#define GL_UNSIGNED_INT_5_9_9_9_REV 0x8C3E +#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH 0x8C76 +#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE 0x8C7F +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS 0x8C80 +#define GL_TRANSFORM_FEEDBACK_VARYINGS 0x8C83 +#define GL_TRANSFORM_FEEDBACK_BUFFER_START 0x8C84 +#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE 0x8C85 +#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN 0x8C88 +#define GL_RASTERIZER_DISCARD 0x8C89 +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS 0x8C8B +#define GL_INTERLEAVED_ATTRIBS 0x8C8C +#define GL_SEPARATE_ATTRIBS 0x8C8D +#define GL_TRANSFORM_FEEDBACK_BUFFER 0x8C8E +#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING 0x8C8F +#define GL_RGBA32UI 0x8D70 +#define GL_RGB32UI 0x8D71 +#define GL_RGBA16UI 0x8D76 +#define GL_RGB16UI 0x8D77 +#define GL_RGBA8UI 0x8D7C +#define GL_RGB8UI 0x8D7D +#define GL_RGBA32I 0x8D82 +#define GL_RGB32I 0x8D83 +#define GL_RGBA16I 0x8D88 +#define GL_RGB16I 0x8D89 +#define GL_RGBA8I 0x8D8E +#define GL_RGB8I 0x8D8F +#define GL_RED_INTEGER 0x8D94 +#define GL_RGB_INTEGER 0x8D98 +#define GL_RGBA_INTEGER 0x8D99 +#define GL_SAMPLER_2D_ARRAY 0x8DC1 +#define GL_SAMPLER_2D_ARRAY_SHADOW 0x8DC4 +#define GL_SAMPLER_CUBE_SHADOW 0x8DC5 +#define GL_UNSIGNED_INT_VEC2 0x8DC6 +#define GL_UNSIGNED_INT_VEC3 0x8DC7 +#define GL_UNSIGNED_INT_VEC4 0x8DC8 +#define GL_INT_SAMPLER_2D 0x8DCA +#define GL_INT_SAMPLER_3D 0x8DCB +#define GL_INT_SAMPLER_CUBE 0x8DCC +#define GL_INT_SAMPLER_2D_ARRAY 0x8DCF +#define GL_UNSIGNED_INT_SAMPLER_2D 0x8DD2 +#define GL_UNSIGNED_INT_SAMPLER_3D 0x8DD3 +#define GL_UNSIGNED_INT_SAMPLER_CUBE 0x8DD4 +#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY 0x8DD7 +#define GL_BUFFER_ACCESS_FLAGS 0x911F +#define GL_BUFFER_MAP_LENGTH 0x9120 +#define GL_BUFFER_MAP_OFFSET 0x9121 +#define GL_DEPTH_COMPONENT32F 0x8CAC +#define GL_DEPTH32F_STENCIL8 0x8CAD +#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV 0x8DAD +#define GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING 0x8210 +#define GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE 0x8211 +#define GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE 0x8212 +#define GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE 0x8213 +#define GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE 0x8214 +#define GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE 0x8215 +#define GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE 0x8216 +#define GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE 0x8217 +#define GL_FRAMEBUFFER_DEFAULT 0x8218 +#define GL_FRAMEBUFFER_UNDEFINED 0x8219 +#define GL_DEPTH_STENCIL_ATTACHMENT 0x821A +#define GL_DEPTH_STENCIL 0x84F9 +#define GL_UNSIGNED_INT_24_8 0x84FA +#define GL_DEPTH24_STENCIL8 0x88F0 +#define GL_UNSIGNED_NORMALIZED 0x8C17 +#define GL_DRAW_FRAMEBUFFER_BINDING 0x8CA6 +#define GL_READ_FRAMEBUFFER 0x8CA8 +#define GL_DRAW_FRAMEBUFFER 0x8CA9 +#define GL_READ_FRAMEBUFFER_BINDING 0x8CAA +#define GL_RENDERBUFFER_SAMPLES 0x8CAB +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER 0x8CD4 +#define GL_MAX_COLOR_ATTACHMENTS 0x8CDF +#define GL_COLOR_ATTACHMENT1 0x8CE1 +#define GL_COLOR_ATTACHMENT2 0x8CE2 +#define GL_COLOR_ATTACHMENT3 0x8CE3 +#define GL_COLOR_ATTACHMENT4 0x8CE4 +#define GL_COLOR_ATTACHMENT5 0x8CE5 +#define GL_COLOR_ATTACHMENT6 0x8CE6 +#define GL_COLOR_ATTACHMENT7 0x8CE7 +#define GL_COLOR_ATTACHMENT8 0x8CE8 +#define GL_COLOR_ATTACHMENT9 0x8CE9 +#define GL_COLOR_ATTACHMENT10 0x8CEA +#define GL_COLOR_ATTACHMENT11 0x8CEB +#define GL_COLOR_ATTACHMENT12 0x8CEC +#define GL_COLOR_ATTACHMENT13 0x8CED +#define GL_COLOR_ATTACHMENT14 0x8CEE +#define GL_COLOR_ATTACHMENT15 0x8CEF +#define GL_COLOR_ATTACHMENT16 0x8CF0 +#define GL_COLOR_ATTACHMENT17 0x8CF1 +#define GL_COLOR_ATTACHMENT18 0x8CF2 +#define GL_COLOR_ATTACHMENT19 0x8CF3 +#define GL_COLOR_ATTACHMENT20 0x8CF4 +#define GL_COLOR_ATTACHMENT21 0x8CF5 +#define GL_COLOR_ATTACHMENT22 0x8CF6 +#define GL_COLOR_ATTACHMENT23 0x8CF7 +#define GL_COLOR_ATTACHMENT24 0x8CF8 +#define GL_COLOR_ATTACHMENT25 0x8CF9 +#define GL_COLOR_ATTACHMENT26 0x8CFA +#define GL_COLOR_ATTACHMENT27 0x8CFB +#define GL_COLOR_ATTACHMENT28 0x8CFC +#define GL_COLOR_ATTACHMENT29 0x8CFD +#define GL_COLOR_ATTACHMENT30 0x8CFE +#define GL_COLOR_ATTACHMENT31 0x8CFF +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE 0x8D56 +#define GL_MAX_SAMPLES 0x8D57 +#define GL_HALF_FLOAT 0x140B +#define GL_MAP_READ_BIT 0x0001 +#define GL_MAP_WRITE_BIT 0x0002 +#define GL_MAP_INVALIDATE_RANGE_BIT 0x0004 +#define GL_MAP_INVALIDATE_BUFFER_BIT 0x0008 +#define GL_MAP_FLUSH_EXPLICIT_BIT 0x0010 +#define GL_MAP_UNSYNCHRONIZED_BIT 0x0020 +#define GL_RG 0x8227 +#define GL_RG_INTEGER 0x8228 +#define GL_R8 0x8229 +#define GL_RG8 0x822B +#define GL_R16F 0x822D +#define GL_R32F 0x822E +#define GL_RG16F 0x822F +#define GL_RG32F 0x8230 +#define GL_R8I 0x8231 +#define GL_R8UI 0x8232 +#define GL_R16I 0x8233 +#define GL_R16UI 0x8234 +#define GL_R32I 0x8235 +#define GL_R32UI 0x8236 +#define GL_RG8I 0x8237 +#define GL_RG8UI 0x8238 +#define GL_RG16I 0x8239 +#define GL_RG16UI 0x823A +#define GL_RG32I 0x823B +#define GL_RG32UI 0x823C +#define GL_VERTEX_ARRAY_BINDING 0x85B5 +#define GL_R8_SNORM 0x8F94 +#define GL_RG8_SNORM 0x8F95 +#define GL_RGB8_SNORM 0x8F96 +#define GL_RGBA8_SNORM 0x8F97 +#define GL_SIGNED_NORMALIZED 0x8F9C +#define GL_PRIMITIVE_RESTART_FIXED_INDEX 0x8D69 +#define GL_COPY_READ_BUFFER 0x8F36 +#define GL_COPY_WRITE_BUFFER 0x8F37 +#define GL_COPY_READ_BUFFER_BINDING 0x8F36 +#define GL_COPY_WRITE_BUFFER_BINDING 0x8F37 +#define GL_UNIFORM_BUFFER 0x8A11 +#define GL_UNIFORM_BUFFER_BINDING 0x8A28 +#define GL_UNIFORM_BUFFER_START 0x8A29 +#define GL_UNIFORM_BUFFER_SIZE 0x8A2A +#define GL_MAX_VERTEX_UNIFORM_BLOCKS 0x8A2B +#define GL_MAX_FRAGMENT_UNIFORM_BLOCKS 0x8A2D +#define GL_MAX_COMBINED_UNIFORM_BLOCKS 0x8A2E +#define GL_MAX_UNIFORM_BUFFER_BINDINGS 0x8A2F +#define GL_MAX_UNIFORM_BLOCK_SIZE 0x8A30 +#define GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS 0x8A31 +#define GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS 0x8A33 +#define GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT 0x8A34 +#define GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH 0x8A35 +#define GL_ACTIVE_UNIFORM_BLOCKS 0x8A36 +#define GL_UNIFORM_TYPE 0x8A37 +#define GL_UNIFORM_SIZE 0x8A38 +#define GL_UNIFORM_NAME_LENGTH 0x8A39 +#define GL_UNIFORM_BLOCK_INDEX 0x8A3A +#define GL_UNIFORM_OFFSET 0x8A3B +#define GL_UNIFORM_ARRAY_STRIDE 0x8A3C +#define GL_UNIFORM_MATRIX_STRIDE 0x8A3D +#define GL_UNIFORM_IS_ROW_MAJOR 0x8A3E +#define GL_UNIFORM_BLOCK_BINDING 0x8A3F +#define GL_UNIFORM_BLOCK_DATA_SIZE 0x8A40 +#define GL_UNIFORM_BLOCK_NAME_LENGTH 0x8A41 +#define GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS 0x8A42 +#define GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES 0x8A43 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER 0x8A44 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER 0x8A46 +#define GL_INVALID_INDEX 0xFFFFFFFFu +#define GL_MAX_VERTEX_OUTPUT_COMPONENTS 0x9122 +#define GL_MAX_FRAGMENT_INPUT_COMPONENTS 0x9125 +#define GL_MAX_SERVER_WAIT_TIMEOUT 0x9111 +#define GL_OBJECT_TYPE 0x9112 +#define GL_SYNC_CONDITION 0x9113 +#define GL_SYNC_STATUS 0x9114 +#define GL_SYNC_FLAGS 0x9115 +#define GL_SYNC_FENCE 0x9116 +#define GL_SYNC_GPU_COMMANDS_COMPLETE 0x9117 +#define GL_UNSIGNALED 0x9118 +#define GL_SIGNALED 0x9119 +#define GL_ALREADY_SIGNALED 0x911A +#define GL_TIMEOUT_EXPIRED 0x911B +#define GL_CONDITION_SATISFIED 0x911C +#define GL_WAIT_FAILED 0x911D +#define GL_SYNC_FLUSH_COMMANDS_BIT 0x00000001 +#define GL_TIMEOUT_IGNORED 0xFFFFFFFFFFFFFFFFull +#define GL_VERTEX_ATTRIB_ARRAY_DIVISOR 0x88FE +#define GL_ANY_SAMPLES_PASSED 0x8C2F +#define GL_ANY_SAMPLES_PASSED_CONSERVATIVE 0x8D6A +#define GL_SAMPLER_BINDING 0x8919 +#define GL_RGB10_A2UI 0x906F +#define GL_TEXTURE_SWIZZLE_R 0x8E42 +#define GL_TEXTURE_SWIZZLE_G 0x8E43 +#define GL_TEXTURE_SWIZZLE_B 0x8E44 +#define GL_TEXTURE_SWIZZLE_A 0x8E45 +#define GL_GREEN 0x1904 +#define GL_BLUE 0x1905 +#define GL_INT_2_10_10_10_REV 0x8D9F +#define GL_TRANSFORM_FEEDBACK 0x8E22 +#define GL_TRANSFORM_FEEDBACK_PAUSED 0x8E23 +#define GL_TRANSFORM_FEEDBACK_ACTIVE 0x8E24 +#define GL_TRANSFORM_FEEDBACK_BINDING 0x8E25 +#define GL_PROGRAM_BINARY_RETRIEVABLE_HINT 0x8257 +#define GL_PROGRAM_BINARY_LENGTH 0x8741 +#define GL_NUM_PROGRAM_BINARY_FORMATS 0x87FE +#define GL_PROGRAM_BINARY_FORMATS 0x87FF +#define GL_COMPRESSED_R11_EAC 0x9270 +#define GL_COMPRESSED_SIGNED_R11_EAC 0x9271 +#define GL_COMPRESSED_RG11_EAC 0x9272 +#define GL_COMPRESSED_SIGNED_RG11_EAC 0x9273 +#define GL_COMPRESSED_RGB8_ETC2 0x9274 +#define GL_COMPRESSED_SRGB8_ETC2 0x9275 +#define GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9276 +#define GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9277 +#define GL_COMPRESSED_RGBA8_ETC2_EAC 0x9278 +#define GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC 0x9279 +#define GL_TEXTURE_IMMUTABLE_FORMAT 0x912F +#define GL_MAX_ELEMENT_INDEX 0x8D6B +#define GL_NUM_SAMPLE_COUNTS 0x9380 +#define GL_TEXTURE_IMMUTABLE_LEVELS 0x82DF +typedef void (GL_APIENTRYP PFNGLREADBUFFERPROC) (GLenum src); +typedef void (GL_APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLGENQUERIESPROC) (GLsizei n, GLuint *ids); +typedef void (GL_APIENTRYP PFNGLDELETEQUERIESPROC) (GLsizei n, const GLuint *ids); +typedef GLboolean (GL_APIENTRYP PFNGLISQUERYPROC) (GLuint id); +typedef void (GL_APIENTRYP PFNGLBEGINQUERYPROC) (GLenum target, GLuint id); +typedef void (GL_APIENTRYP PFNGLENDQUERYPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGETQUERYIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUIVPROC) (GLuint id, GLenum pname, GLuint *params); +typedef GLboolean (GL_APIENTRYP PFNGLUNMAPBUFFERPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVPROC) (GLenum target, GLenum pname, void **params); +typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSPROC) (GLsizei n, const GLenum *bufs); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLBLITFRAMEBUFFERPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYERPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); +typedef void *(GL_APIENTRYP PFNGLMAPBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +typedef void (GL_APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length); +typedef void (GL_APIENTRYP PFNGLBINDVERTEXARRAYPROC) (GLuint array); +typedef void (GL_APIENTRYP PFNGLDELETEVERTEXARRAYSPROC) (GLsizei n, const GLuint *arrays); +typedef void (GL_APIENTRYP PFNGLGENVERTEXARRAYSPROC) (GLsizei n, GLuint *arrays); +typedef GLboolean (GL_APIENTRYP PFNGLISVERTEXARRAYPROC) (GLuint array); +typedef void (GL_APIENTRYP PFNGLGETINTEGERI_VPROC) (GLenum target, GLuint index, GLint *data); +typedef void (GL_APIENTRYP PFNGLBEGINTRANSFORMFEEDBACKPROC) (GLenum primitiveMode); +typedef void (GL_APIENTRYP PFNGLENDTRANSFORMFEEDBACKPROC) (void); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERRANGEPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERBASEPROC) (GLenum target, GLuint index, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLTRANSFORMFEEDBACKVARYINGSPROC) (GLuint program, GLsizei count, const GLchar *const*varyings, GLenum bufferMode); +typedef void (GL_APIENTRYP PFNGLGETTRANSFORMFEEDBACKVARYINGPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBIPOINTERPROC) (GLuint index, GLint size, GLenum type, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIIVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIUIVPROC) (GLuint index, GLenum pname, GLuint *params); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4IPROC) (GLuint index, GLint x, GLint y, GLint z, GLint w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4UIPROC) (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4IVPROC) (GLuint index, const GLint *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4UIVPROC) (GLuint index, const GLuint *v); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMUIVPROC) (GLuint program, GLint location, GLuint *params); +typedef GLint (GL_APIENTRYP PFNGLGETFRAGDATALOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLUNIFORM1UIPROC) (GLint location, GLuint v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM2UIPROC) (GLint location, GLuint v0, GLuint v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM3UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM4UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM1UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERIVPROC) (GLenum buffer, GLint drawbuffer, const GLint *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERUIVPROC) (GLenum buffer, GLint drawbuffer, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERFVPROC) (GLenum buffer, GLint drawbuffer, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERFIPROC) (GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil); +typedef const GLubyte *(GL_APIENTRYP PFNGLGETSTRINGIPROC) (GLenum name, GLuint index); +typedef void (GL_APIENTRYP PFNGLCOPYBUFFERSUBDATAPROC) (GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMINDICESPROC) (GLuint program, GLsizei uniformCount, const GLchar *const*uniformNames, GLuint *uniformIndices); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMSIVPROC) (GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params); +typedef GLuint (GL_APIENTRYP PFNGLGETUNIFORMBLOCKINDEXPROC) (GLuint program, const GLchar *uniformBlockName); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMBLOCKIVPROC) (GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMBLOCKNAMEPROC) (GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName); +typedef void (GL_APIENTRYP PFNGLUNIFORMBLOCKBINDINGPROC) (GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instancecount); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount); +typedef GLsync (GL_APIENTRYP PFNGLFENCESYNCPROC) (GLenum condition, GLbitfield flags); +typedef GLboolean (GL_APIENTRYP PFNGLISSYNCPROC) (GLsync sync); +typedef void (GL_APIENTRYP PFNGLDELETESYNCPROC) (GLsync sync); +typedef GLenum (GL_APIENTRYP PFNGLCLIENTWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64VPROC) (GLenum pname, GLint64 *data); +typedef void (GL_APIENTRYP PFNGLGETSYNCIVPROC) (GLsync sync, GLenum pname, GLsizei count, GLsizei *length, GLint *values); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64I_VPROC) (GLenum target, GLuint index, GLint64 *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERI64VPROC) (GLenum target, GLenum pname, GLint64 *params); +typedef void (GL_APIENTRYP PFNGLGENSAMPLERSPROC) (GLsizei count, GLuint *samplers); +typedef void (GL_APIENTRYP PFNGLDELETESAMPLERSPROC) (GLsizei count, const GLuint *samplers); +typedef GLboolean (GL_APIENTRYP PFNGLISSAMPLERPROC) (GLuint sampler); +typedef void (GL_APIENTRYP PFNGLBINDSAMPLERPROC) (GLuint unit, GLuint sampler); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIPROC) (GLuint sampler, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIVPROC) (GLuint sampler, GLenum pname, const GLint *param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERFPROC) (GLuint sampler, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERFVPROC) (GLuint sampler, GLenum pname, const GLfloat *param); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIVPROC) (GLuint sampler, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERFVPROC) (GLuint sampler, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISORPROC) (GLuint index, GLuint divisor); +typedef void (GL_APIENTRYP PFNGLBINDTRANSFORMFEEDBACKPROC) (GLenum target, GLuint id); +typedef void (GL_APIENTRYP PFNGLDELETETRANSFORMFEEDBACKSPROC) (GLsizei n, const GLuint *ids); +typedef void (GL_APIENTRYP PFNGLGENTRANSFORMFEEDBACKSPROC) (GLsizei n, GLuint *ids); +typedef GLboolean (GL_APIENTRYP PFNGLISTRANSFORMFEEDBACKPROC) (GLuint id); +typedef void (GL_APIENTRYP PFNGLPAUSETRANSFORMFEEDBACKPROC) (void); +typedef void (GL_APIENTRYP PFNGLRESUMETRANSFORMFEEDBACKPROC) (void); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMBINARYPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary); +typedef void (GL_APIENTRYP PFNGLPROGRAMBINARYPROC) (GLuint program, GLenum binaryFormat, const void *binary, GLsizei length); +typedef void (GL_APIENTRYP PFNGLPROGRAMPARAMETERIPROC) (GLuint program, GLenum pname, GLint value); +typedef void (GL_APIENTRYP PFNGLINVALIDATEFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments); +typedef void (GL_APIENTRYP PFNGLINVALIDATESUBFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE3DPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +typedef void (GL_APIENTRYP PFNGLGETINTERNALFORMATIVPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint *params); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glReadBuffer (GLenum src); +GL_APICALL void GL_APIENTRY glDrawRangeElements (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices); +GL_APICALL void GL_APIENTRY glTexImage3D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glCopyTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glCompressedTexImage3D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glGenQueries (GLsizei n, GLuint *ids); +GL_APICALL void GL_APIENTRY glDeleteQueries (GLsizei n, const GLuint *ids); +GL_APICALL GLboolean GL_APIENTRY glIsQuery (GLuint id); +GL_APICALL void GL_APIENTRY glBeginQuery (GLenum target, GLuint id); +GL_APICALL void GL_APIENTRY glEndQuery (GLenum target); +GL_APICALL void GL_APIENTRY glGetQueryiv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetQueryObjectuiv (GLuint id, GLenum pname, GLuint *params); +GL_APICALL GLboolean GL_APIENTRY glUnmapBuffer (GLenum target); +GL_APICALL void GL_APIENTRY glGetBufferPointerv (GLenum target, GLenum pname, void **params); +GL_APICALL void GL_APIENTRY glDrawBuffers (GLsizei n, const GLenum *bufs); +GL_APICALL void GL_APIENTRY glUniformMatrix2x3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3x2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix2x4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4x2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3x4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4x3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glBlitFramebuffer (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glFramebufferTextureLayer (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); +GL_APICALL void *GL_APIENTRY glMapBufferRange (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +GL_APICALL void GL_APIENTRY glFlushMappedBufferRange (GLenum target, GLintptr offset, GLsizeiptr length); +GL_APICALL void GL_APIENTRY glBindVertexArray (GLuint array); +GL_APICALL void GL_APIENTRY glDeleteVertexArrays (GLsizei n, const GLuint *arrays); +GL_APICALL void GL_APIENTRY glGenVertexArrays (GLsizei n, GLuint *arrays); +GL_APICALL GLboolean GL_APIENTRY glIsVertexArray (GLuint array); +GL_APICALL void GL_APIENTRY glGetIntegeri_v (GLenum target, GLuint index, GLint *data); +GL_APICALL void GL_APIENTRY glBeginTransformFeedback (GLenum primitiveMode); +GL_APICALL void GL_APIENTRY glEndTransformFeedback (void); +GL_APICALL void GL_APIENTRY glBindBufferRange (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); +GL_APICALL void GL_APIENTRY glBindBufferBase (GLenum target, GLuint index, GLuint buffer); +GL_APICALL void GL_APIENTRY glTransformFeedbackVaryings (GLuint program, GLsizei count, const GLchar *const*varyings, GLenum bufferMode); +GL_APICALL void GL_APIENTRY glGetTransformFeedbackVarying (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glVertexAttribIPointer (GLuint index, GLint size, GLenum type, GLsizei stride, const void *pointer); +GL_APICALL void GL_APIENTRY glGetVertexAttribIiv (GLuint index, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribIuiv (GLuint index, GLenum pname, GLuint *params); +GL_APICALL void GL_APIENTRY glVertexAttribI4i (GLuint index, GLint x, GLint y, GLint z, GLint w); +GL_APICALL void GL_APIENTRY glVertexAttribI4ui (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +GL_APICALL void GL_APIENTRY glVertexAttribI4iv (GLuint index, const GLint *v); +GL_APICALL void GL_APIENTRY glVertexAttribI4uiv (GLuint index, const GLuint *v); +GL_APICALL void GL_APIENTRY glGetUniformuiv (GLuint program, GLint location, GLuint *params); +GL_APICALL GLint GL_APIENTRY glGetFragDataLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glUniform1ui (GLint location, GLuint v0); +GL_APICALL void GL_APIENTRY glUniform2ui (GLint location, GLuint v0, GLuint v1); +GL_APICALL void GL_APIENTRY glUniform3ui (GLint location, GLuint v0, GLuint v1, GLuint v2); +GL_APICALL void GL_APIENTRY glUniform4ui (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +GL_APICALL void GL_APIENTRY glUniform1uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glUniform2uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glUniform3uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glUniform4uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glClearBufferiv (GLenum buffer, GLint drawbuffer, const GLint *value); +GL_APICALL void GL_APIENTRY glClearBufferuiv (GLenum buffer, GLint drawbuffer, const GLuint *value); +GL_APICALL void GL_APIENTRY glClearBufferfv (GLenum buffer, GLint drawbuffer, const GLfloat *value); +GL_APICALL void GL_APIENTRY glClearBufferfi (GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil); +GL_APICALL const GLubyte *GL_APIENTRY glGetStringi (GLenum name, GLuint index); +GL_APICALL void GL_APIENTRY glCopyBufferSubData (GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +GL_APICALL void GL_APIENTRY glGetUniformIndices (GLuint program, GLsizei uniformCount, const GLchar *const*uniformNames, GLuint *uniformIndices); +GL_APICALL void GL_APIENTRY glGetActiveUniformsiv (GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params); +GL_APICALL GLuint GL_APIENTRY glGetUniformBlockIndex (GLuint program, const GLchar *uniformBlockName); +GL_APICALL void GL_APIENTRY glGetActiveUniformBlockiv (GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetActiveUniformBlockName (GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName); +GL_APICALL void GL_APIENTRY glUniformBlockBinding (GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding); +GL_APICALL void GL_APIENTRY glDrawArraysInstanced (GLenum mode, GLint first, GLsizei count, GLsizei instancecount); +GL_APICALL void GL_APIENTRY glDrawElementsInstanced (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount); +GL_APICALL GLsync GL_APIENTRY glFenceSync (GLenum condition, GLbitfield flags); +GL_APICALL GLboolean GL_APIENTRY glIsSync (GLsync sync); +GL_APICALL void GL_APIENTRY glDeleteSync (GLsync sync); +GL_APICALL GLenum GL_APIENTRY glClientWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_APICALL void GL_APIENTRY glWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_APICALL void GL_APIENTRY glGetInteger64v (GLenum pname, GLint64 *data); +GL_APICALL void GL_APIENTRY glGetSynciv (GLsync sync, GLenum pname, GLsizei count, GLsizei *length, GLint *values); +GL_APICALL void GL_APIENTRY glGetInteger64i_v (GLenum target, GLuint index, GLint64 *data); +GL_APICALL void GL_APIENTRY glGetBufferParameteri64v (GLenum target, GLenum pname, GLint64 *params); +GL_APICALL void GL_APIENTRY glGenSamplers (GLsizei count, GLuint *samplers); +GL_APICALL void GL_APIENTRY glDeleteSamplers (GLsizei count, const GLuint *samplers); +GL_APICALL GLboolean GL_APIENTRY glIsSampler (GLuint sampler); +GL_APICALL void GL_APIENTRY glBindSampler (GLuint unit, GLuint sampler); +GL_APICALL void GL_APIENTRY glSamplerParameteri (GLuint sampler, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glSamplerParameteriv (GLuint sampler, GLenum pname, const GLint *param); +GL_APICALL void GL_APIENTRY glSamplerParameterf (GLuint sampler, GLenum pname, GLfloat param); +GL_APICALL void GL_APIENTRY glSamplerParameterfv (GLuint sampler, GLenum pname, const GLfloat *param); +GL_APICALL void GL_APIENTRY glGetSamplerParameteriv (GLuint sampler, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetSamplerParameterfv (GLuint sampler, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glVertexAttribDivisor (GLuint index, GLuint divisor); +GL_APICALL void GL_APIENTRY glBindTransformFeedback (GLenum target, GLuint id); +GL_APICALL void GL_APIENTRY glDeleteTransformFeedbacks (GLsizei n, const GLuint *ids); +GL_APICALL void GL_APIENTRY glGenTransformFeedbacks (GLsizei n, GLuint *ids); +GL_APICALL GLboolean GL_APIENTRY glIsTransformFeedback (GLuint id); +GL_APICALL void GL_APIENTRY glPauseTransformFeedback (void); +GL_APICALL void GL_APIENTRY glResumeTransformFeedback (void); +GL_APICALL void GL_APIENTRY glGetProgramBinary (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary); +GL_APICALL void GL_APIENTRY glProgramBinary (GLuint program, GLenum binaryFormat, const void *binary, GLsizei length); +GL_APICALL void GL_APIENTRY glProgramParameteri (GLuint program, GLenum pname, GLint value); +GL_APICALL void GL_APIENTRY glInvalidateFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments); +GL_APICALL void GL_APIENTRY glInvalidateSubFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glTexStorage2D (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glTexStorage3D (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +GL_APICALL void GL_APIENTRY glGetInternalformativ (GLenum target, GLenum internalformat, GLenum pname, GLsizei count, GLint *params); +#endif +#endif /* GL_ES_VERSION_3_0 */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/GLES3/gl31.h b/gfx/angle/checkout/include/GLES3/gl31.h new file mode 100644 index 0000000000..502d6feec8 --- /dev/null +++ b/gfx/angle/checkout/include/GLES3/gl31.h @@ -0,0 +1,1507 @@ +#ifndef __gles2_gl31_h_ +#define __gles2_gl31_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright 2013-2020 The Khronos Group Inc. +** SPDX-License-Identifier: MIT +** +** This header is generated from the Khronos OpenGL / OpenGL ES XML +** API Registry. The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** https://github.com/KhronosGroup/OpenGL-Registry +*/ + +#include + +#ifndef GL_APIENTRYP +#define GL_APIENTRYP GL_APIENTRY* +#endif + +#ifndef GL_GLES_PROTOTYPES +#define GL_GLES_PROTOTYPES 1 +#endif + +/* Generated on date 20191013 */ + +/* Generated C header for: + * API: gles2 + * Profile: common + * Versions considered: 2\.[0-9]|3\.[01] + * Versions emitted: .* + * Default extensions included: None + * Additional extensions included: _nomatch_^ + * Extensions removed: _nomatch_^ + */ + +#ifndef GL_ES_VERSION_2_0 +#define GL_ES_VERSION_2_0 1 +#include +typedef khronos_int8_t GLbyte; +typedef khronos_float_t GLclampf; +typedef khronos_int32_t GLfixed; +typedef khronos_int16_t GLshort; +typedef khronos_uint16_t GLushort; +typedef void GLvoid; +typedef struct __GLsync *GLsync; +typedef khronos_int64_t GLint64; +typedef khronos_uint64_t GLuint64; +typedef unsigned int GLenum; +typedef unsigned int GLuint; +typedef char GLchar; +typedef khronos_float_t GLfloat; +typedef khronos_ssize_t GLsizeiptr; +typedef khronos_intptr_t GLintptr; +typedef unsigned int GLbitfield; +typedef int GLint; +typedef unsigned char GLboolean; +typedef int GLsizei; +typedef khronos_uint8_t GLubyte; +#define GL_DEPTH_BUFFER_BIT 0x00000100 +#define GL_STENCIL_BUFFER_BIT 0x00000400 +#define GL_COLOR_BUFFER_BIT 0x00004000 +#define GL_FALSE 0 +#define GL_TRUE 1 +#define GL_POINTS 0x0000 +#define GL_LINES 0x0001 +#define GL_LINE_LOOP 0x0002 +#define GL_LINE_STRIP 0x0003 +#define GL_TRIANGLES 0x0004 +#define GL_TRIANGLE_STRIP 0x0005 +#define GL_TRIANGLE_FAN 0x0006 +#define GL_ZERO 0 +#define GL_ONE 1 +#define GL_SRC_COLOR 0x0300 +#define GL_ONE_MINUS_SRC_COLOR 0x0301 +#define GL_SRC_ALPHA 0x0302 +#define GL_ONE_MINUS_SRC_ALPHA 0x0303 +#define GL_DST_ALPHA 0x0304 +#define GL_ONE_MINUS_DST_ALPHA 0x0305 +#define GL_DST_COLOR 0x0306 +#define GL_ONE_MINUS_DST_COLOR 0x0307 +#define GL_SRC_ALPHA_SATURATE 0x0308 +#define GL_FUNC_ADD 0x8006 +#define GL_BLEND_EQUATION 0x8009 +#define GL_BLEND_EQUATION_RGB 0x8009 +#define GL_BLEND_EQUATION_ALPHA 0x883D +#define GL_FUNC_SUBTRACT 0x800A +#define GL_FUNC_REVERSE_SUBTRACT 0x800B +#define GL_BLEND_DST_RGB 0x80C8 +#define GL_BLEND_SRC_RGB 0x80C9 +#define GL_BLEND_DST_ALPHA 0x80CA +#define GL_BLEND_SRC_ALPHA 0x80CB +#define GL_CONSTANT_COLOR 0x8001 +#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002 +#define GL_CONSTANT_ALPHA 0x8003 +#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004 +#define GL_BLEND_COLOR 0x8005 +#define GL_ARRAY_BUFFER 0x8892 +#define GL_ELEMENT_ARRAY_BUFFER 0x8893 +#define GL_ARRAY_BUFFER_BINDING 0x8894 +#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895 +#define GL_STREAM_DRAW 0x88E0 +#define GL_STATIC_DRAW 0x88E4 +#define GL_DYNAMIC_DRAW 0x88E8 +#define GL_BUFFER_SIZE 0x8764 +#define GL_BUFFER_USAGE 0x8765 +#define GL_CURRENT_VERTEX_ATTRIB 0x8626 +#define GL_FRONT 0x0404 +#define GL_BACK 0x0405 +#define GL_FRONT_AND_BACK 0x0408 +#define GL_TEXTURE_2D 0x0DE1 +#define GL_CULL_FACE 0x0B44 +#define GL_BLEND 0x0BE2 +#define GL_DITHER 0x0BD0 +#define GL_STENCIL_TEST 0x0B90 +#define GL_DEPTH_TEST 0x0B71 +#define GL_SCISSOR_TEST 0x0C11 +#define GL_POLYGON_OFFSET_FILL 0x8037 +#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E +#define GL_SAMPLE_COVERAGE 0x80A0 +#define GL_NO_ERROR 0 +#define GL_INVALID_ENUM 0x0500 +#define GL_INVALID_VALUE 0x0501 +#define GL_INVALID_OPERATION 0x0502 +#define GL_OUT_OF_MEMORY 0x0505 +#define GL_CW 0x0900 +#define GL_CCW 0x0901 +#define GL_LINE_WIDTH 0x0B21 +#define GL_ALIASED_POINT_SIZE_RANGE 0x846D +#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E +#define GL_CULL_FACE_MODE 0x0B45 +#define GL_FRONT_FACE 0x0B46 +#define GL_DEPTH_RANGE 0x0B70 +#define GL_DEPTH_WRITEMASK 0x0B72 +#define GL_DEPTH_CLEAR_VALUE 0x0B73 +#define GL_DEPTH_FUNC 0x0B74 +#define GL_STENCIL_CLEAR_VALUE 0x0B91 +#define GL_STENCIL_FUNC 0x0B92 +#define GL_STENCIL_FAIL 0x0B94 +#define GL_STENCIL_PASS_DEPTH_FAIL 0x0B95 +#define GL_STENCIL_PASS_DEPTH_PASS 0x0B96 +#define GL_STENCIL_REF 0x0B97 +#define GL_STENCIL_VALUE_MASK 0x0B93 +#define GL_STENCIL_WRITEMASK 0x0B98 +#define GL_STENCIL_BACK_FUNC 0x8800 +#define GL_STENCIL_BACK_FAIL 0x8801 +#define GL_STENCIL_BACK_PASS_DEPTH_FAIL 0x8802 +#define GL_STENCIL_BACK_PASS_DEPTH_PASS 0x8803 +#define GL_STENCIL_BACK_REF 0x8CA3 +#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4 +#define GL_STENCIL_BACK_WRITEMASK 0x8CA5 +#define GL_VIEWPORT 0x0BA2 +#define GL_SCISSOR_BOX 0x0C10 +#define GL_COLOR_CLEAR_VALUE 0x0C22 +#define GL_COLOR_WRITEMASK 0x0C23 +#define GL_UNPACK_ALIGNMENT 0x0CF5 +#define GL_PACK_ALIGNMENT 0x0D05 +#define GL_MAX_TEXTURE_SIZE 0x0D33 +#define GL_MAX_VIEWPORT_DIMS 0x0D3A +#define GL_SUBPIXEL_BITS 0x0D50 +#define GL_RED_BITS 0x0D52 +#define GL_GREEN_BITS 0x0D53 +#define GL_BLUE_BITS 0x0D54 +#define GL_ALPHA_BITS 0x0D55 +#define GL_DEPTH_BITS 0x0D56 +#define GL_STENCIL_BITS 0x0D57 +#define GL_POLYGON_OFFSET_UNITS 0x2A00 +#define GL_POLYGON_OFFSET_FACTOR 0x8038 +#define GL_TEXTURE_BINDING_2D 0x8069 +#define GL_SAMPLE_BUFFERS 0x80A8 +#define GL_SAMPLES 0x80A9 +#define GL_SAMPLE_COVERAGE_VALUE 0x80AA +#define GL_SAMPLE_COVERAGE_INVERT 0x80AB +#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 +#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 +#define GL_DONT_CARE 0x1100 +#define GL_FASTEST 0x1101 +#define GL_NICEST 0x1102 +#define GL_GENERATE_MIPMAP_HINT 0x8192 +#define GL_BYTE 0x1400 +#define GL_UNSIGNED_BYTE 0x1401 +#define GL_SHORT 0x1402 +#define GL_UNSIGNED_SHORT 0x1403 +#define GL_INT 0x1404 +#define GL_UNSIGNED_INT 0x1405 +#define GL_FLOAT 0x1406 +#define GL_FIXED 0x140C +#define GL_DEPTH_COMPONENT 0x1902 +#define GL_ALPHA 0x1906 +#define GL_RGB 0x1907 +#define GL_RGBA 0x1908 +#define GL_LUMINANCE 0x1909 +#define GL_LUMINANCE_ALPHA 0x190A +#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033 +#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034 +#define GL_UNSIGNED_SHORT_5_6_5 0x8363 +#define GL_FRAGMENT_SHADER 0x8B30 +#define GL_VERTEX_SHADER 0x8B31 +#define GL_MAX_VERTEX_ATTRIBS 0x8869 +#define GL_MAX_VERTEX_UNIFORM_VECTORS 0x8DFB +#define GL_MAX_VARYING_VECTORS 0x8DFC +#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS 0x8B4D +#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS 0x8B4C +#define GL_MAX_TEXTURE_IMAGE_UNITS 0x8872 +#define GL_MAX_FRAGMENT_UNIFORM_VECTORS 0x8DFD +#define GL_SHADER_TYPE 0x8B4F +#define GL_DELETE_STATUS 0x8B80 +#define GL_LINK_STATUS 0x8B82 +#define GL_VALIDATE_STATUS 0x8B83 +#define GL_ATTACHED_SHADERS 0x8B85 +#define GL_ACTIVE_UNIFORMS 0x8B86 +#define GL_ACTIVE_UNIFORM_MAX_LENGTH 0x8B87 +#define GL_ACTIVE_ATTRIBUTES 0x8B89 +#define GL_ACTIVE_ATTRIBUTE_MAX_LENGTH 0x8B8A +#define GL_SHADING_LANGUAGE_VERSION 0x8B8C +#define GL_CURRENT_PROGRAM 0x8B8D +#define GL_NEVER 0x0200 +#define GL_LESS 0x0201 +#define GL_EQUAL 0x0202 +#define GL_LEQUAL 0x0203 +#define GL_GREATER 0x0204 +#define GL_NOTEQUAL 0x0205 +#define GL_GEQUAL 0x0206 +#define GL_ALWAYS 0x0207 +#define GL_KEEP 0x1E00 +#define GL_REPLACE 0x1E01 +#define GL_INCR 0x1E02 +#define GL_DECR 0x1E03 +#define GL_INVERT 0x150A +#define GL_INCR_WRAP 0x8507 +#define GL_DECR_WRAP 0x8508 +#define GL_VENDOR 0x1F00 +#define GL_RENDERER 0x1F01 +#define GL_VERSION 0x1F02 +#define GL_EXTENSIONS 0x1F03 +#define GL_NEAREST 0x2600 +#define GL_LINEAR 0x2601 +#define GL_NEAREST_MIPMAP_NEAREST 0x2700 +#define GL_LINEAR_MIPMAP_NEAREST 0x2701 +#define GL_NEAREST_MIPMAP_LINEAR 0x2702 +#define GL_LINEAR_MIPMAP_LINEAR 0x2703 +#define GL_TEXTURE_MAG_FILTER 0x2800 +#define GL_TEXTURE_MIN_FILTER 0x2801 +#define GL_TEXTURE_WRAP_S 0x2802 +#define GL_TEXTURE_WRAP_T 0x2803 +#define GL_TEXTURE 0x1702 +#define GL_TEXTURE_CUBE_MAP 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C +#define GL_TEXTURE0 0x84C0 +#define GL_TEXTURE1 0x84C1 +#define GL_TEXTURE2 0x84C2 +#define GL_TEXTURE3 0x84C3 +#define GL_TEXTURE4 0x84C4 +#define GL_TEXTURE5 0x84C5 +#define GL_TEXTURE6 0x84C6 +#define GL_TEXTURE7 0x84C7 +#define GL_TEXTURE8 0x84C8 +#define GL_TEXTURE9 0x84C9 +#define GL_TEXTURE10 0x84CA +#define GL_TEXTURE11 0x84CB +#define GL_TEXTURE12 0x84CC +#define GL_TEXTURE13 0x84CD +#define GL_TEXTURE14 0x84CE +#define GL_TEXTURE15 0x84CF +#define GL_TEXTURE16 0x84D0 +#define GL_TEXTURE17 0x84D1 +#define GL_TEXTURE18 0x84D2 +#define GL_TEXTURE19 0x84D3 +#define GL_TEXTURE20 0x84D4 +#define GL_TEXTURE21 0x84D5 +#define GL_TEXTURE22 0x84D6 +#define GL_TEXTURE23 0x84D7 +#define GL_TEXTURE24 0x84D8 +#define GL_TEXTURE25 0x84D9 +#define GL_TEXTURE26 0x84DA +#define GL_TEXTURE27 0x84DB +#define GL_TEXTURE28 0x84DC +#define GL_TEXTURE29 0x84DD +#define GL_TEXTURE30 0x84DE +#define GL_TEXTURE31 0x84DF +#define GL_ACTIVE_TEXTURE 0x84E0 +#define GL_REPEAT 0x2901 +#define GL_CLAMP_TO_EDGE 0x812F +#define GL_MIRRORED_REPEAT 0x8370 +#define GL_FLOAT_VEC2 0x8B50 +#define GL_FLOAT_VEC3 0x8B51 +#define GL_FLOAT_VEC4 0x8B52 +#define GL_INT_VEC2 0x8B53 +#define GL_INT_VEC3 0x8B54 +#define GL_INT_VEC4 0x8B55 +#define GL_BOOL 0x8B56 +#define GL_BOOL_VEC2 0x8B57 +#define GL_BOOL_VEC3 0x8B58 +#define GL_BOOL_VEC4 0x8B59 +#define GL_FLOAT_MAT2 0x8B5A +#define GL_FLOAT_MAT3 0x8B5B +#define GL_FLOAT_MAT4 0x8B5C +#define GL_SAMPLER_2D 0x8B5E +#define GL_SAMPLER_CUBE 0x8B60 +#define GL_VERTEX_ATTRIB_ARRAY_ENABLED 0x8622 +#define GL_VERTEX_ATTRIB_ARRAY_SIZE 0x8623 +#define GL_VERTEX_ATTRIB_ARRAY_STRIDE 0x8624 +#define GL_VERTEX_ATTRIB_ARRAY_TYPE 0x8625 +#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED 0x886A +#define GL_VERTEX_ATTRIB_ARRAY_POINTER 0x8645 +#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 0x889F +#define GL_IMPLEMENTATION_COLOR_READ_TYPE 0x8B9A +#define GL_IMPLEMENTATION_COLOR_READ_FORMAT 0x8B9B +#define GL_COMPILE_STATUS 0x8B81 +#define GL_INFO_LOG_LENGTH 0x8B84 +#define GL_SHADER_SOURCE_LENGTH 0x8B88 +#define GL_SHADER_COMPILER 0x8DFA +#define GL_SHADER_BINARY_FORMATS 0x8DF8 +#define GL_NUM_SHADER_BINARY_FORMATS 0x8DF9 +#define GL_LOW_FLOAT 0x8DF0 +#define GL_MEDIUM_FLOAT 0x8DF1 +#define GL_HIGH_FLOAT 0x8DF2 +#define GL_LOW_INT 0x8DF3 +#define GL_MEDIUM_INT 0x8DF4 +#define GL_HIGH_INT 0x8DF5 +#define GL_FRAMEBUFFER 0x8D40 +#define GL_RENDERBUFFER 0x8D41 +#define GL_RGBA4 0x8056 +#define GL_RGB5_A1 0x8057 +#define GL_RGB565 0x8D62 +#define GL_DEPTH_COMPONENT16 0x81A5 +#define GL_STENCIL_INDEX8 0x8D48 +#define GL_RENDERBUFFER_WIDTH 0x8D42 +#define GL_RENDERBUFFER_HEIGHT 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT 0x8D44 +#define GL_RENDERBUFFER_RED_SIZE 0x8D50 +#define GL_RENDERBUFFER_GREEN_SIZE 0x8D51 +#define GL_RENDERBUFFER_BLUE_SIZE 0x8D52 +#define GL_RENDERBUFFER_ALPHA_SIZE 0x8D53 +#define GL_RENDERBUFFER_DEPTH_SIZE 0x8D54 +#define GL_RENDERBUFFER_STENCIL_SIZE 0x8D55 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE 0x8CD3 +#define GL_COLOR_ATTACHMENT0 0x8CE0 +#define GL_DEPTH_ATTACHMENT 0x8D00 +#define GL_STENCIL_ATTACHMENT 0x8D20 +#define GL_NONE 0 +#define GL_FRAMEBUFFER_COMPLETE 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS 0x8CD9 +#define GL_FRAMEBUFFER_UNSUPPORTED 0x8CDD +#define GL_FRAMEBUFFER_BINDING 0x8CA6 +#define GL_RENDERBUFFER_BINDING 0x8CA7 +#define GL_MAX_RENDERBUFFER_SIZE 0x84E8 +#define GL_INVALID_FRAMEBUFFER_OPERATION 0x0506 +typedef void (GL_APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); +typedef void (GL_APIENTRYP PFNGLATTACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (GL_APIENTRYP PFNGLBINDATTRIBLOCATIONPROC) (GLuint program, GLuint index, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERPROC) (GLenum target, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLBINDFRAMEBUFFERPROC) (GLenum target, GLuint framebuffer); +typedef void (GL_APIENTRYP PFNGLBINDRENDERBUFFERPROC) (GLenum target, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLBINDTEXTUREPROC) (GLenum target, GLuint texture); +typedef void (GL_APIENTRYP PFNGLBLENDCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEPROC) (GLenum modeRGB, GLenum modeAlpha); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCPROC) (GLenum sfactor, GLenum dfactor); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +typedef void (GL_APIENTRYP PFNGLBUFFERDATAPROC) (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +typedef void (GL_APIENTRYP PFNGLBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +typedef GLenum (GL_APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLCLEARPROC) (GLbitfield mask); +typedef void (GL_APIENTRYP PFNGLCLEARCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLCLEARDEPTHFPROC) (GLfloat d); +typedef void (GL_APIENTRYP PFNGLCLEARSTENCILPROC) (GLint s); +typedef void (GL_APIENTRYP PFNGLCOLORMASKPROC) (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +typedef void (GL_APIENTRYP PFNGLCOMPILESHADERPROC) (GLuint shader); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOPYTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef GLuint (GL_APIENTRYP PFNGLCREATEPROGRAMPROC) (void); +typedef GLuint (GL_APIENTRYP PFNGLCREATESHADERPROC) (GLenum type); +typedef void (GL_APIENTRYP PFNGLCULLFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLDELETEBUFFERSPROC) (GLsizei n, const GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLDELETEFRAMEBUFFERSPROC) (GLsizei n, const GLuint *framebuffers); +typedef void (GL_APIENTRYP PFNGLDELETEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLDELETERENDERBUFFERSPROC) (GLsizei n, const GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLDELETESHADERPROC) (GLuint shader); +typedef void (GL_APIENTRYP PFNGLDELETETEXTURESPROC) (GLsizei n, const GLuint *textures); +typedef void (GL_APIENTRYP PFNGLDEPTHFUNCPROC) (GLenum func); +typedef void (GL_APIENTRYP PFNGLDEPTHMASKPROC) (GLboolean flag); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEFPROC) (GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLDETACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (GL_APIENTRYP PFNGLDISABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSPROC) (GLenum mode, GLint first, GLsizei count); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices); +typedef void (GL_APIENTRYP PFNGLENABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (GL_APIENTRYP PFNGLFINISHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFLUSHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFERPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (GL_APIENTRYP PFNGLFRONTFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLGENBUFFERSPROC) (GLsizei n, GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLGENERATEMIPMAPPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGENFRAMEBUFFERSPROC) (GLsizei n, GLuint *framebuffers); +typedef void (GL_APIENTRYP PFNGLGENRENDERBUFFERSPROC) (GLsizei n, GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLGENTEXTURESPROC) (GLsizei n, GLuint *textures); +typedef void (GL_APIENTRYP PFNGLGETACTIVEATTRIBPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETATTACHEDSHADERSPROC) (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *shaders); +typedef GLint (GL_APIENTRYP PFNGLGETATTRIBLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETBOOLEANVPROC) (GLenum pname, GLboolean *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef GLenum (GL_APIENTRYP PFNGLGETERRORPROC) (void); +typedef void (GL_APIENTRYP PFNGLGETFLOATVPROC) (GLenum pname, GLfloat *data); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETINTEGERVPROC) (GLenum pname, GLint *data); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMIVPROC) (GLuint program, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMINFOLOGPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSHADERIVPROC) (GLuint shader, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSHADERINFOLOGPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLGETSHADERPRECISIONFORMATPROC) (GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision); +typedef void (GL_APIENTRYP PFNGLGETSHADERSOURCEPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +typedef const GLubyte *(GL_APIENTRYP PFNGLGETSTRINGPROC) (GLenum name); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMFVPROC) (GLuint program, GLint location, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMIVPROC) (GLuint program, GLint location, GLint *params); +typedef GLint (GL_APIENTRYP PFNGLGETUNIFORMLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBFVPROC) (GLuint index, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVPROC) (GLuint index, GLenum pname, void **pointer); +typedef void (GL_APIENTRYP PFNGLHINTPROC) (GLenum target, GLenum mode); +typedef GLboolean (GL_APIENTRYP PFNGLISBUFFERPROC) (GLuint buffer); +typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDPROC) (GLenum cap); +typedef GLboolean (GL_APIENTRYP PFNGLISFRAMEBUFFERPROC) (GLuint framebuffer); +typedef GLboolean (GL_APIENTRYP PFNGLISPROGRAMPROC) (GLuint program); +typedef GLboolean (GL_APIENTRYP PFNGLISRENDERBUFFERPROC) (GLuint renderbuffer); +typedef GLboolean (GL_APIENTRYP PFNGLISSHADERPROC) (GLuint shader); +typedef GLboolean (GL_APIENTRYP PFNGLISTEXTUREPROC) (GLuint texture); +typedef void (GL_APIENTRYP PFNGLLINEWIDTHPROC) (GLfloat width); +typedef void (GL_APIENTRYP PFNGLLINKPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLPIXELSTOREIPROC) (GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLPOLYGONOFFSETPROC) (GLfloat factor, GLfloat units); +typedef void (GL_APIENTRYP PFNGLREADPIXELSPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +typedef void (GL_APIENTRYP PFNGLRELEASESHADERCOMPILERPROC) (void); +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert); +typedef void (GL_APIENTRYP PFNGLSCISSORPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSHADERBINARYPROC) (GLsizei count, const GLuint *shaders, GLenum binaryformat, const void *binary, GLsizei length); +typedef void (GL_APIENTRYP PFNGLSHADERSOURCEPROC) (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length); +typedef void (GL_APIENTRYP PFNGLSTENCILFUNCPROC) (GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILFUNCSEPARATEPROC) (GLenum face, GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILMASKPROC) (GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILMASKSEPARATEPROC) (GLenum face, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILOPPROC) (GLenum fail, GLenum zfail, GLenum zpass); +typedef void (GL_APIENTRYP PFNGLSTENCILOPSEPARATEPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE2DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFPROC) (GLenum target, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLUNIFORM1FPROC) (GLint location, GLfloat v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM1FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM1IPROC) (GLint location, GLint v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM1IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2FPROC) (GLint location, GLfloat v0, GLfloat v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM2FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2IPROC) (GLint location, GLint v0, GLint v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM2IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM3FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3IPROC) (GLint location, GLint v0, GLint v1, GLint v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM3IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM4FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4IPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM4IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUSEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLVALIDATEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB1FPROC) (GLuint index, GLfloat x); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB1FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB2FPROC) (GLuint index, GLfloat x, GLfloat y); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB2FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB3FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB3FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBPOINTERPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLVIEWPORTPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glActiveTexture (GLenum texture); +GL_APICALL void GL_APIENTRY glAttachShader (GLuint program, GLuint shader); +GL_APICALL void GL_APIENTRY glBindAttribLocation (GLuint program, GLuint index, const GLchar *name); +GL_APICALL void GL_APIENTRY glBindBuffer (GLenum target, GLuint buffer); +GL_APICALL void GL_APIENTRY glBindFramebuffer (GLenum target, GLuint framebuffer); +GL_APICALL void GL_APIENTRY glBindRenderbuffer (GLenum target, GLuint renderbuffer); +GL_APICALL void GL_APIENTRY glBindTexture (GLenum target, GLuint texture); +GL_APICALL void GL_APIENTRY glBlendColor (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_APICALL void GL_APIENTRY glBlendEquation (GLenum mode); +GL_APICALL void GL_APIENTRY glBlendEquationSeparate (GLenum modeRGB, GLenum modeAlpha); +GL_APICALL void GL_APIENTRY glBlendFunc (GLenum sfactor, GLenum dfactor); +GL_APICALL void GL_APIENTRY glBlendFuncSeparate (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +GL_APICALL void GL_APIENTRY glBufferData (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +GL_APICALL void GL_APIENTRY glBufferSubData (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +GL_APICALL GLenum GL_APIENTRY glCheckFramebufferStatus (GLenum target); +GL_APICALL void GL_APIENTRY glClear (GLbitfield mask); +GL_APICALL void GL_APIENTRY glClearColor (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_APICALL void GL_APIENTRY glClearDepthf (GLfloat d); +GL_APICALL void GL_APIENTRY glClearStencil (GLint s); +GL_APICALL void GL_APIENTRY glColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +GL_APICALL void GL_APIENTRY glCompileShader (GLuint shader); +GL_APICALL void GL_APIENTRY glCompressedTexImage2D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCopyTexImage2D (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +GL_APICALL void GL_APIENTRY glCopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL GLuint GL_APIENTRY glCreateProgram (void); +GL_APICALL GLuint GL_APIENTRY glCreateShader (GLenum type); +GL_APICALL void GL_APIENTRY glCullFace (GLenum mode); +GL_APICALL void GL_APIENTRY glDeleteBuffers (GLsizei n, const GLuint *buffers); +GL_APICALL void GL_APIENTRY glDeleteFramebuffers (GLsizei n, const GLuint *framebuffers); +GL_APICALL void GL_APIENTRY glDeleteProgram (GLuint program); +GL_APICALL void GL_APIENTRY glDeleteRenderbuffers (GLsizei n, const GLuint *renderbuffers); +GL_APICALL void GL_APIENTRY glDeleteShader (GLuint shader); +GL_APICALL void GL_APIENTRY glDeleteTextures (GLsizei n, const GLuint *textures); +GL_APICALL void GL_APIENTRY glDepthFunc (GLenum func); +GL_APICALL void GL_APIENTRY glDepthMask (GLboolean flag); +GL_APICALL void GL_APIENTRY glDepthRangef (GLfloat n, GLfloat f); +GL_APICALL void GL_APIENTRY glDetachShader (GLuint program, GLuint shader); +GL_APICALL void GL_APIENTRY glDisable (GLenum cap); +GL_APICALL void GL_APIENTRY glDisableVertexAttribArray (GLuint index); +GL_APICALL void GL_APIENTRY glDrawArrays (GLenum mode, GLint first, GLsizei count); +GL_APICALL void GL_APIENTRY glDrawElements (GLenum mode, GLsizei count, GLenum type, const void *indices); +GL_APICALL void GL_APIENTRY glEnable (GLenum cap); +GL_APICALL void GL_APIENTRY glEnableVertexAttribArray (GLuint index); +GL_APICALL void GL_APIENTRY glFinish (void); +GL_APICALL void GL_APIENTRY glFlush (void); +GL_APICALL void GL_APIENTRY glFramebufferRenderbuffer (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +GL_APICALL void GL_APIENTRY glFramebufferTexture2D (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +GL_APICALL void GL_APIENTRY glFrontFace (GLenum mode); +GL_APICALL void GL_APIENTRY glGenBuffers (GLsizei n, GLuint *buffers); +GL_APICALL void GL_APIENTRY glGenerateMipmap (GLenum target); +GL_APICALL void GL_APIENTRY glGenFramebuffers (GLsizei n, GLuint *framebuffers); +GL_APICALL void GL_APIENTRY glGenRenderbuffers (GLsizei n, GLuint *renderbuffers); +GL_APICALL void GL_APIENTRY glGenTextures (GLsizei n, GLuint *textures); +GL_APICALL void GL_APIENTRY glGetActiveAttrib (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glGetActiveUniform (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glGetAttachedShaders (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *shaders); +GL_APICALL GLint GL_APIENTRY glGetAttribLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetBooleanv (GLenum pname, GLboolean *data); +GL_APICALL void GL_APIENTRY glGetBufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL GLenum GL_APIENTRY glGetError (void); +GL_APICALL void GL_APIENTRY glGetFloatv (GLenum pname, GLfloat *data); +GL_APICALL void GL_APIENTRY glGetFramebufferAttachmentParameteriv (GLenum target, GLenum attachment, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetIntegerv (GLenum pname, GLint *data); +GL_APICALL void GL_APIENTRY glGetProgramiv (GLuint program, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetProgramInfoLog (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glGetRenderbufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetShaderiv (GLuint shader, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetShaderInfoLog (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glGetShaderPrecisionFormat (GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision); +GL_APICALL void GL_APIENTRY glGetShaderSource (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +GL_APICALL const GLubyte *GL_APIENTRY glGetString (GLenum name); +GL_APICALL void GL_APIENTRY glGetTexParameterfv (GLenum target, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetTexParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetUniformfv (GLuint program, GLint location, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetUniformiv (GLuint program, GLint location, GLint *params); +GL_APICALL GLint GL_APIENTRY glGetUniformLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetVertexAttribfv (GLuint index, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribiv (GLuint index, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribPointerv (GLuint index, GLenum pname, void **pointer); +GL_APICALL void GL_APIENTRY glHint (GLenum target, GLenum mode); +GL_APICALL GLboolean GL_APIENTRY glIsBuffer (GLuint buffer); +GL_APICALL GLboolean GL_APIENTRY glIsEnabled (GLenum cap); +GL_APICALL GLboolean GL_APIENTRY glIsFramebuffer (GLuint framebuffer); +GL_APICALL GLboolean GL_APIENTRY glIsProgram (GLuint program); +GL_APICALL GLboolean GL_APIENTRY glIsRenderbuffer (GLuint renderbuffer); +GL_APICALL GLboolean GL_APIENTRY glIsShader (GLuint shader); +GL_APICALL GLboolean GL_APIENTRY glIsTexture (GLuint texture); +GL_APICALL void GL_APIENTRY glLineWidth (GLfloat width); +GL_APICALL void GL_APIENTRY glLinkProgram (GLuint program); +GL_APICALL void GL_APIENTRY glPixelStorei (GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glPolygonOffset (GLfloat factor, GLfloat units); +GL_APICALL void GL_APIENTRY glReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +GL_APICALL void GL_APIENTRY glReleaseShaderCompiler (void); +GL_APICALL void GL_APIENTRY glRenderbufferStorage (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glSampleCoverage (GLfloat value, GLboolean invert); +GL_APICALL void GL_APIENTRY glScissor (GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glShaderBinary (GLsizei count, const GLuint *shaders, GLenum binaryformat, const void *binary, GLsizei length); +GL_APICALL void GL_APIENTRY glShaderSource (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length); +GL_APICALL void GL_APIENTRY glStencilFunc (GLenum func, GLint ref, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilFuncSeparate (GLenum face, GLenum func, GLint ref, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilMask (GLuint mask); +GL_APICALL void GL_APIENTRY glStencilMaskSeparate (GLenum face, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilOp (GLenum fail, GLenum zfail, GLenum zpass); +GL_APICALL void GL_APIENTRY glStencilOpSeparate (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +GL_APICALL void GL_APIENTRY glTexImage2D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glTexParameterf (GLenum target, GLenum pname, GLfloat param); +GL_APICALL void GL_APIENTRY glTexParameterfv (GLenum target, GLenum pname, const GLfloat *params); +GL_APICALL void GL_APIENTRY glTexParameteri (GLenum target, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glTexParameteriv (GLenum target, GLenum pname, const GLint *params); +GL_APICALL void GL_APIENTRY glTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glUniform1f (GLint location, GLfloat v0); +GL_APICALL void GL_APIENTRY glUniform1fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform1i (GLint location, GLint v0); +GL_APICALL void GL_APIENTRY glUniform1iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform2f (GLint location, GLfloat v0, GLfloat v1); +GL_APICALL void GL_APIENTRY glUniform2fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform2i (GLint location, GLint v0, GLint v1); +GL_APICALL void GL_APIENTRY glUniform2iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform3f (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +GL_APICALL void GL_APIENTRY glUniform3fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform3i (GLint location, GLint v0, GLint v1, GLint v2); +GL_APICALL void GL_APIENTRY glUniform3iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform4f (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +GL_APICALL void GL_APIENTRY glUniform4fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform4i (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +GL_APICALL void GL_APIENTRY glUniform4iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniformMatrix2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUseProgram (GLuint program); +GL_APICALL void GL_APIENTRY glValidateProgram (GLuint program); +GL_APICALL void GL_APIENTRY glVertexAttrib1f (GLuint index, GLfloat x); +GL_APICALL void GL_APIENTRY glVertexAttrib1fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib2f (GLuint index, GLfloat x, GLfloat y); +GL_APICALL void GL_APIENTRY glVertexAttrib2fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib3f (GLuint index, GLfloat x, GLfloat y, GLfloat z); +GL_APICALL void GL_APIENTRY glVertexAttrib3fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib4f (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +GL_APICALL void GL_APIENTRY glVertexAttrib4fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttribPointer (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer); +GL_APICALL void GL_APIENTRY glViewport (GLint x, GLint y, GLsizei width, GLsizei height); +#endif +#endif /* GL_ES_VERSION_2_0 */ + +#ifndef GL_ES_VERSION_3_0 +#define GL_ES_VERSION_3_0 1 +typedef khronos_uint16_t GLhalf; +#define GL_READ_BUFFER 0x0C02 +#define GL_UNPACK_ROW_LENGTH 0x0CF2 +#define GL_UNPACK_SKIP_ROWS 0x0CF3 +#define GL_UNPACK_SKIP_PIXELS 0x0CF4 +#define GL_PACK_ROW_LENGTH 0x0D02 +#define GL_PACK_SKIP_ROWS 0x0D03 +#define GL_PACK_SKIP_PIXELS 0x0D04 +#define GL_COLOR 0x1800 +#define GL_DEPTH 0x1801 +#define GL_STENCIL 0x1802 +#define GL_RED 0x1903 +#define GL_RGB8 0x8051 +#define GL_RGBA8 0x8058 +#define GL_RGB10_A2 0x8059 +#define GL_TEXTURE_BINDING_3D 0x806A +#define GL_UNPACK_SKIP_IMAGES 0x806D +#define GL_UNPACK_IMAGE_HEIGHT 0x806E +#define GL_TEXTURE_3D 0x806F +#define GL_TEXTURE_WRAP_R 0x8072 +#define GL_MAX_3D_TEXTURE_SIZE 0x8073 +#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368 +#define GL_MAX_ELEMENTS_VERTICES 0x80E8 +#define GL_MAX_ELEMENTS_INDICES 0x80E9 +#define GL_TEXTURE_MIN_LOD 0x813A +#define GL_TEXTURE_MAX_LOD 0x813B +#define GL_TEXTURE_BASE_LEVEL 0x813C +#define GL_TEXTURE_MAX_LEVEL 0x813D +#define GL_MIN 0x8007 +#define GL_MAX 0x8008 +#define GL_DEPTH_COMPONENT24 0x81A6 +#define GL_MAX_TEXTURE_LOD_BIAS 0x84FD +#define GL_TEXTURE_COMPARE_MODE 0x884C +#define GL_TEXTURE_COMPARE_FUNC 0x884D +#define GL_CURRENT_QUERY 0x8865 +#define GL_QUERY_RESULT 0x8866 +#define GL_QUERY_RESULT_AVAILABLE 0x8867 +#define GL_BUFFER_MAPPED 0x88BC +#define GL_BUFFER_MAP_POINTER 0x88BD +#define GL_STREAM_READ 0x88E1 +#define GL_STREAM_COPY 0x88E2 +#define GL_STATIC_READ 0x88E5 +#define GL_STATIC_COPY 0x88E6 +#define GL_DYNAMIC_READ 0x88E9 +#define GL_DYNAMIC_COPY 0x88EA +#define GL_MAX_DRAW_BUFFERS 0x8824 +#define GL_DRAW_BUFFER0 0x8825 +#define GL_DRAW_BUFFER1 0x8826 +#define GL_DRAW_BUFFER2 0x8827 +#define GL_DRAW_BUFFER3 0x8828 +#define GL_DRAW_BUFFER4 0x8829 +#define GL_DRAW_BUFFER5 0x882A +#define GL_DRAW_BUFFER6 0x882B +#define GL_DRAW_BUFFER7 0x882C +#define GL_DRAW_BUFFER8 0x882D +#define GL_DRAW_BUFFER9 0x882E +#define GL_DRAW_BUFFER10 0x882F +#define GL_DRAW_BUFFER11 0x8830 +#define GL_DRAW_BUFFER12 0x8831 +#define GL_DRAW_BUFFER13 0x8832 +#define GL_DRAW_BUFFER14 0x8833 +#define GL_DRAW_BUFFER15 0x8834 +#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS 0x8B49 +#define GL_MAX_VERTEX_UNIFORM_COMPONENTS 0x8B4A +#define GL_SAMPLER_3D 0x8B5F +#define GL_SAMPLER_2D_SHADOW 0x8B62 +#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT 0x8B8B +#define GL_PIXEL_PACK_BUFFER 0x88EB +#define GL_PIXEL_UNPACK_BUFFER 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING 0x88EF +#define GL_FLOAT_MAT2x3 0x8B65 +#define GL_FLOAT_MAT2x4 0x8B66 +#define GL_FLOAT_MAT3x2 0x8B67 +#define GL_FLOAT_MAT3x4 0x8B68 +#define GL_FLOAT_MAT4x2 0x8B69 +#define GL_FLOAT_MAT4x3 0x8B6A +#define GL_SRGB 0x8C40 +#define GL_SRGB8 0x8C41 +#define GL_SRGB8_ALPHA8 0x8C43 +#define GL_COMPARE_REF_TO_TEXTURE 0x884E +#define GL_MAJOR_VERSION 0x821B +#define GL_MINOR_VERSION 0x821C +#define GL_NUM_EXTENSIONS 0x821D +#define GL_RGBA32F 0x8814 +#define GL_RGB32F 0x8815 +#define GL_RGBA16F 0x881A +#define GL_RGB16F 0x881B +#define GL_VERTEX_ATTRIB_ARRAY_INTEGER 0x88FD +#define GL_MAX_ARRAY_TEXTURE_LAYERS 0x88FF +#define GL_MIN_PROGRAM_TEXEL_OFFSET 0x8904 +#define GL_MAX_PROGRAM_TEXEL_OFFSET 0x8905 +#define GL_MAX_VARYING_COMPONENTS 0x8B4B +#define GL_TEXTURE_2D_ARRAY 0x8C1A +#define GL_TEXTURE_BINDING_2D_ARRAY 0x8C1D +#define GL_R11F_G11F_B10F 0x8C3A +#define GL_UNSIGNED_INT_10F_11F_11F_REV 0x8C3B +#define GL_RGB9_E5 0x8C3D +#define GL_UNSIGNED_INT_5_9_9_9_REV 0x8C3E +#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH 0x8C76 +#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE 0x8C7F +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS 0x8C80 +#define GL_TRANSFORM_FEEDBACK_VARYINGS 0x8C83 +#define GL_TRANSFORM_FEEDBACK_BUFFER_START 0x8C84 +#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE 0x8C85 +#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN 0x8C88 +#define GL_RASTERIZER_DISCARD 0x8C89 +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS 0x8C8B +#define GL_INTERLEAVED_ATTRIBS 0x8C8C +#define GL_SEPARATE_ATTRIBS 0x8C8D +#define GL_TRANSFORM_FEEDBACK_BUFFER 0x8C8E +#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING 0x8C8F +#define GL_RGBA32UI 0x8D70 +#define GL_RGB32UI 0x8D71 +#define GL_RGBA16UI 0x8D76 +#define GL_RGB16UI 0x8D77 +#define GL_RGBA8UI 0x8D7C +#define GL_RGB8UI 0x8D7D +#define GL_RGBA32I 0x8D82 +#define GL_RGB32I 0x8D83 +#define GL_RGBA16I 0x8D88 +#define GL_RGB16I 0x8D89 +#define GL_RGBA8I 0x8D8E +#define GL_RGB8I 0x8D8F +#define GL_RED_INTEGER 0x8D94 +#define GL_RGB_INTEGER 0x8D98 +#define GL_RGBA_INTEGER 0x8D99 +#define GL_SAMPLER_2D_ARRAY 0x8DC1 +#define GL_SAMPLER_2D_ARRAY_SHADOW 0x8DC4 +#define GL_SAMPLER_CUBE_SHADOW 0x8DC5 +#define GL_UNSIGNED_INT_VEC2 0x8DC6 +#define GL_UNSIGNED_INT_VEC3 0x8DC7 +#define GL_UNSIGNED_INT_VEC4 0x8DC8 +#define GL_INT_SAMPLER_2D 0x8DCA +#define GL_INT_SAMPLER_3D 0x8DCB +#define GL_INT_SAMPLER_CUBE 0x8DCC +#define GL_INT_SAMPLER_2D_ARRAY 0x8DCF +#define GL_UNSIGNED_INT_SAMPLER_2D 0x8DD2 +#define GL_UNSIGNED_INT_SAMPLER_3D 0x8DD3 +#define GL_UNSIGNED_INT_SAMPLER_CUBE 0x8DD4 +#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY 0x8DD7 +#define GL_BUFFER_ACCESS_FLAGS 0x911F +#define GL_BUFFER_MAP_LENGTH 0x9120 +#define GL_BUFFER_MAP_OFFSET 0x9121 +#define GL_DEPTH_COMPONENT32F 0x8CAC +#define GL_DEPTH32F_STENCIL8 0x8CAD +#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV 0x8DAD +#define GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING 0x8210 +#define GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE 0x8211 +#define GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE 0x8212 +#define GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE 0x8213 +#define GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE 0x8214 +#define GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE 0x8215 +#define GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE 0x8216 +#define GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE 0x8217 +#define GL_FRAMEBUFFER_DEFAULT 0x8218 +#define GL_FRAMEBUFFER_UNDEFINED 0x8219 +#define GL_DEPTH_STENCIL_ATTACHMENT 0x821A +#define GL_DEPTH_STENCIL 0x84F9 +#define GL_UNSIGNED_INT_24_8 0x84FA +#define GL_DEPTH24_STENCIL8 0x88F0 +#define GL_UNSIGNED_NORMALIZED 0x8C17 +#define GL_DRAW_FRAMEBUFFER_BINDING 0x8CA6 +#define GL_READ_FRAMEBUFFER 0x8CA8 +#define GL_DRAW_FRAMEBUFFER 0x8CA9 +#define GL_READ_FRAMEBUFFER_BINDING 0x8CAA +#define GL_RENDERBUFFER_SAMPLES 0x8CAB +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER 0x8CD4 +#define GL_MAX_COLOR_ATTACHMENTS 0x8CDF +#define GL_COLOR_ATTACHMENT1 0x8CE1 +#define GL_COLOR_ATTACHMENT2 0x8CE2 +#define GL_COLOR_ATTACHMENT3 0x8CE3 +#define GL_COLOR_ATTACHMENT4 0x8CE4 +#define GL_COLOR_ATTACHMENT5 0x8CE5 +#define GL_COLOR_ATTACHMENT6 0x8CE6 +#define GL_COLOR_ATTACHMENT7 0x8CE7 +#define GL_COLOR_ATTACHMENT8 0x8CE8 +#define GL_COLOR_ATTACHMENT9 0x8CE9 +#define GL_COLOR_ATTACHMENT10 0x8CEA +#define GL_COLOR_ATTACHMENT11 0x8CEB +#define GL_COLOR_ATTACHMENT12 0x8CEC +#define GL_COLOR_ATTACHMENT13 0x8CED +#define GL_COLOR_ATTACHMENT14 0x8CEE +#define GL_COLOR_ATTACHMENT15 0x8CEF +#define GL_COLOR_ATTACHMENT16 0x8CF0 +#define GL_COLOR_ATTACHMENT17 0x8CF1 +#define GL_COLOR_ATTACHMENT18 0x8CF2 +#define GL_COLOR_ATTACHMENT19 0x8CF3 +#define GL_COLOR_ATTACHMENT20 0x8CF4 +#define GL_COLOR_ATTACHMENT21 0x8CF5 +#define GL_COLOR_ATTACHMENT22 0x8CF6 +#define GL_COLOR_ATTACHMENT23 0x8CF7 +#define GL_COLOR_ATTACHMENT24 0x8CF8 +#define GL_COLOR_ATTACHMENT25 0x8CF9 +#define GL_COLOR_ATTACHMENT26 0x8CFA +#define GL_COLOR_ATTACHMENT27 0x8CFB +#define GL_COLOR_ATTACHMENT28 0x8CFC +#define GL_COLOR_ATTACHMENT29 0x8CFD +#define GL_COLOR_ATTACHMENT30 0x8CFE +#define GL_COLOR_ATTACHMENT31 0x8CFF +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE 0x8D56 +#define GL_MAX_SAMPLES 0x8D57 +#define GL_HALF_FLOAT 0x140B +#define GL_MAP_READ_BIT 0x0001 +#define GL_MAP_WRITE_BIT 0x0002 +#define GL_MAP_INVALIDATE_RANGE_BIT 0x0004 +#define GL_MAP_INVALIDATE_BUFFER_BIT 0x0008 +#define GL_MAP_FLUSH_EXPLICIT_BIT 0x0010 +#define GL_MAP_UNSYNCHRONIZED_BIT 0x0020 +#define GL_RG 0x8227 +#define GL_RG_INTEGER 0x8228 +#define GL_R8 0x8229 +#define GL_RG8 0x822B +#define GL_R16F 0x822D +#define GL_R32F 0x822E +#define GL_RG16F 0x822F +#define GL_RG32F 0x8230 +#define GL_R8I 0x8231 +#define GL_R8UI 0x8232 +#define GL_R16I 0x8233 +#define GL_R16UI 0x8234 +#define GL_R32I 0x8235 +#define GL_R32UI 0x8236 +#define GL_RG8I 0x8237 +#define GL_RG8UI 0x8238 +#define GL_RG16I 0x8239 +#define GL_RG16UI 0x823A +#define GL_RG32I 0x823B +#define GL_RG32UI 0x823C +#define GL_VERTEX_ARRAY_BINDING 0x85B5 +#define GL_R8_SNORM 0x8F94 +#define GL_RG8_SNORM 0x8F95 +#define GL_RGB8_SNORM 0x8F96 +#define GL_RGBA8_SNORM 0x8F97 +#define GL_SIGNED_NORMALIZED 0x8F9C +#define GL_PRIMITIVE_RESTART_FIXED_INDEX 0x8D69 +#define GL_COPY_READ_BUFFER 0x8F36 +#define GL_COPY_WRITE_BUFFER 0x8F37 +#define GL_COPY_READ_BUFFER_BINDING 0x8F36 +#define GL_COPY_WRITE_BUFFER_BINDING 0x8F37 +#define GL_UNIFORM_BUFFER 0x8A11 +#define GL_UNIFORM_BUFFER_BINDING 0x8A28 +#define GL_UNIFORM_BUFFER_START 0x8A29 +#define GL_UNIFORM_BUFFER_SIZE 0x8A2A +#define GL_MAX_VERTEX_UNIFORM_BLOCKS 0x8A2B +#define GL_MAX_FRAGMENT_UNIFORM_BLOCKS 0x8A2D +#define GL_MAX_COMBINED_UNIFORM_BLOCKS 0x8A2E +#define GL_MAX_UNIFORM_BUFFER_BINDINGS 0x8A2F +#define GL_MAX_UNIFORM_BLOCK_SIZE 0x8A30 +#define GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS 0x8A31 +#define GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS 0x8A33 +#define GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT 0x8A34 +#define GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH 0x8A35 +#define GL_ACTIVE_UNIFORM_BLOCKS 0x8A36 +#define GL_UNIFORM_TYPE 0x8A37 +#define GL_UNIFORM_SIZE 0x8A38 +#define GL_UNIFORM_NAME_LENGTH 0x8A39 +#define GL_UNIFORM_BLOCK_INDEX 0x8A3A +#define GL_UNIFORM_OFFSET 0x8A3B +#define GL_UNIFORM_ARRAY_STRIDE 0x8A3C +#define GL_UNIFORM_MATRIX_STRIDE 0x8A3D +#define GL_UNIFORM_IS_ROW_MAJOR 0x8A3E +#define GL_UNIFORM_BLOCK_BINDING 0x8A3F +#define GL_UNIFORM_BLOCK_DATA_SIZE 0x8A40 +#define GL_UNIFORM_BLOCK_NAME_LENGTH 0x8A41 +#define GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS 0x8A42 +#define GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES 0x8A43 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER 0x8A44 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER 0x8A46 +#define GL_INVALID_INDEX 0xFFFFFFFFu +#define GL_MAX_VERTEX_OUTPUT_COMPONENTS 0x9122 +#define GL_MAX_FRAGMENT_INPUT_COMPONENTS 0x9125 +#define GL_MAX_SERVER_WAIT_TIMEOUT 0x9111 +#define GL_OBJECT_TYPE 0x9112 +#define GL_SYNC_CONDITION 0x9113 +#define GL_SYNC_STATUS 0x9114 +#define GL_SYNC_FLAGS 0x9115 +#define GL_SYNC_FENCE 0x9116 +#define GL_SYNC_GPU_COMMANDS_COMPLETE 0x9117 +#define GL_UNSIGNALED 0x9118 +#define GL_SIGNALED 0x9119 +#define GL_ALREADY_SIGNALED 0x911A +#define GL_TIMEOUT_EXPIRED 0x911B +#define GL_CONDITION_SATISFIED 0x911C +#define GL_WAIT_FAILED 0x911D +#define GL_SYNC_FLUSH_COMMANDS_BIT 0x00000001 +#define GL_TIMEOUT_IGNORED 0xFFFFFFFFFFFFFFFFull +#define GL_VERTEX_ATTRIB_ARRAY_DIVISOR 0x88FE +#define GL_ANY_SAMPLES_PASSED 0x8C2F +#define GL_ANY_SAMPLES_PASSED_CONSERVATIVE 0x8D6A +#define GL_SAMPLER_BINDING 0x8919 +#define GL_RGB10_A2UI 0x906F +#define GL_TEXTURE_SWIZZLE_R 0x8E42 +#define GL_TEXTURE_SWIZZLE_G 0x8E43 +#define GL_TEXTURE_SWIZZLE_B 0x8E44 +#define GL_TEXTURE_SWIZZLE_A 0x8E45 +#define GL_GREEN 0x1904 +#define GL_BLUE 0x1905 +#define GL_INT_2_10_10_10_REV 0x8D9F +#define GL_TRANSFORM_FEEDBACK 0x8E22 +#define GL_TRANSFORM_FEEDBACK_PAUSED 0x8E23 +#define GL_TRANSFORM_FEEDBACK_ACTIVE 0x8E24 +#define GL_TRANSFORM_FEEDBACK_BINDING 0x8E25 +#define GL_PROGRAM_BINARY_RETRIEVABLE_HINT 0x8257 +#define GL_PROGRAM_BINARY_LENGTH 0x8741 +#define GL_NUM_PROGRAM_BINARY_FORMATS 0x87FE +#define GL_PROGRAM_BINARY_FORMATS 0x87FF +#define GL_COMPRESSED_R11_EAC 0x9270 +#define GL_COMPRESSED_SIGNED_R11_EAC 0x9271 +#define GL_COMPRESSED_RG11_EAC 0x9272 +#define GL_COMPRESSED_SIGNED_RG11_EAC 0x9273 +#define GL_COMPRESSED_RGB8_ETC2 0x9274 +#define GL_COMPRESSED_SRGB8_ETC2 0x9275 +#define GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9276 +#define GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9277 +#define GL_COMPRESSED_RGBA8_ETC2_EAC 0x9278 +#define GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC 0x9279 +#define GL_TEXTURE_IMMUTABLE_FORMAT 0x912F +#define GL_MAX_ELEMENT_INDEX 0x8D6B +#define GL_NUM_SAMPLE_COUNTS 0x9380 +#define GL_TEXTURE_IMMUTABLE_LEVELS 0x82DF +typedef void (GL_APIENTRYP PFNGLREADBUFFERPROC) (GLenum src); +typedef void (GL_APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLGENQUERIESPROC) (GLsizei n, GLuint *ids); +typedef void (GL_APIENTRYP PFNGLDELETEQUERIESPROC) (GLsizei n, const GLuint *ids); +typedef GLboolean (GL_APIENTRYP PFNGLISQUERYPROC) (GLuint id); +typedef void (GL_APIENTRYP PFNGLBEGINQUERYPROC) (GLenum target, GLuint id); +typedef void (GL_APIENTRYP PFNGLENDQUERYPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGETQUERYIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUIVPROC) (GLuint id, GLenum pname, GLuint *params); +typedef GLboolean (GL_APIENTRYP PFNGLUNMAPBUFFERPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVPROC) (GLenum target, GLenum pname, void **params); +typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSPROC) (GLsizei n, const GLenum *bufs); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLBLITFRAMEBUFFERPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYERPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); +typedef void *(GL_APIENTRYP PFNGLMAPBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +typedef void (GL_APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length); +typedef void (GL_APIENTRYP PFNGLBINDVERTEXARRAYPROC) (GLuint array); +typedef void (GL_APIENTRYP PFNGLDELETEVERTEXARRAYSPROC) (GLsizei n, const GLuint *arrays); +typedef void (GL_APIENTRYP PFNGLGENVERTEXARRAYSPROC) (GLsizei n, GLuint *arrays); +typedef GLboolean (GL_APIENTRYP PFNGLISVERTEXARRAYPROC) (GLuint array); +typedef void (GL_APIENTRYP PFNGLGETINTEGERI_VPROC) (GLenum target, GLuint index, GLint *data); +typedef void (GL_APIENTRYP PFNGLBEGINTRANSFORMFEEDBACKPROC) (GLenum primitiveMode); +typedef void (GL_APIENTRYP PFNGLENDTRANSFORMFEEDBACKPROC) (void); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERRANGEPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERBASEPROC) (GLenum target, GLuint index, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLTRANSFORMFEEDBACKVARYINGSPROC) (GLuint program, GLsizei count, const GLchar *const*varyings, GLenum bufferMode); +typedef void (GL_APIENTRYP PFNGLGETTRANSFORMFEEDBACKVARYINGPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBIPOINTERPROC) (GLuint index, GLint size, GLenum type, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIIVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIUIVPROC) (GLuint index, GLenum pname, GLuint *params); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4IPROC) (GLuint index, GLint x, GLint y, GLint z, GLint w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4UIPROC) (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4IVPROC) (GLuint index, const GLint *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4UIVPROC) (GLuint index, const GLuint *v); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMUIVPROC) (GLuint program, GLint location, GLuint *params); +typedef GLint (GL_APIENTRYP PFNGLGETFRAGDATALOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLUNIFORM1UIPROC) (GLint location, GLuint v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM2UIPROC) (GLint location, GLuint v0, GLuint v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM3UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM4UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM1UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERIVPROC) (GLenum buffer, GLint drawbuffer, const GLint *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERUIVPROC) (GLenum buffer, GLint drawbuffer, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERFVPROC) (GLenum buffer, GLint drawbuffer, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERFIPROC) (GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil); +typedef const GLubyte *(GL_APIENTRYP PFNGLGETSTRINGIPROC) (GLenum name, GLuint index); +typedef void (GL_APIENTRYP PFNGLCOPYBUFFERSUBDATAPROC) (GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMINDICESPROC) (GLuint program, GLsizei uniformCount, const GLchar *const*uniformNames, GLuint *uniformIndices); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMSIVPROC) (GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params); +typedef GLuint (GL_APIENTRYP PFNGLGETUNIFORMBLOCKINDEXPROC) (GLuint program, const GLchar *uniformBlockName); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMBLOCKIVPROC) (GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMBLOCKNAMEPROC) (GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName); +typedef void (GL_APIENTRYP PFNGLUNIFORMBLOCKBINDINGPROC) (GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instancecount); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount); +typedef GLsync (GL_APIENTRYP PFNGLFENCESYNCPROC) (GLenum condition, GLbitfield flags); +typedef GLboolean (GL_APIENTRYP PFNGLISSYNCPROC) (GLsync sync); +typedef void (GL_APIENTRYP PFNGLDELETESYNCPROC) (GLsync sync); +typedef GLenum (GL_APIENTRYP PFNGLCLIENTWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64VPROC) (GLenum pname, GLint64 *data); +typedef void (GL_APIENTRYP PFNGLGETSYNCIVPROC) (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64I_VPROC) (GLenum target, GLuint index, GLint64 *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERI64VPROC) (GLenum target, GLenum pname, GLint64 *params); +typedef void (GL_APIENTRYP PFNGLGENSAMPLERSPROC) (GLsizei count, GLuint *samplers); +typedef void (GL_APIENTRYP PFNGLDELETESAMPLERSPROC) (GLsizei count, const GLuint *samplers); +typedef GLboolean (GL_APIENTRYP PFNGLISSAMPLERPROC) (GLuint sampler); +typedef void (GL_APIENTRYP PFNGLBINDSAMPLERPROC) (GLuint unit, GLuint sampler); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIPROC) (GLuint sampler, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIVPROC) (GLuint sampler, GLenum pname, const GLint *param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERFPROC) (GLuint sampler, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERFVPROC) (GLuint sampler, GLenum pname, const GLfloat *param); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIVPROC) (GLuint sampler, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERFVPROC) (GLuint sampler, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISORPROC) (GLuint index, GLuint divisor); +typedef void (GL_APIENTRYP PFNGLBINDTRANSFORMFEEDBACKPROC) (GLenum target, GLuint id); +typedef void (GL_APIENTRYP PFNGLDELETETRANSFORMFEEDBACKSPROC) (GLsizei n, const GLuint *ids); +typedef void (GL_APIENTRYP PFNGLGENTRANSFORMFEEDBACKSPROC) (GLsizei n, GLuint *ids); +typedef GLboolean (GL_APIENTRYP PFNGLISTRANSFORMFEEDBACKPROC) (GLuint id); +typedef void (GL_APIENTRYP PFNGLPAUSETRANSFORMFEEDBACKPROC) (void); +typedef void (GL_APIENTRYP PFNGLRESUMETRANSFORMFEEDBACKPROC) (void); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMBINARYPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary); +typedef void (GL_APIENTRYP PFNGLPROGRAMBINARYPROC) (GLuint program, GLenum binaryFormat, const void *binary, GLsizei length); +typedef void (GL_APIENTRYP PFNGLPROGRAMPARAMETERIPROC) (GLuint program, GLenum pname, GLint value); +typedef void (GL_APIENTRYP PFNGLINVALIDATEFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments); +typedef void (GL_APIENTRYP PFNGLINVALIDATESUBFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE3DPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +typedef void (GL_APIENTRYP PFNGLGETINTERNALFORMATIVPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glReadBuffer (GLenum src); +GL_APICALL void GL_APIENTRY glDrawRangeElements (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices); +GL_APICALL void GL_APIENTRY glTexImage3D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glCopyTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glCompressedTexImage3D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glGenQueries (GLsizei n, GLuint *ids); +GL_APICALL void GL_APIENTRY glDeleteQueries (GLsizei n, const GLuint *ids); +GL_APICALL GLboolean GL_APIENTRY glIsQuery (GLuint id); +GL_APICALL void GL_APIENTRY glBeginQuery (GLenum target, GLuint id); +GL_APICALL void GL_APIENTRY glEndQuery (GLenum target); +GL_APICALL void GL_APIENTRY glGetQueryiv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetQueryObjectuiv (GLuint id, GLenum pname, GLuint *params); +GL_APICALL GLboolean GL_APIENTRY glUnmapBuffer (GLenum target); +GL_APICALL void GL_APIENTRY glGetBufferPointerv (GLenum target, GLenum pname, void **params); +GL_APICALL void GL_APIENTRY glDrawBuffers (GLsizei n, const GLenum *bufs); +GL_APICALL void GL_APIENTRY glUniformMatrix2x3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3x2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix2x4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4x2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3x4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4x3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glBlitFramebuffer (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glFramebufferTextureLayer (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); +GL_APICALL void *GL_APIENTRY glMapBufferRange (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +GL_APICALL void GL_APIENTRY glFlushMappedBufferRange (GLenum target, GLintptr offset, GLsizeiptr length); +GL_APICALL void GL_APIENTRY glBindVertexArray (GLuint array); +GL_APICALL void GL_APIENTRY glDeleteVertexArrays (GLsizei n, const GLuint *arrays); +GL_APICALL void GL_APIENTRY glGenVertexArrays (GLsizei n, GLuint *arrays); +GL_APICALL GLboolean GL_APIENTRY glIsVertexArray (GLuint array); +GL_APICALL void GL_APIENTRY glGetIntegeri_v (GLenum target, GLuint index, GLint *data); +GL_APICALL void GL_APIENTRY glBeginTransformFeedback (GLenum primitiveMode); +GL_APICALL void GL_APIENTRY glEndTransformFeedback (void); +GL_APICALL void GL_APIENTRY glBindBufferRange (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); +GL_APICALL void GL_APIENTRY glBindBufferBase (GLenum target, GLuint index, GLuint buffer); +GL_APICALL void GL_APIENTRY glTransformFeedbackVaryings (GLuint program, GLsizei count, const GLchar *const*varyings, GLenum bufferMode); +GL_APICALL void GL_APIENTRY glGetTransformFeedbackVarying (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glVertexAttribIPointer (GLuint index, GLint size, GLenum type, GLsizei stride, const void *pointer); +GL_APICALL void GL_APIENTRY glGetVertexAttribIiv (GLuint index, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribIuiv (GLuint index, GLenum pname, GLuint *params); +GL_APICALL void GL_APIENTRY glVertexAttribI4i (GLuint index, GLint x, GLint y, GLint z, GLint w); +GL_APICALL void GL_APIENTRY glVertexAttribI4ui (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +GL_APICALL void GL_APIENTRY glVertexAttribI4iv (GLuint index, const GLint *v); +GL_APICALL void GL_APIENTRY glVertexAttribI4uiv (GLuint index, const GLuint *v); +GL_APICALL void GL_APIENTRY glGetUniformuiv (GLuint program, GLint location, GLuint *params); +GL_APICALL GLint GL_APIENTRY glGetFragDataLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glUniform1ui (GLint location, GLuint v0); +GL_APICALL void GL_APIENTRY glUniform2ui (GLint location, GLuint v0, GLuint v1); +GL_APICALL void GL_APIENTRY glUniform3ui (GLint location, GLuint v0, GLuint v1, GLuint v2); +GL_APICALL void GL_APIENTRY glUniform4ui (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +GL_APICALL void GL_APIENTRY glUniform1uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glUniform2uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glUniform3uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glUniform4uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glClearBufferiv (GLenum buffer, GLint drawbuffer, const GLint *value); +GL_APICALL void GL_APIENTRY glClearBufferuiv (GLenum buffer, GLint drawbuffer, const GLuint *value); +GL_APICALL void GL_APIENTRY glClearBufferfv (GLenum buffer, GLint drawbuffer, const GLfloat *value); +GL_APICALL void GL_APIENTRY glClearBufferfi (GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil); +GL_APICALL const GLubyte *GL_APIENTRY glGetStringi (GLenum name, GLuint index); +GL_APICALL void GL_APIENTRY glCopyBufferSubData (GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +GL_APICALL void GL_APIENTRY glGetUniformIndices (GLuint program, GLsizei uniformCount, const GLchar *const*uniformNames, GLuint *uniformIndices); +GL_APICALL void GL_APIENTRY glGetActiveUniformsiv (GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params); +GL_APICALL GLuint GL_APIENTRY glGetUniformBlockIndex (GLuint program, const GLchar *uniformBlockName); +GL_APICALL void GL_APIENTRY glGetActiveUniformBlockiv (GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetActiveUniformBlockName (GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName); +GL_APICALL void GL_APIENTRY glUniformBlockBinding (GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding); +GL_APICALL void GL_APIENTRY glDrawArraysInstanced (GLenum mode, GLint first, GLsizei count, GLsizei instancecount); +GL_APICALL void GL_APIENTRY glDrawElementsInstanced (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount); +GL_APICALL GLsync GL_APIENTRY glFenceSync (GLenum condition, GLbitfield flags); +GL_APICALL GLboolean GL_APIENTRY glIsSync (GLsync sync); +GL_APICALL void GL_APIENTRY glDeleteSync (GLsync sync); +GL_APICALL GLenum GL_APIENTRY glClientWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_APICALL void GL_APIENTRY glWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_APICALL void GL_APIENTRY glGetInteger64v (GLenum pname, GLint64 *data); +GL_APICALL void GL_APIENTRY glGetSynciv (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values); +GL_APICALL void GL_APIENTRY glGetInteger64i_v (GLenum target, GLuint index, GLint64 *data); +GL_APICALL void GL_APIENTRY glGetBufferParameteri64v (GLenum target, GLenum pname, GLint64 *params); +GL_APICALL void GL_APIENTRY glGenSamplers (GLsizei count, GLuint *samplers); +GL_APICALL void GL_APIENTRY glDeleteSamplers (GLsizei count, const GLuint *samplers); +GL_APICALL GLboolean GL_APIENTRY glIsSampler (GLuint sampler); +GL_APICALL void GL_APIENTRY glBindSampler (GLuint unit, GLuint sampler); +GL_APICALL void GL_APIENTRY glSamplerParameteri (GLuint sampler, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glSamplerParameteriv (GLuint sampler, GLenum pname, const GLint *param); +GL_APICALL void GL_APIENTRY glSamplerParameterf (GLuint sampler, GLenum pname, GLfloat param); +GL_APICALL void GL_APIENTRY glSamplerParameterfv (GLuint sampler, GLenum pname, const GLfloat *param); +GL_APICALL void GL_APIENTRY glGetSamplerParameteriv (GLuint sampler, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetSamplerParameterfv (GLuint sampler, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glVertexAttribDivisor (GLuint index, GLuint divisor); +GL_APICALL void GL_APIENTRY glBindTransformFeedback (GLenum target, GLuint id); +GL_APICALL void GL_APIENTRY glDeleteTransformFeedbacks (GLsizei n, const GLuint *ids); +GL_APICALL void GL_APIENTRY glGenTransformFeedbacks (GLsizei n, GLuint *ids); +GL_APICALL GLboolean GL_APIENTRY glIsTransformFeedback (GLuint id); +GL_APICALL void GL_APIENTRY glPauseTransformFeedback (void); +GL_APICALL void GL_APIENTRY glResumeTransformFeedback (void); +GL_APICALL void GL_APIENTRY glGetProgramBinary (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary); +GL_APICALL void GL_APIENTRY glProgramBinary (GLuint program, GLenum binaryFormat, const void *binary, GLsizei length); +GL_APICALL void GL_APIENTRY glProgramParameteri (GLuint program, GLenum pname, GLint value); +GL_APICALL void GL_APIENTRY glInvalidateFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments); +GL_APICALL void GL_APIENTRY glInvalidateSubFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glTexStorage2D (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glTexStorage3D (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +GL_APICALL void GL_APIENTRY glGetInternalformativ (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params); +#endif +#endif /* GL_ES_VERSION_3_0 */ + +#ifndef GL_ES_VERSION_3_1 +#define GL_ES_VERSION_3_1 1 +#define GL_COMPUTE_SHADER 0x91B9 +#define GL_MAX_COMPUTE_UNIFORM_BLOCKS 0x91BB +#define GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS 0x91BC +#define GL_MAX_COMPUTE_IMAGE_UNIFORMS 0x91BD +#define GL_MAX_COMPUTE_SHARED_MEMORY_SIZE 0x8262 +#define GL_MAX_COMPUTE_UNIFORM_COMPONENTS 0x8263 +#define GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS 0x8264 +#define GL_MAX_COMPUTE_ATOMIC_COUNTERS 0x8265 +#define GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS 0x8266 +#define GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS 0x90EB +#define GL_MAX_COMPUTE_WORK_GROUP_COUNT 0x91BE +#define GL_MAX_COMPUTE_WORK_GROUP_SIZE 0x91BF +#define GL_COMPUTE_WORK_GROUP_SIZE 0x8267 +#define GL_DISPATCH_INDIRECT_BUFFER 0x90EE +#define GL_DISPATCH_INDIRECT_BUFFER_BINDING 0x90EF +#define GL_COMPUTE_SHADER_BIT 0x00000020 +#define GL_DRAW_INDIRECT_BUFFER 0x8F3F +#define GL_DRAW_INDIRECT_BUFFER_BINDING 0x8F43 +#define GL_MAX_UNIFORM_LOCATIONS 0x826E +#define GL_FRAMEBUFFER_DEFAULT_WIDTH 0x9310 +#define GL_FRAMEBUFFER_DEFAULT_HEIGHT 0x9311 +#define GL_FRAMEBUFFER_DEFAULT_SAMPLES 0x9313 +#define GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS 0x9314 +#define GL_MAX_FRAMEBUFFER_WIDTH 0x9315 +#define GL_MAX_FRAMEBUFFER_HEIGHT 0x9316 +#define GL_MAX_FRAMEBUFFER_SAMPLES 0x9318 +#define GL_UNIFORM 0x92E1 +#define GL_UNIFORM_BLOCK 0x92E2 +#define GL_PROGRAM_INPUT 0x92E3 +#define GL_PROGRAM_OUTPUT 0x92E4 +#define GL_BUFFER_VARIABLE 0x92E5 +#define GL_SHADER_STORAGE_BLOCK 0x92E6 +#define GL_ATOMIC_COUNTER_BUFFER 0x92C0 +#define GL_TRANSFORM_FEEDBACK_VARYING 0x92F4 +#define GL_ACTIVE_RESOURCES 0x92F5 +#define GL_MAX_NAME_LENGTH 0x92F6 +#define GL_MAX_NUM_ACTIVE_VARIABLES 0x92F7 +#define GL_NAME_LENGTH 0x92F9 +#define GL_TYPE 0x92FA +#define GL_ARRAY_SIZE 0x92FB +#define GL_OFFSET 0x92FC +#define GL_BLOCK_INDEX 0x92FD +#define GL_ARRAY_STRIDE 0x92FE +#define GL_MATRIX_STRIDE 0x92FF +#define GL_IS_ROW_MAJOR 0x9300 +#define GL_ATOMIC_COUNTER_BUFFER_INDEX 0x9301 +#define GL_BUFFER_BINDING 0x9302 +#define GL_BUFFER_DATA_SIZE 0x9303 +#define GL_NUM_ACTIVE_VARIABLES 0x9304 +#define GL_ACTIVE_VARIABLES 0x9305 +#define GL_REFERENCED_BY_VERTEX_SHADER 0x9306 +#define GL_REFERENCED_BY_FRAGMENT_SHADER 0x930A +#define GL_REFERENCED_BY_COMPUTE_SHADER 0x930B +#define GL_TOP_LEVEL_ARRAY_SIZE 0x930C +#define GL_TOP_LEVEL_ARRAY_STRIDE 0x930D +#define GL_LOCATION 0x930E +#define GL_VERTEX_SHADER_BIT 0x00000001 +#define GL_FRAGMENT_SHADER_BIT 0x00000002 +#define GL_ALL_SHADER_BITS 0xFFFFFFFF +#define GL_PROGRAM_SEPARABLE 0x8258 +#define GL_ACTIVE_PROGRAM 0x8259 +#define GL_PROGRAM_PIPELINE_BINDING 0x825A +#define GL_ATOMIC_COUNTER_BUFFER_BINDING 0x92C1 +#define GL_ATOMIC_COUNTER_BUFFER_START 0x92C2 +#define GL_ATOMIC_COUNTER_BUFFER_SIZE 0x92C3 +#define GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS 0x92CC +#define GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS 0x92D0 +#define GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS 0x92D1 +#define GL_MAX_VERTEX_ATOMIC_COUNTERS 0x92D2 +#define GL_MAX_FRAGMENT_ATOMIC_COUNTERS 0x92D6 +#define GL_MAX_COMBINED_ATOMIC_COUNTERS 0x92D7 +#define GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE 0x92D8 +#define GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS 0x92DC +#define GL_ACTIVE_ATOMIC_COUNTER_BUFFERS 0x92D9 +#define GL_UNSIGNED_INT_ATOMIC_COUNTER 0x92DB +#define GL_MAX_IMAGE_UNITS 0x8F38 +#define GL_MAX_VERTEX_IMAGE_UNIFORMS 0x90CA +#define GL_MAX_FRAGMENT_IMAGE_UNIFORMS 0x90CE +#define GL_MAX_COMBINED_IMAGE_UNIFORMS 0x90CF +#define GL_IMAGE_BINDING_NAME 0x8F3A +#define GL_IMAGE_BINDING_LEVEL 0x8F3B +#define GL_IMAGE_BINDING_LAYERED 0x8F3C +#define GL_IMAGE_BINDING_LAYER 0x8F3D +#define GL_IMAGE_BINDING_ACCESS 0x8F3E +#define GL_IMAGE_BINDING_FORMAT 0x906E +#define GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT 0x00000001 +#define GL_ELEMENT_ARRAY_BARRIER_BIT 0x00000002 +#define GL_UNIFORM_BARRIER_BIT 0x00000004 +#define GL_TEXTURE_FETCH_BARRIER_BIT 0x00000008 +#define GL_SHADER_IMAGE_ACCESS_BARRIER_BIT 0x00000020 +#define GL_COMMAND_BARRIER_BIT 0x00000040 +#define GL_PIXEL_BUFFER_BARRIER_BIT 0x00000080 +#define GL_TEXTURE_UPDATE_BARRIER_BIT 0x00000100 +#define GL_BUFFER_UPDATE_BARRIER_BIT 0x00000200 +#define GL_FRAMEBUFFER_BARRIER_BIT 0x00000400 +#define GL_TRANSFORM_FEEDBACK_BARRIER_BIT 0x00000800 +#define GL_ATOMIC_COUNTER_BARRIER_BIT 0x00001000 +#define GL_ALL_BARRIER_BITS 0xFFFFFFFF +#define GL_IMAGE_2D 0x904D +#define GL_IMAGE_3D 0x904E +#define GL_IMAGE_CUBE 0x9050 +#define GL_IMAGE_2D_ARRAY 0x9053 +#define GL_INT_IMAGE_2D 0x9058 +#define GL_INT_IMAGE_3D 0x9059 +#define GL_INT_IMAGE_CUBE 0x905B +#define GL_INT_IMAGE_2D_ARRAY 0x905E +#define GL_UNSIGNED_INT_IMAGE_2D 0x9063 +#define GL_UNSIGNED_INT_IMAGE_3D 0x9064 +#define GL_UNSIGNED_INT_IMAGE_CUBE 0x9066 +#define GL_UNSIGNED_INT_IMAGE_2D_ARRAY 0x9069 +#define GL_IMAGE_FORMAT_COMPATIBILITY_TYPE 0x90C7 +#define GL_IMAGE_FORMAT_COMPATIBILITY_BY_SIZE 0x90C8 +#define GL_IMAGE_FORMAT_COMPATIBILITY_BY_CLASS 0x90C9 +#define GL_READ_ONLY 0x88B8 +#define GL_WRITE_ONLY 0x88B9 +#define GL_READ_WRITE 0x88BA +#define GL_SHADER_STORAGE_BUFFER 0x90D2 +#define GL_SHADER_STORAGE_BUFFER_BINDING 0x90D3 +#define GL_SHADER_STORAGE_BUFFER_START 0x90D4 +#define GL_SHADER_STORAGE_BUFFER_SIZE 0x90D5 +#define GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS 0x90D6 +#define GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS 0x90DA +#define GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS 0x90DB +#define GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS 0x90DC +#define GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS 0x90DD +#define GL_MAX_SHADER_STORAGE_BLOCK_SIZE 0x90DE +#define GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT 0x90DF +#define GL_SHADER_STORAGE_BARRIER_BIT 0x00002000 +#define GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES 0x8F39 +#define GL_DEPTH_STENCIL_TEXTURE_MODE 0x90EA +#define GL_STENCIL_INDEX 0x1901 +#define GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET 0x8E5E +#define GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET 0x8E5F +#define GL_SAMPLE_POSITION 0x8E50 +#define GL_SAMPLE_MASK 0x8E51 +#define GL_SAMPLE_MASK_VALUE 0x8E52 +#define GL_TEXTURE_2D_MULTISAMPLE 0x9100 +#define GL_MAX_SAMPLE_MASK_WORDS 0x8E59 +#define GL_MAX_COLOR_TEXTURE_SAMPLES 0x910E +#define GL_MAX_DEPTH_TEXTURE_SAMPLES 0x910F +#define GL_MAX_INTEGER_SAMPLES 0x9110 +#define GL_TEXTURE_BINDING_2D_MULTISAMPLE 0x9104 +#define GL_TEXTURE_SAMPLES 0x9106 +#define GL_TEXTURE_FIXED_SAMPLE_LOCATIONS 0x9107 +#define GL_TEXTURE_WIDTH 0x1000 +#define GL_TEXTURE_HEIGHT 0x1001 +#define GL_TEXTURE_DEPTH 0x8071 +#define GL_TEXTURE_INTERNAL_FORMAT 0x1003 +#define GL_TEXTURE_RED_SIZE 0x805C +#define GL_TEXTURE_GREEN_SIZE 0x805D +#define GL_TEXTURE_BLUE_SIZE 0x805E +#define GL_TEXTURE_ALPHA_SIZE 0x805F +#define GL_TEXTURE_DEPTH_SIZE 0x884A +#define GL_TEXTURE_STENCIL_SIZE 0x88F1 +#define GL_TEXTURE_SHARED_SIZE 0x8C3F +#define GL_TEXTURE_RED_TYPE 0x8C10 +#define GL_TEXTURE_GREEN_TYPE 0x8C11 +#define GL_TEXTURE_BLUE_TYPE 0x8C12 +#define GL_TEXTURE_ALPHA_TYPE 0x8C13 +#define GL_TEXTURE_DEPTH_TYPE 0x8C16 +#define GL_TEXTURE_COMPRESSED 0x86A1 +#define GL_SAMPLER_2D_MULTISAMPLE 0x9108 +#define GL_INT_SAMPLER_2D_MULTISAMPLE 0x9109 +#define GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE 0x910A +#define GL_VERTEX_ATTRIB_BINDING 0x82D4 +#define GL_VERTEX_ATTRIB_RELATIVE_OFFSET 0x82D5 +#define GL_VERTEX_BINDING_DIVISOR 0x82D6 +#define GL_VERTEX_BINDING_OFFSET 0x82D7 +#define GL_VERTEX_BINDING_STRIDE 0x82D8 +#define GL_VERTEX_BINDING_BUFFER 0x8F4F +#define GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET 0x82D9 +#define GL_MAX_VERTEX_ATTRIB_BINDINGS 0x82DA +#define GL_MAX_VERTEX_ATTRIB_STRIDE 0x82E5 +typedef void (GL_APIENTRYP PFNGLDISPATCHCOMPUTEPROC) (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z); +typedef void (GL_APIENTRYP PFNGLDISPATCHCOMPUTEINDIRECTPROC) (GLintptr indirect); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINDIRECTPROC) (GLenum mode, const void *indirect); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINDIRECTPROC) (GLenum mode, GLenum type, const void *indirect); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERPARAMETERIPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMINTERFACEIVPROC) (GLuint program, GLenum programInterface, GLenum pname, GLint *params); +typedef GLuint (GL_APIENTRYP PFNGLGETPROGRAMRESOURCEINDEXPROC) (GLuint program, GLenum programInterface, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMRESOURCENAMEPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMRESOURCEIVPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params); +typedef GLint (GL_APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONPROC) (GLuint program, GLenum programInterface, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLUSEPROGRAMSTAGESPROC) (GLuint pipeline, GLbitfield stages, GLuint program); +typedef void (GL_APIENTRYP PFNGLACTIVESHADERPROGRAMPROC) (GLuint pipeline, GLuint program); +typedef GLuint (GL_APIENTRYP PFNGLCREATESHADERPROGRAMVPROC) (GLenum type, GLsizei count, const GLchar *const*strings); +typedef void (GL_APIENTRYP PFNGLBINDPROGRAMPIPELINEPROC) (GLuint pipeline); +typedef void (GL_APIENTRYP PFNGLDELETEPROGRAMPIPELINESPROC) (GLsizei n, const GLuint *pipelines); +typedef void (GL_APIENTRYP PFNGLGENPROGRAMPIPELINESPROC) (GLsizei n, GLuint *pipelines); +typedef GLboolean (GL_APIENTRYP PFNGLISPROGRAMPIPELINEPROC) (GLuint pipeline); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMPIPELINEIVPROC) (GLuint pipeline, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1IPROC) (GLuint program, GLint location, GLint v0); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2IPROC) (GLuint program, GLint location, GLint v0, GLint v1); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3IPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4IPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UIPROC) (GLuint program, GLint location, GLuint v0); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UIPROC) (GLuint program, GLint location, GLuint v0, GLuint v1); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UIPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UIPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1FPROC) (GLuint program, GLint location, GLfloat v0); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2FPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3FPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4FPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1IVPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2IVPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3IVPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4IVPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UIVPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UIVPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UIVPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UIVPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1FVPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2FVPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3FVPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4FVPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X3FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X2FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X4FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X2FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X4FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X3FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLVALIDATEPROGRAMPIPELINEPROC) (GLuint pipeline); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMPIPELINEINFOLOGPROC) (GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLBINDIMAGETEXTUREPROC) (GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format); +typedef void (GL_APIENTRYP PFNGLGETBOOLEANI_VPROC) (GLenum target, GLuint index, GLboolean *data); +typedef void (GL_APIENTRYP PFNGLMEMORYBARRIERPROC) (GLbitfield barriers); +typedef void (GL_APIENTRYP PFNGLMEMORYBARRIERBYREGIONPROC) (GLbitfield barriers); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +typedef void (GL_APIENTRYP PFNGLGETMULTISAMPLEFVPROC) (GLenum pname, GLuint index, GLfloat *val); +typedef void (GL_APIENTRYP PFNGLSAMPLEMASKIPROC) (GLuint maskNumber, GLbitfield mask); +typedef void (GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERIVPROC) (GLenum target, GLint level, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERFVPROC) (GLenum target, GLint level, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLBINDVERTEXBUFFERPROC) (GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBIFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBBINDINGPROC) (GLuint attribindex, GLuint bindingindex); +typedef void (GL_APIENTRYP PFNGLVERTEXBINDINGDIVISORPROC) (GLuint bindingindex, GLuint divisor); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glDispatchCompute (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z); +GL_APICALL void GL_APIENTRY glDispatchComputeIndirect (GLintptr indirect); +GL_APICALL void GL_APIENTRY glDrawArraysIndirect (GLenum mode, const void *indirect); +GL_APICALL void GL_APIENTRY glDrawElementsIndirect (GLenum mode, GLenum type, const void *indirect); +GL_APICALL void GL_APIENTRY glFramebufferParameteri (GLenum target, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glGetFramebufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetProgramInterfaceiv (GLuint program, GLenum programInterface, GLenum pname, GLint *params); +GL_APICALL GLuint GL_APIENTRY glGetProgramResourceIndex (GLuint program, GLenum programInterface, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetProgramResourceName (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name); +GL_APICALL void GL_APIENTRY glGetProgramResourceiv (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL GLint GL_APIENTRY glGetProgramResourceLocation (GLuint program, GLenum programInterface, const GLchar *name); +GL_APICALL void GL_APIENTRY glUseProgramStages (GLuint pipeline, GLbitfield stages, GLuint program); +GL_APICALL void GL_APIENTRY glActiveShaderProgram (GLuint pipeline, GLuint program); +GL_APICALL GLuint GL_APIENTRY glCreateShaderProgramv (GLenum type, GLsizei count, const GLchar *const*strings); +GL_APICALL void GL_APIENTRY glBindProgramPipeline (GLuint pipeline); +GL_APICALL void GL_APIENTRY glDeleteProgramPipelines (GLsizei n, const GLuint *pipelines); +GL_APICALL void GL_APIENTRY glGenProgramPipelines (GLsizei n, GLuint *pipelines); +GL_APICALL GLboolean GL_APIENTRY glIsProgramPipeline (GLuint pipeline); +GL_APICALL void GL_APIENTRY glGetProgramPipelineiv (GLuint pipeline, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glProgramUniform1i (GLuint program, GLint location, GLint v0); +GL_APICALL void GL_APIENTRY glProgramUniform2i (GLuint program, GLint location, GLint v0, GLint v1); +GL_APICALL void GL_APIENTRY glProgramUniform3i (GLuint program, GLint location, GLint v0, GLint v1, GLint v2); +GL_APICALL void GL_APIENTRY glProgramUniform4i (GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +GL_APICALL void GL_APIENTRY glProgramUniform1ui (GLuint program, GLint location, GLuint v0); +GL_APICALL void GL_APIENTRY glProgramUniform2ui (GLuint program, GLint location, GLuint v0, GLuint v1); +GL_APICALL void GL_APIENTRY glProgramUniform3ui (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2); +GL_APICALL void GL_APIENTRY glProgramUniform4ui (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +GL_APICALL void GL_APIENTRY glProgramUniform1f (GLuint program, GLint location, GLfloat v0); +GL_APICALL void GL_APIENTRY glProgramUniform2f (GLuint program, GLint location, GLfloat v0, GLfloat v1); +GL_APICALL void GL_APIENTRY glProgramUniform3f (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +GL_APICALL void GL_APIENTRY glProgramUniform4f (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +GL_APICALL void GL_APIENTRY glProgramUniform1iv (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform2iv (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform3iv (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform4iv (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform1uiv (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform2uiv (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform3uiv (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform4uiv (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform1fv (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform2fv (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform3fv (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform4fv (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix2fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix3fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix4fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix2x3fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix3x2fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix2x4fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix4x2fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix3x4fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix4x3fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glValidateProgramPipeline (GLuint pipeline); +GL_APICALL void GL_APIENTRY glGetProgramPipelineInfoLog (GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glBindImageTexture (GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format); +GL_APICALL void GL_APIENTRY glGetBooleani_v (GLenum target, GLuint index, GLboolean *data); +GL_APICALL void GL_APIENTRY glMemoryBarrier (GLbitfield barriers); +GL_APICALL void GL_APIENTRY glMemoryBarrierByRegion (GLbitfield barriers); +GL_APICALL void GL_APIENTRY glTexStorage2DMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +GL_APICALL void GL_APIENTRY glGetMultisamplefv (GLenum pname, GLuint index, GLfloat *val); +GL_APICALL void GL_APIENTRY glSampleMaski (GLuint maskNumber, GLbitfield mask); +GL_APICALL void GL_APIENTRY glGetTexLevelParameteriv (GLenum target, GLint level, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetTexLevelParameterfv (GLenum target, GLint level, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glBindVertexBuffer (GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride); +GL_APICALL void GL_APIENTRY glVertexAttribFormat (GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset); +GL_APICALL void GL_APIENTRY glVertexAttribIFormat (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +GL_APICALL void GL_APIENTRY glVertexAttribBinding (GLuint attribindex, GLuint bindingindex); +GL_APICALL void GL_APIENTRY glVertexBindingDivisor (GLuint bindingindex, GLuint divisor); +#endif +#endif /* GL_ES_VERSION_3_1 */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/GLES3/gl32.h b/gfx/angle/checkout/include/GLES3/gl32.h new file mode 100644 index 0000000000..ae56b0e95f --- /dev/null +++ b/gfx/angle/checkout/include/GLES3/gl32.h @@ -0,0 +1,1808 @@ +#ifndef __gles2_gl32_h_ +#define __gles2_gl32_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright 2013-2020 The Khronos Group Inc. +** SPDX-License-Identifier: MIT +** +** This header is generated from the Khronos OpenGL / OpenGL ES XML +** API Registry. The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** https://github.com/KhronosGroup/OpenGL-Registry +*/ + +#include + +#ifndef GL_APIENTRYP +#define GL_APIENTRYP GL_APIENTRY* +#endif + +#ifndef GL_GLES_PROTOTYPES +#define GL_GLES_PROTOTYPES 1 +#endif + +/* Generated on date 20191013 */ + +/* Generated C header for: + * API: gles2 + * Profile: common + * Versions considered: 2\.[0-9]|3\.[012] + * Versions emitted: .* + * Default extensions included: None + * Additional extensions included: _nomatch_^ + * Extensions removed: _nomatch_^ + */ + +#ifndef GL_ES_VERSION_2_0 +#define GL_ES_VERSION_2_0 1 +#include +typedef khronos_int8_t GLbyte; +typedef khronos_float_t GLclampf; +typedef khronos_int32_t GLfixed; +typedef khronos_int16_t GLshort; +typedef khronos_uint16_t GLushort; +typedef void GLvoid; +typedef struct __GLsync *GLsync; +typedef khronos_int64_t GLint64; +typedef khronos_uint64_t GLuint64; +typedef unsigned int GLenum; +typedef unsigned int GLuint; +typedef char GLchar; +typedef khronos_float_t GLfloat; +typedef khronos_ssize_t GLsizeiptr; +typedef khronos_intptr_t GLintptr; +typedef unsigned int GLbitfield; +typedef int GLint; +typedef unsigned char GLboolean; +typedef int GLsizei; +typedef khronos_uint8_t GLubyte; +#define GL_DEPTH_BUFFER_BIT 0x00000100 +#define GL_STENCIL_BUFFER_BIT 0x00000400 +#define GL_COLOR_BUFFER_BIT 0x00004000 +#define GL_FALSE 0 +#define GL_TRUE 1 +#define GL_POINTS 0x0000 +#define GL_LINES 0x0001 +#define GL_LINE_LOOP 0x0002 +#define GL_LINE_STRIP 0x0003 +#define GL_TRIANGLES 0x0004 +#define GL_TRIANGLE_STRIP 0x0005 +#define GL_TRIANGLE_FAN 0x0006 +#define GL_ZERO 0 +#define GL_ONE 1 +#define GL_SRC_COLOR 0x0300 +#define GL_ONE_MINUS_SRC_COLOR 0x0301 +#define GL_SRC_ALPHA 0x0302 +#define GL_ONE_MINUS_SRC_ALPHA 0x0303 +#define GL_DST_ALPHA 0x0304 +#define GL_ONE_MINUS_DST_ALPHA 0x0305 +#define GL_DST_COLOR 0x0306 +#define GL_ONE_MINUS_DST_COLOR 0x0307 +#define GL_SRC_ALPHA_SATURATE 0x0308 +#define GL_FUNC_ADD 0x8006 +#define GL_BLEND_EQUATION 0x8009 +#define GL_BLEND_EQUATION_RGB 0x8009 +#define GL_BLEND_EQUATION_ALPHA 0x883D +#define GL_FUNC_SUBTRACT 0x800A +#define GL_FUNC_REVERSE_SUBTRACT 0x800B +#define GL_BLEND_DST_RGB 0x80C8 +#define GL_BLEND_SRC_RGB 0x80C9 +#define GL_BLEND_DST_ALPHA 0x80CA +#define GL_BLEND_SRC_ALPHA 0x80CB +#define GL_CONSTANT_COLOR 0x8001 +#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002 +#define GL_CONSTANT_ALPHA 0x8003 +#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004 +#define GL_BLEND_COLOR 0x8005 +#define GL_ARRAY_BUFFER 0x8892 +#define GL_ELEMENT_ARRAY_BUFFER 0x8893 +#define GL_ARRAY_BUFFER_BINDING 0x8894 +#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895 +#define GL_STREAM_DRAW 0x88E0 +#define GL_STATIC_DRAW 0x88E4 +#define GL_DYNAMIC_DRAW 0x88E8 +#define GL_BUFFER_SIZE 0x8764 +#define GL_BUFFER_USAGE 0x8765 +#define GL_CURRENT_VERTEX_ATTRIB 0x8626 +#define GL_FRONT 0x0404 +#define GL_BACK 0x0405 +#define GL_FRONT_AND_BACK 0x0408 +#define GL_TEXTURE_2D 0x0DE1 +#define GL_CULL_FACE 0x0B44 +#define GL_BLEND 0x0BE2 +#define GL_DITHER 0x0BD0 +#define GL_STENCIL_TEST 0x0B90 +#define GL_DEPTH_TEST 0x0B71 +#define GL_SCISSOR_TEST 0x0C11 +#define GL_POLYGON_OFFSET_FILL 0x8037 +#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E +#define GL_SAMPLE_COVERAGE 0x80A0 +#define GL_NO_ERROR 0 +#define GL_INVALID_ENUM 0x0500 +#define GL_INVALID_VALUE 0x0501 +#define GL_INVALID_OPERATION 0x0502 +#define GL_OUT_OF_MEMORY 0x0505 +#define GL_CW 0x0900 +#define GL_CCW 0x0901 +#define GL_LINE_WIDTH 0x0B21 +#define GL_ALIASED_POINT_SIZE_RANGE 0x846D +#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E +#define GL_CULL_FACE_MODE 0x0B45 +#define GL_FRONT_FACE 0x0B46 +#define GL_DEPTH_RANGE 0x0B70 +#define GL_DEPTH_WRITEMASK 0x0B72 +#define GL_DEPTH_CLEAR_VALUE 0x0B73 +#define GL_DEPTH_FUNC 0x0B74 +#define GL_STENCIL_CLEAR_VALUE 0x0B91 +#define GL_STENCIL_FUNC 0x0B92 +#define GL_STENCIL_FAIL 0x0B94 +#define GL_STENCIL_PASS_DEPTH_FAIL 0x0B95 +#define GL_STENCIL_PASS_DEPTH_PASS 0x0B96 +#define GL_STENCIL_REF 0x0B97 +#define GL_STENCIL_VALUE_MASK 0x0B93 +#define GL_STENCIL_WRITEMASK 0x0B98 +#define GL_STENCIL_BACK_FUNC 0x8800 +#define GL_STENCIL_BACK_FAIL 0x8801 +#define GL_STENCIL_BACK_PASS_DEPTH_FAIL 0x8802 +#define GL_STENCIL_BACK_PASS_DEPTH_PASS 0x8803 +#define GL_STENCIL_BACK_REF 0x8CA3 +#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4 +#define GL_STENCIL_BACK_WRITEMASK 0x8CA5 +#define GL_VIEWPORT 0x0BA2 +#define GL_SCISSOR_BOX 0x0C10 +#define GL_COLOR_CLEAR_VALUE 0x0C22 +#define GL_COLOR_WRITEMASK 0x0C23 +#define GL_UNPACK_ALIGNMENT 0x0CF5 +#define GL_PACK_ALIGNMENT 0x0D05 +#define GL_MAX_TEXTURE_SIZE 0x0D33 +#define GL_MAX_VIEWPORT_DIMS 0x0D3A +#define GL_SUBPIXEL_BITS 0x0D50 +#define GL_RED_BITS 0x0D52 +#define GL_GREEN_BITS 0x0D53 +#define GL_BLUE_BITS 0x0D54 +#define GL_ALPHA_BITS 0x0D55 +#define GL_DEPTH_BITS 0x0D56 +#define GL_STENCIL_BITS 0x0D57 +#define GL_POLYGON_OFFSET_UNITS 0x2A00 +#define GL_POLYGON_OFFSET_FACTOR 0x8038 +#define GL_TEXTURE_BINDING_2D 0x8069 +#define GL_SAMPLE_BUFFERS 0x80A8 +#define GL_SAMPLES 0x80A9 +#define GL_SAMPLE_COVERAGE_VALUE 0x80AA +#define GL_SAMPLE_COVERAGE_INVERT 0x80AB +#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 +#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 +#define GL_DONT_CARE 0x1100 +#define GL_FASTEST 0x1101 +#define GL_NICEST 0x1102 +#define GL_GENERATE_MIPMAP_HINT 0x8192 +#define GL_BYTE 0x1400 +#define GL_UNSIGNED_BYTE 0x1401 +#define GL_SHORT 0x1402 +#define GL_UNSIGNED_SHORT 0x1403 +#define GL_INT 0x1404 +#define GL_UNSIGNED_INT 0x1405 +#define GL_FLOAT 0x1406 +#define GL_FIXED 0x140C +#define GL_DEPTH_COMPONENT 0x1902 +#define GL_ALPHA 0x1906 +#define GL_RGB 0x1907 +#define GL_RGBA 0x1908 +#define GL_LUMINANCE 0x1909 +#define GL_LUMINANCE_ALPHA 0x190A +#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033 +#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034 +#define GL_UNSIGNED_SHORT_5_6_5 0x8363 +#define GL_FRAGMENT_SHADER 0x8B30 +#define GL_VERTEX_SHADER 0x8B31 +#define GL_MAX_VERTEX_ATTRIBS 0x8869 +#define GL_MAX_VERTEX_UNIFORM_VECTORS 0x8DFB +#define GL_MAX_VARYING_VECTORS 0x8DFC +#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS 0x8B4D +#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS 0x8B4C +#define GL_MAX_TEXTURE_IMAGE_UNITS 0x8872 +#define GL_MAX_FRAGMENT_UNIFORM_VECTORS 0x8DFD +#define GL_SHADER_TYPE 0x8B4F +#define GL_DELETE_STATUS 0x8B80 +#define GL_LINK_STATUS 0x8B82 +#define GL_VALIDATE_STATUS 0x8B83 +#define GL_ATTACHED_SHADERS 0x8B85 +#define GL_ACTIVE_UNIFORMS 0x8B86 +#define GL_ACTIVE_UNIFORM_MAX_LENGTH 0x8B87 +#define GL_ACTIVE_ATTRIBUTES 0x8B89 +#define GL_ACTIVE_ATTRIBUTE_MAX_LENGTH 0x8B8A +#define GL_SHADING_LANGUAGE_VERSION 0x8B8C +#define GL_CURRENT_PROGRAM 0x8B8D +#define GL_NEVER 0x0200 +#define GL_LESS 0x0201 +#define GL_EQUAL 0x0202 +#define GL_LEQUAL 0x0203 +#define GL_GREATER 0x0204 +#define GL_NOTEQUAL 0x0205 +#define GL_GEQUAL 0x0206 +#define GL_ALWAYS 0x0207 +#define GL_KEEP 0x1E00 +#define GL_REPLACE 0x1E01 +#define GL_INCR 0x1E02 +#define GL_DECR 0x1E03 +#define GL_INVERT 0x150A +#define GL_INCR_WRAP 0x8507 +#define GL_DECR_WRAP 0x8508 +#define GL_VENDOR 0x1F00 +#define GL_RENDERER 0x1F01 +#define GL_VERSION 0x1F02 +#define GL_EXTENSIONS 0x1F03 +#define GL_NEAREST 0x2600 +#define GL_LINEAR 0x2601 +#define GL_NEAREST_MIPMAP_NEAREST 0x2700 +#define GL_LINEAR_MIPMAP_NEAREST 0x2701 +#define GL_NEAREST_MIPMAP_LINEAR 0x2702 +#define GL_LINEAR_MIPMAP_LINEAR 0x2703 +#define GL_TEXTURE_MAG_FILTER 0x2800 +#define GL_TEXTURE_MIN_FILTER 0x2801 +#define GL_TEXTURE_WRAP_S 0x2802 +#define GL_TEXTURE_WRAP_T 0x2803 +#define GL_TEXTURE 0x1702 +#define GL_TEXTURE_CUBE_MAP 0x8513 +#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518 +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519 +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A +#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C +#define GL_TEXTURE0 0x84C0 +#define GL_TEXTURE1 0x84C1 +#define GL_TEXTURE2 0x84C2 +#define GL_TEXTURE3 0x84C3 +#define GL_TEXTURE4 0x84C4 +#define GL_TEXTURE5 0x84C5 +#define GL_TEXTURE6 0x84C6 +#define GL_TEXTURE7 0x84C7 +#define GL_TEXTURE8 0x84C8 +#define GL_TEXTURE9 0x84C9 +#define GL_TEXTURE10 0x84CA +#define GL_TEXTURE11 0x84CB +#define GL_TEXTURE12 0x84CC +#define GL_TEXTURE13 0x84CD +#define GL_TEXTURE14 0x84CE +#define GL_TEXTURE15 0x84CF +#define GL_TEXTURE16 0x84D0 +#define GL_TEXTURE17 0x84D1 +#define GL_TEXTURE18 0x84D2 +#define GL_TEXTURE19 0x84D3 +#define GL_TEXTURE20 0x84D4 +#define GL_TEXTURE21 0x84D5 +#define GL_TEXTURE22 0x84D6 +#define GL_TEXTURE23 0x84D7 +#define GL_TEXTURE24 0x84D8 +#define GL_TEXTURE25 0x84D9 +#define GL_TEXTURE26 0x84DA +#define GL_TEXTURE27 0x84DB +#define GL_TEXTURE28 0x84DC +#define GL_TEXTURE29 0x84DD +#define GL_TEXTURE30 0x84DE +#define GL_TEXTURE31 0x84DF +#define GL_ACTIVE_TEXTURE 0x84E0 +#define GL_REPEAT 0x2901 +#define GL_CLAMP_TO_EDGE 0x812F +#define GL_MIRRORED_REPEAT 0x8370 +#define GL_FLOAT_VEC2 0x8B50 +#define GL_FLOAT_VEC3 0x8B51 +#define GL_FLOAT_VEC4 0x8B52 +#define GL_INT_VEC2 0x8B53 +#define GL_INT_VEC3 0x8B54 +#define GL_INT_VEC4 0x8B55 +#define GL_BOOL 0x8B56 +#define GL_BOOL_VEC2 0x8B57 +#define GL_BOOL_VEC3 0x8B58 +#define GL_BOOL_VEC4 0x8B59 +#define GL_FLOAT_MAT2 0x8B5A +#define GL_FLOAT_MAT3 0x8B5B +#define GL_FLOAT_MAT4 0x8B5C +#define GL_SAMPLER_2D 0x8B5E +#define GL_SAMPLER_CUBE 0x8B60 +#define GL_VERTEX_ATTRIB_ARRAY_ENABLED 0x8622 +#define GL_VERTEX_ATTRIB_ARRAY_SIZE 0x8623 +#define GL_VERTEX_ATTRIB_ARRAY_STRIDE 0x8624 +#define GL_VERTEX_ATTRIB_ARRAY_TYPE 0x8625 +#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED 0x886A +#define GL_VERTEX_ATTRIB_ARRAY_POINTER 0x8645 +#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 0x889F +#define GL_IMPLEMENTATION_COLOR_READ_TYPE 0x8B9A +#define GL_IMPLEMENTATION_COLOR_READ_FORMAT 0x8B9B +#define GL_COMPILE_STATUS 0x8B81 +#define GL_INFO_LOG_LENGTH 0x8B84 +#define GL_SHADER_SOURCE_LENGTH 0x8B88 +#define GL_SHADER_COMPILER 0x8DFA +#define GL_SHADER_BINARY_FORMATS 0x8DF8 +#define GL_NUM_SHADER_BINARY_FORMATS 0x8DF9 +#define GL_LOW_FLOAT 0x8DF0 +#define GL_MEDIUM_FLOAT 0x8DF1 +#define GL_HIGH_FLOAT 0x8DF2 +#define GL_LOW_INT 0x8DF3 +#define GL_MEDIUM_INT 0x8DF4 +#define GL_HIGH_INT 0x8DF5 +#define GL_FRAMEBUFFER 0x8D40 +#define GL_RENDERBUFFER 0x8D41 +#define GL_RGBA4 0x8056 +#define GL_RGB5_A1 0x8057 +#define GL_RGB565 0x8D62 +#define GL_DEPTH_COMPONENT16 0x81A5 +#define GL_STENCIL_INDEX8 0x8D48 +#define GL_RENDERBUFFER_WIDTH 0x8D42 +#define GL_RENDERBUFFER_HEIGHT 0x8D43 +#define GL_RENDERBUFFER_INTERNAL_FORMAT 0x8D44 +#define GL_RENDERBUFFER_RED_SIZE 0x8D50 +#define GL_RENDERBUFFER_GREEN_SIZE 0x8D51 +#define GL_RENDERBUFFER_BLUE_SIZE 0x8D52 +#define GL_RENDERBUFFER_ALPHA_SIZE 0x8D53 +#define GL_RENDERBUFFER_DEPTH_SIZE 0x8D54 +#define GL_RENDERBUFFER_STENCIL_SIZE 0x8D55 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE 0x8CD0 +#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME 0x8CD1 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL 0x8CD2 +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE 0x8CD3 +#define GL_COLOR_ATTACHMENT0 0x8CE0 +#define GL_DEPTH_ATTACHMENT 0x8D00 +#define GL_STENCIL_ATTACHMENT 0x8D20 +#define GL_NONE 0 +#define GL_FRAMEBUFFER_COMPLETE 0x8CD5 +#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT 0x8CD6 +#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT 0x8CD7 +#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS 0x8CD9 +#define GL_FRAMEBUFFER_UNSUPPORTED 0x8CDD +#define GL_FRAMEBUFFER_BINDING 0x8CA6 +#define GL_RENDERBUFFER_BINDING 0x8CA7 +#define GL_MAX_RENDERBUFFER_SIZE 0x84E8 +#define GL_INVALID_FRAMEBUFFER_OPERATION 0x0506 +typedef void (GL_APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); +typedef void (GL_APIENTRYP PFNGLATTACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (GL_APIENTRYP PFNGLBINDATTRIBLOCATIONPROC) (GLuint program, GLuint index, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERPROC) (GLenum target, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLBINDFRAMEBUFFERPROC) (GLenum target, GLuint framebuffer); +typedef void (GL_APIENTRYP PFNGLBINDRENDERBUFFERPROC) (GLenum target, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLBINDTEXTUREPROC) (GLenum target, GLuint texture); +typedef void (GL_APIENTRYP PFNGLBLENDCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEPROC) (GLenum modeRGB, GLenum modeAlpha); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCPROC) (GLenum sfactor, GLenum dfactor); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +typedef void (GL_APIENTRYP PFNGLBUFFERDATAPROC) (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +typedef void (GL_APIENTRYP PFNGLBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +typedef GLenum (GL_APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLCLEARPROC) (GLbitfield mask); +typedef void (GL_APIENTRYP PFNGLCLEARCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (GL_APIENTRYP PFNGLCLEARDEPTHFPROC) (GLfloat d); +typedef void (GL_APIENTRYP PFNGLCLEARSTENCILPROC) (GLint s); +typedef void (GL_APIENTRYP PFNGLCOLORMASKPROC) (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +typedef void (GL_APIENTRYP PFNGLCOMPILESHADERPROC) (GLuint shader); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOPYTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef GLuint (GL_APIENTRYP PFNGLCREATEPROGRAMPROC) (void); +typedef GLuint (GL_APIENTRYP PFNGLCREATESHADERPROC) (GLenum type); +typedef void (GL_APIENTRYP PFNGLCULLFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLDELETEBUFFERSPROC) (GLsizei n, const GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLDELETEFRAMEBUFFERSPROC) (GLsizei n, const GLuint *framebuffers); +typedef void (GL_APIENTRYP PFNGLDELETEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLDELETERENDERBUFFERSPROC) (GLsizei n, const GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLDELETESHADERPROC) (GLuint shader); +typedef void (GL_APIENTRYP PFNGLDELETETEXTURESPROC) (GLsizei n, const GLuint *textures); +typedef void (GL_APIENTRYP PFNGLDEPTHFUNCPROC) (GLenum func); +typedef void (GL_APIENTRYP PFNGLDEPTHMASKPROC) (GLboolean flag); +typedef void (GL_APIENTRYP PFNGLDEPTHRANGEFPROC) (GLfloat n, GLfloat f); +typedef void (GL_APIENTRYP PFNGLDETACHSHADERPROC) (GLuint program, GLuint shader); +typedef void (GL_APIENTRYP PFNGLDISABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSPROC) (GLenum mode, GLint first, GLsizei count); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices); +typedef void (GL_APIENTRYP PFNGLENABLEPROC) (GLenum cap); +typedef void (GL_APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYPROC) (GLuint index); +typedef void (GL_APIENTRYP PFNGLFINISHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFLUSHPROC) (void); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFERPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +typedef void (GL_APIENTRYP PFNGLFRONTFACEPROC) (GLenum mode); +typedef void (GL_APIENTRYP PFNGLGENBUFFERSPROC) (GLsizei n, GLuint *buffers); +typedef void (GL_APIENTRYP PFNGLGENERATEMIPMAPPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGENFRAMEBUFFERSPROC) (GLsizei n, GLuint *framebuffers); +typedef void (GL_APIENTRYP PFNGLGENRENDERBUFFERSPROC) (GLsizei n, GLuint *renderbuffers); +typedef void (GL_APIENTRYP PFNGLGENTEXTURESPROC) (GLsizei n, GLuint *textures); +typedef void (GL_APIENTRYP PFNGLGETACTIVEATTRIBPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETATTACHEDSHADERSPROC) (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *shaders); +typedef GLint (GL_APIENTRYP PFNGLGETATTRIBLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETBOOLEANVPROC) (GLenum pname, GLboolean *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef GLenum (GL_APIENTRYP PFNGLGETERRORPROC) (void); +typedef void (GL_APIENTRYP PFNGLGETFLOATVPROC) (GLenum pname, GLfloat *data); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETINTEGERVPROC) (GLenum pname, GLint *data); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMIVPROC) (GLuint program, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMINFOLOGPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSHADERIVPROC) (GLuint shader, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSHADERINFOLOGPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLGETSHADERPRECISIONFORMATPROC) (GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision); +typedef void (GL_APIENTRYP PFNGLGETSHADERSOURCEPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +typedef const GLubyte *(GL_APIENTRYP PFNGLGETSTRINGPROC) (GLenum name); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMFVPROC) (GLuint program, GLint location, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMIVPROC) (GLuint program, GLint location, GLint *params); +typedef GLint (GL_APIENTRYP PFNGLGETUNIFORMLOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBFVPROC) (GLuint index, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVPROC) (GLuint index, GLenum pname, void **pointer); +typedef void (GL_APIENTRYP PFNGLHINTPROC) (GLenum target, GLenum mode); +typedef GLboolean (GL_APIENTRYP PFNGLISBUFFERPROC) (GLuint buffer); +typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDPROC) (GLenum cap); +typedef GLboolean (GL_APIENTRYP PFNGLISFRAMEBUFFERPROC) (GLuint framebuffer); +typedef GLboolean (GL_APIENTRYP PFNGLISPROGRAMPROC) (GLuint program); +typedef GLboolean (GL_APIENTRYP PFNGLISRENDERBUFFERPROC) (GLuint renderbuffer); +typedef GLboolean (GL_APIENTRYP PFNGLISSHADERPROC) (GLuint shader); +typedef GLboolean (GL_APIENTRYP PFNGLISTEXTUREPROC) (GLuint texture); +typedef void (GL_APIENTRYP PFNGLLINEWIDTHPROC) (GLfloat width); +typedef void (GL_APIENTRYP PFNGLLINKPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLPIXELSTOREIPROC) (GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLPOLYGONOFFSETPROC) (GLfloat factor, GLfloat units); +typedef void (GL_APIENTRYP PFNGLREADPIXELSPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +typedef void (GL_APIENTRYP PFNGLRELEASESHADERCOMPILERPROC) (void); +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert); +typedef void (GL_APIENTRYP PFNGLSCISSORPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLSHADERBINARYPROC) (GLsizei count, const GLuint *shaders, GLenum binaryformat, const void *binary, GLsizei length); +typedef void (GL_APIENTRYP PFNGLSHADERSOURCEPROC) (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length); +typedef void (GL_APIENTRYP PFNGLSTENCILFUNCPROC) (GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILFUNCSEPARATEPROC) (GLenum face, GLenum func, GLint ref, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILMASKPROC) (GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILMASKSEPARATEPROC) (GLenum face, GLuint mask); +typedef void (GL_APIENTRYP PFNGLSTENCILOPPROC) (GLenum fail, GLenum zfail, GLenum zpass); +typedef void (GL_APIENTRYP PFNGLSTENCILOPSEPARATEPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE2DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFPROC) (GLenum target, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLUNIFORM1FPROC) (GLint location, GLfloat v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM1FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM1IPROC) (GLint location, GLint v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM1IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2FPROC) (GLint location, GLfloat v0, GLfloat v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM2FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2IPROC) (GLint location, GLint v0, GLint v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM2IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM3FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3IPROC) (GLint location, GLint v0, GLint v1, GLint v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM3IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM4FVPROC) (GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4IPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM4IVPROC) (GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUSEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLVALIDATEPROGRAMPROC) (GLuint program); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB1FPROC) (GLuint index, GLfloat x); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB1FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB2FPROC) (GLuint index, GLfloat x, GLfloat y); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB2FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB3FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB3FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIB4FVPROC) (GLuint index, const GLfloat *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBPOINTERPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLVIEWPORTPROC) (GLint x, GLint y, GLsizei width, GLsizei height); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glActiveTexture (GLenum texture); +GL_APICALL void GL_APIENTRY glAttachShader (GLuint program, GLuint shader); +GL_APICALL void GL_APIENTRY glBindAttribLocation (GLuint program, GLuint index, const GLchar *name); +GL_APICALL void GL_APIENTRY glBindBuffer (GLenum target, GLuint buffer); +GL_APICALL void GL_APIENTRY glBindFramebuffer (GLenum target, GLuint framebuffer); +GL_APICALL void GL_APIENTRY glBindRenderbuffer (GLenum target, GLuint renderbuffer); +GL_APICALL void GL_APIENTRY glBindTexture (GLenum target, GLuint texture); +GL_APICALL void GL_APIENTRY glBlendColor (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_APICALL void GL_APIENTRY glBlendEquation (GLenum mode); +GL_APICALL void GL_APIENTRY glBlendEquationSeparate (GLenum modeRGB, GLenum modeAlpha); +GL_APICALL void GL_APIENTRY glBlendFunc (GLenum sfactor, GLenum dfactor); +GL_APICALL void GL_APIENTRY glBlendFuncSeparate (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +GL_APICALL void GL_APIENTRY glBufferData (GLenum target, GLsizeiptr size, const void *data, GLenum usage); +GL_APICALL void GL_APIENTRY glBufferSubData (GLenum target, GLintptr offset, GLsizeiptr size, const void *data); +GL_APICALL GLenum GL_APIENTRY glCheckFramebufferStatus (GLenum target); +GL_APICALL void GL_APIENTRY glClear (GLbitfield mask); +GL_APICALL void GL_APIENTRY glClearColor (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +GL_APICALL void GL_APIENTRY glClearDepthf (GLfloat d); +GL_APICALL void GL_APIENTRY glClearStencil (GLint s); +GL_APICALL void GL_APIENTRY glColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); +GL_APICALL void GL_APIENTRY glCompileShader (GLuint shader); +GL_APICALL void GL_APIENTRY glCompressedTexImage2D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCopyTexImage2D (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); +GL_APICALL void GL_APIENTRY glCopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL GLuint GL_APIENTRY glCreateProgram (void); +GL_APICALL GLuint GL_APIENTRY glCreateShader (GLenum type); +GL_APICALL void GL_APIENTRY glCullFace (GLenum mode); +GL_APICALL void GL_APIENTRY glDeleteBuffers (GLsizei n, const GLuint *buffers); +GL_APICALL void GL_APIENTRY glDeleteFramebuffers (GLsizei n, const GLuint *framebuffers); +GL_APICALL void GL_APIENTRY glDeleteProgram (GLuint program); +GL_APICALL void GL_APIENTRY glDeleteRenderbuffers (GLsizei n, const GLuint *renderbuffers); +GL_APICALL void GL_APIENTRY glDeleteShader (GLuint shader); +GL_APICALL void GL_APIENTRY glDeleteTextures (GLsizei n, const GLuint *textures); +GL_APICALL void GL_APIENTRY glDepthFunc (GLenum func); +GL_APICALL void GL_APIENTRY glDepthMask (GLboolean flag); +GL_APICALL void GL_APIENTRY glDepthRangef (GLfloat n, GLfloat f); +GL_APICALL void GL_APIENTRY glDetachShader (GLuint program, GLuint shader); +GL_APICALL void GL_APIENTRY glDisable (GLenum cap); +GL_APICALL void GL_APIENTRY glDisableVertexAttribArray (GLuint index); +GL_APICALL void GL_APIENTRY glDrawArrays (GLenum mode, GLint first, GLsizei count); +GL_APICALL void GL_APIENTRY glDrawElements (GLenum mode, GLsizei count, GLenum type, const void *indices); +GL_APICALL void GL_APIENTRY glEnable (GLenum cap); +GL_APICALL void GL_APIENTRY glEnableVertexAttribArray (GLuint index); +GL_APICALL void GL_APIENTRY glFinish (void); +GL_APICALL void GL_APIENTRY glFlush (void); +GL_APICALL void GL_APIENTRY glFramebufferRenderbuffer (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); +GL_APICALL void GL_APIENTRY glFramebufferTexture2D (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); +GL_APICALL void GL_APIENTRY glFrontFace (GLenum mode); +GL_APICALL void GL_APIENTRY glGenBuffers (GLsizei n, GLuint *buffers); +GL_APICALL void GL_APIENTRY glGenerateMipmap (GLenum target); +GL_APICALL void GL_APIENTRY glGenFramebuffers (GLsizei n, GLuint *framebuffers); +GL_APICALL void GL_APIENTRY glGenRenderbuffers (GLsizei n, GLuint *renderbuffers); +GL_APICALL void GL_APIENTRY glGenTextures (GLsizei n, GLuint *textures); +GL_APICALL void GL_APIENTRY glGetActiveAttrib (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glGetActiveUniform (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glGetAttachedShaders (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *shaders); +GL_APICALL GLint GL_APIENTRY glGetAttribLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetBooleanv (GLenum pname, GLboolean *data); +GL_APICALL void GL_APIENTRY glGetBufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL GLenum GL_APIENTRY glGetError (void); +GL_APICALL void GL_APIENTRY glGetFloatv (GLenum pname, GLfloat *data); +GL_APICALL void GL_APIENTRY glGetFramebufferAttachmentParameteriv (GLenum target, GLenum attachment, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetIntegerv (GLenum pname, GLint *data); +GL_APICALL void GL_APIENTRY glGetProgramiv (GLuint program, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetProgramInfoLog (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glGetRenderbufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetShaderiv (GLuint shader, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetShaderInfoLog (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glGetShaderPrecisionFormat (GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision); +GL_APICALL void GL_APIENTRY glGetShaderSource (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); +GL_APICALL const GLubyte *GL_APIENTRY glGetString (GLenum name); +GL_APICALL void GL_APIENTRY glGetTexParameterfv (GLenum target, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetTexParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetUniformfv (GLuint program, GLint location, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetUniformiv (GLuint program, GLint location, GLint *params); +GL_APICALL GLint GL_APIENTRY glGetUniformLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetVertexAttribfv (GLuint index, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribiv (GLuint index, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribPointerv (GLuint index, GLenum pname, void **pointer); +GL_APICALL void GL_APIENTRY glHint (GLenum target, GLenum mode); +GL_APICALL GLboolean GL_APIENTRY glIsBuffer (GLuint buffer); +GL_APICALL GLboolean GL_APIENTRY glIsEnabled (GLenum cap); +GL_APICALL GLboolean GL_APIENTRY glIsFramebuffer (GLuint framebuffer); +GL_APICALL GLboolean GL_APIENTRY glIsProgram (GLuint program); +GL_APICALL GLboolean GL_APIENTRY glIsRenderbuffer (GLuint renderbuffer); +GL_APICALL GLboolean GL_APIENTRY glIsShader (GLuint shader); +GL_APICALL GLboolean GL_APIENTRY glIsTexture (GLuint texture); +GL_APICALL void GL_APIENTRY glLineWidth (GLfloat width); +GL_APICALL void GL_APIENTRY glLinkProgram (GLuint program); +GL_APICALL void GL_APIENTRY glPixelStorei (GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glPolygonOffset (GLfloat factor, GLfloat units); +GL_APICALL void GL_APIENTRY glReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, void *pixels); +GL_APICALL void GL_APIENTRY glReleaseShaderCompiler (void); +GL_APICALL void GL_APIENTRY glRenderbufferStorage (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glSampleCoverage (GLfloat value, GLboolean invert); +GL_APICALL void GL_APIENTRY glScissor (GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glShaderBinary (GLsizei count, const GLuint *shaders, GLenum binaryformat, const void *binary, GLsizei length); +GL_APICALL void GL_APIENTRY glShaderSource (GLuint shader, GLsizei count, const GLchar *const*string, const GLint *length); +GL_APICALL void GL_APIENTRY glStencilFunc (GLenum func, GLint ref, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilFuncSeparate (GLenum face, GLenum func, GLint ref, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilMask (GLuint mask); +GL_APICALL void GL_APIENTRY glStencilMaskSeparate (GLenum face, GLuint mask); +GL_APICALL void GL_APIENTRY glStencilOp (GLenum fail, GLenum zfail, GLenum zpass); +GL_APICALL void GL_APIENTRY glStencilOpSeparate (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); +GL_APICALL void GL_APIENTRY glTexImage2D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glTexParameterf (GLenum target, GLenum pname, GLfloat param); +GL_APICALL void GL_APIENTRY glTexParameterfv (GLenum target, GLenum pname, const GLfloat *params); +GL_APICALL void GL_APIENTRY glTexParameteri (GLenum target, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glTexParameteriv (GLenum target, GLenum pname, const GLint *params); +GL_APICALL void GL_APIENTRY glTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glUniform1f (GLint location, GLfloat v0); +GL_APICALL void GL_APIENTRY glUniform1fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform1i (GLint location, GLint v0); +GL_APICALL void GL_APIENTRY glUniform1iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform2f (GLint location, GLfloat v0, GLfloat v1); +GL_APICALL void GL_APIENTRY glUniform2fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform2i (GLint location, GLint v0, GLint v1); +GL_APICALL void GL_APIENTRY glUniform2iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform3f (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +GL_APICALL void GL_APIENTRY glUniform3fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform3i (GLint location, GLint v0, GLint v1, GLint v2); +GL_APICALL void GL_APIENTRY glUniform3iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniform4f (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +GL_APICALL void GL_APIENTRY glUniform4fv (GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniform4i (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +GL_APICALL void GL_APIENTRY glUniform4iv (GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glUniformMatrix2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUseProgram (GLuint program); +GL_APICALL void GL_APIENTRY glValidateProgram (GLuint program); +GL_APICALL void GL_APIENTRY glVertexAttrib1f (GLuint index, GLfloat x); +GL_APICALL void GL_APIENTRY glVertexAttrib1fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib2f (GLuint index, GLfloat x, GLfloat y); +GL_APICALL void GL_APIENTRY glVertexAttrib2fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib3f (GLuint index, GLfloat x, GLfloat y, GLfloat z); +GL_APICALL void GL_APIENTRY glVertexAttrib3fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttrib4f (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); +GL_APICALL void GL_APIENTRY glVertexAttrib4fv (GLuint index, const GLfloat *v); +GL_APICALL void GL_APIENTRY glVertexAttribPointer (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const void *pointer); +GL_APICALL void GL_APIENTRY glViewport (GLint x, GLint y, GLsizei width, GLsizei height); +#endif +#endif /* GL_ES_VERSION_2_0 */ + +#ifndef GL_ES_VERSION_3_0 +#define GL_ES_VERSION_3_0 1 +typedef khronos_uint16_t GLhalf; +#define GL_READ_BUFFER 0x0C02 +#define GL_UNPACK_ROW_LENGTH 0x0CF2 +#define GL_UNPACK_SKIP_ROWS 0x0CF3 +#define GL_UNPACK_SKIP_PIXELS 0x0CF4 +#define GL_PACK_ROW_LENGTH 0x0D02 +#define GL_PACK_SKIP_ROWS 0x0D03 +#define GL_PACK_SKIP_PIXELS 0x0D04 +#define GL_COLOR 0x1800 +#define GL_DEPTH 0x1801 +#define GL_STENCIL 0x1802 +#define GL_RED 0x1903 +#define GL_RGB8 0x8051 +#define GL_RGBA8 0x8058 +#define GL_RGB10_A2 0x8059 +#define GL_TEXTURE_BINDING_3D 0x806A +#define GL_UNPACK_SKIP_IMAGES 0x806D +#define GL_UNPACK_IMAGE_HEIGHT 0x806E +#define GL_TEXTURE_3D 0x806F +#define GL_TEXTURE_WRAP_R 0x8072 +#define GL_MAX_3D_TEXTURE_SIZE 0x8073 +#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368 +#define GL_MAX_ELEMENTS_VERTICES 0x80E8 +#define GL_MAX_ELEMENTS_INDICES 0x80E9 +#define GL_TEXTURE_MIN_LOD 0x813A +#define GL_TEXTURE_MAX_LOD 0x813B +#define GL_TEXTURE_BASE_LEVEL 0x813C +#define GL_TEXTURE_MAX_LEVEL 0x813D +#define GL_MIN 0x8007 +#define GL_MAX 0x8008 +#define GL_DEPTH_COMPONENT24 0x81A6 +#define GL_MAX_TEXTURE_LOD_BIAS 0x84FD +#define GL_TEXTURE_COMPARE_MODE 0x884C +#define GL_TEXTURE_COMPARE_FUNC 0x884D +#define GL_CURRENT_QUERY 0x8865 +#define GL_QUERY_RESULT 0x8866 +#define GL_QUERY_RESULT_AVAILABLE 0x8867 +#define GL_BUFFER_MAPPED 0x88BC +#define GL_BUFFER_MAP_POINTER 0x88BD +#define GL_STREAM_READ 0x88E1 +#define GL_STREAM_COPY 0x88E2 +#define GL_STATIC_READ 0x88E5 +#define GL_STATIC_COPY 0x88E6 +#define GL_DYNAMIC_READ 0x88E9 +#define GL_DYNAMIC_COPY 0x88EA +#define GL_MAX_DRAW_BUFFERS 0x8824 +#define GL_DRAW_BUFFER0 0x8825 +#define GL_DRAW_BUFFER1 0x8826 +#define GL_DRAW_BUFFER2 0x8827 +#define GL_DRAW_BUFFER3 0x8828 +#define GL_DRAW_BUFFER4 0x8829 +#define GL_DRAW_BUFFER5 0x882A +#define GL_DRAW_BUFFER6 0x882B +#define GL_DRAW_BUFFER7 0x882C +#define GL_DRAW_BUFFER8 0x882D +#define GL_DRAW_BUFFER9 0x882E +#define GL_DRAW_BUFFER10 0x882F +#define GL_DRAW_BUFFER11 0x8830 +#define GL_DRAW_BUFFER12 0x8831 +#define GL_DRAW_BUFFER13 0x8832 +#define GL_DRAW_BUFFER14 0x8833 +#define GL_DRAW_BUFFER15 0x8834 +#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS 0x8B49 +#define GL_MAX_VERTEX_UNIFORM_COMPONENTS 0x8B4A +#define GL_SAMPLER_3D 0x8B5F +#define GL_SAMPLER_2D_SHADOW 0x8B62 +#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT 0x8B8B +#define GL_PIXEL_PACK_BUFFER 0x88EB +#define GL_PIXEL_UNPACK_BUFFER 0x88EC +#define GL_PIXEL_PACK_BUFFER_BINDING 0x88ED +#define GL_PIXEL_UNPACK_BUFFER_BINDING 0x88EF +#define GL_FLOAT_MAT2x3 0x8B65 +#define GL_FLOAT_MAT2x4 0x8B66 +#define GL_FLOAT_MAT3x2 0x8B67 +#define GL_FLOAT_MAT3x4 0x8B68 +#define GL_FLOAT_MAT4x2 0x8B69 +#define GL_FLOAT_MAT4x3 0x8B6A +#define GL_SRGB 0x8C40 +#define GL_SRGB8 0x8C41 +#define GL_SRGB8_ALPHA8 0x8C43 +#define GL_COMPARE_REF_TO_TEXTURE 0x884E +#define GL_MAJOR_VERSION 0x821B +#define GL_MINOR_VERSION 0x821C +#define GL_NUM_EXTENSIONS 0x821D +#define GL_RGBA32F 0x8814 +#define GL_RGB32F 0x8815 +#define GL_RGBA16F 0x881A +#define GL_RGB16F 0x881B +#define GL_VERTEX_ATTRIB_ARRAY_INTEGER 0x88FD +#define GL_MAX_ARRAY_TEXTURE_LAYERS 0x88FF +#define GL_MIN_PROGRAM_TEXEL_OFFSET 0x8904 +#define GL_MAX_PROGRAM_TEXEL_OFFSET 0x8905 +#define GL_MAX_VARYING_COMPONENTS 0x8B4B +#define GL_TEXTURE_2D_ARRAY 0x8C1A +#define GL_TEXTURE_BINDING_2D_ARRAY 0x8C1D +#define GL_R11F_G11F_B10F 0x8C3A +#define GL_UNSIGNED_INT_10F_11F_11F_REV 0x8C3B +#define GL_RGB9_E5 0x8C3D +#define GL_UNSIGNED_INT_5_9_9_9_REV 0x8C3E +#define GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH 0x8C76 +#define GL_TRANSFORM_FEEDBACK_BUFFER_MODE 0x8C7F +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS 0x8C80 +#define GL_TRANSFORM_FEEDBACK_VARYINGS 0x8C83 +#define GL_TRANSFORM_FEEDBACK_BUFFER_START 0x8C84 +#define GL_TRANSFORM_FEEDBACK_BUFFER_SIZE 0x8C85 +#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN 0x8C88 +#define GL_RASTERIZER_DISCARD 0x8C89 +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS 0x8C8B +#define GL_INTERLEAVED_ATTRIBS 0x8C8C +#define GL_SEPARATE_ATTRIBS 0x8C8D +#define GL_TRANSFORM_FEEDBACK_BUFFER 0x8C8E +#define GL_TRANSFORM_FEEDBACK_BUFFER_BINDING 0x8C8F +#define GL_RGBA32UI 0x8D70 +#define GL_RGB32UI 0x8D71 +#define GL_RGBA16UI 0x8D76 +#define GL_RGB16UI 0x8D77 +#define GL_RGBA8UI 0x8D7C +#define GL_RGB8UI 0x8D7D +#define GL_RGBA32I 0x8D82 +#define GL_RGB32I 0x8D83 +#define GL_RGBA16I 0x8D88 +#define GL_RGB16I 0x8D89 +#define GL_RGBA8I 0x8D8E +#define GL_RGB8I 0x8D8F +#define GL_RED_INTEGER 0x8D94 +#define GL_RGB_INTEGER 0x8D98 +#define GL_RGBA_INTEGER 0x8D99 +#define GL_SAMPLER_2D_ARRAY 0x8DC1 +#define GL_SAMPLER_2D_ARRAY_SHADOW 0x8DC4 +#define GL_SAMPLER_CUBE_SHADOW 0x8DC5 +#define GL_UNSIGNED_INT_VEC2 0x8DC6 +#define GL_UNSIGNED_INT_VEC3 0x8DC7 +#define GL_UNSIGNED_INT_VEC4 0x8DC8 +#define GL_INT_SAMPLER_2D 0x8DCA +#define GL_INT_SAMPLER_3D 0x8DCB +#define GL_INT_SAMPLER_CUBE 0x8DCC +#define GL_INT_SAMPLER_2D_ARRAY 0x8DCF +#define GL_UNSIGNED_INT_SAMPLER_2D 0x8DD2 +#define GL_UNSIGNED_INT_SAMPLER_3D 0x8DD3 +#define GL_UNSIGNED_INT_SAMPLER_CUBE 0x8DD4 +#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY 0x8DD7 +#define GL_BUFFER_ACCESS_FLAGS 0x911F +#define GL_BUFFER_MAP_LENGTH 0x9120 +#define GL_BUFFER_MAP_OFFSET 0x9121 +#define GL_DEPTH_COMPONENT32F 0x8CAC +#define GL_DEPTH32F_STENCIL8 0x8CAD +#define GL_FLOAT_32_UNSIGNED_INT_24_8_REV 0x8DAD +#define GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING 0x8210 +#define GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE 0x8211 +#define GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE 0x8212 +#define GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE 0x8213 +#define GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE 0x8214 +#define GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE 0x8215 +#define GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE 0x8216 +#define GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE 0x8217 +#define GL_FRAMEBUFFER_DEFAULT 0x8218 +#define GL_FRAMEBUFFER_UNDEFINED 0x8219 +#define GL_DEPTH_STENCIL_ATTACHMENT 0x821A +#define GL_DEPTH_STENCIL 0x84F9 +#define GL_UNSIGNED_INT_24_8 0x84FA +#define GL_DEPTH24_STENCIL8 0x88F0 +#define GL_UNSIGNED_NORMALIZED 0x8C17 +#define GL_DRAW_FRAMEBUFFER_BINDING 0x8CA6 +#define GL_READ_FRAMEBUFFER 0x8CA8 +#define GL_DRAW_FRAMEBUFFER 0x8CA9 +#define GL_READ_FRAMEBUFFER_BINDING 0x8CAA +#define GL_RENDERBUFFER_SAMPLES 0x8CAB +#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER 0x8CD4 +#define GL_MAX_COLOR_ATTACHMENTS 0x8CDF +#define GL_COLOR_ATTACHMENT1 0x8CE1 +#define GL_COLOR_ATTACHMENT2 0x8CE2 +#define GL_COLOR_ATTACHMENT3 0x8CE3 +#define GL_COLOR_ATTACHMENT4 0x8CE4 +#define GL_COLOR_ATTACHMENT5 0x8CE5 +#define GL_COLOR_ATTACHMENT6 0x8CE6 +#define GL_COLOR_ATTACHMENT7 0x8CE7 +#define GL_COLOR_ATTACHMENT8 0x8CE8 +#define GL_COLOR_ATTACHMENT9 0x8CE9 +#define GL_COLOR_ATTACHMENT10 0x8CEA +#define GL_COLOR_ATTACHMENT11 0x8CEB +#define GL_COLOR_ATTACHMENT12 0x8CEC +#define GL_COLOR_ATTACHMENT13 0x8CED +#define GL_COLOR_ATTACHMENT14 0x8CEE +#define GL_COLOR_ATTACHMENT15 0x8CEF +#define GL_COLOR_ATTACHMENT16 0x8CF0 +#define GL_COLOR_ATTACHMENT17 0x8CF1 +#define GL_COLOR_ATTACHMENT18 0x8CF2 +#define GL_COLOR_ATTACHMENT19 0x8CF3 +#define GL_COLOR_ATTACHMENT20 0x8CF4 +#define GL_COLOR_ATTACHMENT21 0x8CF5 +#define GL_COLOR_ATTACHMENT22 0x8CF6 +#define GL_COLOR_ATTACHMENT23 0x8CF7 +#define GL_COLOR_ATTACHMENT24 0x8CF8 +#define GL_COLOR_ATTACHMENT25 0x8CF9 +#define GL_COLOR_ATTACHMENT26 0x8CFA +#define GL_COLOR_ATTACHMENT27 0x8CFB +#define GL_COLOR_ATTACHMENT28 0x8CFC +#define GL_COLOR_ATTACHMENT29 0x8CFD +#define GL_COLOR_ATTACHMENT30 0x8CFE +#define GL_COLOR_ATTACHMENT31 0x8CFF +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE 0x8D56 +#define GL_MAX_SAMPLES 0x8D57 +#define GL_HALF_FLOAT 0x140B +#define GL_MAP_READ_BIT 0x0001 +#define GL_MAP_WRITE_BIT 0x0002 +#define GL_MAP_INVALIDATE_RANGE_BIT 0x0004 +#define GL_MAP_INVALIDATE_BUFFER_BIT 0x0008 +#define GL_MAP_FLUSH_EXPLICIT_BIT 0x0010 +#define GL_MAP_UNSYNCHRONIZED_BIT 0x0020 +#define GL_RG 0x8227 +#define GL_RG_INTEGER 0x8228 +#define GL_R8 0x8229 +#define GL_RG8 0x822B +#define GL_R16F 0x822D +#define GL_R32F 0x822E +#define GL_RG16F 0x822F +#define GL_RG32F 0x8230 +#define GL_R8I 0x8231 +#define GL_R8UI 0x8232 +#define GL_R16I 0x8233 +#define GL_R16UI 0x8234 +#define GL_R32I 0x8235 +#define GL_R32UI 0x8236 +#define GL_RG8I 0x8237 +#define GL_RG8UI 0x8238 +#define GL_RG16I 0x8239 +#define GL_RG16UI 0x823A +#define GL_RG32I 0x823B +#define GL_RG32UI 0x823C +#define GL_VERTEX_ARRAY_BINDING 0x85B5 +#define GL_R8_SNORM 0x8F94 +#define GL_RG8_SNORM 0x8F95 +#define GL_RGB8_SNORM 0x8F96 +#define GL_RGBA8_SNORM 0x8F97 +#define GL_SIGNED_NORMALIZED 0x8F9C +#define GL_PRIMITIVE_RESTART_FIXED_INDEX 0x8D69 +#define GL_COPY_READ_BUFFER 0x8F36 +#define GL_COPY_WRITE_BUFFER 0x8F37 +#define GL_COPY_READ_BUFFER_BINDING 0x8F36 +#define GL_COPY_WRITE_BUFFER_BINDING 0x8F37 +#define GL_UNIFORM_BUFFER 0x8A11 +#define GL_UNIFORM_BUFFER_BINDING 0x8A28 +#define GL_UNIFORM_BUFFER_START 0x8A29 +#define GL_UNIFORM_BUFFER_SIZE 0x8A2A +#define GL_MAX_VERTEX_UNIFORM_BLOCKS 0x8A2B +#define GL_MAX_FRAGMENT_UNIFORM_BLOCKS 0x8A2D +#define GL_MAX_COMBINED_UNIFORM_BLOCKS 0x8A2E +#define GL_MAX_UNIFORM_BUFFER_BINDINGS 0x8A2F +#define GL_MAX_UNIFORM_BLOCK_SIZE 0x8A30 +#define GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS 0x8A31 +#define GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS 0x8A33 +#define GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT 0x8A34 +#define GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH 0x8A35 +#define GL_ACTIVE_UNIFORM_BLOCKS 0x8A36 +#define GL_UNIFORM_TYPE 0x8A37 +#define GL_UNIFORM_SIZE 0x8A38 +#define GL_UNIFORM_NAME_LENGTH 0x8A39 +#define GL_UNIFORM_BLOCK_INDEX 0x8A3A +#define GL_UNIFORM_OFFSET 0x8A3B +#define GL_UNIFORM_ARRAY_STRIDE 0x8A3C +#define GL_UNIFORM_MATRIX_STRIDE 0x8A3D +#define GL_UNIFORM_IS_ROW_MAJOR 0x8A3E +#define GL_UNIFORM_BLOCK_BINDING 0x8A3F +#define GL_UNIFORM_BLOCK_DATA_SIZE 0x8A40 +#define GL_UNIFORM_BLOCK_NAME_LENGTH 0x8A41 +#define GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS 0x8A42 +#define GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES 0x8A43 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER 0x8A44 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER 0x8A46 +#define GL_INVALID_INDEX 0xFFFFFFFFu +#define GL_MAX_VERTEX_OUTPUT_COMPONENTS 0x9122 +#define GL_MAX_FRAGMENT_INPUT_COMPONENTS 0x9125 +#define GL_MAX_SERVER_WAIT_TIMEOUT 0x9111 +#define GL_OBJECT_TYPE 0x9112 +#define GL_SYNC_CONDITION 0x9113 +#define GL_SYNC_STATUS 0x9114 +#define GL_SYNC_FLAGS 0x9115 +#define GL_SYNC_FENCE 0x9116 +#define GL_SYNC_GPU_COMMANDS_COMPLETE 0x9117 +#define GL_UNSIGNALED 0x9118 +#define GL_SIGNALED 0x9119 +#define GL_ALREADY_SIGNALED 0x911A +#define GL_TIMEOUT_EXPIRED 0x911B +#define GL_CONDITION_SATISFIED 0x911C +#define GL_WAIT_FAILED 0x911D +#define GL_SYNC_FLUSH_COMMANDS_BIT 0x00000001 +#define GL_TIMEOUT_IGNORED 0xFFFFFFFFFFFFFFFFull +#define GL_VERTEX_ATTRIB_ARRAY_DIVISOR 0x88FE +#define GL_ANY_SAMPLES_PASSED 0x8C2F +#define GL_ANY_SAMPLES_PASSED_CONSERVATIVE 0x8D6A +#define GL_SAMPLER_BINDING 0x8919 +#define GL_RGB10_A2UI 0x906F +#define GL_TEXTURE_SWIZZLE_R 0x8E42 +#define GL_TEXTURE_SWIZZLE_G 0x8E43 +#define GL_TEXTURE_SWIZZLE_B 0x8E44 +#define GL_TEXTURE_SWIZZLE_A 0x8E45 +#define GL_GREEN 0x1904 +#define GL_BLUE 0x1905 +#define GL_INT_2_10_10_10_REV 0x8D9F +#define GL_TRANSFORM_FEEDBACK 0x8E22 +#define GL_TRANSFORM_FEEDBACK_PAUSED 0x8E23 +#define GL_TRANSFORM_FEEDBACK_ACTIVE 0x8E24 +#define GL_TRANSFORM_FEEDBACK_BINDING 0x8E25 +#define GL_PROGRAM_BINARY_RETRIEVABLE_HINT 0x8257 +#define GL_PROGRAM_BINARY_LENGTH 0x8741 +#define GL_NUM_PROGRAM_BINARY_FORMATS 0x87FE +#define GL_PROGRAM_BINARY_FORMATS 0x87FF +#define GL_COMPRESSED_R11_EAC 0x9270 +#define GL_COMPRESSED_SIGNED_R11_EAC 0x9271 +#define GL_COMPRESSED_RG11_EAC 0x9272 +#define GL_COMPRESSED_SIGNED_RG11_EAC 0x9273 +#define GL_COMPRESSED_RGB8_ETC2 0x9274 +#define GL_COMPRESSED_SRGB8_ETC2 0x9275 +#define GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9276 +#define GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9277 +#define GL_COMPRESSED_RGBA8_ETC2_EAC 0x9278 +#define GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC 0x9279 +#define GL_TEXTURE_IMMUTABLE_FORMAT 0x912F +#define GL_MAX_ELEMENT_INDEX 0x8D6B +#define GL_NUM_SAMPLE_COUNTS 0x9380 +#define GL_TEXTURE_IMMUTABLE_LEVELS 0x82DF +typedef void (GL_APIENTRYP PFNGLREADBUFFERPROC) (GLenum src); +typedef void (GL_APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices); +typedef void (GL_APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels); +typedef void (GL_APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void *data); +typedef void (GL_APIENTRYP PFNGLGENQUERIESPROC) (GLsizei n, GLuint *ids); +typedef void (GL_APIENTRYP PFNGLDELETEQUERIESPROC) (GLsizei n, const GLuint *ids); +typedef GLboolean (GL_APIENTRYP PFNGLISQUERYPROC) (GLuint id); +typedef void (GL_APIENTRYP PFNGLBEGINQUERYPROC) (GLenum target, GLuint id); +typedef void (GL_APIENTRYP PFNGLENDQUERYPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGETQUERYIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETQUERYOBJECTUIVPROC) (GLuint id, GLenum pname, GLuint *params); +typedef GLboolean (GL_APIENTRYP PFNGLUNMAPBUFFERPROC) (GLenum target); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVPROC) (GLenum target, GLenum pname, void **params); +typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSPROC) (GLsizei n, const GLenum *bufs); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX2X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4X2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX3X4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLUNIFORMMATRIX4X3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLBLITFRAMEBUFFERPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURELAYERPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); +typedef void *(GL_APIENTRYP PFNGLMAPBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +typedef void (GL_APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEPROC) (GLenum target, GLintptr offset, GLsizeiptr length); +typedef void (GL_APIENTRYP PFNGLBINDVERTEXARRAYPROC) (GLuint array); +typedef void (GL_APIENTRYP PFNGLDELETEVERTEXARRAYSPROC) (GLsizei n, const GLuint *arrays); +typedef void (GL_APIENTRYP PFNGLGENVERTEXARRAYSPROC) (GLsizei n, GLuint *arrays); +typedef GLboolean (GL_APIENTRYP PFNGLISVERTEXARRAYPROC) (GLuint array); +typedef void (GL_APIENTRYP PFNGLGETINTEGERI_VPROC) (GLenum target, GLuint index, GLint *data); +typedef void (GL_APIENTRYP PFNGLBEGINTRANSFORMFEEDBACKPROC) (GLenum primitiveMode); +typedef void (GL_APIENTRYP PFNGLENDTRANSFORMFEEDBACKPROC) (void); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERRANGEPROC) (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); +typedef void (GL_APIENTRYP PFNGLBINDBUFFERBASEPROC) (GLenum target, GLuint index, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLTRANSFORMFEEDBACKVARYINGSPROC) (GLuint program, GLsizei count, const GLchar *const*varyings, GLenum bufferMode); +typedef void (GL_APIENTRYP PFNGLGETTRANSFORMFEEDBACKVARYINGPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBIPOINTERPROC) (GLuint index, GLint size, GLenum type, GLsizei stride, const void *pointer); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIIVPROC) (GLuint index, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETVERTEXATTRIBIUIVPROC) (GLuint index, GLenum pname, GLuint *params); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4IPROC) (GLuint index, GLint x, GLint y, GLint z, GLint w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4UIPROC) (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4IVPROC) (GLuint index, const GLint *v); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBI4UIVPROC) (GLuint index, const GLuint *v); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMUIVPROC) (GLuint program, GLint location, GLuint *params); +typedef GLint (GL_APIENTRYP PFNGLGETFRAGDATALOCATIONPROC) (GLuint program, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLUNIFORM1UIPROC) (GLint location, GLuint v0); +typedef void (GL_APIENTRYP PFNGLUNIFORM2UIPROC) (GLint location, GLuint v0, GLuint v1); +typedef void (GL_APIENTRYP PFNGLUNIFORM3UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2); +typedef void (GL_APIENTRYP PFNGLUNIFORM4UIPROC) (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +typedef void (GL_APIENTRYP PFNGLUNIFORM1UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM2UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM3UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLUNIFORM4UIVPROC) (GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERIVPROC) (GLenum buffer, GLint drawbuffer, const GLint *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERUIVPROC) (GLenum buffer, GLint drawbuffer, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERFVPROC) (GLenum buffer, GLint drawbuffer, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLCLEARBUFFERFIPROC) (GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil); +typedef const GLubyte *(GL_APIENTRYP PFNGLGETSTRINGIPROC) (GLenum name, GLuint index); +typedef void (GL_APIENTRYP PFNGLCOPYBUFFERSUBDATAPROC) (GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +typedef void (GL_APIENTRYP PFNGLGETUNIFORMINDICESPROC) (GLuint program, GLsizei uniformCount, const GLchar *const*uniformNames, GLuint *uniformIndices); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMSIVPROC) (GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params); +typedef GLuint (GL_APIENTRYP PFNGLGETUNIFORMBLOCKINDEXPROC) (GLuint program, const GLchar *uniformBlockName); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMBLOCKIVPROC) (GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETACTIVEUNIFORMBLOCKNAMEPROC) (GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName); +typedef void (GL_APIENTRYP PFNGLUNIFORMBLOCKBINDINGPROC) (GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instancecount); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount); +typedef GLsync (GL_APIENTRYP PFNGLFENCESYNCPROC) (GLenum condition, GLbitfield flags); +typedef GLboolean (GL_APIENTRYP PFNGLISSYNCPROC) (GLsync sync); +typedef void (GL_APIENTRYP PFNGLDELETESYNCPROC) (GLsync sync); +typedef GLenum (GL_APIENTRYP PFNGLCLIENTWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLWAITSYNCPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64VPROC) (GLenum pname, GLint64 *data); +typedef void (GL_APIENTRYP PFNGLGETSYNCIVPROC) (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64I_VPROC) (GLenum target, GLuint index, GLint64 *data); +typedef void (GL_APIENTRYP PFNGLGETBUFFERPARAMETERI64VPROC) (GLenum target, GLenum pname, GLint64 *params); +typedef void (GL_APIENTRYP PFNGLGENSAMPLERSPROC) (GLsizei count, GLuint *samplers); +typedef void (GL_APIENTRYP PFNGLDELETESAMPLERSPROC) (GLsizei count, const GLuint *samplers); +typedef GLboolean (GL_APIENTRYP PFNGLISSAMPLERPROC) (GLuint sampler); +typedef void (GL_APIENTRYP PFNGLBINDSAMPLERPROC) (GLuint unit, GLuint sampler); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIPROC) (GLuint sampler, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIVPROC) (GLuint sampler, GLenum pname, const GLint *param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERFPROC) (GLuint sampler, GLenum pname, GLfloat param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERFVPROC) (GLuint sampler, GLenum pname, const GLfloat *param); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIVPROC) (GLuint sampler, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERFVPROC) (GLuint sampler, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISORPROC) (GLuint index, GLuint divisor); +typedef void (GL_APIENTRYP PFNGLBINDTRANSFORMFEEDBACKPROC) (GLenum target, GLuint id); +typedef void (GL_APIENTRYP PFNGLDELETETRANSFORMFEEDBACKSPROC) (GLsizei n, const GLuint *ids); +typedef void (GL_APIENTRYP PFNGLGENTRANSFORMFEEDBACKSPROC) (GLsizei n, GLuint *ids); +typedef GLboolean (GL_APIENTRYP PFNGLISTRANSFORMFEEDBACKPROC) (GLuint id); +typedef void (GL_APIENTRYP PFNGLPAUSETRANSFORMFEEDBACKPROC) (void); +typedef void (GL_APIENTRYP PFNGLRESUMETRANSFORMFEEDBACKPROC) (void); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMBINARYPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary); +typedef void (GL_APIENTRYP PFNGLPROGRAMBINARYPROC) (GLuint program, GLenum binaryFormat, const void *binary, GLsizei length); +typedef void (GL_APIENTRYP PFNGLPROGRAMPARAMETERIPROC) (GLuint program, GLenum pname, GLint value); +typedef void (GL_APIENTRYP PFNGLINVALIDATEFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments); +typedef void (GL_APIENTRYP PFNGLINVALIDATESUBFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE3DPROC) (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +typedef void (GL_APIENTRYP PFNGLGETINTERNALFORMATIVPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glReadBuffer (GLenum src); +GL_APICALL void GL_APIENTRY glDrawRangeElements (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices); +GL_APICALL void GL_APIENTRY glTexImage3D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *pixels); +GL_APICALL void GL_APIENTRY glCopyTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glCompressedTexImage3D (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glCompressedTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const void *data); +GL_APICALL void GL_APIENTRY glGenQueries (GLsizei n, GLuint *ids); +GL_APICALL void GL_APIENTRY glDeleteQueries (GLsizei n, const GLuint *ids); +GL_APICALL GLboolean GL_APIENTRY glIsQuery (GLuint id); +GL_APICALL void GL_APIENTRY glBeginQuery (GLenum target, GLuint id); +GL_APICALL void GL_APIENTRY glEndQuery (GLenum target); +GL_APICALL void GL_APIENTRY glGetQueryiv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetQueryObjectuiv (GLuint id, GLenum pname, GLuint *params); +GL_APICALL GLboolean GL_APIENTRY glUnmapBuffer (GLenum target); +GL_APICALL void GL_APIENTRY glGetBufferPointerv (GLenum target, GLenum pname, void **params); +GL_APICALL void GL_APIENTRY glDrawBuffers (GLsizei n, const GLenum *bufs); +GL_APICALL void GL_APIENTRY glUniformMatrix2x3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3x2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix2x4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4x2fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix3x4fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glUniformMatrix4x3fv (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glBlitFramebuffer (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glFramebufferTextureLayer (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); +GL_APICALL void *GL_APIENTRY glMapBufferRange (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +GL_APICALL void GL_APIENTRY glFlushMappedBufferRange (GLenum target, GLintptr offset, GLsizeiptr length); +GL_APICALL void GL_APIENTRY glBindVertexArray (GLuint array); +GL_APICALL void GL_APIENTRY glDeleteVertexArrays (GLsizei n, const GLuint *arrays); +GL_APICALL void GL_APIENTRY glGenVertexArrays (GLsizei n, GLuint *arrays); +GL_APICALL GLboolean GL_APIENTRY glIsVertexArray (GLuint array); +GL_APICALL void GL_APIENTRY glGetIntegeri_v (GLenum target, GLuint index, GLint *data); +GL_APICALL void GL_APIENTRY glBeginTransformFeedback (GLenum primitiveMode); +GL_APICALL void GL_APIENTRY glEndTransformFeedback (void); +GL_APICALL void GL_APIENTRY glBindBufferRange (GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); +GL_APICALL void GL_APIENTRY glBindBufferBase (GLenum target, GLuint index, GLuint buffer); +GL_APICALL void GL_APIENTRY glTransformFeedbackVaryings (GLuint program, GLsizei count, const GLchar *const*varyings, GLenum bufferMode); +GL_APICALL void GL_APIENTRY glGetTransformFeedbackVarying (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name); +GL_APICALL void GL_APIENTRY glVertexAttribIPointer (GLuint index, GLint size, GLenum type, GLsizei stride, const void *pointer); +GL_APICALL void GL_APIENTRY glGetVertexAttribIiv (GLuint index, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetVertexAttribIuiv (GLuint index, GLenum pname, GLuint *params); +GL_APICALL void GL_APIENTRY glVertexAttribI4i (GLuint index, GLint x, GLint y, GLint z, GLint w); +GL_APICALL void GL_APIENTRY glVertexAttribI4ui (GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); +GL_APICALL void GL_APIENTRY glVertexAttribI4iv (GLuint index, const GLint *v); +GL_APICALL void GL_APIENTRY glVertexAttribI4uiv (GLuint index, const GLuint *v); +GL_APICALL void GL_APIENTRY glGetUniformuiv (GLuint program, GLint location, GLuint *params); +GL_APICALL GLint GL_APIENTRY glGetFragDataLocation (GLuint program, const GLchar *name); +GL_APICALL void GL_APIENTRY glUniform1ui (GLint location, GLuint v0); +GL_APICALL void GL_APIENTRY glUniform2ui (GLint location, GLuint v0, GLuint v1); +GL_APICALL void GL_APIENTRY glUniform3ui (GLint location, GLuint v0, GLuint v1, GLuint v2); +GL_APICALL void GL_APIENTRY glUniform4ui (GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +GL_APICALL void GL_APIENTRY glUniform1uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glUniform2uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glUniform3uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glUniform4uiv (GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glClearBufferiv (GLenum buffer, GLint drawbuffer, const GLint *value); +GL_APICALL void GL_APIENTRY glClearBufferuiv (GLenum buffer, GLint drawbuffer, const GLuint *value); +GL_APICALL void GL_APIENTRY glClearBufferfv (GLenum buffer, GLint drawbuffer, const GLfloat *value); +GL_APICALL void GL_APIENTRY glClearBufferfi (GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil); +GL_APICALL const GLubyte *GL_APIENTRY glGetStringi (GLenum name, GLuint index); +GL_APICALL void GL_APIENTRY glCopyBufferSubData (GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +GL_APICALL void GL_APIENTRY glGetUniformIndices (GLuint program, GLsizei uniformCount, const GLchar *const*uniformNames, GLuint *uniformIndices); +GL_APICALL void GL_APIENTRY glGetActiveUniformsiv (GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params); +GL_APICALL GLuint GL_APIENTRY glGetUniformBlockIndex (GLuint program, const GLchar *uniformBlockName); +GL_APICALL void GL_APIENTRY glGetActiveUniformBlockiv (GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetActiveUniformBlockName (GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName); +GL_APICALL void GL_APIENTRY glUniformBlockBinding (GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding); +GL_APICALL void GL_APIENTRY glDrawArraysInstanced (GLenum mode, GLint first, GLsizei count, GLsizei instancecount); +GL_APICALL void GL_APIENTRY glDrawElementsInstanced (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount); +GL_APICALL GLsync GL_APIENTRY glFenceSync (GLenum condition, GLbitfield flags); +GL_APICALL GLboolean GL_APIENTRY glIsSync (GLsync sync); +GL_APICALL void GL_APIENTRY glDeleteSync (GLsync sync); +GL_APICALL GLenum GL_APIENTRY glClientWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_APICALL void GL_APIENTRY glWaitSync (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_APICALL void GL_APIENTRY glGetInteger64v (GLenum pname, GLint64 *data); +GL_APICALL void GL_APIENTRY glGetSynciv (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values); +GL_APICALL void GL_APIENTRY glGetInteger64i_v (GLenum target, GLuint index, GLint64 *data); +GL_APICALL void GL_APIENTRY glGetBufferParameteri64v (GLenum target, GLenum pname, GLint64 *params); +GL_APICALL void GL_APIENTRY glGenSamplers (GLsizei count, GLuint *samplers); +GL_APICALL void GL_APIENTRY glDeleteSamplers (GLsizei count, const GLuint *samplers); +GL_APICALL GLboolean GL_APIENTRY glIsSampler (GLuint sampler); +GL_APICALL void GL_APIENTRY glBindSampler (GLuint unit, GLuint sampler); +GL_APICALL void GL_APIENTRY glSamplerParameteri (GLuint sampler, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glSamplerParameteriv (GLuint sampler, GLenum pname, const GLint *param); +GL_APICALL void GL_APIENTRY glSamplerParameterf (GLuint sampler, GLenum pname, GLfloat param); +GL_APICALL void GL_APIENTRY glSamplerParameterfv (GLuint sampler, GLenum pname, const GLfloat *param); +GL_APICALL void GL_APIENTRY glGetSamplerParameteriv (GLuint sampler, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetSamplerParameterfv (GLuint sampler, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glVertexAttribDivisor (GLuint index, GLuint divisor); +GL_APICALL void GL_APIENTRY glBindTransformFeedback (GLenum target, GLuint id); +GL_APICALL void GL_APIENTRY glDeleteTransformFeedbacks (GLsizei n, const GLuint *ids); +GL_APICALL void GL_APIENTRY glGenTransformFeedbacks (GLsizei n, GLuint *ids); +GL_APICALL GLboolean GL_APIENTRY glIsTransformFeedback (GLuint id); +GL_APICALL void GL_APIENTRY glPauseTransformFeedback (void); +GL_APICALL void GL_APIENTRY glResumeTransformFeedback (void); +GL_APICALL void GL_APIENTRY glGetProgramBinary (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary); +GL_APICALL void GL_APIENTRY glProgramBinary (GLuint program, GLenum binaryFormat, const void *binary, GLsizei length); +GL_APICALL void GL_APIENTRY glProgramParameteri (GLuint program, GLenum pname, GLint value); +GL_APICALL void GL_APIENTRY glInvalidateFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments); +GL_APICALL void GL_APIENTRY glInvalidateSubFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glTexStorage2D (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height); +GL_APICALL void GL_APIENTRY glTexStorage3D (GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); +GL_APICALL void GL_APIENTRY glGetInternalformativ (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params); +#endif +#endif /* GL_ES_VERSION_3_0 */ + +#ifndef GL_ES_VERSION_3_1 +#define GL_ES_VERSION_3_1 1 +#define GL_COMPUTE_SHADER 0x91B9 +#define GL_MAX_COMPUTE_UNIFORM_BLOCKS 0x91BB +#define GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS 0x91BC +#define GL_MAX_COMPUTE_IMAGE_UNIFORMS 0x91BD +#define GL_MAX_COMPUTE_SHARED_MEMORY_SIZE 0x8262 +#define GL_MAX_COMPUTE_UNIFORM_COMPONENTS 0x8263 +#define GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS 0x8264 +#define GL_MAX_COMPUTE_ATOMIC_COUNTERS 0x8265 +#define GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS 0x8266 +#define GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS 0x90EB +#define GL_MAX_COMPUTE_WORK_GROUP_COUNT 0x91BE +#define GL_MAX_COMPUTE_WORK_GROUP_SIZE 0x91BF +#define GL_COMPUTE_WORK_GROUP_SIZE 0x8267 +#define GL_DISPATCH_INDIRECT_BUFFER 0x90EE +#define GL_DISPATCH_INDIRECT_BUFFER_BINDING 0x90EF +#define GL_COMPUTE_SHADER_BIT 0x00000020 +#define GL_DRAW_INDIRECT_BUFFER 0x8F3F +#define GL_DRAW_INDIRECT_BUFFER_BINDING 0x8F43 +#define GL_MAX_UNIFORM_LOCATIONS 0x826E +#define GL_FRAMEBUFFER_DEFAULT_WIDTH 0x9310 +#define GL_FRAMEBUFFER_DEFAULT_HEIGHT 0x9311 +#define GL_FRAMEBUFFER_DEFAULT_SAMPLES 0x9313 +#define GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS 0x9314 +#define GL_MAX_FRAMEBUFFER_WIDTH 0x9315 +#define GL_MAX_FRAMEBUFFER_HEIGHT 0x9316 +#define GL_MAX_FRAMEBUFFER_SAMPLES 0x9318 +#define GL_UNIFORM 0x92E1 +#define GL_UNIFORM_BLOCK 0x92E2 +#define GL_PROGRAM_INPUT 0x92E3 +#define GL_PROGRAM_OUTPUT 0x92E4 +#define GL_BUFFER_VARIABLE 0x92E5 +#define GL_SHADER_STORAGE_BLOCK 0x92E6 +#define GL_ATOMIC_COUNTER_BUFFER 0x92C0 +#define GL_TRANSFORM_FEEDBACK_VARYING 0x92F4 +#define GL_ACTIVE_RESOURCES 0x92F5 +#define GL_MAX_NAME_LENGTH 0x92F6 +#define GL_MAX_NUM_ACTIVE_VARIABLES 0x92F7 +#define GL_NAME_LENGTH 0x92F9 +#define GL_TYPE 0x92FA +#define GL_ARRAY_SIZE 0x92FB +#define GL_OFFSET 0x92FC +#define GL_BLOCK_INDEX 0x92FD +#define GL_ARRAY_STRIDE 0x92FE +#define GL_MATRIX_STRIDE 0x92FF +#define GL_IS_ROW_MAJOR 0x9300 +#define GL_ATOMIC_COUNTER_BUFFER_INDEX 0x9301 +#define GL_BUFFER_BINDING 0x9302 +#define GL_BUFFER_DATA_SIZE 0x9303 +#define GL_NUM_ACTIVE_VARIABLES 0x9304 +#define GL_ACTIVE_VARIABLES 0x9305 +#define GL_REFERENCED_BY_VERTEX_SHADER 0x9306 +#define GL_REFERENCED_BY_FRAGMENT_SHADER 0x930A +#define GL_REFERENCED_BY_COMPUTE_SHADER 0x930B +#define GL_TOP_LEVEL_ARRAY_SIZE 0x930C +#define GL_TOP_LEVEL_ARRAY_STRIDE 0x930D +#define GL_LOCATION 0x930E +#define GL_VERTEX_SHADER_BIT 0x00000001 +#define GL_FRAGMENT_SHADER_BIT 0x00000002 +#define GL_ALL_SHADER_BITS 0xFFFFFFFF +#define GL_PROGRAM_SEPARABLE 0x8258 +#define GL_ACTIVE_PROGRAM 0x8259 +#define GL_PROGRAM_PIPELINE_BINDING 0x825A +#define GL_ATOMIC_COUNTER_BUFFER_BINDING 0x92C1 +#define GL_ATOMIC_COUNTER_BUFFER_START 0x92C2 +#define GL_ATOMIC_COUNTER_BUFFER_SIZE 0x92C3 +#define GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS 0x92CC +#define GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS 0x92D0 +#define GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS 0x92D1 +#define GL_MAX_VERTEX_ATOMIC_COUNTERS 0x92D2 +#define GL_MAX_FRAGMENT_ATOMIC_COUNTERS 0x92D6 +#define GL_MAX_COMBINED_ATOMIC_COUNTERS 0x92D7 +#define GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE 0x92D8 +#define GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS 0x92DC +#define GL_ACTIVE_ATOMIC_COUNTER_BUFFERS 0x92D9 +#define GL_UNSIGNED_INT_ATOMIC_COUNTER 0x92DB +#define GL_MAX_IMAGE_UNITS 0x8F38 +#define GL_MAX_VERTEX_IMAGE_UNIFORMS 0x90CA +#define GL_MAX_FRAGMENT_IMAGE_UNIFORMS 0x90CE +#define GL_MAX_COMBINED_IMAGE_UNIFORMS 0x90CF +#define GL_IMAGE_BINDING_NAME 0x8F3A +#define GL_IMAGE_BINDING_LEVEL 0x8F3B +#define GL_IMAGE_BINDING_LAYERED 0x8F3C +#define GL_IMAGE_BINDING_LAYER 0x8F3D +#define GL_IMAGE_BINDING_ACCESS 0x8F3E +#define GL_IMAGE_BINDING_FORMAT 0x906E +#define GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT 0x00000001 +#define GL_ELEMENT_ARRAY_BARRIER_BIT 0x00000002 +#define GL_UNIFORM_BARRIER_BIT 0x00000004 +#define GL_TEXTURE_FETCH_BARRIER_BIT 0x00000008 +#define GL_SHADER_IMAGE_ACCESS_BARRIER_BIT 0x00000020 +#define GL_COMMAND_BARRIER_BIT 0x00000040 +#define GL_PIXEL_BUFFER_BARRIER_BIT 0x00000080 +#define GL_TEXTURE_UPDATE_BARRIER_BIT 0x00000100 +#define GL_BUFFER_UPDATE_BARRIER_BIT 0x00000200 +#define GL_FRAMEBUFFER_BARRIER_BIT 0x00000400 +#define GL_TRANSFORM_FEEDBACK_BARRIER_BIT 0x00000800 +#define GL_ATOMIC_COUNTER_BARRIER_BIT 0x00001000 +#define GL_ALL_BARRIER_BITS 0xFFFFFFFF +#define GL_IMAGE_2D 0x904D +#define GL_IMAGE_3D 0x904E +#define GL_IMAGE_CUBE 0x9050 +#define GL_IMAGE_2D_ARRAY 0x9053 +#define GL_INT_IMAGE_2D 0x9058 +#define GL_INT_IMAGE_3D 0x9059 +#define GL_INT_IMAGE_CUBE 0x905B +#define GL_INT_IMAGE_2D_ARRAY 0x905E +#define GL_UNSIGNED_INT_IMAGE_2D 0x9063 +#define GL_UNSIGNED_INT_IMAGE_3D 0x9064 +#define GL_UNSIGNED_INT_IMAGE_CUBE 0x9066 +#define GL_UNSIGNED_INT_IMAGE_2D_ARRAY 0x9069 +#define GL_IMAGE_FORMAT_COMPATIBILITY_TYPE 0x90C7 +#define GL_IMAGE_FORMAT_COMPATIBILITY_BY_SIZE 0x90C8 +#define GL_IMAGE_FORMAT_COMPATIBILITY_BY_CLASS 0x90C9 +#define GL_READ_ONLY 0x88B8 +#define GL_WRITE_ONLY 0x88B9 +#define GL_READ_WRITE 0x88BA +#define GL_SHADER_STORAGE_BUFFER 0x90D2 +#define GL_SHADER_STORAGE_BUFFER_BINDING 0x90D3 +#define GL_SHADER_STORAGE_BUFFER_START 0x90D4 +#define GL_SHADER_STORAGE_BUFFER_SIZE 0x90D5 +#define GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS 0x90D6 +#define GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS 0x90DA +#define GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS 0x90DB +#define GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS 0x90DC +#define GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS 0x90DD +#define GL_MAX_SHADER_STORAGE_BLOCK_SIZE 0x90DE +#define GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT 0x90DF +#define GL_SHADER_STORAGE_BARRIER_BIT 0x00002000 +#define GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES 0x8F39 +#define GL_DEPTH_STENCIL_TEXTURE_MODE 0x90EA +#define GL_STENCIL_INDEX 0x1901 +#define GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET 0x8E5E +#define GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET 0x8E5F +#define GL_SAMPLE_POSITION 0x8E50 +#define GL_SAMPLE_MASK 0x8E51 +#define GL_SAMPLE_MASK_VALUE 0x8E52 +#define GL_TEXTURE_2D_MULTISAMPLE 0x9100 +#define GL_MAX_SAMPLE_MASK_WORDS 0x8E59 +#define GL_MAX_COLOR_TEXTURE_SAMPLES 0x910E +#define GL_MAX_DEPTH_TEXTURE_SAMPLES 0x910F +#define GL_MAX_INTEGER_SAMPLES 0x9110 +#define GL_TEXTURE_BINDING_2D_MULTISAMPLE 0x9104 +#define GL_TEXTURE_SAMPLES 0x9106 +#define GL_TEXTURE_FIXED_SAMPLE_LOCATIONS 0x9107 +#define GL_TEXTURE_WIDTH 0x1000 +#define GL_TEXTURE_HEIGHT 0x1001 +#define GL_TEXTURE_DEPTH 0x8071 +#define GL_TEXTURE_INTERNAL_FORMAT 0x1003 +#define GL_TEXTURE_RED_SIZE 0x805C +#define GL_TEXTURE_GREEN_SIZE 0x805D +#define GL_TEXTURE_BLUE_SIZE 0x805E +#define GL_TEXTURE_ALPHA_SIZE 0x805F +#define GL_TEXTURE_DEPTH_SIZE 0x884A +#define GL_TEXTURE_STENCIL_SIZE 0x88F1 +#define GL_TEXTURE_SHARED_SIZE 0x8C3F +#define GL_TEXTURE_RED_TYPE 0x8C10 +#define GL_TEXTURE_GREEN_TYPE 0x8C11 +#define GL_TEXTURE_BLUE_TYPE 0x8C12 +#define GL_TEXTURE_ALPHA_TYPE 0x8C13 +#define GL_TEXTURE_DEPTH_TYPE 0x8C16 +#define GL_TEXTURE_COMPRESSED 0x86A1 +#define GL_SAMPLER_2D_MULTISAMPLE 0x9108 +#define GL_INT_SAMPLER_2D_MULTISAMPLE 0x9109 +#define GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE 0x910A +#define GL_VERTEX_ATTRIB_BINDING 0x82D4 +#define GL_VERTEX_ATTRIB_RELATIVE_OFFSET 0x82D5 +#define GL_VERTEX_BINDING_DIVISOR 0x82D6 +#define GL_VERTEX_BINDING_OFFSET 0x82D7 +#define GL_VERTEX_BINDING_STRIDE 0x82D8 +#define GL_VERTEX_BINDING_BUFFER 0x8F4F +#define GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET 0x82D9 +#define GL_MAX_VERTEX_ATTRIB_BINDINGS 0x82DA +#define GL_MAX_VERTEX_ATTRIB_STRIDE 0x82E5 +typedef void (GL_APIENTRYP PFNGLDISPATCHCOMPUTEPROC) (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z); +typedef void (GL_APIENTRYP PFNGLDISPATCHCOMPUTEINDIRECTPROC) (GLintptr indirect); +typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINDIRECTPROC) (GLenum mode, const void *indirect); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINDIRECTPROC) (GLenum mode, GLenum type, const void *indirect); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERPARAMETERIPROC) (GLenum target, GLenum pname, GLint param); +typedef void (GL_APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMINTERFACEIVPROC) (GLuint program, GLenum programInterface, GLenum pname, GLint *params); +typedef GLuint (GL_APIENTRYP PFNGLGETPROGRAMRESOURCEINDEXPROC) (GLuint program, GLenum programInterface, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMRESOURCENAMEPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMRESOURCEIVPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params); +typedef GLint (GL_APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONPROC) (GLuint program, GLenum programInterface, const GLchar *name); +typedef void (GL_APIENTRYP PFNGLUSEPROGRAMSTAGESPROC) (GLuint pipeline, GLbitfield stages, GLuint program); +typedef void (GL_APIENTRYP PFNGLACTIVESHADERPROGRAMPROC) (GLuint pipeline, GLuint program); +typedef GLuint (GL_APIENTRYP PFNGLCREATESHADERPROGRAMVPROC) (GLenum type, GLsizei count, const GLchar *const*strings); +typedef void (GL_APIENTRYP PFNGLBINDPROGRAMPIPELINEPROC) (GLuint pipeline); +typedef void (GL_APIENTRYP PFNGLDELETEPROGRAMPIPELINESPROC) (GLsizei n, const GLuint *pipelines); +typedef void (GL_APIENTRYP PFNGLGENPROGRAMPIPELINESPROC) (GLsizei n, GLuint *pipelines); +typedef GLboolean (GL_APIENTRYP PFNGLISPROGRAMPIPELINEPROC) (GLuint pipeline); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMPIPELINEIVPROC) (GLuint pipeline, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1IPROC) (GLuint program, GLint location, GLint v0); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2IPROC) (GLuint program, GLint location, GLint v0, GLint v1); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3IPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4IPROC) (GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UIPROC) (GLuint program, GLint location, GLuint v0); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UIPROC) (GLuint program, GLint location, GLuint v0, GLuint v1); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UIPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UIPROC) (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1FPROC) (GLuint program, GLint location, GLfloat v0); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2FPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3FPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4FPROC) (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1IVPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2IVPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3IVPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4IVPROC) (GLuint program, GLint location, GLsizei count, const GLint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1UIVPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2UIVPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3UIVPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4UIVPROC) (GLuint program, GLint location, GLsizei count, const GLuint *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM1FVPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM2FVPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM3FVPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORM4FVPROC) (GLuint program, GLint location, GLsizei count, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X3FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X2FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX2X4FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X2FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX3X4FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLPROGRAMUNIFORMMATRIX4X3FVPROC) (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +typedef void (GL_APIENTRYP PFNGLVALIDATEPROGRAMPIPELINEPROC) (GLuint pipeline); +typedef void (GL_APIENTRYP PFNGLGETPROGRAMPIPELINEINFOLOGPROC) (GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +typedef void (GL_APIENTRYP PFNGLBINDIMAGETEXTUREPROC) (GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format); +typedef void (GL_APIENTRYP PFNGLGETBOOLEANI_VPROC) (GLenum target, GLuint index, GLboolean *data); +typedef void (GL_APIENTRYP PFNGLMEMORYBARRIERPROC) (GLbitfield barriers); +typedef void (GL_APIENTRYP PFNGLMEMORYBARRIERBYREGIONPROC) (GLbitfield barriers); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE2DMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +typedef void (GL_APIENTRYP PFNGLGETMULTISAMPLEFVPROC) (GLenum pname, GLuint index, GLfloat *val); +typedef void (GL_APIENTRYP PFNGLSAMPLEMASKIPROC) (GLuint maskNumber, GLbitfield mask); +typedef void (GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERIVPROC) (GLenum target, GLint level, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXLEVELPARAMETERFVPROC) (GLenum target, GLint level, GLenum pname, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLBINDVERTEXBUFFERPROC) (GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBIFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBBINDINGPROC) (GLuint attribindex, GLuint bindingindex); +typedef void (GL_APIENTRYP PFNGLVERTEXBINDINGDIVISORPROC) (GLuint bindingindex, GLuint divisor); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glDispatchCompute (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z); +GL_APICALL void GL_APIENTRY glDispatchComputeIndirect (GLintptr indirect); +GL_APICALL void GL_APIENTRY glDrawArraysIndirect (GLenum mode, const void *indirect); +GL_APICALL void GL_APIENTRY glDrawElementsIndirect (GLenum mode, GLenum type, const void *indirect); +GL_APICALL void GL_APIENTRY glFramebufferParameteri (GLenum target, GLenum pname, GLint param); +GL_APICALL void GL_APIENTRY glGetFramebufferParameteriv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetProgramInterfaceiv (GLuint program, GLenum programInterface, GLenum pname, GLint *params); +GL_APICALL GLuint GL_APIENTRY glGetProgramResourceIndex (GLuint program, GLenum programInterface, const GLchar *name); +GL_APICALL void GL_APIENTRY glGetProgramResourceName (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name); +GL_APICALL void GL_APIENTRY glGetProgramResourceiv (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params); +GL_APICALL GLint GL_APIENTRY glGetProgramResourceLocation (GLuint program, GLenum programInterface, const GLchar *name); +GL_APICALL void GL_APIENTRY glUseProgramStages (GLuint pipeline, GLbitfield stages, GLuint program); +GL_APICALL void GL_APIENTRY glActiveShaderProgram (GLuint pipeline, GLuint program); +GL_APICALL GLuint GL_APIENTRY glCreateShaderProgramv (GLenum type, GLsizei count, const GLchar *const*strings); +GL_APICALL void GL_APIENTRY glBindProgramPipeline (GLuint pipeline); +GL_APICALL void GL_APIENTRY glDeleteProgramPipelines (GLsizei n, const GLuint *pipelines); +GL_APICALL void GL_APIENTRY glGenProgramPipelines (GLsizei n, GLuint *pipelines); +GL_APICALL GLboolean GL_APIENTRY glIsProgramPipeline (GLuint pipeline); +GL_APICALL void GL_APIENTRY glGetProgramPipelineiv (GLuint pipeline, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glProgramUniform1i (GLuint program, GLint location, GLint v0); +GL_APICALL void GL_APIENTRY glProgramUniform2i (GLuint program, GLint location, GLint v0, GLint v1); +GL_APICALL void GL_APIENTRY glProgramUniform3i (GLuint program, GLint location, GLint v0, GLint v1, GLint v2); +GL_APICALL void GL_APIENTRY glProgramUniform4i (GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3); +GL_APICALL void GL_APIENTRY glProgramUniform1ui (GLuint program, GLint location, GLuint v0); +GL_APICALL void GL_APIENTRY glProgramUniform2ui (GLuint program, GLint location, GLuint v0, GLuint v1); +GL_APICALL void GL_APIENTRY glProgramUniform3ui (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2); +GL_APICALL void GL_APIENTRY glProgramUniform4ui (GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3); +GL_APICALL void GL_APIENTRY glProgramUniform1f (GLuint program, GLint location, GLfloat v0); +GL_APICALL void GL_APIENTRY glProgramUniform2f (GLuint program, GLint location, GLfloat v0, GLfloat v1); +GL_APICALL void GL_APIENTRY glProgramUniform3f (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2); +GL_APICALL void GL_APIENTRY glProgramUniform4f (GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); +GL_APICALL void GL_APIENTRY glProgramUniform1iv (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform2iv (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform3iv (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform4iv (GLuint program, GLint location, GLsizei count, const GLint *value); +GL_APICALL void GL_APIENTRY glProgramUniform1uiv (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform2uiv (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform3uiv (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform4uiv (GLuint program, GLint location, GLsizei count, const GLuint *value); +GL_APICALL void GL_APIENTRY glProgramUniform1fv (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform2fv (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform3fv (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniform4fv (GLuint program, GLint location, GLsizei count, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix2fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix3fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix4fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix2x3fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix3x2fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix2x4fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix4x2fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix3x4fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glProgramUniformMatrix4x3fv (GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); +GL_APICALL void GL_APIENTRY glValidateProgramPipeline (GLuint pipeline); +GL_APICALL void GL_APIENTRY glGetProgramPipelineInfoLog (GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog); +GL_APICALL void GL_APIENTRY glBindImageTexture (GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format); +GL_APICALL void GL_APIENTRY glGetBooleani_v (GLenum target, GLuint index, GLboolean *data); +GL_APICALL void GL_APIENTRY glMemoryBarrier (GLbitfield barriers); +GL_APICALL void GL_APIENTRY glMemoryBarrierByRegion (GLbitfield barriers); +GL_APICALL void GL_APIENTRY glTexStorage2DMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +GL_APICALL void GL_APIENTRY glGetMultisamplefv (GLenum pname, GLuint index, GLfloat *val); +GL_APICALL void GL_APIENTRY glSampleMaski (GLuint maskNumber, GLbitfield mask); +GL_APICALL void GL_APIENTRY glGetTexLevelParameteriv (GLenum target, GLint level, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetTexLevelParameterfv (GLenum target, GLint level, GLenum pname, GLfloat *params); +GL_APICALL void GL_APIENTRY glBindVertexBuffer (GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride); +GL_APICALL void GL_APIENTRY glVertexAttribFormat (GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset); +GL_APICALL void GL_APIENTRY glVertexAttribIFormat (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +GL_APICALL void GL_APIENTRY glVertexAttribBinding (GLuint attribindex, GLuint bindingindex); +GL_APICALL void GL_APIENTRY glVertexBindingDivisor (GLuint bindingindex, GLuint divisor); +#endif +#endif /* GL_ES_VERSION_3_1 */ + +#ifndef GL_ES_VERSION_3_2 +#define GL_ES_VERSION_3_2 1 +typedef void (GL_APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam); +#define GL_MULTISAMPLE_LINE_WIDTH_RANGE 0x9381 +#define GL_MULTISAMPLE_LINE_WIDTH_GRANULARITY 0x9382 +#define GL_MULTIPLY 0x9294 +#define GL_SCREEN 0x9295 +#define GL_OVERLAY 0x9296 +#define GL_DARKEN 0x9297 +#define GL_LIGHTEN 0x9298 +#define GL_COLORDODGE 0x9299 +#define GL_COLORBURN 0x929A +#define GL_HARDLIGHT 0x929B +#define GL_SOFTLIGHT 0x929C +#define GL_DIFFERENCE 0x929E +#define GL_EXCLUSION 0x92A0 +#define GL_HSL_HUE 0x92AD +#define GL_HSL_SATURATION 0x92AE +#define GL_HSL_COLOR 0x92AF +#define GL_HSL_LUMINOSITY 0x92B0 +#define GL_DEBUG_OUTPUT_SYNCHRONOUS 0x8242 +#define GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH 0x8243 +#define GL_DEBUG_CALLBACK_FUNCTION 0x8244 +#define GL_DEBUG_CALLBACK_USER_PARAM 0x8245 +#define GL_DEBUG_SOURCE_API 0x8246 +#define GL_DEBUG_SOURCE_WINDOW_SYSTEM 0x8247 +#define GL_DEBUG_SOURCE_SHADER_COMPILER 0x8248 +#define GL_DEBUG_SOURCE_THIRD_PARTY 0x8249 +#define GL_DEBUG_SOURCE_APPLICATION 0x824A +#define GL_DEBUG_SOURCE_OTHER 0x824B +#define GL_DEBUG_TYPE_ERROR 0x824C +#define GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR 0x824D +#define GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR 0x824E +#define GL_DEBUG_TYPE_PORTABILITY 0x824F +#define GL_DEBUG_TYPE_PERFORMANCE 0x8250 +#define GL_DEBUG_TYPE_OTHER 0x8251 +#define GL_DEBUG_TYPE_MARKER 0x8268 +#define GL_DEBUG_TYPE_PUSH_GROUP 0x8269 +#define GL_DEBUG_TYPE_POP_GROUP 0x826A +#define GL_DEBUG_SEVERITY_NOTIFICATION 0x826B +#define GL_MAX_DEBUG_GROUP_STACK_DEPTH 0x826C +#define GL_DEBUG_GROUP_STACK_DEPTH 0x826D +#define GL_BUFFER 0x82E0 +#define GL_SHADER 0x82E1 +#define GL_PROGRAM 0x82E2 +#define GL_VERTEX_ARRAY 0x8074 +#define GL_QUERY 0x82E3 +#define GL_PROGRAM_PIPELINE 0x82E4 +#define GL_SAMPLER 0x82E6 +#define GL_MAX_LABEL_LENGTH 0x82E8 +#define GL_MAX_DEBUG_MESSAGE_LENGTH 0x9143 +#define GL_MAX_DEBUG_LOGGED_MESSAGES 0x9144 +#define GL_DEBUG_LOGGED_MESSAGES 0x9145 +#define GL_DEBUG_SEVERITY_HIGH 0x9146 +#define GL_DEBUG_SEVERITY_MEDIUM 0x9147 +#define GL_DEBUG_SEVERITY_LOW 0x9148 +#define GL_DEBUG_OUTPUT 0x92E0 +#define GL_CONTEXT_FLAG_DEBUG_BIT 0x00000002 +#define GL_STACK_OVERFLOW 0x0503 +#define GL_STACK_UNDERFLOW 0x0504 +#define GL_GEOMETRY_SHADER 0x8DD9 +#define GL_GEOMETRY_SHADER_BIT 0x00000004 +#define GL_GEOMETRY_VERTICES_OUT 0x8916 +#define GL_GEOMETRY_INPUT_TYPE 0x8917 +#define GL_GEOMETRY_OUTPUT_TYPE 0x8918 +#define GL_GEOMETRY_SHADER_INVOCATIONS 0x887F +#define GL_LAYER_PROVOKING_VERTEX 0x825E +#define GL_LINES_ADJACENCY 0x000A +#define GL_LINE_STRIP_ADJACENCY 0x000B +#define GL_TRIANGLES_ADJACENCY 0x000C +#define GL_TRIANGLE_STRIP_ADJACENCY 0x000D +#define GL_MAX_GEOMETRY_UNIFORM_COMPONENTS 0x8DDF +#define GL_MAX_GEOMETRY_UNIFORM_BLOCKS 0x8A2C +#define GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS 0x8A32 +#define GL_MAX_GEOMETRY_INPUT_COMPONENTS 0x9123 +#define GL_MAX_GEOMETRY_OUTPUT_COMPONENTS 0x9124 +#define GL_MAX_GEOMETRY_OUTPUT_VERTICES 0x8DE0 +#define GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS 0x8DE1 +#define GL_MAX_GEOMETRY_SHADER_INVOCATIONS 0x8E5A +#define GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS 0x8C29 +#define GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS 0x92CF +#define GL_MAX_GEOMETRY_ATOMIC_COUNTERS 0x92D5 +#define GL_MAX_GEOMETRY_IMAGE_UNIFORMS 0x90CD +#define GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS 0x90D7 +#define GL_FIRST_VERTEX_CONVENTION 0x8E4D +#define GL_LAST_VERTEX_CONVENTION 0x8E4E +#define GL_UNDEFINED_VERTEX 0x8260 +#define GL_PRIMITIVES_GENERATED 0x8C87 +#define GL_FRAMEBUFFER_DEFAULT_LAYERS 0x9312 +#define GL_MAX_FRAMEBUFFER_LAYERS 0x9317 +#define GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS 0x8DA8 +#define GL_FRAMEBUFFER_ATTACHMENT_LAYERED 0x8DA7 +#define GL_REFERENCED_BY_GEOMETRY_SHADER 0x9309 +#define GL_PRIMITIVE_BOUNDING_BOX 0x92BE +#define GL_CONTEXT_FLAG_ROBUST_ACCESS_BIT 0x00000004 +#define GL_CONTEXT_FLAGS 0x821E +#define GL_LOSE_CONTEXT_ON_RESET 0x8252 +#define GL_GUILTY_CONTEXT_RESET 0x8253 +#define GL_INNOCENT_CONTEXT_RESET 0x8254 +#define GL_UNKNOWN_CONTEXT_RESET 0x8255 +#define GL_RESET_NOTIFICATION_STRATEGY 0x8256 +#define GL_NO_RESET_NOTIFICATION 0x8261 +#define GL_CONTEXT_LOST 0x0507 +#define GL_SAMPLE_SHADING 0x8C36 +#define GL_MIN_SAMPLE_SHADING_VALUE 0x8C37 +#define GL_MIN_FRAGMENT_INTERPOLATION_OFFSET 0x8E5B +#define GL_MAX_FRAGMENT_INTERPOLATION_OFFSET 0x8E5C +#define GL_FRAGMENT_INTERPOLATION_OFFSET_BITS 0x8E5D +#define GL_PATCHES 0x000E +#define GL_PATCH_VERTICES 0x8E72 +#define GL_TESS_CONTROL_OUTPUT_VERTICES 0x8E75 +#define GL_TESS_GEN_MODE 0x8E76 +#define GL_TESS_GEN_SPACING 0x8E77 +#define GL_TESS_GEN_VERTEX_ORDER 0x8E78 +#define GL_TESS_GEN_POINT_MODE 0x8E79 +#define GL_ISOLINES 0x8E7A +#define GL_QUADS 0x0007 +#define GL_FRACTIONAL_ODD 0x8E7B +#define GL_FRACTIONAL_EVEN 0x8E7C +#define GL_MAX_PATCH_VERTICES 0x8E7D +#define GL_MAX_TESS_GEN_LEVEL 0x8E7E +#define GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS 0x8E7F +#define GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS 0x8E80 +#define GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS 0x8E81 +#define GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS 0x8E82 +#define GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS 0x8E83 +#define GL_MAX_TESS_PATCH_COMPONENTS 0x8E84 +#define GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS 0x8E85 +#define GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS 0x8E86 +#define GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS 0x8E89 +#define GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS 0x8E8A +#define GL_MAX_TESS_CONTROL_INPUT_COMPONENTS 0x886C +#define GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS 0x886D +#define GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS 0x8E1E +#define GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS 0x8E1F +#define GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS 0x92CD +#define GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS 0x92CE +#define GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS 0x92D3 +#define GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS 0x92D4 +#define GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS 0x90CB +#define GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS 0x90CC +#define GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS 0x90D8 +#define GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS 0x90D9 +#define GL_PRIMITIVE_RESTART_FOR_PATCHES_SUPPORTED 0x8221 +#define GL_IS_PER_PATCH 0x92E7 +#define GL_REFERENCED_BY_TESS_CONTROL_SHADER 0x9307 +#define GL_REFERENCED_BY_TESS_EVALUATION_SHADER 0x9308 +#define GL_TESS_CONTROL_SHADER 0x8E88 +#define GL_TESS_EVALUATION_SHADER 0x8E87 +#define GL_TESS_CONTROL_SHADER_BIT 0x00000008 +#define GL_TESS_EVALUATION_SHADER_BIT 0x00000010 +#define GL_TEXTURE_BORDER_COLOR 0x1004 +#define GL_CLAMP_TO_BORDER 0x812D +#define GL_TEXTURE_BUFFER 0x8C2A +#define GL_TEXTURE_BUFFER_BINDING 0x8C2A +#define GL_MAX_TEXTURE_BUFFER_SIZE 0x8C2B +#define GL_TEXTURE_BINDING_BUFFER 0x8C2C +#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING 0x8C2D +#define GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT 0x919F +#define GL_SAMPLER_BUFFER 0x8DC2 +#define GL_INT_SAMPLER_BUFFER 0x8DD0 +#define GL_UNSIGNED_INT_SAMPLER_BUFFER 0x8DD8 +#define GL_IMAGE_BUFFER 0x9051 +#define GL_INT_IMAGE_BUFFER 0x905C +#define GL_UNSIGNED_INT_IMAGE_BUFFER 0x9067 +#define GL_TEXTURE_BUFFER_OFFSET 0x919D +#define GL_TEXTURE_BUFFER_SIZE 0x919E +#define GL_COMPRESSED_RGBA_ASTC_4x4 0x93B0 +#define GL_COMPRESSED_RGBA_ASTC_5x4 0x93B1 +#define GL_COMPRESSED_RGBA_ASTC_5x5 0x93B2 +#define GL_COMPRESSED_RGBA_ASTC_6x5 0x93B3 +#define GL_COMPRESSED_RGBA_ASTC_6x6 0x93B4 +#define GL_COMPRESSED_RGBA_ASTC_8x5 0x93B5 +#define GL_COMPRESSED_RGBA_ASTC_8x6 0x93B6 +#define GL_COMPRESSED_RGBA_ASTC_8x8 0x93B7 +#define GL_COMPRESSED_RGBA_ASTC_10x5 0x93B8 +#define GL_COMPRESSED_RGBA_ASTC_10x6 0x93B9 +#define GL_COMPRESSED_RGBA_ASTC_10x8 0x93BA +#define GL_COMPRESSED_RGBA_ASTC_10x10 0x93BB +#define GL_COMPRESSED_RGBA_ASTC_12x10 0x93BC +#define GL_COMPRESSED_RGBA_ASTC_12x12 0x93BD +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4 0x93D0 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4 0x93D1 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5 0x93D2 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5 0x93D3 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6 0x93D4 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5 0x93D5 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6 0x93D6 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8 0x93D7 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5 0x93D8 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6 0x93D9 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8 0x93DA +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10 0x93DB +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10 0x93DC +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12 0x93DD +#define GL_TEXTURE_CUBE_MAP_ARRAY 0x9009 +#define GL_TEXTURE_BINDING_CUBE_MAP_ARRAY 0x900A +#define GL_SAMPLER_CUBE_MAP_ARRAY 0x900C +#define GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW 0x900D +#define GL_INT_SAMPLER_CUBE_MAP_ARRAY 0x900E +#define GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY 0x900F +#define GL_IMAGE_CUBE_MAP_ARRAY 0x9054 +#define GL_INT_IMAGE_CUBE_MAP_ARRAY 0x905F +#define GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY 0x906A +#define GL_TEXTURE_2D_MULTISAMPLE_ARRAY 0x9102 +#define GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY 0x9105 +#define GL_SAMPLER_2D_MULTISAMPLE_ARRAY 0x910B +#define GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY 0x910C +#define GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY 0x910D +typedef void (GL_APIENTRYP PFNGLBLENDBARRIERPROC) (void); +typedef void (GL_APIENTRYP PFNGLCOPYIMAGESUBDATAPROC) (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth); +typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGECONTROLPROC) (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled); +typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGEINSERTPROC) (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf); +typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGECALLBACKPROC) (GLDEBUGPROC callback, const void *userParam); +typedef GLuint (GL_APIENTRYP PFNGLGETDEBUGMESSAGELOGPROC) (GLuint count, GLsizei bufSize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog); +typedef void (GL_APIENTRYP PFNGLPUSHDEBUGGROUPPROC) (GLenum source, GLuint id, GLsizei length, const GLchar *message); +typedef void (GL_APIENTRYP PFNGLPOPDEBUGGROUPPROC) (void); +typedef void (GL_APIENTRYP PFNGLOBJECTLABELPROC) (GLenum identifier, GLuint name, GLsizei length, const GLchar *label); +typedef void (GL_APIENTRYP PFNGLGETOBJECTLABELPROC) (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label); +typedef void (GL_APIENTRYP PFNGLOBJECTPTRLABELPROC) (const void *ptr, GLsizei length, const GLchar *label); +typedef void (GL_APIENTRYP PFNGLGETOBJECTPTRLABELPROC) (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label); +typedef void (GL_APIENTRYP PFNGLGETPOINTERVPROC) (GLenum pname, void **params); +typedef void (GL_APIENTRYP PFNGLENABLEIPROC) (GLenum target, GLuint index); +typedef void (GL_APIENTRYP PFNGLDISABLEIPROC) (GLenum target, GLuint index); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONIPROC) (GLuint buf, GLenum mode); +typedef void (GL_APIENTRYP PFNGLBLENDEQUATIONSEPARATEIPROC) (GLuint buf, GLenum modeRGB, GLenum modeAlpha); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCIPROC) (GLuint buf, GLenum src, GLenum dst); +typedef void (GL_APIENTRYP PFNGLBLENDFUNCSEPARATEIPROC) (GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha); +typedef void (GL_APIENTRYP PFNGLCOLORMASKIPROC) (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); +typedef GLboolean (GL_APIENTRYP PFNGLISENABLEDIPROC) (GLenum target, GLuint index); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSBASEVERTEXPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLint basevertex); +typedef void (GL_APIENTRYP PFNGLDRAWRANGEELEMENTSBASEVERTEXPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices, GLint basevertex); +typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTUREPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level); +typedef void (GL_APIENTRYP PFNGLPRIMITIVEBOUNDINGBOXPROC) (GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW); +typedef GLenum (GL_APIENTRYP PFNGLGETGRAPHICSRESETSTATUSPROC) (void); +typedef void (GL_APIENTRYP PFNGLREADNPIXELSPROC) (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMFVPROC) (GLuint program, GLint location, GLsizei bufSize, GLfloat *params); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMIVPROC) (GLuint program, GLint location, GLsizei bufSize, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETNUNIFORMUIVPROC) (GLuint program, GLint location, GLsizei bufSize, GLuint *params); +typedef void (GL_APIENTRYP PFNGLMINSAMPLESHADINGPROC) (GLfloat value); +typedef void (GL_APIENTRYP PFNGLPATCHPARAMETERIPROC) (GLenum pname, GLint value); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIIVPROC) (GLenum target, GLenum pname, const GLint *params); +typedef void (GL_APIENTRYP PFNGLTEXPARAMETERIUIVPROC) (GLenum target, GLenum pname, const GLuint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETTEXPARAMETERIUIVPROC) (GLenum target, GLenum pname, GLuint *params); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIIVPROC) (GLuint sampler, GLenum pname, const GLint *param); +typedef void (GL_APIENTRYP PFNGLSAMPLERPARAMETERIUIVPROC) (GLuint sampler, GLenum pname, const GLuint *param); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIIVPROC) (GLuint sampler, GLenum pname, GLint *params); +typedef void (GL_APIENTRYP PFNGLGETSAMPLERPARAMETERIUIVPROC) (GLuint sampler, GLenum pname, GLuint *params); +typedef void (GL_APIENTRYP PFNGLTEXBUFFERPROC) (GLenum target, GLenum internalformat, GLuint buffer); +typedef void (GL_APIENTRYP PFNGLTEXBUFFERRANGEPROC) (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +typedef void (GL_APIENTRYP PFNGLTEXSTORAGE3DMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations); +#if GL_GLES_PROTOTYPES +GL_APICALL void GL_APIENTRY glBlendBarrier (void); +GL_APICALL void GL_APIENTRY glCopyImageSubData (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth); +GL_APICALL void GL_APIENTRY glDebugMessageControl (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled); +GL_APICALL void GL_APIENTRY glDebugMessageInsert (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf); +GL_APICALL void GL_APIENTRY glDebugMessageCallback (GLDEBUGPROC callback, const void *userParam); +GL_APICALL GLuint GL_APIENTRY glGetDebugMessageLog (GLuint count, GLsizei bufSize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog); +GL_APICALL void GL_APIENTRY glPushDebugGroup (GLenum source, GLuint id, GLsizei length, const GLchar *message); +GL_APICALL void GL_APIENTRY glPopDebugGroup (void); +GL_APICALL void GL_APIENTRY glObjectLabel (GLenum identifier, GLuint name, GLsizei length, const GLchar *label); +GL_APICALL void GL_APIENTRY glGetObjectLabel (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label); +GL_APICALL void GL_APIENTRY glObjectPtrLabel (const void *ptr, GLsizei length, const GLchar *label); +GL_APICALL void GL_APIENTRY glGetObjectPtrLabel (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label); +GL_APICALL void GL_APIENTRY glGetPointerv (GLenum pname, void **params); +GL_APICALL void GL_APIENTRY glEnablei (GLenum target, GLuint index); +GL_APICALL void GL_APIENTRY glDisablei (GLenum target, GLuint index); +GL_APICALL void GL_APIENTRY glBlendEquationi (GLuint buf, GLenum mode); +GL_APICALL void GL_APIENTRY glBlendEquationSeparatei (GLuint buf, GLenum modeRGB, GLenum modeAlpha); +GL_APICALL void GL_APIENTRY glBlendFunci (GLuint buf, GLenum src, GLenum dst); +GL_APICALL void GL_APIENTRY glBlendFuncSeparatei (GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha); +GL_APICALL void GL_APIENTRY glColorMaski (GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a); +GL_APICALL GLboolean GL_APIENTRY glIsEnabledi (GLenum target, GLuint index); +GL_APICALL void GL_APIENTRY glDrawElementsBaseVertex (GLenum mode, GLsizei count, GLenum type, const void *indices, GLint basevertex); +GL_APICALL void GL_APIENTRY glDrawRangeElementsBaseVertex (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const void *indices, GLint basevertex); +GL_APICALL void GL_APIENTRY glDrawElementsInstancedBaseVertex (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex); +GL_APICALL void GL_APIENTRY glFramebufferTexture (GLenum target, GLenum attachment, GLuint texture, GLint level); +GL_APICALL void GL_APIENTRY glPrimitiveBoundingBox (GLfloat minX, GLfloat minY, GLfloat minZ, GLfloat minW, GLfloat maxX, GLfloat maxY, GLfloat maxZ, GLfloat maxW); +GL_APICALL GLenum GL_APIENTRY glGetGraphicsResetStatus (void); +GL_APICALL void GL_APIENTRY glReadnPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data); +GL_APICALL void GL_APIENTRY glGetnUniformfv (GLuint program, GLint location, GLsizei bufSize, GLfloat *params); +GL_APICALL void GL_APIENTRY glGetnUniformiv (GLuint program, GLint location, GLsizei bufSize, GLint *params); +GL_APICALL void GL_APIENTRY glGetnUniformuiv (GLuint program, GLint location, GLsizei bufSize, GLuint *params); +GL_APICALL void GL_APIENTRY glMinSampleShading (GLfloat value); +GL_APICALL void GL_APIENTRY glPatchParameteri (GLenum pname, GLint value); +GL_APICALL void GL_APIENTRY glTexParameterIiv (GLenum target, GLenum pname, const GLint *params); +GL_APICALL void GL_APIENTRY glTexParameterIuiv (GLenum target, GLenum pname, const GLuint *params); +GL_APICALL void GL_APIENTRY glGetTexParameterIiv (GLenum target, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetTexParameterIuiv (GLenum target, GLenum pname, GLuint *params); +GL_APICALL void GL_APIENTRY glSamplerParameterIiv (GLuint sampler, GLenum pname, const GLint *param); +GL_APICALL void GL_APIENTRY glSamplerParameterIuiv (GLuint sampler, GLenum pname, const GLuint *param); +GL_APICALL void GL_APIENTRY glGetSamplerParameterIiv (GLuint sampler, GLenum pname, GLint *params); +GL_APICALL void GL_APIENTRY glGetSamplerParameterIuiv (GLuint sampler, GLenum pname, GLuint *params); +GL_APICALL void GL_APIENTRY glTexBuffer (GLenum target, GLenum internalformat, GLuint buffer); +GL_APICALL void GL_APIENTRY glTexBufferRange (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +GL_APICALL void GL_APIENTRY glTexStorage3DMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations); +#endif +#endif /* GL_ES_VERSION_3_2 */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/GLES3/gl3platform.h b/gfx/angle/checkout/include/GLES3/gl3platform.h new file mode 100644 index 0000000000..8699212de6 --- /dev/null +++ b/gfx/angle/checkout/include/GLES3/gl3platform.h @@ -0,0 +1,27 @@ +#ifndef __gl3platform_h_ +#define __gl3platform_h_ + +/* +** Copyright 2017-2020 The Khronos Group Inc. +** SPDX-License-Identifier: Apache-2.0 +*/ + +/* Platform-specific types and definitions for OpenGL ES 3.X gl3.h + * + * Adopters may modify khrplatform.h and this file to suit their platform. + * Please contribute modifications back to Khronos as pull requests on the + * public github repository: + * https://github.com/KhronosGroup/OpenGL-Registry + */ + +#include + +#ifndef GL_APICALL +#define GL_APICALL KHRONOS_APICALL +#endif + +#ifndef GL_APIENTRY +#define GL_APIENTRY KHRONOS_APIENTRY +#endif + +#endif /* __gl3platform_h_ */ diff --git a/gfx/angle/checkout/include/GLSLANG/ShaderLang.h b/gfx/angle/checkout/include/GLSLANG/ShaderLang.h new file mode 100644 index 0000000000..d55e7ebce3 --- /dev/null +++ b/gfx/angle/checkout/include/GLSLANG/ShaderLang.h @@ -0,0 +1,1001 @@ +// +// Copyright 2002 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +#ifndef GLSLANG_SHADERLANG_H_ +#define GLSLANG_SHADERLANG_H_ + +#include + +#include "KHR/khrplatform.h" + +#include +#include +#include +#include +#include + +// +// This is the platform independent interface between an OGL driver +// and the shading language compiler. +// + +// Note: make sure to increment ANGLE_SH_VERSION when changing ShaderVars.h +#include "ShaderVars.h" + +// Version number for shader translation API. +// It is incremented every time the API changes. +#define ANGLE_SH_VERSION 308 + +enum ShShaderSpec +{ + SH_GLES2_SPEC, + SH_WEBGL_SPEC, + + SH_GLES3_SPEC, + SH_WEBGL2_SPEC, + + SH_GLES3_1_SPEC, + SH_WEBGL3_SPEC, + + SH_GLES3_2_SPEC, + + SH_GL_CORE_SPEC, + SH_GL_COMPATIBILITY_SPEC, +}; + +enum ShShaderOutput +{ + // ESSL output only supported in some configurations. + SH_ESSL_OUTPUT = 0x8B45, + + // GLSL output only supported in some configurations. + SH_GLSL_COMPATIBILITY_OUTPUT = 0x8B46, + // Note: GL introduced core profiles in 1.5. + SH_GLSL_130_OUTPUT = 0x8B47, + SH_GLSL_140_OUTPUT = 0x8B80, + SH_GLSL_150_CORE_OUTPUT = 0x8B81, + SH_GLSL_330_CORE_OUTPUT = 0x8B82, + SH_GLSL_400_CORE_OUTPUT = 0x8B83, + SH_GLSL_410_CORE_OUTPUT = 0x8B84, + SH_GLSL_420_CORE_OUTPUT = 0x8B85, + SH_GLSL_430_CORE_OUTPUT = 0x8B86, + SH_GLSL_440_CORE_OUTPUT = 0x8B87, + SH_GLSL_450_CORE_OUTPUT = 0x8B88, + + // Prefer using these to specify HLSL output type: + SH_HLSL_3_0_OUTPUT = 0x8B48, // D3D 9 + SH_HLSL_4_1_OUTPUT = 0x8B49, // D3D 11 + SH_HLSL_4_0_FL9_3_OUTPUT = 0x8B4A, // D3D 11 feature level 9_3 + + // Output SPIR-V for the Vulkan backend. + SH_SPIRV_VULKAN_OUTPUT = 0x8B4B, + + // Output SPIR-V to be cross compiled to Metal. + SH_SPIRV_METAL_OUTPUT = 0x8B4C, + + // Output for MSL + SH_MSL_METAL_OUTPUT = 0x8B4D, +}; + +// For ANGLE_shader_pixel_local_storage. +// Instructs the compiler which pixel local storage configuration to generate code for. +enum class ShPixelLocalStorageType +{ + NotSupported, + ImageStoreR32PackedFormats, + ImageStoreNativeFormats, + FramebufferFetch +}; + +// For ANGLE_shader_pixel_local_storage_coherent. +// Instructs the compiler which fragment synchronization method to use, if any. +enum class ShFragmentSynchronizationType +{ + NotSupported, // Fragments cannot be ordered or synchronized. + + Automatic, // Fragments are automatically raster-ordered and synchronized. + + FragmentShaderInterlock_NV_GL, + FragmentShaderOrdering_INTEL_GL, + FragmentShaderInterlock_ARB_GL, // Also compiles to SPV_EXT_fragment_shader_interlock. + + RasterizerOrderViews_D3D, + + RasterOrderGroups_Metal, + + InvalidEnum, + EnumCount = InvalidEnum, +}; + +// Compile options. +struct ShCompileOptionsMetal +{ + // Direct-to-metal backend constants: + + // Binding index for driver uniforms: + int driverUniformsBindingIndex; + // Binding index for default uniforms: + int defaultUniformsBindingIndex; + // Binding index for UBO's argument buffer + int UBOArgumentBufferBindingIndex; +}; + +struct ShCompileOptionsPLS +{ + ShPixelLocalStorageType type = ShPixelLocalStorageType::NotSupported; + // For ANGLE_shader_pixel_local_storage_coherent. + ShFragmentSynchronizationType fragmentSynchronizationType = + ShFragmentSynchronizationType::NotSupported; +}; + +struct ShCompileOptions +{ + ShCompileOptions(); + ShCompileOptions(const ShCompileOptions &other); + ShCompileOptions &operator=(const ShCompileOptions &other); + + // Translates intermediate tree to glsl, hlsl, msl, or SPIR-V binary. Can be queried by + // calling sh::GetObjectCode(). + uint64_t objectCode : 1; + + // Extracts attributes, uniforms, and varyings. Can be queried by calling ShGetVariableInfo(). + uint64_t variables : 1; + + // Tracks the source path for shaders. Can be queried with getSourcePath(). + uint64_t sourcePath : 1; + + // Whether the internal representation of the AST should be output. + uint64_t intermediateTree : 1; + + // If requested, validates the AST after every transformation. Useful for debugging. + uint64_t validateAST : 1; + + // Validates loop and indexing in the shader to ensure that they do not exceed the minimum + // functionality mandated in GLSL 1.0 spec, Appendix A, Section 4 and 5. There is no need to + // specify this parameter when compiling for WebGL - it is implied. + uint64_t validateLoopIndexing : 1; + + // Emits #line directives in HLSL. + uint64_t lineDirectives : 1; + + // Due to spec difference between GLSL 4.1 or lower and ESSL3, some platforms (for example, Mac + // OSX core profile) require a variable's "invariant"/"centroid" qualifiers to match between + // vertex and fragment shader. A simple solution to allow such shaders to link is to omit the + // two qualifiers. AMD driver in Linux requires invariant qualifier to match between vertex and + // fragment shaders, while ESSL3 disallows invariant qualifier in fragment shader and GLSL >= + // 4.2 doesn't require invariant qualifier to match between shaders. Remove invariant qualifier + // from vertex shader to workaround AMD driver bug. + // Note that the two flags take effect on ESSL3 input shaders translated to GLSL 4.1 or lower + // and to GLSL 4.2 or newer on Linux AMD. + // TODO(zmo): This is not a good long-term solution. Simply dropping these qualifiers may break + // some developers' content. A more complex workaround of dynamically generating, compiling, and + // re-linking shaders that use these qualifiers should be implemented. + uint64_t removeInvariantAndCentroidForESSL3 : 1; + + // This flag works around bug in Intel Mac drivers related to abs(i) where i is an integer. + uint64_t emulateAbsIntFunction : 1; + + // Enforce the GLSL 1.017 Appendix A section 7 packing restrictions. This flag only enforces + // (and can only enforce) the packing restrictions for uniform variables in both vertex and + // fragment shaders. ShCheckVariablesWithinPackingLimits() lets embedders enforce the packing + // restrictions for varying variables during program link time. + uint64_t enforcePackingRestrictions : 1; + + // This flag ensures all indirect (expression-based) array indexing is clamped to the bounds of + // the array. This ensures, for example, that you cannot read off the end of a uniform, whether + // an array vec234, or mat234 type. + uint64_t clampIndirectArrayBounds : 1; + + // This flag limits the complexity of an expression. + uint64_t limitExpressionComplexity : 1; + + // This flag limits the depth of the call stack. + uint64_t limitCallStackDepth : 1; + + // This flag initializes gl_Position to vec4(0,0,0,0) at the beginning of the vertex shader's + // main(), and has no effect in the fragment shader. It is intended as a workaround for drivers + // which incorrectly fail to link programs if gl_Position is not written. + uint64_t initGLPosition : 1; + + // This flag initializes gl_PointSize to 0.0f at the beginning of the vertex shader's + // main(), and has no effect in the fragment shader. It is intended to assist in working around + // bugs on some drivers when this is left written and then POINTS are drawn. + uint64_t initGLPointSize : 1; + + // This flag replaces + // "a && b" with "a ? b : false", + // "a || b" with "a ? true : b". + // This is to work around a MacOSX driver bug that |b| is executed independent of |a|'s value. + uint64_t unfoldShortCircuit : 1; + + // This flag initializes output variables to 0 at the beginning of main(). It is to avoid + // undefined behaviors. + uint64_t initOutputVariables : 1; + + // This flag scalarizes vec/ivec/bvec/mat constructor args. It is intended as a workaround for + // Linux/Mac driver bugs. + uint64_t scalarizeVecAndMatConstructorArgs : 1; + + // This flag overwrites a struct name with a unique prefix. It is intended as a workaround for + // drivers that do not handle struct scopes correctly, including all Mac drivers and Linux AMD. + uint64_t regenerateStructNames : 1; + + // This flag works around bugs in Mac drivers related to do-while by transforming them into an + // other construct. + uint64_t rewriteDoWhileLoops : 1; + + // This flag works around a bug in the HLSL compiler optimizer that folds certain constant pow + // expressions incorrectly. Only applies to the HLSL back-end. It works by expanding the integer + // pow expressions into a series of multiplies. + uint64_t expandSelectHLSLIntegerPowExpressions : 1; + + // Flatten "#pragma STDGL invariant(all)" into the declarations of varying variables and + // built-in GLSL variables. This compiler option is enabled automatically when needed. + uint64_t flattenPragmaSTDGLInvariantAll : 1; + + // Some drivers do not take into account the base level of the texture in the results of the + // HLSL GetDimensions builtin. This flag instructs the compiler to manually add the base level + // offsetting. + uint64_t HLSLGetDimensionsIgnoresBaseLevel : 1; + + // This flag works around an issue in translating GLSL function texelFetchOffset on INTEL + // drivers. It works by translating texelFetchOffset into texelFetch. + uint64_t rewriteTexelFetchOffsetToTexelFetch : 1; + + // This flag works around condition bug of for and while loops in Intel Mac OSX drivers. + // Condition calculation is not correct. Rewrite it from "CONDITION" to "CONDITION && true". + uint64_t addAndTrueToLoopCondition : 1; + + // This flag works around a bug in evaluating unary minus operator on integer on some INTEL + // drivers. It works by translating -(int) into ~(int) + 1. + uint64_t rewriteIntegerUnaryMinusOperator : 1; + + // This flag works around a bug in evaluating isnan() on some INTEL D3D and Mac OSX drivers. It + // works by using an expression to emulate this function. + uint64_t emulateIsnanFloatFunction : 1; + + // This flag will use all uniforms of unused std140 and shared uniform blocks at the beginning + // of the vertex/fragment shader's main(). It is intended as a workaround for Mac drivers with + // shader version 4.10. In those drivers, they will treat unused std140 and shared uniform + // blocks' members as inactive. However, WebGL2.0 based on OpenGL ES3.0.4 requires all members + // of a named uniform block declared with a shared or std140 layout qualifier to be considered + // active. The uniform block itself is also considered active. + uint64_t useUnusedStandardSharedBlocks : 1; + + // This flag works around a bug in unary minus operator on float numbers on Intel Mac OSX 10.11 + // drivers. It works by translating -float into 0.0 - float. + uint64_t rewriteFloatUnaryMinusOperator : 1; + + // This flag works around a bug in evaluating atan(y, x) on some NVIDIA OpenGL drivers. It + // works by using an expression to emulate this function. + uint64_t emulateAtan2FloatFunction : 1; + + // Set to initialize uninitialized local and global temporary variables. Should only be used + // with GLSL output. In HLSL output variables are initialized regardless of if this flag is set. + uint64_t initializeUninitializedLocals : 1; + + // The flag modifies the shader in the following way: + // + // Every occurrence of gl_InstanceID is replaced by the global temporary variable InstanceID. + // Every occurrence of gl_ViewID_OVR is replaced by the varying variable ViewID_OVR. + // At the beginning of the body of main() in a vertex shader the following initializers are + // added: + // ViewID_OVR = uint(gl_InstanceID) % num_views; + // InstanceID = gl_InstanceID / num_views; + // ViewID_OVR is added as a varying variable to both the vertex and fragment shaders. + uint64_t initializeBuiltinsForInstancedMultiview : 1; + + // With the flag enabled the GLSL/ESSL vertex shader is modified to include code for viewport + // selection in the following way: + // - Code to enable the extension ARB_shader_viewport_layer_array/NV_viewport_array2 is + // included. + // - Code to select the viewport index or layer is inserted at the beginning of main after + // ViewID_OVR's initialization. + // - A declaration of the uniform multiviewBaseViewLayerIndex. + // Note: The initializeBuiltinsForInstancedMultiview flag also has to be enabled to have the + // temporary variable ViewID_OVR declared and initialized. + uint64_t selectViewInNvGLSLVertexShader : 1; + + // If the flag is enabled, gl_PointSize is clamped to the maximum point size specified in + // ShBuiltInResources in vertex shaders. + uint64_t clampPointSize : 1; + + // This flag indicates whether advanced blend equation should be emulated. Currently only + // implemented for the Vulkan backend. + uint64_t addAdvancedBlendEquationsEmulation : 1; + + // Don't use loops to initialize uninitialized variables. Only has an effect if some kind of + // variable initialization is turned on. + uint64_t dontUseLoopsToInitializeVariables : 1; + + // Don't use D3D constant register zero when allocating space for uniforms. This is targeted to + // work around a bug in NVIDIA D3D driver version 388.59 where in very specific cases the driver + // would not handle constant register zero correctly. Only has an effect on HLSL translation. + uint64_t skipD3DConstantRegisterZero : 1; + + // Clamp gl_FragDepth to the range [0.0, 1.0] in case it is statically used. + uint64_t clampFragDepth : 1; + + // Rewrite expressions like "v.x = z = expression;". Works around a bug in NVIDIA OpenGL drivers + // prior to version 397.31. + uint64_t rewriteRepeatedAssignToSwizzled : 1; + + // Rewrite gl_DrawID as a uniform int + uint64_t emulateGLDrawID : 1; + + // This flag initializes shared variables to 0. It is to avoid ompute shaders being able to + // read undefined values that could be coming from another webpage/application. + uint64_t initSharedVariables : 1; + + // Forces the value returned from an atomic operations to be always be resolved. This is + // targeted to workaround a bug in NVIDIA D3D driver where the return value from + // RWByteAddressBuffer.InterlockedAdd does not get resolved when used in the .yzw components of + // a RWByteAddressBuffer.Store operation. Only has an effect on HLSL translation. + // http://anglebug.com/3246 + uint64_t forceAtomicValueResolution : 1; + + // Rewrite gl_BaseVertex and gl_BaseInstance as uniform int + uint64_t emulateGLBaseVertexBaseInstance : 1; + + // Emulate seamful cube map sampling for OpenGL ES2.0. Currently only applies to the Vulkan + // backend, as is done after samplers are moved out of structs. Can likely be made to work on + // the other backends as well. + uint64_t emulateSeamfulCubeMapSampling : 1; + + // This flag controls how to translate WEBGL_video_texture sampling function. + uint64_t takeVideoTextureAsExternalOES : 1; + + // This flag works around a inconsistent behavior in Mac AMD driver where gl_VertexID doesn't + // include base vertex value. It replaces gl_VertexID with (gl_VertexID + angle_BaseVertex) when + // angle_BaseVertex is available. + uint64_t addBaseVertexToVertexID : 1; + + // This works around the dynamic lvalue indexing of swizzled vectors on various platforms. + uint64_t removeDynamicIndexingOfSwizzledVector : 1; + + // This flag works around a slow fxc compile performance issue with dynamic uniform indexing. + uint64_t allowTranslateUniformBlockToStructuredBuffer : 1; + + // This flag allows us to add a decoration for layout(yuv) in shaders. + uint64_t addVulkanYUVLayoutQualifier : 1; + + // This flag allows disabling ARB_texture_rectangle on a per-compile basis. This is necessary + // for WebGL contexts becuase ARB_texture_rectangle may be necessary for the WebGL + // implementation internally but shouldn't be exposed to WebGL user code. + uint64_t disableARBTextureRectangle : 1; + + // This flag works around a driver bug by rewriting uses of row-major matrices as column-major + // in ESSL 3.00 and greater shaders. + uint64_t rewriteRowMajorMatrices : 1; + + // Drop any explicit precision qualifiers from shader. + uint64_t ignorePrecisionQualifiers : 1; + + // Ask compiler to generate code for depth correction to conform to the Vulkan clip space. If + // VK_EXT_depth_clip_control is supported, this code is not generated, saving a uniform look up. + uint64_t addVulkanDepthCorrection : 1; + + uint64_t forceShaderPrecisionHighpToMediump : 1; + + // Allow compiler to use specialization constant to do pre-rotation and y flip. + uint64_t useSpecializationConstant : 1; + + // Ask compiler to generate Vulkan transform feedback emulation support code. + uint64_t addVulkanXfbEmulationSupportCode : 1; + + // Ask compiler to generate Vulkan transform feedback support code when using the + // VK_EXT_transform_feedback extension. + uint64_t addVulkanXfbExtensionSupportCode : 1; + + // This flag initializes fragment shader's output variables to zero at the beginning of the + // fragment shader's main(). It is intended as a workaround for drivers which get context lost + // if gl_FragColor is not written. + uint64_t initFragmentOutputVariables : 1; + + // Transitory flag to select between producing SPIR-V directly vs using glslang. Ignored in + // non-assert-enabled builds to avoid increasing ANGLE's binary size. + uint64_t generateSpirvThroughGlslang : 1; + + // Insert explicit casts for float/double/unsigned/signed int on macOS 10.15 with Intel driver + uint64_t addExplicitBoolCasts : 1; + + // Add round() after applying dither. This works around a Qualcomm quirk where values can get + // ceil()ed instead. + uint64_t roundOutputAfterDithering : 1; + + // Even when the dividend and divisor have the same value some platforms do not return 1.0f. + // Need to emit different division code for such platforms. + uint64_t precisionSafeDivision : 1; + + // anglebug.com/7527: packUnorm4x8 fails on Pixel 4 if it is not passed a highp vec4. + // TODO(anglebug.com/7527): This workaround is currently only applied for pixel local storage. + // We may want to apply it generally. + uint64_t passHighpToPackUnormSnormBuiltins : 1; + + ShCompileOptionsMetal metal; + ShCompileOptionsPLS pls; +}; + +// The 64 bits hash function. The first parameter is the input string; the +// second parameter is the string length. +using ShHashFunction64 = khronos_uint64_t (*)(const char *, size_t); + +// +// Implementation dependent built-in resources (constants and extensions). +// The names for these resources has been obtained by stripping gl_/GL_. +// +struct ShBuiltInResources +{ + ShBuiltInResources(); + ShBuiltInResources(const ShBuiltInResources &other); + ShBuiltInResources &operator=(const ShBuiltInResources &other); + + // Constants. + int MaxVertexAttribs; + int MaxVertexUniformVectors; + int MaxVaryingVectors; + int MaxVertexTextureImageUnits; + int MaxCombinedTextureImageUnits; + int MaxTextureImageUnits; + int MaxFragmentUniformVectors; + int MaxDrawBuffers; + + // Extensions. + // Set to 1 to enable the extension, else 0. + int OES_standard_derivatives; + int OES_EGL_image_external; + int OES_EGL_image_external_essl3; + int NV_EGL_stream_consumer_external; + int ARB_texture_rectangle; + int EXT_blend_func_extended; + int EXT_draw_buffers; + int EXT_frag_depth; + int EXT_shader_texture_lod; + int EXT_shader_framebuffer_fetch; + int EXT_shader_framebuffer_fetch_non_coherent; + int NV_shader_framebuffer_fetch; + int NV_shader_noperspective_interpolation; + int ARM_shader_framebuffer_fetch; + int OVR_multiview; + int OVR_multiview2; + int EXT_multisampled_render_to_texture; + int EXT_multisampled_render_to_texture2; + int EXT_YUV_target; + int EXT_geometry_shader; + int OES_geometry_shader; + int OES_shader_io_blocks; + int EXT_shader_io_blocks; + int EXT_gpu_shader5; + int EXT_shader_non_constant_global_initializers; + int OES_texture_storage_multisample_2d_array; + int OES_texture_3D; + int ANGLE_shader_pixel_local_storage; + int ANGLE_texture_multisample; + int ANGLE_multi_draw; + // TODO(angleproject:3402) remove after chromium side removal to pass compilation + int ANGLE_base_vertex_base_instance; + int WEBGL_video_texture; + int APPLE_clip_distance; + int OES_texture_cube_map_array; + int EXT_texture_cube_map_array; + int EXT_shadow_samplers; + int OES_shader_multisample_interpolation; + int OES_shader_image_atomic; + int EXT_tessellation_shader; + int OES_texture_buffer; + int EXT_texture_buffer; + int OES_sample_variables; + int EXT_clip_cull_distance; + int EXT_primitive_bounding_box; + int OES_primitive_bounding_box; + int ANGLE_base_vertex_base_instance_shader_builtin; + int ANDROID_extension_pack_es31a; + int KHR_blend_equation_advanced; + + // Set to 1 to enable replacing GL_EXT_draw_buffers #extension directives + // with GL_NV_draw_buffers in ESSL output. This flag can be used to emulate + // EXT_draw_buffers by using it in combination with GLES3.0 glDrawBuffers + // function. This applies to Tegra K1 devices. + int NV_draw_buffers; + + // Set to 1 if highp precision is supported in the ESSL 1.00 version of the + // fragment language. Does not affect versions of the language where highp + // support is mandatory. + // Default is 0. + int FragmentPrecisionHigh; + + // GLSL ES 3.0 constants. + int MaxVertexOutputVectors; + int MaxFragmentInputVectors; + int MinProgramTexelOffset; + int MaxProgramTexelOffset; + + // Extension constants. + + // Value of GL_MAX_DUAL_SOURCE_DRAW_BUFFERS_EXT for OpenGL ES output context. + // Value of GL_MAX_DUAL_SOURCE_DRAW_BUFFERS for OpenGL output context. + // GLES SL version 100 gl_MaxDualSourceDrawBuffersEXT value for EXT_blend_func_extended. + int MaxDualSourceDrawBuffers; + + // Value of GL_MAX_VIEWS_OVR. + int MaxViewsOVR; + + // Name Hashing. + // Set a 64 bit hash function to enable user-defined name hashing. + // Default is NULL. + ShHashFunction64 HashFunction; + + // The maximum complexity an expression can be when limitExpressionComplexity is turned on. + int MaxExpressionComplexity; + + // The maximum depth a call stack can be. + int MaxCallStackDepth; + + // The maximum number of parameters a function can have when limitExpressionComplexity is turned + // on. + int MaxFunctionParameters; + + // GLES 3.1 constants + + // texture gather offset constraints. + int MinProgramTextureGatherOffset; + int MaxProgramTextureGatherOffset; + + // maximum number of available image units + int MaxImageUnits; + + // OES_sample_variables constant + // maximum number of available samples + int MaxSamples; + + // maximum number of image uniforms in a vertex shader + int MaxVertexImageUniforms; + + // maximum number of image uniforms in a fragment shader + int MaxFragmentImageUniforms; + + // maximum number of image uniforms in a compute shader + int MaxComputeImageUniforms; + + // maximum total number of image uniforms in a program + int MaxCombinedImageUniforms; + + // maximum number of uniform locations + int MaxUniformLocations; + + // maximum number of ssbos and images in a shader + int MaxCombinedShaderOutputResources; + + // maximum number of groups in each dimension + std::array MaxComputeWorkGroupCount; + // maximum number of threads per work group in each dimension + std::array MaxComputeWorkGroupSize; + + // maximum number of total uniform components + int MaxComputeUniformComponents; + + // maximum number of texture image units in a compute shader + int MaxComputeTextureImageUnits; + + // maximum number of atomic counters in a compute shader + int MaxComputeAtomicCounters; + + // maximum number of atomic counter buffers in a compute shader + int MaxComputeAtomicCounterBuffers; + + // maximum number of atomic counters in a vertex shader + int MaxVertexAtomicCounters; + + // maximum number of atomic counters in a fragment shader + int MaxFragmentAtomicCounters; + + // maximum number of atomic counters in a program + int MaxCombinedAtomicCounters; + + // maximum binding for an atomic counter + int MaxAtomicCounterBindings; + + // maximum number of atomic counter buffers in a vertex shader + int MaxVertexAtomicCounterBuffers; + + // maximum number of atomic counter buffers in a fragment shader + int MaxFragmentAtomicCounterBuffers; + + // maximum number of atomic counter buffers in a program + int MaxCombinedAtomicCounterBuffers; + + // maximum number of buffer object storage in machine units + int MaxAtomicCounterBufferSize; + + // maximum number of uniform block bindings + int MaxUniformBufferBindings; + + // maximum number of shader storage buffer bindings + int MaxShaderStorageBufferBindings; + + // maximum point size (higher limit from ALIASED_POINT_SIZE_RANGE) + float MaxPointSize; + + // EXT_geometry_shader constants + int MaxGeometryUniformComponents; + int MaxGeometryUniformBlocks; + int MaxGeometryInputComponents; + int MaxGeometryOutputComponents; + int MaxGeometryOutputVertices; + int MaxGeometryTotalOutputComponents; + int MaxGeometryTextureImageUnits; + int MaxGeometryAtomicCounterBuffers; + int MaxGeometryAtomicCounters; + int MaxGeometryShaderStorageBlocks; + int MaxGeometryShaderInvocations; + int MaxGeometryImageUniforms; + + // EXT_tessellation_shader constants + int MaxTessControlInputComponents; + int MaxTessControlOutputComponents; + int MaxTessControlTextureImageUnits; + int MaxTessControlUniformComponents; + int MaxTessControlTotalOutputComponents; + int MaxTessControlImageUniforms; + int MaxTessControlAtomicCounters; + int MaxTessControlAtomicCounterBuffers; + + int MaxTessPatchComponents; + int MaxPatchVertices; + int MaxTessGenLevel; + + int MaxTessEvaluationInputComponents; + int MaxTessEvaluationOutputComponents; + int MaxTessEvaluationTextureImageUnits; + int MaxTessEvaluationUniformComponents; + int MaxTessEvaluationImageUniforms; + int MaxTessEvaluationAtomicCounters; + int MaxTessEvaluationAtomicCounterBuffers; + + // Subpixel bits used in rasterization. + int SubPixelBits; + + // APPLE_clip_distance/EXT_clip_cull_distance constant + int MaxClipDistances; + int MaxCullDistances; + int MaxCombinedClipAndCullDistances; + + // ANGLE_shader_pixel_local_storage. + int MaxPixelLocalStoragePlanes; + int MaxColorAttachmentsWithActivePixelLocalStorage; + int MaxCombinedDrawBuffersAndPixelLocalStoragePlanes; +}; + +// +// ShHandle held by but opaque to the driver. It is allocated, +// managed, and de-allocated by the compiler. Its contents +// are defined by and used by the compiler. +// +// If handle creation fails, 0 will be returned. +// +using ShHandle = void *; + +namespace sh +{ +using BinaryBlob = std::vector; + +// +// Driver must call this first, once, before doing any other compiler operations. +// If the function succeeds, the return value is true, else false. +// +bool Initialize(); +// +// Driver should call this at shutdown. +// If the function succeeds, the return value is true, else false. +// +bool Finalize(); + +// +// Initialize built-in resources with minimum expected values. +// Parameters: +// resources: The object to initialize. Will be comparable with memcmp. +// +void InitBuiltInResources(ShBuiltInResources *resources); + +// +// Returns a copy of the current ShBuiltInResources stored in the compiler. +// Parameters: +// handle: Specifies the handle of the compiler to be used. +ShBuiltInResources GetBuiltInResources(const ShHandle handle); + +// +// Returns the a concatenated list of the items in ShBuiltInResources as a null-terminated string. +// This function must be updated whenever ShBuiltInResources is changed. +// Parameters: +// handle: Specifies the handle of the compiler to be used. +const std::string &GetBuiltInResourcesString(const ShHandle handle); + +// +// Driver calls these to create and destroy compiler objects. +// +// Returns the handle of constructed compiler, null if the requested compiler is not supported. +// Parameters: +// type: Specifies the type of shader - GL_FRAGMENT_SHADER or GL_VERTEX_SHADER. +// spec: Specifies the language spec the compiler must conform to - SH_GLES2_SPEC or SH_WEBGL_SPEC. +// output: Specifies the output code type - for example SH_ESSL_OUTPUT, SH_GLSL_OUTPUT, +// SH_HLSL_3_0_OUTPUT or SH_HLSL_4_1_OUTPUT. Note: Each output type may only +// be supported in some configurations. +// resources: Specifies the built-in resources. +ShHandle ConstructCompiler(sh::GLenum type, + ShShaderSpec spec, + ShShaderOutput output, + const ShBuiltInResources *resources); +void Destruct(ShHandle handle); + +// +// Compiles the given shader source. +// If the function succeeds, the return value is true, else false. +// Parameters: +// handle: Specifies the handle of compiler to be used. +// shaderStrings: Specifies an array of pointers to null-terminated strings containing the shader +// source code. +// numStrings: Specifies the number of elements in shaderStrings array. +// compileOptions: A mask of compile options defined above. +bool Compile(const ShHandle handle, + const char *const shaderStrings[], + size_t numStrings, + const ShCompileOptions &compileOptions); + +// Clears the results from the previous compilation. +void ClearResults(const ShHandle handle); + +// Return the version of the shader language. +int GetShaderVersion(const ShHandle handle); + +// Return the currently set language output type. +ShShaderOutput GetShaderOutputType(const ShHandle handle); + +// Returns null-terminated information log for a compiled shader. +// Parameters: +// handle: Specifies the compiler +const std::string &GetInfoLog(const ShHandle handle); + +// Returns null-terminated object code for a compiled shader. Only valid for output types that +// generate human-readable code (GLSL, ESSL or HLSL). +// Parameters: +// handle: Specifies the compiler +const std::string &GetObjectCode(const ShHandle handle); + +// Returns object binary blob for a compiled shader. Only valid for output types that +// generate binary blob (SPIR-V). +// Parameters: +// handle: Specifies the compiler +const BinaryBlob &GetObjectBinaryBlob(const ShHandle handle); + +// Returns a (original_name, hash) map containing all the user defined names in the shader, +// including variable names, function names, struct names, and struct field names. +// Parameters: +// handle: Specifies the compiler +const std::map *GetNameHashingMap(const ShHandle handle); + +// Shader variable inspection. +// Returns a pointer to a list of variables of the designated type. +// (See ShaderVars.h for type definitions, included above) +// Returns NULL on failure. +// Parameters: +// handle: Specifies the compiler +const std::vector *GetUniforms(const ShHandle handle); +const std::vector *GetVaryings(const ShHandle handle); +const std::vector *GetInputVaryings(const ShHandle handle); +const std::vector *GetOutputVaryings(const ShHandle handle); +const std::vector *GetAttributes(const ShHandle handle); +const std::vector *GetOutputVariables(const ShHandle handle); +const std::vector *GetInterfaceBlocks(const ShHandle handle); +const std::vector *GetUniformBlocks(const ShHandle handle); +const std::vector *GetShaderStorageBlocks(const ShHandle handle); +sh::WorkGroupSize GetComputeShaderLocalGroupSize(const ShHandle handle); +// Returns the number of views specified through the num_views layout qualifier. If num_views is +// not set, the function returns -1. +int GetVertexShaderNumViews(const ShHandle handle); +// Returns true if the shader has specified the |sample| qualifier, implying that per-sample shading +// should be enabled +bool EnablesPerSampleShading(const ShHandle handle); + +// Returns specialization constant usage bits +uint32_t GetShaderSpecConstUsageBits(const ShHandle handle); + +// Returns true if the passed in variables pack in maxVectors followingthe packing rules from the +// GLSL 1.017 spec, Appendix A, section 7. +// Returns false otherwise. Also look at the enforcePackingRestrictions flag above. +// Parameters: +// maxVectors: the available rows of registers. +// variables: an array of variables. +bool CheckVariablesWithinPackingLimits(int maxVectors, + const std::vector &variables); + +// Gives the compiler-assigned register for a shader storage block. +// The method writes the value to the output variable "indexOut". +// Returns true if it found a valid shader storage block, false otherwise. +// Parameters: +// handle: Specifies the compiler +// shaderStorageBlockName: Specifies the shader storage block +// indexOut: output variable that stores the assigned register +bool GetShaderStorageBlockRegister(const ShHandle handle, + const std::string &shaderStorageBlockName, + unsigned int *indexOut); + +// Gives the compiler-assigned register for a uniform block. +// The method writes the value to the output variable "indexOut". +// Returns true if it found a valid uniform block, false otherwise. +// Parameters: +// handle: Specifies the compiler +// uniformBlockName: Specifies the uniform block +// indexOut: output variable that stores the assigned register +bool GetUniformBlockRegister(const ShHandle handle, + const std::string &uniformBlockName, + unsigned int *indexOut); + +bool ShouldUniformBlockUseStructuredBuffer(const ShHandle handle, + const std::string &uniformBlockName); +const std::set *GetSlowCompilingUniformBlockSet(const ShHandle handle); + +// Gives a map from uniform names to compiler-assigned registers in the default uniform block. +// Note that the map contains also registers of samplers that have been extracted from structs. +const std::map *GetUniformRegisterMap(const ShHandle handle); + +// Sampler, image and atomic counters share registers(t type and u type), +// GetReadonlyImage2DRegisterIndex and GetImage2DRegisterIndex return the first index into +// a range of reserved registers for image2D/iimage2D/uimage2D variables. +// Parameters: handle: Specifies the compiler +unsigned int GetReadonlyImage2DRegisterIndex(const ShHandle handle); +unsigned int GetImage2DRegisterIndex(const ShHandle handle); + +// The method records these used function names related with image2D/iimage2D/uimage2D, these +// functions will be dynamically generated. +// Parameters: +// handle: Specifies the compiler +const std::set *GetUsedImage2DFunctionNames(const ShHandle handle); + +bool HasDiscardInFragmentShader(const ShHandle handle); +bool HasValidGeometryShaderInputPrimitiveType(const ShHandle handle); +bool HasValidGeometryShaderOutputPrimitiveType(const ShHandle handle); +bool HasValidGeometryShaderMaxVertices(const ShHandle handle); +bool HasValidTessGenMode(const ShHandle handle); +bool HasValidTessGenSpacing(const ShHandle handle); +bool HasValidTessGenVertexOrder(const ShHandle handle); +bool HasValidTessGenPointMode(const ShHandle handle); +GLenum GetGeometryShaderInputPrimitiveType(const ShHandle handle); +GLenum GetGeometryShaderOutputPrimitiveType(const ShHandle handle); +int GetGeometryShaderInvocations(const ShHandle handle); +int GetGeometryShaderMaxVertices(const ShHandle handle); +unsigned int GetShaderSharedMemorySize(const ShHandle handle); +int GetTessControlShaderVertices(const ShHandle handle); +GLenum GetTessGenMode(const ShHandle handle); +GLenum GetTessGenSpacing(const ShHandle handle); +GLenum GetTessGenVertexOrder(const ShHandle handle); +GLenum GetTessGenPointMode(const ShHandle handle); + +// Returns the blend equation list supported in the fragment shader. This is a bitset of +// gl::BlendEquationType, and can only include bits from KHR_blend_equation_advanced. +uint32_t GetAdvancedBlendEquations(const ShHandle handle); + +// +// Helper function to identify specs that are based on the WebGL spec. +// +inline bool IsWebGLBasedSpec(ShShaderSpec spec) +{ + return (spec == SH_WEBGL_SPEC || spec == SH_WEBGL2_SPEC || spec == SH_WEBGL3_SPEC); +} + +// +// Helper function to identify DesktopGL specs +// +inline bool IsDesktopGLSpec(ShShaderSpec spec) +{ + return spec == SH_GL_CORE_SPEC || spec == SH_GL_COMPATIBILITY_SPEC; +} + +// Can't prefix with just _ because then we might introduce a double underscore, which is not safe +// in GLSL (ESSL 3.00.6 section 3.8: All identifiers containing a double underscore are reserved for +// use by the underlying implementation). u is short for user-defined. +extern const char kUserDefinedNamePrefix[]; + +namespace vk +{ + +// Specialization constant ids +enum class SpecializationConstantId : uint32_t +{ + SurfaceRotation = 0, + Dither = 1, + + InvalidEnum = 2, + EnumCount = InvalidEnum, +}; + +enum class SpecConstUsage : uint32_t +{ + Rotation = 0, + Dither = 1, + + InvalidEnum = 2, + EnumCount = InvalidEnum, +}; + +enum ColorAttachmentDitherControl +{ + // See comments in ContextVk::updateDither and EmulateDithering.cpp + kDitherControlNoDither = 0, + kDitherControlDither4444 = 1, + kDitherControlDither5551 = 2, + kDitherControlDither565 = 3, +}; + +// Interface block name containing the aggregate default uniforms +extern const char kDefaultUniformsNameVS[]; +extern const char kDefaultUniformsNameTCS[]; +extern const char kDefaultUniformsNameTES[]; +extern const char kDefaultUniformsNameGS[]; +extern const char kDefaultUniformsNameFS[]; +extern const char kDefaultUniformsNameCS[]; + +// Interface block and variable names containing driver uniforms +extern const char kDriverUniformsBlockName[]; +extern const char kDriverUniformsVarName[]; + +// Packing information for driver uniform's misc field: +// - 1 bit for whether surface rotation results in swapped axes +// - 5 bits for advanced blend equation +// - 6 bits for sample count +// - 8 bits for enabled clip planes +// - 1 bit for whether depth should be transformed to Vulkan clip space +// - 11 bits unused +constexpr uint32_t kDriverUniformsMiscSwapXYMask = 0x1; +constexpr uint32_t kDriverUniformsMiscAdvancedBlendEquationOffset = 1; +constexpr uint32_t kDriverUniformsMiscAdvancedBlendEquationMask = 0x1F; +constexpr uint32_t kDriverUniformsMiscSampleCountOffset = 6; +constexpr uint32_t kDriverUniformsMiscSampleCountMask = 0x3F; +constexpr uint32_t kDriverUniformsMiscEnabledClipPlanesOffset = 12; +constexpr uint32_t kDriverUniformsMiscEnabledClipPlanesMask = 0xFF; +constexpr uint32_t kDriverUniformsMiscTransformDepthOffset = 20; +constexpr uint32_t kDriverUniformsMiscTransformDepthMask = 0x1; + +// Interface block array name used for atomic counter emulation +extern const char kAtomicCountersBlockName[]; + +// Transform feedback emulation support +extern const char kXfbEmulationGetOffsetsFunctionName[]; +extern const char kXfbEmulationCaptureFunctionName[]; +extern const char kXfbEmulationBufferBlockName[]; +extern const char kXfbEmulationBufferName[]; +extern const char kXfbEmulationBufferFieldName[]; + +// Transform feedback extension support +extern const char kXfbExtensionPositionOutName[]; + +// Pre-rotation support +extern const char kTransformPositionFunctionName[]; + +// EXT_shader_framebuffer_fetch and EXT_shader_framebuffer_fetch_non_coherent +extern const char kInputAttachmentName[]; + +} // namespace vk + +namespace mtl +{ +// Specialization constant to enable GL_SAMPLE_COVERAGE_VALUE emulation. +extern const char kCoverageMaskEnabledConstName[]; + +// Specialization constant to emulate rasterizer discard. +extern const char kRasterizerDiscardEnabledConstName[]; + +// Specialization constant to enable depth write in fragment shaders. +extern const char kDepthWriteEnabledConstName[]; +} // namespace mtl + +// For backends that use glslang (the Vulkan shader compiler), i.e. Vulkan and Metal, call these to +// initialize and finalize glslang itself. This can be called independently from Initialize() and +// Finalize(). +void InitializeGlslang(); +void FinalizeGlslang(); + +} // namespace sh + +#endif // GLSLANG_SHADERLANG_H_ diff --git a/gfx/angle/checkout/include/GLSLANG/ShaderVars.h b/gfx/angle/checkout/include/GLSLANG/ShaderVars.h new file mode 100644 index 0000000000..4b76d33af2 --- /dev/null +++ b/gfx/angle/checkout/include/GLSLANG/ShaderVars.h @@ -0,0 +1,331 @@ +// +// Copyright 2013 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// ShaderVars.h: +// Types to represent GL variables (varyings, uniforms, etc) +// + +#ifndef GLSLANG_SHADERVARS_H_ +#define GLSLANG_SHADERVARS_H_ + +#include +#include +#include +#include + +namespace sh +{ +// GLenum alias +typedef unsigned int GLenum; + +// Varying interpolation qualifier, see section 4.3.9 of the ESSL 3.00.4 spec +enum InterpolationType +{ + INTERPOLATION_SMOOTH, + INTERPOLATION_CENTROID, + INTERPOLATION_SAMPLE, + INTERPOLATION_FLAT, + INTERPOLATION_NOPERSPECTIVE +}; + +const char *InterpolationTypeToString(InterpolationType type); + +// Validate link & SSO consistency of interpolation qualifiers +bool InterpolationTypesMatch(InterpolationType a, InterpolationType b); + +// Uniform block layout qualifier, see section 4.3.8.3 of the ESSL 3.00.4 spec +enum BlockLayoutType +{ + BLOCKLAYOUT_STANDARD, + BLOCKLAYOUT_STD140 = BLOCKLAYOUT_STANDARD, + BLOCKLAYOUT_STD430, // Shader storage block layout qualifier + BLOCKLAYOUT_PACKED, + BLOCKLAYOUT_SHARED +}; + +const char *BlockLayoutTypeToString(BlockLayoutType type); + +// Interface Blocks, see section 4.3.9 of the ESSL 3.10 spec +enum class BlockType +{ + BLOCK_UNIFORM, + BLOCK_BUFFER, +}; + +const char *BlockTypeToString(BlockType type); + +// Base class for all variables defined in shaders, including Varyings, Uniforms, etc +// Note: we must override the copy constructor and assignment operator so we can +// work around excessive GCC binary bloating: +// See https://code.google.com/p/angleproject/issues/detail?id=697 +struct ShaderVariable +{ + ShaderVariable(); + ShaderVariable(GLenum typeIn); + ShaderVariable(GLenum typeIn, unsigned int arraySizeIn); + ~ShaderVariable(); + ShaderVariable(const ShaderVariable &other); + ShaderVariable &operator=(const ShaderVariable &other); + bool operator==(const ShaderVariable &other) const; + bool operator!=(const ShaderVariable &other) const { return !operator==(other); } + + bool isArrayOfArrays() const { return arraySizes.size() >= 2u; } + bool isArray() const { return !arraySizes.empty(); } + unsigned int getArraySizeProduct() const; + // Return the inner array size product. + // For example, if there's a variable declared as size 3 array of size 4 array of size 5 array + // of int: + // int a[3][4][5]; + // then getInnerArraySizeProduct of a would be 4*5. + unsigned int getInnerArraySizeProduct() const; + + // Array size 0 means not an array when passed to or returned from these functions. + // Note that setArraySize() is deprecated and should not be used inside ANGLE. + unsigned int getOutermostArraySize() const { return isArray() ? arraySizes.back() : 0; } + void setArraySize(unsigned int size); + + // Turn this ShaderVariable from an array into a specific element in that array. Will update + // flattenedOffsetInParentArrays. + void indexIntoArray(unsigned int arrayIndex); + + // Get the nth nested array size from the top. Caller is responsible for range checking + // arrayNestingIndex. + unsigned int getNestedArraySize(unsigned int arrayNestingIndex) const; + + // This function should only be used with variables that are of a basic type or an array of a + // basic type. Shader interface variables that are enumerated according to rules in GLES 3.1 + // spec section 7.3.1.1 page 77 are fine. For those variables the return value should match the + // ARRAY_SIZE value that can be queried through the API. + unsigned int getBasicTypeElementCount() const; + + unsigned int getExternalSize() const; + + bool isStruct() const { return !fields.empty(); } + const std::string &getStructName() const { return structOrBlockName; } + void setStructName(const std::string &newName) { structOrBlockName = newName; } + + // All of the shader's variables are described using nested data + // structures. This is needed in order to disambiguate similar looking + // types, such as two structs containing the same fields, but in + // different orders. "findInfoByMappedName" provides an easy query for + // users to dive into the data structure and fetch the unique variable + // instance corresponding to a dereferencing chain of the top-level + // variable. + // Given a mapped name like 'a[0].b.c[0]', return the ShaderVariable + // that defines 'c' in |leafVar|, and the original name 'A[0].B.C[0]' + // in |originalName|, based on the assumption that |this| defines 'a'. + // If no match is found, return false. + bool findInfoByMappedName(const std::string &mappedFullName, + const ShaderVariable **leafVar, + std::string *originalFullName) const; + + // Find the child field which matches 'fullName' == var.name + "." + field.name. + // Return nullptr if not found. + const sh::ShaderVariable *findField(const std::string &fullName, uint32_t *fieldIndexOut) const; + + bool isBuiltIn() const; + bool isEmulatedBuiltIn() const; + + // Offset of this variable in parent arrays. In case the parent is an array of arrays, the + // offset is outerArrayElement * innerArraySize + innerArrayElement. + // For example, if there's a variable declared as size 3 array of size 4 array of int: + // int a[3][4]; + // then the flattenedOffsetInParentArrays of a[2] would be 2. + // and flattenedOffsetInParentArrays of a[2][1] would be 2*4 + 1 = 9. + int parentArrayIndex() const + { + return hasParentArrayIndex() ? flattenedOffsetInParentArrays : 0; + } + + int getFlattenedOffsetInParentArrays() const { return flattenedOffsetInParentArrays; } + void setParentArrayIndex(int indexIn) { flattenedOffsetInParentArrays = indexIn; } + + bool hasParentArrayIndex() const { return flattenedOffsetInParentArrays != -1; } + + void resetEffectiveLocation(); + void updateEffectiveLocation(const sh::ShaderVariable &parent); + + // Decide whether two uniforms are the same at shader link time, + // assuming they are from consecutive shader stages. + // GLSL ES Spec 3.00.3, section 4.3.5. + // GLSL ES Spec 3.10.4, section 4.4.5 + bool isSameUniformAtLinkTime(const ShaderVariable &other) const; + + // InterfaceBlockField + // Decide whether two InterfaceBlock fields are the same at shader + // link time, assuming they are from consecutive shader stages. + // See GLSL ES Spec 3.00.3, sec 4.3.7. + bool isSameInterfaceBlockFieldAtLinkTime(const ShaderVariable &other) const; + + // Decide whether two varyings are the same at shader link time, + // assuming they are from consecutive shader stages. + // Invariance needs to match only in ESSL1. Relevant spec sections: + // GLSL ES 3.00.4, sections 4.6.1 and 4.3.9. + // GLSL ES 1.00.17, section 4.6.4. + bool isSameVaryingAtLinkTime(const ShaderVariable &other, int shaderVersion) const; + // Deprecated version of isSameVaryingAtLinkTime, which assumes ESSL1. + bool isSameVaryingAtLinkTime(const ShaderVariable &other) const; + + // Shader I/O blocks may match by block name or instance, based on whether both stages have an + // instance name or not. + bool isSameNameAtLinkTime(const ShaderVariable &other) const; + + // NOTE: When adding new members, the following functions also need to be updated: + // gl::WriteShaderVar(BinaryOutputStream *stream, const sh::ShaderVariable &var) + // gl::LoadShaderVar(BinaryInputStream *stream, sh::ShaderVariable *var) + + GLenum type; + GLenum precision; + std::string name; + std::string mappedName; + + // Used to make an array type. Outermost array size is stored at the end of the vector. + std::vector arraySizes; + + // Static use means that the variable is accessed somewhere in the shader source. + bool staticUse; + // A variable is active unless the compiler determined that it is not accessed by the shader. + // All active variables are statically used, but not all statically used variables are + // necessarily active. GLES 3.0.5 section 2.12.6. GLES 3.1 section 7.3.1. + bool active; + std::vector fields; + // structOrBlockName is used for: + // - varyings of struct type, in which case it contains the struct name. + // - shader I/O blocks, in which case it contains the block name. + std::string structOrBlockName; + std::string mappedStructOrBlockName; + + // Only applies to interface block fields. Kept here for simplicity. + bool isRowMajorLayout; + + // VariableWithLocation + int location; + + // The location of inputs or outputs without location layout quailifer will be updated to '-1'. + // GLES Spec 3.1, Section 7.3. PROGRAM OBJECTS + // Not all active variables are assigned valid locations; + // the following variables will have an effective location of -1: + bool hasImplicitLocation; + + // Uniform + int binding; + GLenum imageUnitFormat; + int offset; + bool rasterOrdered; + bool readonly; + bool writeonly; + + // From EXT_shader_framebuffer_fetch / KHR_blend_equation_advanced + bool isFragmentInOut; + + // OutputVariable + // From EXT_blend_func_extended. + int index; + + // From EXT_YUV_target + bool yuv; + + // Varying + InterpolationType interpolation; + bool isInvariant; + bool isShaderIOBlock; + bool isPatch; + + // If the variable is a sampler that has ever been statically used with texelFetch + bool texelFetchStaticUse; + + protected: + bool isSameVariableAtLinkTime(const ShaderVariable &other, + bool matchPrecision, + bool matchName) const; + + // NOTE: When adding new members, the following functions also need to be updated: + // gl::WriteShaderVar(BinaryOutputStream *stream, const sh::ShaderVariable &var) + // gl::LoadShaderVar(BinaryInputStream *stream, sh::ShaderVariable *var) + + int flattenedOffsetInParentArrays; +}; + +// TODO: anglebug.com/3899 +// For backwards compatibility for other codebases (e.g., chromium/src/gpu/command_buffer/service) +using Uniform = ShaderVariable; +using Attribute = ShaderVariable; +using OutputVariable = ShaderVariable; +using InterfaceBlockField = ShaderVariable; +using Varying = ShaderVariable; + +struct InterfaceBlock +{ + InterfaceBlock(); + ~InterfaceBlock(); + InterfaceBlock(const InterfaceBlock &other); + InterfaceBlock &operator=(const InterfaceBlock &other); + + // Fields from blocks with non-empty instance names are prefixed with the block name. + std::string fieldPrefix() const; + std::string fieldMappedPrefix() const; + + // Decide whether two interface blocks are the same at shader link time. + bool isSameInterfaceBlockAtLinkTime(const InterfaceBlock &other) const; + + bool isBuiltIn() const; + + bool isArray() const { return arraySize > 0; } + unsigned int elementCount() const { return std::max(1u, arraySize); } + + std::string name; + std::string mappedName; + std::string instanceName; + unsigned int arraySize; + BlockLayoutType layout; + + // Deprecated. Matrix packing should only be queried from individual fields of the block. + // TODO(oetuaho): Remove this once it is no longer used in Chromium. + bool isRowMajorLayout; + + int binding; + bool staticUse; + bool active; + BlockType blockType; + std::vector fields; +}; + +struct WorkGroupSize +{ + // Must have a trivial default constructor since it is used in YYSTYPE. + inline WorkGroupSize() = default; + inline explicit constexpr WorkGroupSize(int initialSize); + + void fill(int fillValue); + void setLocalSize(int localSizeX, int localSizeY, int localSizeZ); + + int &operator[](size_t index); + int operator[](size_t index) const; + size_t size() const; + + // Checks whether two work group size declarations match. + // Two work group size declarations are the same if the explicitly specified elements are the + // same or if one of them is specified as one and the other one is not specified + bool isWorkGroupSizeMatching(const WorkGroupSize &right) const; + + // Checks whether any of the values are set. + bool isAnyValueSet() const; + + // Checks whether all of the values are set. + bool isDeclared() const; + + // Checks whether either all of the values are set, or none of them are. + bool isLocalSizeValid() const; + + int localSizeQualifiers[3]; +}; + +inline constexpr WorkGroupSize::WorkGroupSize(int initialSize) + : localSizeQualifiers{initialSize, initialSize, initialSize} +{} + +} // namespace sh + +#endif // GLSLANG_SHADERVARS_H_ diff --git a/gfx/angle/checkout/include/GLX/glxext.h b/gfx/angle/checkout/include/GLX/glxext.h new file mode 100644 index 0000000000..b918317fb9 --- /dev/null +++ b/gfx/angle/checkout/include/GLX/glxext.h @@ -0,0 +1,954 @@ +#ifndef __glx_glxext_h_ +#define __glx_glxext_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright 2013-2020 The Khronos Group Inc. +** SPDX-License-Identifier: MIT +** +** This header is generated from the Khronos OpenGL / OpenGL ES XML +** API Registry. The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** https://github.com/KhronosGroup/OpenGL-Registry +*/ + +#define GLX_GLXEXT_VERSION 20220530 + +/* Generated C header for: + * API: glx + * Versions considered: .* + * Versions emitted: 1\.[3-9] + * Default extensions included: glx + * Additional extensions included: _nomatch_^ + * Extensions removed: _nomatch_^ + */ + +#ifndef GLX_VERSION_1_3 +#define GLX_VERSION_1_3 1 +typedef XID GLXContextID; +typedef struct __GLXFBConfigRec *GLXFBConfig; +typedef XID GLXWindow; +typedef XID GLXPbuffer; +#define GLX_WINDOW_BIT 0x00000001 +#define GLX_PIXMAP_BIT 0x00000002 +#define GLX_PBUFFER_BIT 0x00000004 +#define GLX_RGBA_BIT 0x00000001 +#define GLX_COLOR_INDEX_BIT 0x00000002 +#define GLX_PBUFFER_CLOBBER_MASK 0x08000000 +#define GLX_FRONT_LEFT_BUFFER_BIT 0x00000001 +#define GLX_FRONT_RIGHT_BUFFER_BIT 0x00000002 +#define GLX_BACK_LEFT_BUFFER_BIT 0x00000004 +#define GLX_BACK_RIGHT_BUFFER_BIT 0x00000008 +#define GLX_AUX_BUFFERS_BIT 0x00000010 +#define GLX_DEPTH_BUFFER_BIT 0x00000020 +#define GLX_STENCIL_BUFFER_BIT 0x00000040 +#define GLX_ACCUM_BUFFER_BIT 0x00000080 +#define GLX_CONFIG_CAVEAT 0x20 +#define GLX_X_VISUAL_TYPE 0x22 +#define GLX_TRANSPARENT_TYPE 0x23 +#define GLX_TRANSPARENT_INDEX_VALUE 0x24 +#define GLX_TRANSPARENT_RED_VALUE 0x25 +#define GLX_TRANSPARENT_GREEN_VALUE 0x26 +#define GLX_TRANSPARENT_BLUE_VALUE 0x27 +#define GLX_TRANSPARENT_ALPHA_VALUE 0x28 +#define GLX_DONT_CARE 0xFFFFFFFF +#define GLX_NONE 0x8000 +#define GLX_SLOW_CONFIG 0x8001 +#define GLX_TRUE_COLOR 0x8002 +#define GLX_DIRECT_COLOR 0x8003 +#define GLX_PSEUDO_COLOR 0x8004 +#define GLX_STATIC_COLOR 0x8005 +#define GLX_GRAY_SCALE 0x8006 +#define GLX_STATIC_GRAY 0x8007 +#define GLX_TRANSPARENT_RGB 0x8008 +#define GLX_TRANSPARENT_INDEX 0x8009 +#define GLX_VISUAL_ID 0x800B +#define GLX_SCREEN 0x800C +#define GLX_NON_CONFORMANT_CONFIG 0x800D +#define GLX_DRAWABLE_TYPE 0x8010 +#define GLX_RENDER_TYPE 0x8011 +#define GLX_X_RENDERABLE 0x8012 +#define GLX_FBCONFIG_ID 0x8013 +#define GLX_RGBA_TYPE 0x8014 +#define GLX_COLOR_INDEX_TYPE 0x8015 +#define GLX_MAX_PBUFFER_WIDTH 0x8016 +#define GLX_MAX_PBUFFER_HEIGHT 0x8017 +#define GLX_MAX_PBUFFER_PIXELS 0x8018 +#define GLX_PRESERVED_CONTENTS 0x801B +#define GLX_LARGEST_PBUFFER 0x801C +#define GLX_WIDTH 0x801D +#define GLX_HEIGHT 0x801E +#define GLX_EVENT_MASK 0x801F +#define GLX_DAMAGED 0x8020 +#define GLX_SAVED 0x8021 +#define GLX_WINDOW 0x8022 +#define GLX_PBUFFER 0x8023 +#define GLX_PBUFFER_HEIGHT 0x8040 +#define GLX_PBUFFER_WIDTH 0x8041 +typedef GLXFBConfig *( *PFNGLXGETFBCONFIGSPROC) (Display *dpy, int screen, int *nelements); +typedef GLXFBConfig *( *PFNGLXCHOOSEFBCONFIGPROC) (Display *dpy, int screen, const int *attrib_list, int *nelements); +typedef int ( *PFNGLXGETFBCONFIGATTRIBPROC) (Display *dpy, GLXFBConfig config, int attribute, int *value); +typedef XVisualInfo *( *PFNGLXGETVISUALFROMFBCONFIGPROC) (Display *dpy, GLXFBConfig config); +typedef GLXWindow ( *PFNGLXCREATEWINDOWPROC) (Display *dpy, GLXFBConfig config, Window win, const int *attrib_list); +typedef void ( *PFNGLXDESTROYWINDOWPROC) (Display *dpy, GLXWindow win); +typedef GLXPixmap ( *PFNGLXCREATEPIXMAPPROC) (Display *dpy, GLXFBConfig config, Pixmap pixmap, const int *attrib_list); +typedef void ( *PFNGLXDESTROYPIXMAPPROC) (Display *dpy, GLXPixmap pixmap); +typedef GLXPbuffer ( *PFNGLXCREATEPBUFFERPROC) (Display *dpy, GLXFBConfig config, const int *attrib_list); +typedef void ( *PFNGLXDESTROYPBUFFERPROC) (Display *dpy, GLXPbuffer pbuf); +typedef void ( *PFNGLXQUERYDRAWABLEPROC) (Display *dpy, GLXDrawable draw, int attribute, unsigned int *value); +typedef GLXContext ( *PFNGLXCREATENEWCONTEXTPROC) (Display *dpy, GLXFBConfig config, int render_type, GLXContext share_list, Bool direct); +typedef Bool ( *PFNGLXMAKECONTEXTCURRENTPROC) (Display *dpy, GLXDrawable draw, GLXDrawable read, GLXContext ctx); +typedef GLXDrawable ( *PFNGLXGETCURRENTREADDRAWABLEPROC) (void); +typedef int ( *PFNGLXQUERYCONTEXTPROC) (Display *dpy, GLXContext ctx, int attribute, int *value); +typedef void ( *PFNGLXSELECTEVENTPROC) (Display *dpy, GLXDrawable draw, unsigned long event_mask); +typedef void ( *PFNGLXGETSELECTEDEVENTPROC) (Display *dpy, GLXDrawable draw, unsigned long *event_mask); +#ifdef GLX_GLXEXT_PROTOTYPES +GLXFBConfig *glXGetFBConfigs (Display *dpy, int screen, int *nelements); +GLXFBConfig *glXChooseFBConfig (Display *dpy, int screen, const int *attrib_list, int *nelements); +int glXGetFBConfigAttrib (Display *dpy, GLXFBConfig config, int attribute, int *value); +XVisualInfo *glXGetVisualFromFBConfig (Display *dpy, GLXFBConfig config); +GLXWindow glXCreateWindow (Display *dpy, GLXFBConfig config, Window win, const int *attrib_list); +void glXDestroyWindow (Display *dpy, GLXWindow win); +GLXPixmap glXCreatePixmap (Display *dpy, GLXFBConfig config, Pixmap pixmap, const int *attrib_list); +void glXDestroyPixmap (Display *dpy, GLXPixmap pixmap); +GLXPbuffer glXCreatePbuffer (Display *dpy, GLXFBConfig config, const int *attrib_list); +void glXDestroyPbuffer (Display *dpy, GLXPbuffer pbuf); +void glXQueryDrawable (Display *dpy, GLXDrawable draw, int attribute, unsigned int *value); +GLXContext glXCreateNewContext (Display *dpy, GLXFBConfig config, int render_type, GLXContext share_list, Bool direct); +Bool glXMakeContextCurrent (Display *dpy, GLXDrawable draw, GLXDrawable read, GLXContext ctx); +GLXDrawable glXGetCurrentReadDrawable (void); +int glXQueryContext (Display *dpy, GLXContext ctx, int attribute, int *value); +void glXSelectEvent (Display *dpy, GLXDrawable draw, unsigned long event_mask); +void glXGetSelectedEvent (Display *dpy, GLXDrawable draw, unsigned long *event_mask); +#endif +#endif /* GLX_VERSION_1_3 */ + +#ifndef GLX_VERSION_1_4 +#define GLX_VERSION_1_4 1 +typedef void ( *__GLXextFuncPtr)(void); +#define GLX_SAMPLE_BUFFERS 100000 +#define GLX_SAMPLES 100001 +typedef __GLXextFuncPtr ( *PFNGLXGETPROCADDRESSPROC) (const GLubyte *procName); +#ifdef GLX_GLXEXT_PROTOTYPES +__GLXextFuncPtr glXGetProcAddress (const GLubyte *procName); +#endif +#endif /* GLX_VERSION_1_4 */ + +#ifndef GLX_ARB_context_flush_control +#define GLX_ARB_context_flush_control 1 +#define GLX_CONTEXT_RELEASE_BEHAVIOR_ARB 0x2097 +#define GLX_CONTEXT_RELEASE_BEHAVIOR_NONE_ARB 0 +#define GLX_CONTEXT_RELEASE_BEHAVIOR_FLUSH_ARB 0x2098 +#endif /* GLX_ARB_context_flush_control */ + +#ifndef GLX_ARB_create_context +#define GLX_ARB_create_context 1 +#define GLX_CONTEXT_DEBUG_BIT_ARB 0x00000001 +#define GLX_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x00000002 +#define GLX_CONTEXT_MAJOR_VERSION_ARB 0x2091 +#define GLX_CONTEXT_MINOR_VERSION_ARB 0x2092 +#define GLX_CONTEXT_FLAGS_ARB 0x2094 +typedef GLXContext ( *PFNGLXCREATECONTEXTATTRIBSARBPROC) (Display *dpy, GLXFBConfig config, GLXContext share_context, Bool direct, const int *attrib_list); +#ifdef GLX_GLXEXT_PROTOTYPES +GLXContext glXCreateContextAttribsARB (Display *dpy, GLXFBConfig config, GLXContext share_context, Bool direct, const int *attrib_list); +#endif +#endif /* GLX_ARB_create_context */ + +#ifndef GLX_ARB_create_context_no_error +#define GLX_ARB_create_context_no_error 1 +#define GLX_CONTEXT_OPENGL_NO_ERROR_ARB 0x31B3 +#endif /* GLX_ARB_create_context_no_error */ + +#ifndef GLX_ARB_create_context_profile +#define GLX_ARB_create_context_profile 1 +#define GLX_CONTEXT_CORE_PROFILE_BIT_ARB 0x00000001 +#define GLX_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB 0x00000002 +#define GLX_CONTEXT_PROFILE_MASK_ARB 0x9126 +#endif /* GLX_ARB_create_context_profile */ + +#ifndef GLX_ARB_create_context_robustness +#define GLX_ARB_create_context_robustness 1 +#define GLX_CONTEXT_ROBUST_ACCESS_BIT_ARB 0x00000004 +#define GLX_LOSE_CONTEXT_ON_RESET_ARB 0x8252 +#define GLX_CONTEXT_RESET_NOTIFICATION_STRATEGY_ARB 0x8256 +#define GLX_NO_RESET_NOTIFICATION_ARB 0x8261 +#endif /* GLX_ARB_create_context_robustness */ + +#ifndef GLX_ARB_fbconfig_float +#define GLX_ARB_fbconfig_float 1 +#define GLX_RGBA_FLOAT_TYPE_ARB 0x20B9 +#define GLX_RGBA_FLOAT_BIT_ARB 0x00000004 +#endif /* GLX_ARB_fbconfig_float */ + +#ifndef GLX_ARB_framebuffer_sRGB +#define GLX_ARB_framebuffer_sRGB 1 +#define GLX_FRAMEBUFFER_SRGB_CAPABLE_ARB 0x20B2 +#endif /* GLX_ARB_framebuffer_sRGB */ + +#ifndef GLX_ARB_get_proc_address +#define GLX_ARB_get_proc_address 1 +typedef __GLXextFuncPtr ( *PFNGLXGETPROCADDRESSARBPROC) (const GLubyte *procName); +#ifdef GLX_GLXEXT_PROTOTYPES +__GLXextFuncPtr glXGetProcAddressARB (const GLubyte *procName); +#endif +#endif /* GLX_ARB_get_proc_address */ + +#ifndef GLX_ARB_multisample +#define GLX_ARB_multisample 1 +#define GLX_SAMPLE_BUFFERS_ARB 100000 +#define GLX_SAMPLES_ARB 100001 +#endif /* GLX_ARB_multisample */ + +#ifndef GLX_ARB_robustness_application_isolation +#define GLX_ARB_robustness_application_isolation 1 +#define GLX_CONTEXT_RESET_ISOLATION_BIT_ARB 0x00000008 +#endif /* GLX_ARB_robustness_application_isolation */ + +#ifndef GLX_ARB_robustness_share_group_isolation +#define GLX_ARB_robustness_share_group_isolation 1 +#endif /* GLX_ARB_robustness_share_group_isolation */ + +#ifndef GLX_ARB_vertex_buffer_object +#define GLX_ARB_vertex_buffer_object 1 +#define GLX_CONTEXT_ALLOW_BUFFER_BYTE_ORDER_MISMATCH_ARB 0x2095 +#endif /* GLX_ARB_vertex_buffer_object */ + +#ifndef GLX_3DFX_multisample +#define GLX_3DFX_multisample 1 +#define GLX_SAMPLE_BUFFERS_3DFX 0x8050 +#define GLX_SAMPLES_3DFX 0x8051 +#endif /* GLX_3DFX_multisample */ + +#ifndef GLX_AMD_gpu_association +#define GLX_AMD_gpu_association 1 +#define GLX_GPU_VENDOR_AMD 0x1F00 +#define GLX_GPU_RENDERER_STRING_AMD 0x1F01 +#define GLX_GPU_OPENGL_VERSION_STRING_AMD 0x1F02 +#define GLX_GPU_FASTEST_TARGET_GPUS_AMD 0x21A2 +#define GLX_GPU_RAM_AMD 0x21A3 +#define GLX_GPU_CLOCK_AMD 0x21A4 +#define GLX_GPU_NUM_PIPES_AMD 0x21A5 +#define GLX_GPU_NUM_SIMD_AMD 0x21A6 +#define GLX_GPU_NUM_RB_AMD 0x21A7 +#define GLX_GPU_NUM_SPI_AMD 0x21A8 +typedef unsigned int ( *PFNGLXGETGPUIDSAMDPROC) (unsigned int maxCount, unsigned int *ids); +typedef int ( *PFNGLXGETGPUINFOAMDPROC) (unsigned int id, int property, GLenum dataType, unsigned int size, void *data); +typedef unsigned int ( *PFNGLXGETCONTEXTGPUIDAMDPROC) (GLXContext ctx); +typedef GLXContext ( *PFNGLXCREATEASSOCIATEDCONTEXTAMDPROC) (unsigned int id, GLXContext share_list); +typedef GLXContext ( *PFNGLXCREATEASSOCIATEDCONTEXTATTRIBSAMDPROC) (unsigned int id, GLXContext share_context, const int *attribList); +typedef Bool ( *PFNGLXDELETEASSOCIATEDCONTEXTAMDPROC) (GLXContext ctx); +typedef Bool ( *PFNGLXMAKEASSOCIATEDCONTEXTCURRENTAMDPROC) (GLXContext ctx); +typedef GLXContext ( *PFNGLXGETCURRENTASSOCIATEDCONTEXTAMDPROC) (void); +typedef void ( *PFNGLXBLITCONTEXTFRAMEBUFFERAMDPROC) (GLXContext dstCtx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +#ifdef GLX_GLXEXT_PROTOTYPES +unsigned int glXGetGPUIDsAMD (unsigned int maxCount, unsigned int *ids); +int glXGetGPUInfoAMD (unsigned int id, int property, GLenum dataType, unsigned int size, void *data); +unsigned int glXGetContextGPUIDAMD (GLXContext ctx); +GLXContext glXCreateAssociatedContextAMD (unsigned int id, GLXContext share_list); +GLXContext glXCreateAssociatedContextAttribsAMD (unsigned int id, GLXContext share_context, const int *attribList); +Bool glXDeleteAssociatedContextAMD (GLXContext ctx); +Bool glXMakeAssociatedContextCurrentAMD (GLXContext ctx); +GLXContext glXGetCurrentAssociatedContextAMD (void); +void glXBlitContextFramebufferAMD (GLXContext dstCtx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +#endif +#endif /* GLX_AMD_gpu_association */ + +#ifndef GLX_EXT_buffer_age +#define GLX_EXT_buffer_age 1 +#define GLX_BACK_BUFFER_AGE_EXT 0x20F4 +#endif /* GLX_EXT_buffer_age */ + +#ifndef GLX_EXT_context_priority +#define GLX_EXT_context_priority 1 +#define GLX_CONTEXT_PRIORITY_LEVEL_EXT 0x3100 +#define GLX_CONTEXT_PRIORITY_HIGH_EXT 0x3101 +#define GLX_CONTEXT_PRIORITY_MEDIUM_EXT 0x3102 +#define GLX_CONTEXT_PRIORITY_LOW_EXT 0x3103 +#endif /* GLX_EXT_context_priority */ + +#ifndef GLX_EXT_create_context_es2_profile +#define GLX_EXT_create_context_es2_profile 1 +#define GLX_CONTEXT_ES2_PROFILE_BIT_EXT 0x00000004 +#endif /* GLX_EXT_create_context_es2_profile */ + +#ifndef GLX_EXT_create_context_es_profile +#define GLX_EXT_create_context_es_profile 1 +#define GLX_CONTEXT_ES_PROFILE_BIT_EXT 0x00000004 +#endif /* GLX_EXT_create_context_es_profile */ + +#ifndef GLX_EXT_fbconfig_packed_float +#define GLX_EXT_fbconfig_packed_float 1 +#define GLX_RGBA_UNSIGNED_FLOAT_TYPE_EXT 0x20B1 +#define GLX_RGBA_UNSIGNED_FLOAT_BIT_EXT 0x00000008 +#endif /* GLX_EXT_fbconfig_packed_float */ + +#ifndef GLX_EXT_framebuffer_sRGB +#define GLX_EXT_framebuffer_sRGB 1 +#define GLX_FRAMEBUFFER_SRGB_CAPABLE_EXT 0x20B2 +#endif /* GLX_EXT_framebuffer_sRGB */ + +#ifndef GLX_EXT_get_drawable_type +#define GLX_EXT_get_drawable_type 1 +#endif /* GLX_EXT_get_drawable_type */ + +#ifndef GLX_EXT_import_context +#define GLX_EXT_import_context 1 +#define GLX_SHARE_CONTEXT_EXT 0x800A +#define GLX_VISUAL_ID_EXT 0x800B +#define GLX_SCREEN_EXT 0x800C +typedef Display *( *PFNGLXGETCURRENTDISPLAYEXTPROC) (void); +typedef int ( *PFNGLXQUERYCONTEXTINFOEXTPROC) (Display *dpy, GLXContext context, int attribute, int *value); +typedef GLXContextID ( *PFNGLXGETCONTEXTIDEXTPROC) (const GLXContext context); +typedef GLXContext ( *PFNGLXIMPORTCONTEXTEXTPROC) (Display *dpy, GLXContextID contextID); +typedef void ( *PFNGLXFREECONTEXTEXTPROC) (Display *dpy, GLXContext context); +#ifdef GLX_GLXEXT_PROTOTYPES +Display *glXGetCurrentDisplayEXT (void); +int glXQueryContextInfoEXT (Display *dpy, GLXContext context, int attribute, int *value); +GLXContextID glXGetContextIDEXT (const GLXContext context); +GLXContext glXImportContextEXT (Display *dpy, GLXContextID contextID); +void glXFreeContextEXT (Display *dpy, GLXContext context); +#endif +#endif /* GLX_EXT_import_context */ + +#ifndef GLX_EXT_libglvnd +#define GLX_EXT_libglvnd 1 +#define GLX_VENDOR_NAMES_EXT 0x20F6 +#endif /* GLX_EXT_libglvnd */ + +#ifndef GLX_EXT_no_config_context +#define GLX_EXT_no_config_context 1 +#endif /* GLX_EXT_no_config_context */ + +#ifndef GLX_EXT_stereo_tree +#define GLX_EXT_stereo_tree 1 +typedef struct { + int type; + unsigned long serial; + Bool send_event; + Display *display; + int extension; + int evtype; + GLXDrawable window; + Bool stereo_tree; +} GLXStereoNotifyEventEXT; +#define GLX_STEREO_TREE_EXT 0x20F5 +#define GLX_STEREO_NOTIFY_MASK_EXT 0x00000001 +#define GLX_STEREO_NOTIFY_EXT 0x00000000 +#endif /* GLX_EXT_stereo_tree */ + +#ifndef GLX_EXT_swap_control +#define GLX_EXT_swap_control 1 +#define GLX_SWAP_INTERVAL_EXT 0x20F1 +#define GLX_MAX_SWAP_INTERVAL_EXT 0x20F2 +typedef void ( *PFNGLXSWAPINTERVALEXTPROC) (Display *dpy, GLXDrawable drawable, int interval); +#ifdef GLX_GLXEXT_PROTOTYPES +void glXSwapIntervalEXT (Display *dpy, GLXDrawable drawable, int interval); +#endif +#endif /* GLX_EXT_swap_control */ + +#ifndef GLX_EXT_swap_control_tear +#define GLX_EXT_swap_control_tear 1 +#define GLX_LATE_SWAPS_TEAR_EXT 0x20F3 +#endif /* GLX_EXT_swap_control_tear */ + +#ifndef GLX_EXT_texture_from_pixmap +#define GLX_EXT_texture_from_pixmap 1 +#define GLX_TEXTURE_1D_BIT_EXT 0x00000001 +#define GLX_TEXTURE_2D_BIT_EXT 0x00000002 +#define GLX_TEXTURE_RECTANGLE_BIT_EXT 0x00000004 +#define GLX_BIND_TO_TEXTURE_RGB_EXT 0x20D0 +#define GLX_BIND_TO_TEXTURE_RGBA_EXT 0x20D1 +#define GLX_BIND_TO_MIPMAP_TEXTURE_EXT 0x20D2 +#define GLX_BIND_TO_TEXTURE_TARGETS_EXT 0x20D3 +#define GLX_Y_INVERTED_EXT 0x20D4 +#define GLX_TEXTURE_FORMAT_EXT 0x20D5 +#define GLX_TEXTURE_TARGET_EXT 0x20D6 +#define GLX_MIPMAP_TEXTURE_EXT 0x20D7 +#define GLX_TEXTURE_FORMAT_NONE_EXT 0x20D8 +#define GLX_TEXTURE_FORMAT_RGB_EXT 0x20D9 +#define GLX_TEXTURE_FORMAT_RGBA_EXT 0x20DA +#define GLX_TEXTURE_1D_EXT 0x20DB +#define GLX_TEXTURE_2D_EXT 0x20DC +#define GLX_TEXTURE_RECTANGLE_EXT 0x20DD +#define GLX_FRONT_LEFT_EXT 0x20DE +#define GLX_FRONT_RIGHT_EXT 0x20DF +#define GLX_BACK_LEFT_EXT 0x20E0 +#define GLX_BACK_RIGHT_EXT 0x20E1 +#define GLX_FRONT_EXT 0x20DE +#define GLX_BACK_EXT 0x20E0 +#define GLX_AUX0_EXT 0x20E2 +#define GLX_AUX1_EXT 0x20E3 +#define GLX_AUX2_EXT 0x20E4 +#define GLX_AUX3_EXT 0x20E5 +#define GLX_AUX4_EXT 0x20E6 +#define GLX_AUX5_EXT 0x20E7 +#define GLX_AUX6_EXT 0x20E8 +#define GLX_AUX7_EXT 0x20E9 +#define GLX_AUX8_EXT 0x20EA +#define GLX_AUX9_EXT 0x20EB +typedef void ( *PFNGLXBINDTEXIMAGEEXTPROC) (Display *dpy, GLXDrawable drawable, int buffer, const int *attrib_list); +typedef void ( *PFNGLXRELEASETEXIMAGEEXTPROC) (Display *dpy, GLXDrawable drawable, int buffer); +#ifdef GLX_GLXEXT_PROTOTYPES +void glXBindTexImageEXT (Display *dpy, GLXDrawable drawable, int buffer, const int *attrib_list); +void glXReleaseTexImageEXT (Display *dpy, GLXDrawable drawable, int buffer); +#endif +#endif /* GLX_EXT_texture_from_pixmap */ + +#ifndef GLX_EXT_visual_info +#define GLX_EXT_visual_info 1 +#define GLX_X_VISUAL_TYPE_EXT 0x22 +#define GLX_TRANSPARENT_TYPE_EXT 0x23 +#define GLX_TRANSPARENT_INDEX_VALUE_EXT 0x24 +#define GLX_TRANSPARENT_RED_VALUE_EXT 0x25 +#define GLX_TRANSPARENT_GREEN_VALUE_EXT 0x26 +#define GLX_TRANSPARENT_BLUE_VALUE_EXT 0x27 +#define GLX_TRANSPARENT_ALPHA_VALUE_EXT 0x28 +#define GLX_NONE_EXT 0x8000 +#define GLX_TRUE_COLOR_EXT 0x8002 +#define GLX_DIRECT_COLOR_EXT 0x8003 +#define GLX_PSEUDO_COLOR_EXT 0x8004 +#define GLX_STATIC_COLOR_EXT 0x8005 +#define GLX_GRAY_SCALE_EXT 0x8006 +#define GLX_STATIC_GRAY_EXT 0x8007 +#define GLX_TRANSPARENT_RGB_EXT 0x8008 +#define GLX_TRANSPARENT_INDEX_EXT 0x8009 +#endif /* GLX_EXT_visual_info */ + +#ifndef GLX_EXT_visual_rating +#define GLX_EXT_visual_rating 1 +#define GLX_VISUAL_CAVEAT_EXT 0x20 +#define GLX_SLOW_VISUAL_EXT 0x8001 +#define GLX_NON_CONFORMANT_VISUAL_EXT 0x800D +#endif /* GLX_EXT_visual_rating */ + +#ifndef GLX_INTEL_swap_event +#define GLX_INTEL_swap_event 1 +#define GLX_BUFFER_SWAP_COMPLETE_INTEL_MASK 0x04000000 +#define GLX_EXCHANGE_COMPLETE_INTEL 0x8180 +#define GLX_COPY_COMPLETE_INTEL 0x8181 +#define GLX_FLIP_COMPLETE_INTEL 0x8182 +#endif /* GLX_INTEL_swap_event */ + +#ifndef GLX_MESA_agp_offset +#define GLX_MESA_agp_offset 1 +typedef unsigned int ( *PFNGLXGETAGPOFFSETMESAPROC) (const void *pointer); +#ifdef GLX_GLXEXT_PROTOTYPES +unsigned int glXGetAGPOffsetMESA (const void *pointer); +#endif +#endif /* GLX_MESA_agp_offset */ + +#ifndef GLX_MESA_copy_sub_buffer +#define GLX_MESA_copy_sub_buffer 1 +typedef void ( *PFNGLXCOPYSUBBUFFERMESAPROC) (Display *dpy, GLXDrawable drawable, int x, int y, int width, int height); +#ifdef GLX_GLXEXT_PROTOTYPES +void glXCopySubBufferMESA (Display *dpy, GLXDrawable drawable, int x, int y, int width, int height); +#endif +#endif /* GLX_MESA_copy_sub_buffer */ + +#ifndef GLX_MESA_pixmap_colormap +#define GLX_MESA_pixmap_colormap 1 +typedef GLXPixmap ( *PFNGLXCREATEGLXPIXMAPMESAPROC) (Display *dpy, XVisualInfo *visual, Pixmap pixmap, Colormap cmap); +#ifdef GLX_GLXEXT_PROTOTYPES +GLXPixmap glXCreateGLXPixmapMESA (Display *dpy, XVisualInfo *visual, Pixmap pixmap, Colormap cmap); +#endif +#endif /* GLX_MESA_pixmap_colormap */ + +#ifndef GLX_MESA_query_renderer +#define GLX_MESA_query_renderer 1 +#define GLX_RENDERER_VENDOR_ID_MESA 0x8183 +#define GLX_RENDERER_DEVICE_ID_MESA 0x8184 +#define GLX_RENDERER_VERSION_MESA 0x8185 +#define GLX_RENDERER_ACCELERATED_MESA 0x8186 +#define GLX_RENDERER_VIDEO_MEMORY_MESA 0x8187 +#define GLX_RENDERER_UNIFIED_MEMORY_ARCHITECTURE_MESA 0x8188 +#define GLX_RENDERER_PREFERRED_PROFILE_MESA 0x8189 +#define GLX_RENDERER_OPENGL_CORE_PROFILE_VERSION_MESA 0x818A +#define GLX_RENDERER_OPENGL_COMPATIBILITY_PROFILE_VERSION_MESA 0x818B +#define GLX_RENDERER_OPENGL_ES_PROFILE_VERSION_MESA 0x818C +#define GLX_RENDERER_OPENGL_ES2_PROFILE_VERSION_MESA 0x818D +typedef Bool ( *PFNGLXQUERYCURRENTRENDERERINTEGERMESAPROC) (int attribute, unsigned int *value); +typedef const char *( *PFNGLXQUERYCURRENTRENDERERSTRINGMESAPROC) (int attribute); +typedef Bool ( *PFNGLXQUERYRENDERERINTEGERMESAPROC) (Display *dpy, int screen, int renderer, int attribute, unsigned int *value); +typedef const char *( *PFNGLXQUERYRENDERERSTRINGMESAPROC) (Display *dpy, int screen, int renderer, int attribute); +#ifdef GLX_GLXEXT_PROTOTYPES +Bool glXQueryCurrentRendererIntegerMESA (int attribute, unsigned int *value); +const char *glXQueryCurrentRendererStringMESA (int attribute); +Bool glXQueryRendererIntegerMESA (Display *dpy, int screen, int renderer, int attribute, unsigned int *value); +const char *glXQueryRendererStringMESA (Display *dpy, int screen, int renderer, int attribute); +#endif +#endif /* GLX_MESA_query_renderer */ + +#ifndef GLX_MESA_release_buffers +#define GLX_MESA_release_buffers 1 +typedef Bool ( *PFNGLXRELEASEBUFFERSMESAPROC) (Display *dpy, GLXDrawable drawable); +#ifdef GLX_GLXEXT_PROTOTYPES +Bool glXReleaseBuffersMESA (Display *dpy, GLXDrawable drawable); +#endif +#endif /* GLX_MESA_release_buffers */ + +#ifndef GLX_MESA_set_3dfx_mode +#define GLX_MESA_set_3dfx_mode 1 +#define GLX_3DFX_WINDOW_MODE_MESA 0x1 +#define GLX_3DFX_FULLSCREEN_MODE_MESA 0x2 +typedef GLboolean ( *PFNGLXSET3DFXMODEMESAPROC) (GLint mode); +#ifdef GLX_GLXEXT_PROTOTYPES +GLboolean glXSet3DfxModeMESA (GLint mode); +#endif +#endif /* GLX_MESA_set_3dfx_mode */ + +#ifndef GLX_MESA_swap_control +#define GLX_MESA_swap_control 1 +typedef int ( *PFNGLXGETSWAPINTERVALMESAPROC) (void); +typedef int ( *PFNGLXSWAPINTERVALMESAPROC) (unsigned int interval); +#ifdef GLX_GLXEXT_PROTOTYPES +int glXGetSwapIntervalMESA (void); +int glXSwapIntervalMESA (unsigned int interval); +#endif +#endif /* GLX_MESA_swap_control */ + +#ifndef GLX_NV_copy_buffer +#define GLX_NV_copy_buffer 1 +typedef void ( *PFNGLXCOPYBUFFERSUBDATANVPROC) (Display *dpy, GLXContext readCtx, GLXContext writeCtx, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +typedef void ( *PFNGLXNAMEDCOPYBUFFERSUBDATANVPROC) (Display *dpy, GLXContext readCtx, GLXContext writeCtx, GLuint readBuffer, GLuint writeBuffer, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +#ifdef GLX_GLXEXT_PROTOTYPES +void glXCopyBufferSubDataNV (Display *dpy, GLXContext readCtx, GLXContext writeCtx, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +void glXNamedCopyBufferSubDataNV (Display *dpy, GLXContext readCtx, GLXContext writeCtx, GLuint readBuffer, GLuint writeBuffer, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size); +#endif +#endif /* GLX_NV_copy_buffer */ + +#ifndef GLX_NV_copy_image +#define GLX_NV_copy_image 1 +typedef void ( *PFNGLXCOPYIMAGESUBDATANVPROC) (Display *dpy, GLXContext srcCtx, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLXContext dstCtx, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei width, GLsizei height, GLsizei depth); +#ifdef GLX_GLXEXT_PROTOTYPES +void glXCopyImageSubDataNV (Display *dpy, GLXContext srcCtx, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLXContext dstCtx, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei width, GLsizei height, GLsizei depth); +#endif +#endif /* GLX_NV_copy_image */ + +#ifndef GLX_NV_delay_before_swap +#define GLX_NV_delay_before_swap 1 +typedef Bool ( *PFNGLXDELAYBEFORESWAPNVPROC) (Display *dpy, GLXDrawable drawable, GLfloat seconds); +#ifdef GLX_GLXEXT_PROTOTYPES +Bool glXDelayBeforeSwapNV (Display *dpy, GLXDrawable drawable, GLfloat seconds); +#endif +#endif /* GLX_NV_delay_before_swap */ + +#ifndef GLX_NV_float_buffer +#define GLX_NV_float_buffer 1 +#define GLX_FLOAT_COMPONENTS_NV 0x20B0 +#endif /* GLX_NV_float_buffer */ + +#ifndef GLX_NV_multigpu_context +#define GLX_NV_multigpu_context 1 +#define GLX_CONTEXT_MULTIGPU_ATTRIB_NV 0x20AA +#define GLX_CONTEXT_MULTIGPU_ATTRIB_SINGLE_NV 0x20AB +#define GLX_CONTEXT_MULTIGPU_ATTRIB_AFR_NV 0x20AC +#define GLX_CONTEXT_MULTIGPU_ATTRIB_MULTICAST_NV 0x20AD +#define GLX_CONTEXT_MULTIGPU_ATTRIB_MULTI_DISPLAY_MULTICAST_NV 0x20AE +#endif /* GLX_NV_multigpu_context */ + +#ifndef GLX_NV_multisample_coverage +#define GLX_NV_multisample_coverage 1 +#define GLX_COVERAGE_SAMPLES_NV 100001 +#define GLX_COLOR_SAMPLES_NV 0x20B3 +#endif /* GLX_NV_multisample_coverage */ + +#ifndef GLX_NV_present_video +#define GLX_NV_present_video 1 +#define GLX_NUM_VIDEO_SLOTS_NV 0x20F0 +typedef unsigned int *( *PFNGLXENUMERATEVIDEODEVICESNVPROC) (Display *dpy, int screen, int *nelements); +typedef int ( *PFNGLXBINDVIDEODEVICENVPROC) (Display *dpy, unsigned int video_slot, unsigned int video_device, const int *attrib_list); +#ifdef GLX_GLXEXT_PROTOTYPES +unsigned int *glXEnumerateVideoDevicesNV (Display *dpy, int screen, int *nelements); +int glXBindVideoDeviceNV (Display *dpy, unsigned int video_slot, unsigned int video_device, const int *attrib_list); +#endif +#endif /* GLX_NV_present_video */ + +#ifndef GLX_NV_robustness_video_memory_purge +#define GLX_NV_robustness_video_memory_purge 1 +#define GLX_GENERATE_RESET_ON_VIDEO_MEMORY_PURGE_NV 0x20F7 +#endif /* GLX_NV_robustness_video_memory_purge */ + +#ifndef GLX_NV_swap_group +#define GLX_NV_swap_group 1 +typedef Bool ( *PFNGLXJOINSWAPGROUPNVPROC) (Display *dpy, GLXDrawable drawable, GLuint group); +typedef Bool ( *PFNGLXBINDSWAPBARRIERNVPROC) (Display *dpy, GLuint group, GLuint barrier); +typedef Bool ( *PFNGLXQUERYSWAPGROUPNVPROC) (Display *dpy, GLXDrawable drawable, GLuint *group, GLuint *barrier); +typedef Bool ( *PFNGLXQUERYMAXSWAPGROUPSNVPROC) (Display *dpy, int screen, GLuint *maxGroups, GLuint *maxBarriers); +typedef Bool ( *PFNGLXQUERYFRAMECOUNTNVPROC) (Display *dpy, int screen, GLuint *count); +typedef Bool ( *PFNGLXRESETFRAMECOUNTNVPROC) (Display *dpy, int screen); +#ifdef GLX_GLXEXT_PROTOTYPES +Bool glXJoinSwapGroupNV (Display *dpy, GLXDrawable drawable, GLuint group); +Bool glXBindSwapBarrierNV (Display *dpy, GLuint group, GLuint barrier); +Bool glXQuerySwapGroupNV (Display *dpy, GLXDrawable drawable, GLuint *group, GLuint *barrier); +Bool glXQueryMaxSwapGroupsNV (Display *dpy, int screen, GLuint *maxGroups, GLuint *maxBarriers); +Bool glXQueryFrameCountNV (Display *dpy, int screen, GLuint *count); +Bool glXResetFrameCountNV (Display *dpy, int screen); +#endif +#endif /* GLX_NV_swap_group */ + +#ifndef GLX_NV_video_capture +#define GLX_NV_video_capture 1 +typedef XID GLXVideoCaptureDeviceNV; +#define GLX_DEVICE_ID_NV 0x20CD +#define GLX_UNIQUE_ID_NV 0x20CE +#define GLX_NUM_VIDEO_CAPTURE_SLOTS_NV 0x20CF +typedef int ( *PFNGLXBINDVIDEOCAPTUREDEVICENVPROC) (Display *dpy, unsigned int video_capture_slot, GLXVideoCaptureDeviceNV device); +typedef GLXVideoCaptureDeviceNV *( *PFNGLXENUMERATEVIDEOCAPTUREDEVICESNVPROC) (Display *dpy, int screen, int *nelements); +typedef void ( *PFNGLXLOCKVIDEOCAPTUREDEVICENVPROC) (Display *dpy, GLXVideoCaptureDeviceNV device); +typedef int ( *PFNGLXQUERYVIDEOCAPTUREDEVICENVPROC) (Display *dpy, GLXVideoCaptureDeviceNV device, int attribute, int *value); +typedef void ( *PFNGLXRELEASEVIDEOCAPTUREDEVICENVPROC) (Display *dpy, GLXVideoCaptureDeviceNV device); +#ifdef GLX_GLXEXT_PROTOTYPES +int glXBindVideoCaptureDeviceNV (Display *dpy, unsigned int video_capture_slot, GLXVideoCaptureDeviceNV device); +GLXVideoCaptureDeviceNV *glXEnumerateVideoCaptureDevicesNV (Display *dpy, int screen, int *nelements); +void glXLockVideoCaptureDeviceNV (Display *dpy, GLXVideoCaptureDeviceNV device); +int glXQueryVideoCaptureDeviceNV (Display *dpy, GLXVideoCaptureDeviceNV device, int attribute, int *value); +void glXReleaseVideoCaptureDeviceNV (Display *dpy, GLXVideoCaptureDeviceNV device); +#endif +#endif /* GLX_NV_video_capture */ + +#ifndef GLX_NV_video_out +#define GLX_NV_video_out 1 +typedef unsigned int GLXVideoDeviceNV; +#define GLX_VIDEO_OUT_COLOR_NV 0x20C3 +#define GLX_VIDEO_OUT_ALPHA_NV 0x20C4 +#define GLX_VIDEO_OUT_DEPTH_NV 0x20C5 +#define GLX_VIDEO_OUT_COLOR_AND_ALPHA_NV 0x20C6 +#define GLX_VIDEO_OUT_COLOR_AND_DEPTH_NV 0x20C7 +#define GLX_VIDEO_OUT_FRAME_NV 0x20C8 +#define GLX_VIDEO_OUT_FIELD_1_NV 0x20C9 +#define GLX_VIDEO_OUT_FIELD_2_NV 0x20CA +#define GLX_VIDEO_OUT_STACKED_FIELDS_1_2_NV 0x20CB +#define GLX_VIDEO_OUT_STACKED_FIELDS_2_1_NV 0x20CC +typedef int ( *PFNGLXGETVIDEODEVICENVPROC) (Display *dpy, int screen, int numVideoDevices, GLXVideoDeviceNV *pVideoDevice); +typedef int ( *PFNGLXRELEASEVIDEODEVICENVPROC) (Display *dpy, int screen, GLXVideoDeviceNV VideoDevice); +typedef int ( *PFNGLXBINDVIDEOIMAGENVPROC) (Display *dpy, GLXVideoDeviceNV VideoDevice, GLXPbuffer pbuf, int iVideoBuffer); +typedef int ( *PFNGLXRELEASEVIDEOIMAGENVPROC) (Display *dpy, GLXPbuffer pbuf); +typedef int ( *PFNGLXSENDPBUFFERTOVIDEONVPROC) (Display *dpy, GLXPbuffer pbuf, int iBufferType, unsigned long *pulCounterPbuffer, GLboolean bBlock); +typedef int ( *PFNGLXGETVIDEOINFONVPROC) (Display *dpy, int screen, GLXVideoDeviceNV VideoDevice, unsigned long *pulCounterOutputPbuffer, unsigned long *pulCounterOutputVideo); +#ifdef GLX_GLXEXT_PROTOTYPES +int glXGetVideoDeviceNV (Display *dpy, int screen, int numVideoDevices, GLXVideoDeviceNV *pVideoDevice); +int glXReleaseVideoDeviceNV (Display *dpy, int screen, GLXVideoDeviceNV VideoDevice); +int glXBindVideoImageNV (Display *dpy, GLXVideoDeviceNV VideoDevice, GLXPbuffer pbuf, int iVideoBuffer); +int glXReleaseVideoImageNV (Display *dpy, GLXPbuffer pbuf); +int glXSendPbufferToVideoNV (Display *dpy, GLXPbuffer pbuf, int iBufferType, unsigned long *pulCounterPbuffer, GLboolean bBlock); +int glXGetVideoInfoNV (Display *dpy, int screen, GLXVideoDeviceNV VideoDevice, unsigned long *pulCounterOutputPbuffer, unsigned long *pulCounterOutputVideo); +#endif +#endif /* GLX_NV_video_out */ + +#ifndef GLX_OML_swap_method +#define GLX_OML_swap_method 1 +#define GLX_SWAP_METHOD_OML 0x8060 +#define GLX_SWAP_EXCHANGE_OML 0x8061 +#define GLX_SWAP_COPY_OML 0x8062 +#define GLX_SWAP_UNDEFINED_OML 0x8063 +#endif /* GLX_OML_swap_method */ + +#ifndef GLX_OML_sync_control +#define GLX_OML_sync_control 1 +#ifndef GLEXT_64_TYPES_DEFINED +/* This code block is duplicated in glext.h, so must be protected */ +#define GLEXT_64_TYPES_DEFINED +/* Define int32_t, int64_t, and uint64_t types for UST/MSC */ +/* (as used in the GLX_OML_sync_control extension). */ +#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L +#include +#elif defined(__sun__) || defined(__digital__) +#include +#if defined(__STDC__) +#if defined(__arch64__) || defined(_LP64) +typedef long int int64_t; +typedef unsigned long int uint64_t; +#else +typedef long long int int64_t; +typedef unsigned long long int uint64_t; +#endif /* __arch64__ */ +#endif /* __STDC__ */ +#elif defined( __VMS ) || defined(__sgi) +#include +#elif defined(__SCO__) || defined(__USLC__) +#include +#elif defined(__UNIXOS2__) || defined(__SOL64__) +typedef long int int32_t; +typedef long long int int64_t; +typedef unsigned long long int uint64_t; +#elif defined(_WIN32) && defined(__GNUC__) +#include +#elif defined(_WIN32) +typedef __int32 int32_t; +typedef __int64 int64_t; +typedef unsigned __int64 uint64_t; +#else +/* Fallback if nothing above works */ +#include +#endif +#endif +typedef Bool ( *PFNGLXGETSYNCVALUESOMLPROC) (Display *dpy, GLXDrawable drawable, int64_t *ust, int64_t *msc, int64_t *sbc); +typedef Bool ( *PFNGLXGETMSCRATEOMLPROC) (Display *dpy, GLXDrawable drawable, int32_t *numerator, int32_t *denominator); +typedef int64_t ( *PFNGLXSWAPBUFFERSMSCOMLPROC) (Display *dpy, GLXDrawable drawable, int64_t target_msc, int64_t divisor, int64_t remainder); +typedef Bool ( *PFNGLXWAITFORMSCOMLPROC) (Display *dpy, GLXDrawable drawable, int64_t target_msc, int64_t divisor, int64_t remainder, int64_t *ust, int64_t *msc, int64_t *sbc); +typedef Bool ( *PFNGLXWAITFORSBCOMLPROC) (Display *dpy, GLXDrawable drawable, int64_t target_sbc, int64_t *ust, int64_t *msc, int64_t *sbc); +#ifdef GLX_GLXEXT_PROTOTYPES +Bool glXGetSyncValuesOML (Display *dpy, GLXDrawable drawable, int64_t *ust, int64_t *msc, int64_t *sbc); +Bool glXGetMscRateOML (Display *dpy, GLXDrawable drawable, int32_t *numerator, int32_t *denominator); +int64_t glXSwapBuffersMscOML (Display *dpy, GLXDrawable drawable, int64_t target_msc, int64_t divisor, int64_t remainder); +Bool glXWaitForMscOML (Display *dpy, GLXDrawable drawable, int64_t target_msc, int64_t divisor, int64_t remainder, int64_t *ust, int64_t *msc, int64_t *sbc); +Bool glXWaitForSbcOML (Display *dpy, GLXDrawable drawable, int64_t target_sbc, int64_t *ust, int64_t *msc, int64_t *sbc); +#endif +#endif /* GLX_OML_sync_control */ + +#ifndef GLX_SGIS_blended_overlay +#define GLX_SGIS_blended_overlay 1 +#define GLX_BLENDED_RGBA_SGIS 0x8025 +#endif /* GLX_SGIS_blended_overlay */ + +#ifndef GLX_SGIS_multisample +#define GLX_SGIS_multisample 1 +#define GLX_SAMPLE_BUFFERS_SGIS 100000 +#define GLX_SAMPLES_SGIS 100001 +#endif /* GLX_SGIS_multisample */ + +#ifndef GLX_SGIS_shared_multisample +#define GLX_SGIS_shared_multisample 1 +#define GLX_MULTISAMPLE_SUB_RECT_WIDTH_SGIS 0x8026 +#define GLX_MULTISAMPLE_SUB_RECT_HEIGHT_SGIS 0x8027 +#endif /* GLX_SGIS_shared_multisample */ + +#ifndef GLX_SGIX_dmbuffer +#define GLX_SGIX_dmbuffer 1 +typedef XID GLXPbufferSGIX; +#ifdef _DM_BUFFER_H_ +#define GLX_DIGITAL_MEDIA_PBUFFER_SGIX 0x8024 +typedef Bool ( *PFNGLXASSOCIATEDMPBUFFERSGIXPROC) (Display *dpy, GLXPbufferSGIX pbuffer, DMparams *params, DMbuffer dmbuffer); +#ifdef GLX_GLXEXT_PROTOTYPES +Bool glXAssociateDMPbufferSGIX (Display *dpy, GLXPbufferSGIX pbuffer, DMparams *params, DMbuffer dmbuffer); +#endif +#endif /* _DM_BUFFER_H_ */ +#endif /* GLX_SGIX_dmbuffer */ + +#ifndef GLX_SGIX_fbconfig +#define GLX_SGIX_fbconfig 1 +typedef struct __GLXFBConfigRec *GLXFBConfigSGIX; +#define GLX_WINDOW_BIT_SGIX 0x00000001 +#define GLX_PIXMAP_BIT_SGIX 0x00000002 +#define GLX_RGBA_BIT_SGIX 0x00000001 +#define GLX_COLOR_INDEX_BIT_SGIX 0x00000002 +#define GLX_DRAWABLE_TYPE_SGIX 0x8010 +#define GLX_RENDER_TYPE_SGIX 0x8011 +#define GLX_X_RENDERABLE_SGIX 0x8012 +#define GLX_FBCONFIG_ID_SGIX 0x8013 +#define GLX_RGBA_TYPE_SGIX 0x8014 +#define GLX_COLOR_INDEX_TYPE_SGIX 0x8015 +typedef int ( *PFNGLXGETFBCONFIGATTRIBSGIXPROC) (Display *dpy, GLXFBConfigSGIX config, int attribute, int *value); +typedef GLXFBConfigSGIX *( *PFNGLXCHOOSEFBCONFIGSGIXPROC) (Display *dpy, int screen, int *attrib_list, int *nelements); +typedef GLXPixmap ( *PFNGLXCREATEGLXPIXMAPWITHCONFIGSGIXPROC) (Display *dpy, GLXFBConfigSGIX config, Pixmap pixmap); +typedef GLXContext ( *PFNGLXCREATECONTEXTWITHCONFIGSGIXPROC) (Display *dpy, GLXFBConfigSGIX config, int render_type, GLXContext share_list, Bool direct); +typedef XVisualInfo *( *PFNGLXGETVISUALFROMFBCONFIGSGIXPROC) (Display *dpy, GLXFBConfigSGIX config); +typedef GLXFBConfigSGIX ( *PFNGLXGETFBCONFIGFROMVISUALSGIXPROC) (Display *dpy, XVisualInfo *vis); +#ifdef GLX_GLXEXT_PROTOTYPES +int glXGetFBConfigAttribSGIX (Display *dpy, GLXFBConfigSGIX config, int attribute, int *value); +GLXFBConfigSGIX *glXChooseFBConfigSGIX (Display *dpy, int screen, int *attrib_list, int *nelements); +GLXPixmap glXCreateGLXPixmapWithConfigSGIX (Display *dpy, GLXFBConfigSGIX config, Pixmap pixmap); +GLXContext glXCreateContextWithConfigSGIX (Display *dpy, GLXFBConfigSGIX config, int render_type, GLXContext share_list, Bool direct); +XVisualInfo *glXGetVisualFromFBConfigSGIX (Display *dpy, GLXFBConfigSGIX config); +GLXFBConfigSGIX glXGetFBConfigFromVisualSGIX (Display *dpy, XVisualInfo *vis); +#endif +#endif /* GLX_SGIX_fbconfig */ + +#ifndef GLX_SGIX_hyperpipe +#define GLX_SGIX_hyperpipe 1 +typedef struct { + char pipeName[80]; /* Should be [GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX] */ + int networkId; +} GLXHyperpipeNetworkSGIX; +typedef struct { + char pipeName[80]; /* Should be [GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX] */ + int channel; + unsigned int participationType; + int timeSlice; +} GLXHyperpipeConfigSGIX; +typedef struct { + char pipeName[80]; /* Should be [GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX] */ + int srcXOrigin, srcYOrigin, srcWidth, srcHeight; + int destXOrigin, destYOrigin, destWidth, destHeight; +} GLXPipeRect; +typedef struct { + char pipeName[80]; /* Should be [GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX] */ + int XOrigin, YOrigin, maxHeight, maxWidth; +} GLXPipeRectLimits; +#define GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX 80 +#define GLX_BAD_HYPERPIPE_CONFIG_SGIX 91 +#define GLX_BAD_HYPERPIPE_SGIX 92 +#define GLX_HYPERPIPE_DISPLAY_PIPE_SGIX 0x00000001 +#define GLX_HYPERPIPE_RENDER_PIPE_SGIX 0x00000002 +#define GLX_PIPE_RECT_SGIX 0x00000001 +#define GLX_PIPE_RECT_LIMITS_SGIX 0x00000002 +#define GLX_HYPERPIPE_STEREO_SGIX 0x00000003 +#define GLX_HYPERPIPE_PIXEL_AVERAGE_SGIX 0x00000004 +#define GLX_HYPERPIPE_ID_SGIX 0x8030 +typedef GLXHyperpipeNetworkSGIX *( *PFNGLXQUERYHYPERPIPENETWORKSGIXPROC) (Display *dpy, int *npipes); +typedef int ( *PFNGLXHYPERPIPECONFIGSGIXPROC) (Display *dpy, int networkId, int npipes, GLXHyperpipeConfigSGIX *cfg, int *hpId); +typedef GLXHyperpipeConfigSGIX *( *PFNGLXQUERYHYPERPIPECONFIGSGIXPROC) (Display *dpy, int hpId, int *npipes); +typedef int ( *PFNGLXDESTROYHYPERPIPECONFIGSGIXPROC) (Display *dpy, int hpId); +typedef int ( *PFNGLXBINDHYPERPIPESGIXPROC) (Display *dpy, int hpId); +typedef int ( *PFNGLXQUERYHYPERPIPEBESTATTRIBSGIXPROC) (Display *dpy, int timeSlice, int attrib, int size, void *attribList, void *returnAttribList); +typedef int ( *PFNGLXHYPERPIPEATTRIBSGIXPROC) (Display *dpy, int timeSlice, int attrib, int size, void *attribList); +typedef int ( *PFNGLXQUERYHYPERPIPEATTRIBSGIXPROC) (Display *dpy, int timeSlice, int attrib, int size, void *returnAttribList); +#ifdef GLX_GLXEXT_PROTOTYPES +GLXHyperpipeNetworkSGIX *glXQueryHyperpipeNetworkSGIX (Display *dpy, int *npipes); +int glXHyperpipeConfigSGIX (Display *dpy, int networkId, int npipes, GLXHyperpipeConfigSGIX *cfg, int *hpId); +GLXHyperpipeConfigSGIX *glXQueryHyperpipeConfigSGIX (Display *dpy, int hpId, int *npipes); +int glXDestroyHyperpipeConfigSGIX (Display *dpy, int hpId); +int glXBindHyperpipeSGIX (Display *dpy, int hpId); +int glXQueryHyperpipeBestAttribSGIX (Display *dpy, int timeSlice, int attrib, int size, void *attribList, void *returnAttribList); +int glXHyperpipeAttribSGIX (Display *dpy, int timeSlice, int attrib, int size, void *attribList); +int glXQueryHyperpipeAttribSGIX (Display *dpy, int timeSlice, int attrib, int size, void *returnAttribList); +#endif +#endif /* GLX_SGIX_hyperpipe */ + +#ifndef GLX_SGIX_pbuffer +#define GLX_SGIX_pbuffer 1 +#define GLX_PBUFFER_BIT_SGIX 0x00000004 +#define GLX_BUFFER_CLOBBER_MASK_SGIX 0x08000000 +#define GLX_FRONT_LEFT_BUFFER_BIT_SGIX 0x00000001 +#define GLX_FRONT_RIGHT_BUFFER_BIT_SGIX 0x00000002 +#define GLX_BACK_LEFT_BUFFER_BIT_SGIX 0x00000004 +#define GLX_BACK_RIGHT_BUFFER_BIT_SGIX 0x00000008 +#define GLX_AUX_BUFFERS_BIT_SGIX 0x00000010 +#define GLX_DEPTH_BUFFER_BIT_SGIX 0x00000020 +#define GLX_STENCIL_BUFFER_BIT_SGIX 0x00000040 +#define GLX_ACCUM_BUFFER_BIT_SGIX 0x00000080 +#define GLX_SAMPLE_BUFFERS_BIT_SGIX 0x00000100 +#define GLX_MAX_PBUFFER_WIDTH_SGIX 0x8016 +#define GLX_MAX_PBUFFER_HEIGHT_SGIX 0x8017 +#define GLX_MAX_PBUFFER_PIXELS_SGIX 0x8018 +#define GLX_OPTIMAL_PBUFFER_WIDTH_SGIX 0x8019 +#define GLX_OPTIMAL_PBUFFER_HEIGHT_SGIX 0x801A +#define GLX_PRESERVED_CONTENTS_SGIX 0x801B +#define GLX_LARGEST_PBUFFER_SGIX 0x801C +#define GLX_WIDTH_SGIX 0x801D +#define GLX_HEIGHT_SGIX 0x801E +#define GLX_EVENT_MASK_SGIX 0x801F +#define GLX_DAMAGED_SGIX 0x8020 +#define GLX_SAVED_SGIX 0x8021 +#define GLX_WINDOW_SGIX 0x8022 +#define GLX_PBUFFER_SGIX 0x8023 +typedef GLXPbufferSGIX ( *PFNGLXCREATEGLXPBUFFERSGIXPROC) (Display *dpy, GLXFBConfigSGIX config, unsigned int width, unsigned int height, int *attrib_list); +typedef void ( *PFNGLXDESTROYGLXPBUFFERSGIXPROC) (Display *dpy, GLXPbufferSGIX pbuf); +typedef void ( *PFNGLXQUERYGLXPBUFFERSGIXPROC) (Display *dpy, GLXPbufferSGIX pbuf, int attribute, unsigned int *value); +typedef void ( *PFNGLXSELECTEVENTSGIXPROC) (Display *dpy, GLXDrawable drawable, unsigned long mask); +typedef void ( *PFNGLXGETSELECTEDEVENTSGIXPROC) (Display *dpy, GLXDrawable drawable, unsigned long *mask); +#ifdef GLX_GLXEXT_PROTOTYPES +GLXPbufferSGIX glXCreateGLXPbufferSGIX (Display *dpy, GLXFBConfigSGIX config, unsigned int width, unsigned int height, int *attrib_list); +void glXDestroyGLXPbufferSGIX (Display *dpy, GLXPbufferSGIX pbuf); +void glXQueryGLXPbufferSGIX (Display *dpy, GLXPbufferSGIX pbuf, int attribute, unsigned int *value); +void glXSelectEventSGIX (Display *dpy, GLXDrawable drawable, unsigned long mask); +void glXGetSelectedEventSGIX (Display *dpy, GLXDrawable drawable, unsigned long *mask); +#endif +#endif /* GLX_SGIX_pbuffer */ + +#ifndef GLX_SGIX_swap_barrier +#define GLX_SGIX_swap_barrier 1 +typedef void ( *PFNGLXBINDSWAPBARRIERSGIXPROC) (Display *dpy, GLXDrawable drawable, int barrier); +typedef Bool ( *PFNGLXQUERYMAXSWAPBARRIERSSGIXPROC) (Display *dpy, int screen, int *max); +#ifdef GLX_GLXEXT_PROTOTYPES +void glXBindSwapBarrierSGIX (Display *dpy, GLXDrawable drawable, int barrier); +Bool glXQueryMaxSwapBarriersSGIX (Display *dpy, int screen, int *max); +#endif +#endif /* GLX_SGIX_swap_barrier */ + +#ifndef GLX_SGIX_swap_group +#define GLX_SGIX_swap_group 1 +typedef void ( *PFNGLXJOINSWAPGROUPSGIXPROC) (Display *dpy, GLXDrawable drawable, GLXDrawable member); +#ifdef GLX_GLXEXT_PROTOTYPES +void glXJoinSwapGroupSGIX (Display *dpy, GLXDrawable drawable, GLXDrawable member); +#endif +#endif /* GLX_SGIX_swap_group */ + +#ifndef GLX_SGIX_video_resize +#define GLX_SGIX_video_resize 1 +#define GLX_SYNC_FRAME_SGIX 0x00000000 +#define GLX_SYNC_SWAP_SGIX 0x00000001 +typedef int ( *PFNGLXBINDCHANNELTOWINDOWSGIXPROC) (Display *display, int screen, int channel, Window window); +typedef int ( *PFNGLXCHANNELRECTSGIXPROC) (Display *display, int screen, int channel, int x, int y, int w, int h); +typedef int ( *PFNGLXQUERYCHANNELRECTSGIXPROC) (Display *display, int screen, int channel, int *dx, int *dy, int *dw, int *dh); +typedef int ( *PFNGLXQUERYCHANNELDELTASSGIXPROC) (Display *display, int screen, int channel, int *x, int *y, int *w, int *h); +typedef int ( *PFNGLXCHANNELRECTSYNCSGIXPROC) (Display *display, int screen, int channel, GLenum synctype); +#ifdef GLX_GLXEXT_PROTOTYPES +int glXBindChannelToWindowSGIX (Display *display, int screen, int channel, Window window); +int glXChannelRectSGIX (Display *display, int screen, int channel, int x, int y, int w, int h); +int glXQueryChannelRectSGIX (Display *display, int screen, int channel, int *dx, int *dy, int *dw, int *dh); +int glXQueryChannelDeltasSGIX (Display *display, int screen, int channel, int *x, int *y, int *w, int *h); +int glXChannelRectSyncSGIX (Display *display, int screen, int channel, GLenum synctype); +#endif +#endif /* GLX_SGIX_video_resize */ + +#ifndef GLX_SGIX_video_source +#define GLX_SGIX_video_source 1 +typedef XID GLXVideoSourceSGIX; +#ifdef _VL_H +typedef GLXVideoSourceSGIX ( *PFNGLXCREATEGLXVIDEOSOURCESGIXPROC) (Display *display, int screen, VLServer server, VLPath path, int nodeClass, VLNode drainNode); +typedef void ( *PFNGLXDESTROYGLXVIDEOSOURCESGIXPROC) (Display *dpy, GLXVideoSourceSGIX glxvideosource); +#ifdef GLX_GLXEXT_PROTOTYPES +GLXVideoSourceSGIX glXCreateGLXVideoSourceSGIX (Display *display, int screen, VLServer server, VLPath path, int nodeClass, VLNode drainNode); +void glXDestroyGLXVideoSourceSGIX (Display *dpy, GLXVideoSourceSGIX glxvideosource); +#endif +#endif /* _VL_H */ +#endif /* GLX_SGIX_video_source */ + +#ifndef GLX_SGIX_visual_select_group +#define GLX_SGIX_visual_select_group 1 +#define GLX_VISUAL_SELECT_GROUP_SGIX 0x8028 +#endif /* GLX_SGIX_visual_select_group */ + +#ifndef GLX_SGI_cushion +#define GLX_SGI_cushion 1 +typedef void ( *PFNGLXCUSHIONSGIPROC) (Display *dpy, Window window, float cushion); +#ifdef GLX_GLXEXT_PROTOTYPES +void glXCushionSGI (Display *dpy, Window window, float cushion); +#endif +#endif /* GLX_SGI_cushion */ + +#ifndef GLX_SGI_make_current_read +#define GLX_SGI_make_current_read 1 +typedef Bool ( *PFNGLXMAKECURRENTREADSGIPROC) (Display *dpy, GLXDrawable draw, GLXDrawable read, GLXContext ctx); +typedef GLXDrawable ( *PFNGLXGETCURRENTREADDRAWABLESGIPROC) (void); +#ifdef GLX_GLXEXT_PROTOTYPES +Bool glXMakeCurrentReadSGI (Display *dpy, GLXDrawable draw, GLXDrawable read, GLXContext ctx); +GLXDrawable glXGetCurrentReadDrawableSGI (void); +#endif +#endif /* GLX_SGI_make_current_read */ + +#ifndef GLX_SGI_swap_control +#define GLX_SGI_swap_control 1 +typedef int ( *PFNGLXSWAPINTERVALSGIPROC) (int interval); +#ifdef GLX_GLXEXT_PROTOTYPES +int glXSwapIntervalSGI (int interval); +#endif +#endif /* GLX_SGI_swap_control */ + +#ifndef GLX_SGI_video_sync +#define GLX_SGI_video_sync 1 +typedef int ( *PFNGLXGETVIDEOSYNCSGIPROC) (unsigned int *count); +typedef int ( *PFNGLXWAITVIDEOSYNCSGIPROC) (int divisor, int remainder, unsigned int *count); +#ifdef GLX_GLXEXT_PROTOTYPES +int glXGetVideoSyncSGI (unsigned int *count); +int glXWaitVideoSyncSGI (int divisor, int remainder, unsigned int *count); +#endif +#endif /* GLX_SGI_video_sync */ + +#ifndef GLX_SUN_get_transparent_index +#define GLX_SUN_get_transparent_index 1 +typedef Status ( *PFNGLXGETTRANSPARENTINDEXSUNPROC) (Display *dpy, Window overlay, Window underlay, unsigned long *pTransparentIndex); +#ifdef GLX_GLXEXT_PROTOTYPES +Status glXGetTransparentIndexSUN (Display *dpy, Window overlay, Window underlay, unsigned long *pTransparentIndex); +#endif +#endif /* GLX_SUN_get_transparent_index */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/KHR/khrplatform.h b/gfx/angle/checkout/include/KHR/khrplatform.h new file mode 100644 index 0000000000..dd22d92701 --- /dev/null +++ b/gfx/angle/checkout/include/KHR/khrplatform.h @@ -0,0 +1,290 @@ +#ifndef __khrplatform_h_ +#define __khrplatform_h_ + +/* +** Copyright (c) 2008-2018 The Khronos Group Inc. +** +** Permission is hereby granted, free of charge, to any person obtaining a +** copy of this software and/or associated documentation files (the +** "Materials"), to deal in the Materials without restriction, including +** without limitation the rights to use, copy, modify, merge, publish, +** distribute, sublicense, and/or sell copies of the Materials, and to +** permit persons to whom the Materials are furnished to do so, subject to +** the following conditions: +** +** The above copyright notice and this permission notice shall be included +** in all copies or substantial portions of the Materials. +** +** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. +*/ + +/* Khronos platform-specific types and definitions. + * + * The master copy of khrplatform.h is maintained in the Khronos EGL + * Registry repository at https://github.com/KhronosGroup/EGL-Registry + * The last semantic modification to khrplatform.h was at commit ID: + * 67a3e0864c2d75ea5287b9f3d2eb74a745936692 + * + * Adopters may modify this file to suit their platform. Adopters are + * encouraged to submit platform specific modifications to the Khronos + * group so that they can be included in future versions of this file. + * Please submit changes by filing pull requests or issues on + * the EGL Registry repository linked above. + * + * + * See the Implementer's Guidelines for information about where this file + * should be located on your system and for more details of its use: + * http://www.khronos.org/registry/implementers_guide.pdf + * + * This file should be included as + * #include + * by Khronos client API header files that use its types and defines. + * + * The types in khrplatform.h should only be used to define API-specific types. + * + * Types defined in khrplatform.h: + * khronos_int8_t signed 8 bit + * khronos_uint8_t unsigned 8 bit + * khronos_int16_t signed 16 bit + * khronos_uint16_t unsigned 16 bit + * khronos_int32_t signed 32 bit + * khronos_uint32_t unsigned 32 bit + * khronos_int64_t signed 64 bit + * khronos_uint64_t unsigned 64 bit + * khronos_intptr_t signed same number of bits as a pointer + * khronos_uintptr_t unsigned same number of bits as a pointer + * khronos_ssize_t signed size + * khronos_usize_t unsigned size + * khronos_float_t signed 32 bit floating point + * khronos_time_ns_t unsigned 64 bit time in nanoseconds + * khronos_utime_nanoseconds_t unsigned time interval or absolute time in + * nanoseconds + * khronos_stime_nanoseconds_t signed time interval in nanoseconds + * khronos_boolean_enum_t enumerated boolean type. This should + * only be used as a base type when a client API's boolean type is + * an enum. Client APIs which use an integer or other type for + * booleans cannot use this as the base type for their boolean. + * + * Tokens defined in khrplatform.h: + * + * KHRONOS_FALSE, KHRONOS_TRUE Enumerated boolean false/true values. + * + * KHRONOS_SUPPORT_INT64 is 1 if 64 bit integers are supported; otherwise 0. + * KHRONOS_SUPPORT_FLOAT is 1 if floats are supported; otherwise 0. + * + * Calling convention macros defined in this file: + * KHRONOS_APICALL + * KHRONOS_APIENTRY + * KHRONOS_APIATTRIBUTES + * + * These may be used in function prototypes as: + * + * KHRONOS_APICALL void KHRONOS_APIENTRY funcname( + * int arg1, + * int arg2) KHRONOS_APIATTRIBUTES; + */ + +#if defined(__SCITECH_SNAP__) && !defined(KHRONOS_STATIC) +# define KHRONOS_STATIC 1 +#endif + +/*------------------------------------------------------------------------- + * Definition of KHRONOS_APICALL + *------------------------------------------------------------------------- + * This precedes the return type of the function in the function prototype. + */ +#if defined(KHRONOS_STATIC) + /* If the preprocessor constant KHRONOS_STATIC is defined, make the + * header compatible with static linking. */ +# define KHRONOS_APICALL +#elif defined(_WIN32) +# define KHRONOS_APICALL __declspec(dllimport) +#elif defined (__SYMBIAN32__) +# define KHRONOS_APICALL IMPORT_C +#elif defined(__ANDROID__) +# define KHRONOS_APICALL __attribute__((visibility("default"))) +#else +# define KHRONOS_APICALL +#endif + +/*------------------------------------------------------------------------- + * Definition of KHRONOS_APIENTRY + *------------------------------------------------------------------------- + * This follows the return type of the function and precedes the function + * name in the function prototype. + */ +#if defined(_WIN32) && !defined(_WIN32_WCE) && !defined(__SCITECH_SNAP__) + /* Win32 but not WinCE */ +# define KHRONOS_APIENTRY __stdcall +#else +# define KHRONOS_APIENTRY +#endif + +/*------------------------------------------------------------------------- + * Definition of KHRONOS_APIATTRIBUTES + *------------------------------------------------------------------------- + * This follows the closing parenthesis of the function prototype arguments. + */ +#if defined (__ARMCC_2__) +#define KHRONOS_APIATTRIBUTES __softfp +#else +#define KHRONOS_APIATTRIBUTES +#endif + +/*------------------------------------------------------------------------- + * basic type definitions + *-----------------------------------------------------------------------*/ +#if (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) || defined(__GNUC__) || defined(__SCO__) || defined(__USLC__) + + +/* + * Using + */ +#include +typedef int32_t khronos_int32_t; +typedef uint32_t khronos_uint32_t; +typedef int64_t khronos_int64_t; +typedef uint64_t khronos_uint64_t; +#define KHRONOS_SUPPORT_INT64 1 +#define KHRONOS_SUPPORT_FLOAT 1 + +#elif defined(__VMS ) || defined(__sgi) + +/* + * Using + */ +#include +typedef int32_t khronos_int32_t; +typedef uint32_t khronos_uint32_t; +typedef int64_t khronos_int64_t; +typedef uint64_t khronos_uint64_t; +#define KHRONOS_SUPPORT_INT64 1 +#define KHRONOS_SUPPORT_FLOAT 1 + +#elif defined(_WIN32) && !defined(__SCITECH_SNAP__) + +/* + * Win32 + */ +typedef __int32 khronos_int32_t; +typedef unsigned __int32 khronos_uint32_t; +typedef __int64 khronos_int64_t; +typedef unsigned __int64 khronos_uint64_t; +#define KHRONOS_SUPPORT_INT64 1 +#define KHRONOS_SUPPORT_FLOAT 1 + +#elif defined(__sun__) || defined(__digital__) + +/* + * Sun or Digital + */ +typedef int khronos_int32_t; +typedef unsigned int khronos_uint32_t; +#if defined(__arch64__) || defined(_LP64) +typedef long int khronos_int64_t; +typedef unsigned long int khronos_uint64_t; +#else +typedef long long int khronos_int64_t; +typedef unsigned long long int khronos_uint64_t; +#endif /* __arch64__ */ +#define KHRONOS_SUPPORT_INT64 1 +#define KHRONOS_SUPPORT_FLOAT 1 + +#elif 0 + +/* + * Hypothetical platform with no float or int64 support + */ +typedef int khronos_int32_t; +typedef unsigned int khronos_uint32_t; +#define KHRONOS_SUPPORT_INT64 0 +#define KHRONOS_SUPPORT_FLOAT 0 + +#else + +/* + * Generic fallback + */ +#include +typedef int32_t khronos_int32_t; +typedef uint32_t khronos_uint32_t; +typedef int64_t khronos_int64_t; +typedef uint64_t khronos_uint64_t; +#define KHRONOS_SUPPORT_INT64 1 +#define KHRONOS_SUPPORT_FLOAT 1 + +#endif + + +/* + * Types that are (so far) the same on all platforms + */ +typedef signed char khronos_int8_t; +typedef unsigned char khronos_uint8_t; +typedef signed short int khronos_int16_t; +typedef unsigned short int khronos_uint16_t; + +/* + * Types that differ between LLP64 and LP64 architectures - in LLP64, + * pointers are 64 bits, but 'long' is still 32 bits. Win64 appears + * to be the only LLP64 architecture in current use. + */ +#ifdef _WIN64 +typedef signed long long int khronos_intptr_t; +typedef unsigned long long int khronos_uintptr_t; +typedef signed long long int khronos_ssize_t; +typedef unsigned long long int khronos_usize_t; +#else +typedef signed long int khronos_intptr_t; +typedef unsigned long int khronos_uintptr_t; +typedef signed long int khronos_ssize_t; +typedef unsigned long int khronos_usize_t; +#endif + +#if KHRONOS_SUPPORT_FLOAT +/* + * Float type + */ +typedef float khronos_float_t; +#endif + +#if KHRONOS_SUPPORT_INT64 +/* Time types + * + * These types can be used to represent a time interval in nanoseconds or + * an absolute Unadjusted System Time. Unadjusted System Time is the number + * of nanoseconds since some arbitrary system event (e.g. since the last + * time the system booted). The Unadjusted System Time is an unsigned + * 64 bit value that wraps back to 0 every 584 years. Time intervals + * may be either signed or unsigned. + */ +typedef khronos_uint64_t khronos_utime_nanoseconds_t; +typedef khronos_int64_t khronos_stime_nanoseconds_t; +#endif + +/* + * Dummy value used to pad enum types to 32 bits. + */ +#ifndef KHRONOS_MAX_ENUM +#define KHRONOS_MAX_ENUM 0x7FFFFFFF +#endif + +/* + * Enumerated boolean type + * + * Values other than zero should be considered to be true. Therefore + * comparisons should not be made against KHRONOS_TRUE. + */ +typedef enum { + KHRONOS_FALSE = 0, + KHRONOS_TRUE = 1, + KHRONOS_BOOLEAN_ENUM_FORCE_SIZE = KHRONOS_MAX_ENUM +} khronos_boolean_enum_t; + +#endif /* __khrplatform_h_ */ diff --git a/gfx/angle/checkout/include/WGL/wgl.h b/gfx/angle/checkout/include/WGL/wgl.h new file mode 100644 index 0000000000..0bae52bdda --- /dev/null +++ b/gfx/angle/checkout/include/WGL/wgl.h @@ -0,0 +1,946 @@ +#ifndef __wgl_wgl_h_ +#define __wgl_wgl_h_ 1 + +#ifdef __cplusplus +extern "C" { +#endif + +/* +** Copyright (c) 2013-2018 The Khronos Group Inc. +** +** Permission is hereby granted, free of charge, to any person obtaining a +** copy of this software and/or associated documentation files (the +** "Materials"), to deal in the Materials without restriction, including +** without limitation the rights to use, copy, modify, merge, publish, +** distribute, sublicense, and/or sell copies of the Materials, and to +** permit persons to whom the Materials are furnished to do so, subject to +** the following conditions: +** +** The above copyright notice and this permission notice shall be included +** in all copies or substantial portions of the Materials. +** +** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. +*/ +/* +** This header is generated from the Khronos OpenGL / OpenGL ES XML +** API Registry. The current version of the Registry, generator scripts +** used to make the header, and the header can be found at +** https://github.com/KhronosGroup/OpenGL-Registry +*/ + +#if defined(_WIN32) && !defined(APIENTRY) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) +#define WIN32_LEAN_AND_MEAN 1 +#include +#endif + +/* Generated on date 20181206 */ + +/* Generated C header for: + * API: wgl + * Versions considered: .* + * Versions emitted: .* + * Default extensions included: wgl + * Additional extensions included: _nomatch_^ + * Extensions removed: _nomatch_^ + */ + +#ifndef WGL_VERSION_1_0 +#define WGL_VERSION_1_0 1 +#define WGL_FONT_LINES 0 +#define WGL_FONT_POLYGONS 1 +#define WGL_SWAP_MAIN_PLANE 0x00000001 +#define WGL_SWAP_OVERLAY1 0x00000002 +#define WGL_SWAP_OVERLAY2 0x00000004 +#define WGL_SWAP_OVERLAY3 0x00000008 +#define WGL_SWAP_OVERLAY4 0x00000010 +#define WGL_SWAP_OVERLAY5 0x00000020 +#define WGL_SWAP_OVERLAY6 0x00000040 +#define WGL_SWAP_OVERLAY7 0x00000080 +#define WGL_SWAP_OVERLAY8 0x00000100 +#define WGL_SWAP_OVERLAY9 0x00000200 +#define WGL_SWAP_OVERLAY10 0x00000400 +#define WGL_SWAP_OVERLAY11 0x00000800 +#define WGL_SWAP_OVERLAY12 0x00001000 +#define WGL_SWAP_OVERLAY13 0x00002000 +#define WGL_SWAP_OVERLAY14 0x00004000 +#define WGL_SWAP_OVERLAY15 0x00008000 +#define WGL_SWAP_UNDERLAY1 0x00010000 +#define WGL_SWAP_UNDERLAY2 0x00020000 +#define WGL_SWAP_UNDERLAY3 0x00040000 +#define WGL_SWAP_UNDERLAY4 0x00080000 +#define WGL_SWAP_UNDERLAY5 0x00100000 +#define WGL_SWAP_UNDERLAY6 0x00200000 +#define WGL_SWAP_UNDERLAY7 0x00400000 +#define WGL_SWAP_UNDERLAY8 0x00800000 +#define WGL_SWAP_UNDERLAY9 0x01000000 +#define WGL_SWAP_UNDERLAY10 0x02000000 +#define WGL_SWAP_UNDERLAY11 0x04000000 +#define WGL_SWAP_UNDERLAY12 0x08000000 +#define WGL_SWAP_UNDERLAY13 0x10000000 +#define WGL_SWAP_UNDERLAY14 0x20000000 +#define WGL_SWAP_UNDERLAY15 0x40000000 +typedef int (WINAPI * PFNCHOOSEPIXELFORMATPROC) (HDC hDc, const PIXELFORMATDESCRIPTOR *pPfd); +typedef int (WINAPI * PFNDESCRIBEPIXELFORMATPROC) (HDC hdc, int ipfd, UINT cjpfd, const PIXELFORMATDESCRIPTOR *ppfd); +typedef UINT (WINAPI * PFNGETENHMETAFILEPIXELFORMATPROC) (HENHMETAFILE hemf, const PIXELFORMATDESCRIPTOR *ppfd); +typedef int (WINAPI * PFNGETPIXELFORMATPROC) (HDC hdc); +typedef BOOL (WINAPI * PFNSETPIXELFORMATPROC) (HDC hdc, int ipfd, const PIXELFORMATDESCRIPTOR *ppfd); +typedef BOOL (WINAPI * PFNSWAPBUFFERSPROC) (HDC hdc); +typedef BOOL (WINAPI * PFNWGLCOPYCONTEXTPROC) (HGLRC hglrcSrc, HGLRC hglrcDst, UINT mask); +typedef HGLRC (WINAPI * PFNWGLCREATECONTEXTPROC) (HDC hDc); +typedef HGLRC (WINAPI * PFNWGLCREATELAYERCONTEXTPROC) (HDC hDc, int level); +typedef BOOL (WINAPI * PFNWGLDELETECONTEXTPROC) (HGLRC oldContext); +typedef BOOL (WINAPI * PFNWGLDESCRIBELAYERPLANEPROC) (HDC hDc, int pixelFormat, int layerPlane, UINT nBytes, const LAYERPLANEDESCRIPTOR *plpd); +typedef HGLRC (WINAPI * PFNWGLGETCURRENTCONTEXTPROC) (void); +typedef HDC (WINAPI * PFNWGLGETCURRENTDCPROC) (void); +typedef int (WINAPI * PFNWGLGETLAYERPALETTEENTRIESPROC) (HDC hdc, int iLayerPlane, int iStart, int cEntries, const COLORREF *pcr); +typedef PROC (WINAPI * PFNWGLGETPROCADDRESSPROC) (LPCSTR lpszProc); +typedef BOOL (WINAPI * PFNWGLMAKECURRENTPROC) (HDC hDc, HGLRC newContext); +typedef BOOL (WINAPI * PFNWGLREALIZELAYERPALETTEPROC) (HDC hdc, int iLayerPlane, BOOL bRealize); +typedef int (WINAPI * PFNWGLSETLAYERPALETTEENTRIESPROC) (HDC hdc, int iLayerPlane, int iStart, int cEntries, const COLORREF *pcr); +typedef BOOL (WINAPI * PFNWGLSHARELISTSPROC) (HGLRC hrcSrvShare, HGLRC hrcSrvSource); +typedef BOOL (WINAPI * PFNWGLSWAPLAYERBUFFERSPROC) (HDC hdc, UINT fuFlags); +typedef BOOL (WINAPI * PFNWGLUSEFONTBITMAPSPROC) (HDC hDC, DWORD first, DWORD count, DWORD listBase); +typedef BOOL (WINAPI * PFNWGLUSEFONTBITMAPSAPROC) (HDC hDC, DWORD first, DWORD count, DWORD listBase); +typedef BOOL (WINAPI * PFNWGLUSEFONTBITMAPSWPROC) (HDC hDC, DWORD first, DWORD count, DWORD listBase); +typedef BOOL (WINAPI * PFNWGLUSEFONTOUTLINESPROC) (HDC hDC, DWORD first, DWORD count, DWORD listBase, FLOAT deviation, FLOAT extrusion, int format, LPGLYPHMETRICSFLOAT lpgmf); +typedef BOOL (WINAPI * PFNWGLUSEFONTOUTLINESAPROC) (HDC hDC, DWORD first, DWORD count, DWORD listBase, FLOAT deviation, FLOAT extrusion, int format, LPGLYPHMETRICSFLOAT lpgmf); +typedef BOOL (WINAPI * PFNWGLUSEFONTOUTLINESWPROC) (HDC hDC, DWORD first, DWORD count, DWORD listBase, FLOAT deviation, FLOAT extrusion, int format, LPGLYPHMETRICSFLOAT lpgmf); +#ifdef WGL_WGLEXT_PROTOTYPES +int WINAPI ChoosePixelFormat (HDC hDc, const PIXELFORMATDESCRIPTOR *pPfd); +int WINAPI DescribePixelFormat (HDC hdc, int ipfd, UINT cjpfd, const PIXELFORMATDESCRIPTOR *ppfd); +UINT WINAPI GetEnhMetaFilePixelFormat (HENHMETAFILE hemf, const PIXELFORMATDESCRIPTOR *ppfd); +int WINAPI GetPixelFormat (HDC hdc); +BOOL WINAPI SetPixelFormat (HDC hdc, int ipfd, const PIXELFORMATDESCRIPTOR *ppfd); +BOOL WINAPI SwapBuffers (HDC hdc); +BOOL WINAPI wglCopyContext (HGLRC hglrcSrc, HGLRC hglrcDst, UINT mask); +HGLRC WINAPI wglCreateContext (HDC hDc); +HGLRC WINAPI wglCreateLayerContext (HDC hDc, int level); +BOOL WINAPI wglDeleteContext (HGLRC oldContext); +BOOL WINAPI wglDescribeLayerPlane (HDC hDc, int pixelFormat, int layerPlane, UINT nBytes, const LAYERPLANEDESCRIPTOR *plpd); +HGLRC WINAPI wglGetCurrentContext (void); +HDC WINAPI wglGetCurrentDC (void); +int WINAPI wglGetLayerPaletteEntries (HDC hdc, int iLayerPlane, int iStart, int cEntries, const COLORREF *pcr); +PROC WINAPI wglGetProcAddress (LPCSTR lpszProc); +BOOL WINAPI wglMakeCurrent (HDC hDc, HGLRC newContext); +BOOL WINAPI wglRealizeLayerPalette (HDC hdc, int iLayerPlane, BOOL bRealize); +int WINAPI wglSetLayerPaletteEntries (HDC hdc, int iLayerPlane, int iStart, int cEntries, const COLORREF *pcr); +BOOL WINAPI wglShareLists (HGLRC hrcSrvShare, HGLRC hrcSrvSource); +BOOL WINAPI wglSwapLayerBuffers (HDC hdc, UINT fuFlags); +BOOL WINAPI wglUseFontBitmaps (HDC hDC, DWORD first, DWORD count, DWORD listBase); +BOOL WINAPI wglUseFontBitmapsA (HDC hDC, DWORD first, DWORD count, DWORD listBase); +BOOL WINAPI wglUseFontBitmapsW (HDC hDC, DWORD first, DWORD count, DWORD listBase); +BOOL WINAPI wglUseFontOutlines (HDC hDC, DWORD first, DWORD count, DWORD listBase, FLOAT deviation, FLOAT extrusion, int format, LPGLYPHMETRICSFLOAT lpgmf); +BOOL WINAPI wglUseFontOutlinesA (HDC hDC, DWORD first, DWORD count, DWORD listBase, FLOAT deviation, FLOAT extrusion, int format, LPGLYPHMETRICSFLOAT lpgmf); +BOOL WINAPI wglUseFontOutlinesW (HDC hDC, DWORD first, DWORD count, DWORD listBase, FLOAT deviation, FLOAT extrusion, int format, LPGLYPHMETRICSFLOAT lpgmf); +#endif +#endif /* WGL_VERSION_1_0 */ + +#ifndef WGL_ARB_buffer_region +#define WGL_ARB_buffer_region 1 +#define WGL_FRONT_COLOR_BUFFER_BIT_ARB 0x00000001 +#define WGL_BACK_COLOR_BUFFER_BIT_ARB 0x00000002 +#define WGL_DEPTH_BUFFER_BIT_ARB 0x00000004 +#define WGL_STENCIL_BUFFER_BIT_ARB 0x00000008 +typedef HANDLE (WINAPI * PFNWGLCREATEBUFFERREGIONARBPROC) (HDC hDC, int iLayerPlane, UINT uType); +typedef VOID (WINAPI * PFNWGLDELETEBUFFERREGIONARBPROC) (HANDLE hRegion); +typedef BOOL (WINAPI * PFNWGLSAVEBUFFERREGIONARBPROC) (HANDLE hRegion, int x, int y, int width, int height); +typedef BOOL (WINAPI * PFNWGLRESTOREBUFFERREGIONARBPROC) (HANDLE hRegion, int x, int y, int width, int height, int xSrc, int ySrc); +#ifdef WGL_WGLEXT_PROTOTYPES +HANDLE WINAPI wglCreateBufferRegionARB (HDC hDC, int iLayerPlane, UINT uType); +VOID WINAPI wglDeleteBufferRegionARB (HANDLE hRegion); +BOOL WINAPI wglSaveBufferRegionARB (HANDLE hRegion, int x, int y, int width, int height); +BOOL WINAPI wglRestoreBufferRegionARB (HANDLE hRegion, int x, int y, int width, int height, int xSrc, int ySrc); +#endif +#endif /* WGL_ARB_buffer_region */ + +#ifndef WGL_ARB_context_flush_control +#define WGL_ARB_context_flush_control 1 +#define WGL_CONTEXT_RELEASE_BEHAVIOR_ARB 0x2097 +#define WGL_CONTEXT_RELEASE_BEHAVIOR_NONE_ARB 0 +#define WGL_CONTEXT_RELEASE_BEHAVIOR_FLUSH_ARB 0x2098 +#endif /* WGL_ARB_context_flush_control */ + +#ifndef WGL_ARB_create_context +#define WGL_ARB_create_context 1 +#define WGL_CONTEXT_DEBUG_BIT_ARB 0x00000001 +#define WGL_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x00000002 +#define WGL_CONTEXT_MAJOR_VERSION_ARB 0x2091 +#define WGL_CONTEXT_MINOR_VERSION_ARB 0x2092 +#define WGL_CONTEXT_LAYER_PLANE_ARB 0x2093 +#define WGL_CONTEXT_FLAGS_ARB 0x2094 +#define ERROR_INVALID_VERSION_ARB 0x2095 +typedef HGLRC (WINAPI * PFNWGLCREATECONTEXTATTRIBSARBPROC) (HDC hDC, HGLRC hShareContext, const int *attribList); +#ifdef WGL_WGLEXT_PROTOTYPES +HGLRC WINAPI wglCreateContextAttribsARB (HDC hDC, HGLRC hShareContext, const int *attribList); +#endif +#endif /* WGL_ARB_create_context */ + +#ifndef WGL_ARB_create_context_no_error +#define WGL_ARB_create_context_no_error 1 +#define WGL_CONTEXT_OPENGL_NO_ERROR_ARB 0x31B3 +#endif /* WGL_ARB_create_context_no_error */ + +#ifndef WGL_ARB_create_context_profile +#define WGL_ARB_create_context_profile 1 +#define WGL_CONTEXT_PROFILE_MASK_ARB 0x9126 +#define WGL_CONTEXT_CORE_PROFILE_BIT_ARB 0x00000001 +#define WGL_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB 0x00000002 +#define ERROR_INVALID_PROFILE_ARB 0x2096 +#endif /* WGL_ARB_create_context_profile */ + +#ifndef WGL_ARB_create_context_robustness +#define WGL_ARB_create_context_robustness 1 +#define WGL_CONTEXT_ROBUST_ACCESS_BIT_ARB 0x00000004 +#define WGL_LOSE_CONTEXT_ON_RESET_ARB 0x8252 +#define WGL_CONTEXT_RESET_NOTIFICATION_STRATEGY_ARB 0x8256 +#define WGL_NO_RESET_NOTIFICATION_ARB 0x8261 +#endif /* WGL_ARB_create_context_robustness */ + +#ifndef WGL_ARB_extensions_string +#define WGL_ARB_extensions_string 1 +typedef const char *(WINAPI * PFNWGLGETEXTENSIONSSTRINGARBPROC) (HDC hdc); +#ifdef WGL_WGLEXT_PROTOTYPES +const char *WINAPI wglGetExtensionsStringARB (HDC hdc); +#endif +#endif /* WGL_ARB_extensions_string */ + +#ifndef WGL_ARB_framebuffer_sRGB +#define WGL_ARB_framebuffer_sRGB 1 +#define WGL_FRAMEBUFFER_SRGB_CAPABLE_ARB 0x20A9 +#endif /* WGL_ARB_framebuffer_sRGB */ + +#ifndef WGL_ARB_make_current_read +#define WGL_ARB_make_current_read 1 +#define ERROR_INVALID_PIXEL_TYPE_ARB 0x2043 +#define ERROR_INCOMPATIBLE_DEVICE_CONTEXTS_ARB 0x2054 +typedef BOOL (WINAPI * PFNWGLMAKECONTEXTCURRENTARBPROC) (HDC hDrawDC, HDC hReadDC, HGLRC hglrc); +typedef HDC (WINAPI * PFNWGLGETCURRENTREADDCARBPROC) (void); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglMakeContextCurrentARB (HDC hDrawDC, HDC hReadDC, HGLRC hglrc); +HDC WINAPI wglGetCurrentReadDCARB (void); +#endif +#endif /* WGL_ARB_make_current_read */ + +#ifndef WGL_ARB_multisample +#define WGL_ARB_multisample 1 +#define WGL_SAMPLE_BUFFERS_ARB 0x2041 +#define WGL_SAMPLES_ARB 0x2042 +#endif /* WGL_ARB_multisample */ + +#ifndef WGL_ARB_pbuffer +#define WGL_ARB_pbuffer 1 +DECLARE_HANDLE(HPBUFFERARB); +#define WGL_DRAW_TO_PBUFFER_ARB 0x202D +#define WGL_MAX_PBUFFER_PIXELS_ARB 0x202E +#define WGL_MAX_PBUFFER_WIDTH_ARB 0x202F +#define WGL_MAX_PBUFFER_HEIGHT_ARB 0x2030 +#define WGL_PBUFFER_LARGEST_ARB 0x2033 +#define WGL_PBUFFER_WIDTH_ARB 0x2034 +#define WGL_PBUFFER_HEIGHT_ARB 0x2035 +#define WGL_PBUFFER_LOST_ARB 0x2036 +typedef HPBUFFERARB (WINAPI * PFNWGLCREATEPBUFFERARBPROC) (HDC hDC, int iPixelFormat, int iWidth, int iHeight, const int *piAttribList); +typedef HDC (WINAPI * PFNWGLGETPBUFFERDCARBPROC) (HPBUFFERARB hPbuffer); +typedef int (WINAPI * PFNWGLRELEASEPBUFFERDCARBPROC) (HPBUFFERARB hPbuffer, HDC hDC); +typedef BOOL (WINAPI * PFNWGLDESTROYPBUFFERARBPROC) (HPBUFFERARB hPbuffer); +typedef BOOL (WINAPI * PFNWGLQUERYPBUFFERARBPROC) (HPBUFFERARB hPbuffer, int iAttribute, int *piValue); +#ifdef WGL_WGLEXT_PROTOTYPES +HPBUFFERARB WINAPI wglCreatePbufferARB (HDC hDC, int iPixelFormat, int iWidth, int iHeight, const int *piAttribList); +HDC WINAPI wglGetPbufferDCARB (HPBUFFERARB hPbuffer); +int WINAPI wglReleasePbufferDCARB (HPBUFFERARB hPbuffer, HDC hDC); +BOOL WINAPI wglDestroyPbufferARB (HPBUFFERARB hPbuffer); +BOOL WINAPI wglQueryPbufferARB (HPBUFFERARB hPbuffer, int iAttribute, int *piValue); +#endif +#endif /* WGL_ARB_pbuffer */ + +#ifndef WGL_ARB_pixel_format +#define WGL_ARB_pixel_format 1 +#define WGL_NUMBER_PIXEL_FORMATS_ARB 0x2000 +#define WGL_DRAW_TO_WINDOW_ARB 0x2001 +#define WGL_DRAW_TO_BITMAP_ARB 0x2002 +#define WGL_ACCELERATION_ARB 0x2003 +#define WGL_NEED_PALETTE_ARB 0x2004 +#define WGL_NEED_SYSTEM_PALETTE_ARB 0x2005 +#define WGL_SWAP_LAYER_BUFFERS_ARB 0x2006 +#define WGL_SWAP_METHOD_ARB 0x2007 +#define WGL_NUMBER_OVERLAYS_ARB 0x2008 +#define WGL_NUMBER_UNDERLAYS_ARB 0x2009 +#define WGL_TRANSPARENT_ARB 0x200A +#define WGL_TRANSPARENT_RED_VALUE_ARB 0x2037 +#define WGL_TRANSPARENT_GREEN_VALUE_ARB 0x2038 +#define WGL_TRANSPARENT_BLUE_VALUE_ARB 0x2039 +#define WGL_TRANSPARENT_ALPHA_VALUE_ARB 0x203A +#define WGL_TRANSPARENT_INDEX_VALUE_ARB 0x203B +#define WGL_SHARE_DEPTH_ARB 0x200C +#define WGL_SHARE_STENCIL_ARB 0x200D +#define WGL_SHARE_ACCUM_ARB 0x200E +#define WGL_SUPPORT_GDI_ARB 0x200F +#define WGL_SUPPORT_OPENGL_ARB 0x2010 +#define WGL_DOUBLE_BUFFER_ARB 0x2011 +#define WGL_STEREO_ARB 0x2012 +#define WGL_PIXEL_TYPE_ARB 0x2013 +#define WGL_COLOR_BITS_ARB 0x2014 +#define WGL_RED_BITS_ARB 0x2015 +#define WGL_RED_SHIFT_ARB 0x2016 +#define WGL_GREEN_BITS_ARB 0x2017 +#define WGL_GREEN_SHIFT_ARB 0x2018 +#define WGL_BLUE_BITS_ARB 0x2019 +#define WGL_BLUE_SHIFT_ARB 0x201A +#define WGL_ALPHA_BITS_ARB 0x201B +#define WGL_ALPHA_SHIFT_ARB 0x201C +#define WGL_ACCUM_BITS_ARB 0x201D +#define WGL_ACCUM_RED_BITS_ARB 0x201E +#define WGL_ACCUM_GREEN_BITS_ARB 0x201F +#define WGL_ACCUM_BLUE_BITS_ARB 0x2020 +#define WGL_ACCUM_ALPHA_BITS_ARB 0x2021 +#define WGL_DEPTH_BITS_ARB 0x2022 +#define WGL_STENCIL_BITS_ARB 0x2023 +#define WGL_AUX_BUFFERS_ARB 0x2024 +#define WGL_NO_ACCELERATION_ARB 0x2025 +#define WGL_GENERIC_ACCELERATION_ARB 0x2026 +#define WGL_FULL_ACCELERATION_ARB 0x2027 +#define WGL_SWAP_EXCHANGE_ARB 0x2028 +#define WGL_SWAP_COPY_ARB 0x2029 +#define WGL_SWAP_UNDEFINED_ARB 0x202A +#define WGL_TYPE_RGBA_ARB 0x202B +#define WGL_TYPE_COLORINDEX_ARB 0x202C +typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBIVARBPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int *piAttributes, int *piValues); +typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBFVARBPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int *piAttributes, FLOAT *pfValues); +typedef BOOL (WINAPI * PFNWGLCHOOSEPIXELFORMATARBPROC) (HDC hdc, const int *piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglGetPixelFormatAttribivARB (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int *piAttributes, int *piValues); +BOOL WINAPI wglGetPixelFormatAttribfvARB (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int *piAttributes, FLOAT *pfValues); +BOOL WINAPI wglChoosePixelFormatARB (HDC hdc, const int *piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats); +#endif +#endif /* WGL_ARB_pixel_format */ + +#ifndef WGL_ARB_pixel_format_float +#define WGL_ARB_pixel_format_float 1 +#define WGL_TYPE_RGBA_FLOAT_ARB 0x21A0 +#endif /* WGL_ARB_pixel_format_float */ + +#ifndef WGL_ARB_render_texture +#define WGL_ARB_render_texture 1 +#define WGL_BIND_TO_TEXTURE_RGB_ARB 0x2070 +#define WGL_BIND_TO_TEXTURE_RGBA_ARB 0x2071 +#define WGL_TEXTURE_FORMAT_ARB 0x2072 +#define WGL_TEXTURE_TARGET_ARB 0x2073 +#define WGL_MIPMAP_TEXTURE_ARB 0x2074 +#define WGL_TEXTURE_RGB_ARB 0x2075 +#define WGL_TEXTURE_RGBA_ARB 0x2076 +#define WGL_NO_TEXTURE_ARB 0x2077 +#define WGL_TEXTURE_CUBE_MAP_ARB 0x2078 +#define WGL_TEXTURE_1D_ARB 0x2079 +#define WGL_TEXTURE_2D_ARB 0x207A +#define WGL_MIPMAP_LEVEL_ARB 0x207B +#define WGL_CUBE_MAP_FACE_ARB 0x207C +#define WGL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB 0x207D +#define WGL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB 0x207E +#define WGL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB 0x207F +#define WGL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB 0x2080 +#define WGL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB 0x2081 +#define WGL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB 0x2082 +#define WGL_FRONT_LEFT_ARB 0x2083 +#define WGL_FRONT_RIGHT_ARB 0x2084 +#define WGL_BACK_LEFT_ARB 0x2085 +#define WGL_BACK_RIGHT_ARB 0x2086 +#define WGL_AUX0_ARB 0x2087 +#define WGL_AUX1_ARB 0x2088 +#define WGL_AUX2_ARB 0x2089 +#define WGL_AUX3_ARB 0x208A +#define WGL_AUX4_ARB 0x208B +#define WGL_AUX5_ARB 0x208C +#define WGL_AUX6_ARB 0x208D +#define WGL_AUX7_ARB 0x208E +#define WGL_AUX8_ARB 0x208F +#define WGL_AUX9_ARB 0x2090 +typedef BOOL (WINAPI * PFNWGLBINDTEXIMAGEARBPROC) (HPBUFFERARB hPbuffer, int iBuffer); +typedef BOOL (WINAPI * PFNWGLRELEASETEXIMAGEARBPROC) (HPBUFFERARB hPbuffer, int iBuffer); +typedef BOOL (WINAPI * PFNWGLSETPBUFFERATTRIBARBPROC) (HPBUFFERARB hPbuffer, const int *piAttribList); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglBindTexImageARB (HPBUFFERARB hPbuffer, int iBuffer); +BOOL WINAPI wglReleaseTexImageARB (HPBUFFERARB hPbuffer, int iBuffer); +BOOL WINAPI wglSetPbufferAttribARB (HPBUFFERARB hPbuffer, const int *piAttribList); +#endif +#endif /* WGL_ARB_render_texture */ + +#ifndef WGL_ARB_robustness_application_isolation +#define WGL_ARB_robustness_application_isolation 1 +#define WGL_CONTEXT_RESET_ISOLATION_BIT_ARB 0x00000008 +#endif /* WGL_ARB_robustness_application_isolation */ + +#ifndef WGL_ARB_robustness_share_group_isolation +#define WGL_ARB_robustness_share_group_isolation 1 +#endif /* WGL_ARB_robustness_share_group_isolation */ + +#ifndef WGL_3DFX_multisample +#define WGL_3DFX_multisample 1 +#define WGL_SAMPLE_BUFFERS_3DFX 0x2060 +#define WGL_SAMPLES_3DFX 0x2061 +#endif /* WGL_3DFX_multisample */ + +#ifndef WGL_3DL_stereo_control +#define WGL_3DL_stereo_control 1 +#define WGL_STEREO_EMITTER_ENABLE_3DL 0x2055 +#define WGL_STEREO_EMITTER_DISABLE_3DL 0x2056 +#define WGL_STEREO_POLARITY_NORMAL_3DL 0x2057 +#define WGL_STEREO_POLARITY_INVERT_3DL 0x2058 +typedef BOOL (WINAPI * PFNWGLSETSTEREOEMITTERSTATE3DLPROC) (HDC hDC, UINT uState); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglSetStereoEmitterState3DL (HDC hDC, UINT uState); +#endif +#endif /* WGL_3DL_stereo_control */ + +#ifndef WGL_AMD_gpu_association +#define WGL_AMD_gpu_association 1 +#define WGL_GPU_VENDOR_AMD 0x1F00 +#define WGL_GPU_RENDERER_STRING_AMD 0x1F01 +#define WGL_GPU_OPENGL_VERSION_STRING_AMD 0x1F02 +#define WGL_GPU_FASTEST_TARGET_GPUS_AMD 0x21A2 +#define WGL_GPU_RAM_AMD 0x21A3 +#define WGL_GPU_CLOCK_AMD 0x21A4 +#define WGL_GPU_NUM_PIPES_AMD 0x21A5 +#define WGL_GPU_NUM_SIMD_AMD 0x21A6 +#define WGL_GPU_NUM_RB_AMD 0x21A7 +#define WGL_GPU_NUM_SPI_AMD 0x21A8 +typedef UINT (WINAPI * PFNWGLGETGPUIDSAMDPROC) (UINT maxCount, UINT *ids); +typedef INT (WINAPI * PFNWGLGETGPUINFOAMDPROC) (UINT id, int property, GLenum dataType, UINT size, void *data); +typedef UINT (WINAPI * PFNWGLGETCONTEXTGPUIDAMDPROC) (HGLRC hglrc); +typedef HGLRC (WINAPI * PFNWGLCREATEASSOCIATEDCONTEXTAMDPROC) (UINT id); +typedef HGLRC (WINAPI * PFNWGLCREATEASSOCIATEDCONTEXTATTRIBSAMDPROC) (UINT id, HGLRC hShareContext, const int *attribList); +typedef BOOL (WINAPI * PFNWGLDELETEASSOCIATEDCONTEXTAMDPROC) (HGLRC hglrc); +typedef BOOL (WINAPI * PFNWGLMAKEASSOCIATEDCONTEXTCURRENTAMDPROC) (HGLRC hglrc); +typedef HGLRC (WINAPI * PFNWGLGETCURRENTASSOCIATEDCONTEXTAMDPROC) (void); +typedef VOID (WINAPI * PFNWGLBLITCONTEXTFRAMEBUFFERAMDPROC) (HGLRC dstCtx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +#ifdef WGL_WGLEXT_PROTOTYPES +UINT WINAPI wglGetGPUIDsAMD (UINT maxCount, UINT *ids); +INT WINAPI wglGetGPUInfoAMD (UINT id, int property, GLenum dataType, UINT size, void *data); +UINT WINAPI wglGetContextGPUIDAMD (HGLRC hglrc); +HGLRC WINAPI wglCreateAssociatedContextAMD (UINT id); +HGLRC WINAPI wglCreateAssociatedContextAttribsAMD (UINT id, HGLRC hShareContext, const int *attribList); +BOOL WINAPI wglDeleteAssociatedContextAMD (HGLRC hglrc); +BOOL WINAPI wglMakeAssociatedContextCurrentAMD (HGLRC hglrc); +HGLRC WINAPI wglGetCurrentAssociatedContextAMD (void); +VOID WINAPI wglBlitContextFramebufferAMD (HGLRC dstCtx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); +#endif +#endif /* WGL_AMD_gpu_association */ + +#ifndef WGL_ATI_pixel_format_float +#define WGL_ATI_pixel_format_float 1 +#define WGL_TYPE_RGBA_FLOAT_ATI 0x21A0 +#endif /* WGL_ATI_pixel_format_float */ + +#ifndef WGL_ATI_render_texture_rectangle +#define WGL_ATI_render_texture_rectangle 1 +#define WGL_TEXTURE_RECTANGLE_ATI 0x21A5 +#endif /* WGL_ATI_render_texture_rectangle */ + +#ifndef WGL_EXT_colorspace +#define WGL_EXT_colorspace 1 +#define WGL_COLORSPACE_EXT 0x309D +#define WGL_COLORSPACE_SRGB_EXT 0x3089 +#define WGL_COLORSPACE_LINEAR_EXT 0x308A +#endif /* WGL_EXT_colorspace */ + +#ifndef WGL_EXT_create_context_es2_profile +#define WGL_EXT_create_context_es2_profile 1 +#define WGL_CONTEXT_ES2_PROFILE_BIT_EXT 0x00000004 +#endif /* WGL_EXT_create_context_es2_profile */ + +#ifndef WGL_EXT_create_context_es_profile +#define WGL_EXT_create_context_es_profile 1 +#define WGL_CONTEXT_ES_PROFILE_BIT_EXT 0x00000004 +#endif /* WGL_EXT_create_context_es_profile */ + +#ifndef WGL_EXT_depth_float +#define WGL_EXT_depth_float 1 +#define WGL_DEPTH_FLOAT_EXT 0x2040 +#endif /* WGL_EXT_depth_float */ + +#ifndef WGL_EXT_display_color_table +#define WGL_EXT_display_color_table 1 +typedef GLboolean (WINAPI * PFNWGLCREATEDISPLAYCOLORTABLEEXTPROC) (GLushort id); +typedef GLboolean (WINAPI * PFNWGLLOADDISPLAYCOLORTABLEEXTPROC) (const GLushort *table, GLuint length); +typedef GLboolean (WINAPI * PFNWGLBINDDISPLAYCOLORTABLEEXTPROC) (GLushort id); +typedef VOID (WINAPI * PFNWGLDESTROYDISPLAYCOLORTABLEEXTPROC) (GLushort id); +#ifdef WGL_WGLEXT_PROTOTYPES +GLboolean WINAPI wglCreateDisplayColorTableEXT (GLushort id); +GLboolean WINAPI wglLoadDisplayColorTableEXT (const GLushort *table, GLuint length); +GLboolean WINAPI wglBindDisplayColorTableEXT (GLushort id); +VOID WINAPI wglDestroyDisplayColorTableEXT (GLushort id); +#endif +#endif /* WGL_EXT_display_color_table */ + +#ifndef WGL_EXT_extensions_string +#define WGL_EXT_extensions_string 1 +typedef const char *(WINAPI * PFNWGLGETEXTENSIONSSTRINGEXTPROC) (void); +#ifdef WGL_WGLEXT_PROTOTYPES +const char *WINAPI wglGetExtensionsStringEXT (void); +#endif +#endif /* WGL_EXT_extensions_string */ + +#ifndef WGL_EXT_framebuffer_sRGB +#define WGL_EXT_framebuffer_sRGB 1 +#define WGL_FRAMEBUFFER_SRGB_CAPABLE_EXT 0x20A9 +#endif /* WGL_EXT_framebuffer_sRGB */ + +#ifndef WGL_EXT_make_current_read +#define WGL_EXT_make_current_read 1 +#define ERROR_INVALID_PIXEL_TYPE_EXT 0x2043 +typedef BOOL (WINAPI * PFNWGLMAKECONTEXTCURRENTEXTPROC) (HDC hDrawDC, HDC hReadDC, HGLRC hglrc); +typedef HDC (WINAPI * PFNWGLGETCURRENTREADDCEXTPROC) (void); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglMakeContextCurrentEXT (HDC hDrawDC, HDC hReadDC, HGLRC hglrc); +HDC WINAPI wglGetCurrentReadDCEXT (void); +#endif +#endif /* WGL_EXT_make_current_read */ + +#ifndef WGL_EXT_multisample +#define WGL_EXT_multisample 1 +#define WGL_SAMPLE_BUFFERS_EXT 0x2041 +#define WGL_SAMPLES_EXT 0x2042 +#endif /* WGL_EXT_multisample */ + +#ifndef WGL_EXT_pbuffer +#define WGL_EXT_pbuffer 1 +DECLARE_HANDLE(HPBUFFEREXT); +#define WGL_DRAW_TO_PBUFFER_EXT 0x202D +#define WGL_MAX_PBUFFER_PIXELS_EXT 0x202E +#define WGL_MAX_PBUFFER_WIDTH_EXT 0x202F +#define WGL_MAX_PBUFFER_HEIGHT_EXT 0x2030 +#define WGL_OPTIMAL_PBUFFER_WIDTH_EXT 0x2031 +#define WGL_OPTIMAL_PBUFFER_HEIGHT_EXT 0x2032 +#define WGL_PBUFFER_LARGEST_EXT 0x2033 +#define WGL_PBUFFER_WIDTH_EXT 0x2034 +#define WGL_PBUFFER_HEIGHT_EXT 0x2035 +typedef HPBUFFEREXT (WINAPI * PFNWGLCREATEPBUFFEREXTPROC) (HDC hDC, int iPixelFormat, int iWidth, int iHeight, const int *piAttribList); +typedef HDC (WINAPI * PFNWGLGETPBUFFERDCEXTPROC) (HPBUFFEREXT hPbuffer); +typedef int (WINAPI * PFNWGLRELEASEPBUFFERDCEXTPROC) (HPBUFFEREXT hPbuffer, HDC hDC); +typedef BOOL (WINAPI * PFNWGLDESTROYPBUFFEREXTPROC) (HPBUFFEREXT hPbuffer); +typedef BOOL (WINAPI * PFNWGLQUERYPBUFFEREXTPROC) (HPBUFFEREXT hPbuffer, int iAttribute, int *piValue); +#ifdef WGL_WGLEXT_PROTOTYPES +HPBUFFEREXT WINAPI wglCreatePbufferEXT (HDC hDC, int iPixelFormat, int iWidth, int iHeight, const int *piAttribList); +HDC WINAPI wglGetPbufferDCEXT (HPBUFFEREXT hPbuffer); +int WINAPI wglReleasePbufferDCEXT (HPBUFFEREXT hPbuffer, HDC hDC); +BOOL WINAPI wglDestroyPbufferEXT (HPBUFFEREXT hPbuffer); +BOOL WINAPI wglQueryPbufferEXT (HPBUFFEREXT hPbuffer, int iAttribute, int *piValue); +#endif +#endif /* WGL_EXT_pbuffer */ + +#ifndef WGL_EXT_pixel_format +#define WGL_EXT_pixel_format 1 +#define WGL_NUMBER_PIXEL_FORMATS_EXT 0x2000 +#define WGL_DRAW_TO_WINDOW_EXT 0x2001 +#define WGL_DRAW_TO_BITMAP_EXT 0x2002 +#define WGL_ACCELERATION_EXT 0x2003 +#define WGL_NEED_PALETTE_EXT 0x2004 +#define WGL_NEED_SYSTEM_PALETTE_EXT 0x2005 +#define WGL_SWAP_LAYER_BUFFERS_EXT 0x2006 +#define WGL_SWAP_METHOD_EXT 0x2007 +#define WGL_NUMBER_OVERLAYS_EXT 0x2008 +#define WGL_NUMBER_UNDERLAYS_EXT 0x2009 +#define WGL_TRANSPARENT_EXT 0x200A +#define WGL_TRANSPARENT_VALUE_EXT 0x200B +#define WGL_SHARE_DEPTH_EXT 0x200C +#define WGL_SHARE_STENCIL_EXT 0x200D +#define WGL_SHARE_ACCUM_EXT 0x200E +#define WGL_SUPPORT_GDI_EXT 0x200F +#define WGL_SUPPORT_OPENGL_EXT 0x2010 +#define WGL_DOUBLE_BUFFER_EXT 0x2011 +#define WGL_STEREO_EXT 0x2012 +#define WGL_PIXEL_TYPE_EXT 0x2013 +#define WGL_COLOR_BITS_EXT 0x2014 +#define WGL_RED_BITS_EXT 0x2015 +#define WGL_RED_SHIFT_EXT 0x2016 +#define WGL_GREEN_BITS_EXT 0x2017 +#define WGL_GREEN_SHIFT_EXT 0x2018 +#define WGL_BLUE_BITS_EXT 0x2019 +#define WGL_BLUE_SHIFT_EXT 0x201A +#define WGL_ALPHA_BITS_EXT 0x201B +#define WGL_ALPHA_SHIFT_EXT 0x201C +#define WGL_ACCUM_BITS_EXT 0x201D +#define WGL_ACCUM_RED_BITS_EXT 0x201E +#define WGL_ACCUM_GREEN_BITS_EXT 0x201F +#define WGL_ACCUM_BLUE_BITS_EXT 0x2020 +#define WGL_ACCUM_ALPHA_BITS_EXT 0x2021 +#define WGL_DEPTH_BITS_EXT 0x2022 +#define WGL_STENCIL_BITS_EXT 0x2023 +#define WGL_AUX_BUFFERS_EXT 0x2024 +#define WGL_NO_ACCELERATION_EXT 0x2025 +#define WGL_GENERIC_ACCELERATION_EXT 0x2026 +#define WGL_FULL_ACCELERATION_EXT 0x2027 +#define WGL_SWAP_EXCHANGE_EXT 0x2028 +#define WGL_SWAP_COPY_EXT 0x2029 +#define WGL_SWAP_UNDEFINED_EXT 0x202A +#define WGL_TYPE_RGBA_EXT 0x202B +#define WGL_TYPE_COLORINDEX_EXT 0x202C +typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBIVEXTPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int *piAttributes, int *piValues); +typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBFVEXTPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int *piAttributes, FLOAT *pfValues); +typedef BOOL (WINAPI * PFNWGLCHOOSEPIXELFORMATEXTPROC) (HDC hdc, const int *piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglGetPixelFormatAttribivEXT (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int *piAttributes, int *piValues); +BOOL WINAPI wglGetPixelFormatAttribfvEXT (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int *piAttributes, FLOAT *pfValues); +BOOL WINAPI wglChoosePixelFormatEXT (HDC hdc, const int *piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats); +#endif +#endif /* WGL_EXT_pixel_format */ + +#ifndef WGL_EXT_pixel_format_packed_float +#define WGL_EXT_pixel_format_packed_float 1 +#define WGL_TYPE_RGBA_UNSIGNED_FLOAT_EXT 0x20A8 +#endif /* WGL_EXT_pixel_format_packed_float */ + +#ifndef WGL_EXT_swap_control +#define WGL_EXT_swap_control 1 +typedef BOOL (WINAPI * PFNWGLSWAPINTERVALEXTPROC) (int interval); +typedef int (WINAPI * PFNWGLGETSWAPINTERVALEXTPROC) (void); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglSwapIntervalEXT (int interval); +int WINAPI wglGetSwapIntervalEXT (void); +#endif +#endif /* WGL_EXT_swap_control */ + +#ifndef WGL_EXT_swap_control_tear +#define WGL_EXT_swap_control_tear 1 +#endif /* WGL_EXT_swap_control_tear */ + +#ifndef WGL_I3D_digital_video_control +#define WGL_I3D_digital_video_control 1 +#define WGL_DIGITAL_VIDEO_CURSOR_ALPHA_FRAMEBUFFER_I3D 0x2050 +#define WGL_DIGITAL_VIDEO_CURSOR_ALPHA_VALUE_I3D 0x2051 +#define WGL_DIGITAL_VIDEO_CURSOR_INCLUDED_I3D 0x2052 +#define WGL_DIGITAL_VIDEO_GAMMA_CORRECTED_I3D 0x2053 +typedef BOOL (WINAPI * PFNWGLGETDIGITALVIDEOPARAMETERSI3DPROC) (HDC hDC, int iAttribute, int *piValue); +typedef BOOL (WINAPI * PFNWGLSETDIGITALVIDEOPARAMETERSI3DPROC) (HDC hDC, int iAttribute, const int *piValue); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglGetDigitalVideoParametersI3D (HDC hDC, int iAttribute, int *piValue); +BOOL WINAPI wglSetDigitalVideoParametersI3D (HDC hDC, int iAttribute, const int *piValue); +#endif +#endif /* WGL_I3D_digital_video_control */ + +#ifndef WGL_I3D_gamma +#define WGL_I3D_gamma 1 +#define WGL_GAMMA_TABLE_SIZE_I3D 0x204E +#define WGL_GAMMA_EXCLUDE_DESKTOP_I3D 0x204F +typedef BOOL (WINAPI * PFNWGLGETGAMMATABLEPARAMETERSI3DPROC) (HDC hDC, int iAttribute, int *piValue); +typedef BOOL (WINAPI * PFNWGLSETGAMMATABLEPARAMETERSI3DPROC) (HDC hDC, int iAttribute, const int *piValue); +typedef BOOL (WINAPI * PFNWGLGETGAMMATABLEI3DPROC) (HDC hDC, int iEntries, USHORT *puRed, USHORT *puGreen, USHORT *puBlue); +typedef BOOL (WINAPI * PFNWGLSETGAMMATABLEI3DPROC) (HDC hDC, int iEntries, const USHORT *puRed, const USHORT *puGreen, const USHORT *puBlue); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglGetGammaTableParametersI3D (HDC hDC, int iAttribute, int *piValue); +BOOL WINAPI wglSetGammaTableParametersI3D (HDC hDC, int iAttribute, const int *piValue); +BOOL WINAPI wglGetGammaTableI3D (HDC hDC, int iEntries, USHORT *puRed, USHORT *puGreen, USHORT *puBlue); +BOOL WINAPI wglSetGammaTableI3D (HDC hDC, int iEntries, const USHORT *puRed, const USHORT *puGreen, const USHORT *puBlue); +#endif +#endif /* WGL_I3D_gamma */ + +#ifndef WGL_I3D_genlock +#define WGL_I3D_genlock 1 +#define WGL_GENLOCK_SOURCE_MULTIVIEW_I3D 0x2044 +#define WGL_GENLOCK_SOURCE_EXTERNAL_SYNC_I3D 0x2045 +#define WGL_GENLOCK_SOURCE_EXTERNAL_FIELD_I3D 0x2046 +#define WGL_GENLOCK_SOURCE_EXTERNAL_TTL_I3D 0x2047 +#define WGL_GENLOCK_SOURCE_DIGITAL_SYNC_I3D 0x2048 +#define WGL_GENLOCK_SOURCE_DIGITAL_FIELD_I3D 0x2049 +#define WGL_GENLOCK_SOURCE_EDGE_FALLING_I3D 0x204A +#define WGL_GENLOCK_SOURCE_EDGE_RISING_I3D 0x204B +#define WGL_GENLOCK_SOURCE_EDGE_BOTH_I3D 0x204C +typedef BOOL (WINAPI * PFNWGLENABLEGENLOCKI3DPROC) (HDC hDC); +typedef BOOL (WINAPI * PFNWGLDISABLEGENLOCKI3DPROC) (HDC hDC); +typedef BOOL (WINAPI * PFNWGLISENABLEDGENLOCKI3DPROC) (HDC hDC, BOOL *pFlag); +typedef BOOL (WINAPI * PFNWGLGENLOCKSOURCEI3DPROC) (HDC hDC, UINT uSource); +typedef BOOL (WINAPI * PFNWGLGETGENLOCKSOURCEI3DPROC) (HDC hDC, UINT *uSource); +typedef BOOL (WINAPI * PFNWGLGENLOCKSOURCEEDGEI3DPROC) (HDC hDC, UINT uEdge); +typedef BOOL (WINAPI * PFNWGLGETGENLOCKSOURCEEDGEI3DPROC) (HDC hDC, UINT *uEdge); +typedef BOOL (WINAPI * PFNWGLGENLOCKSAMPLERATEI3DPROC) (HDC hDC, UINT uRate); +typedef BOOL (WINAPI * PFNWGLGETGENLOCKSAMPLERATEI3DPROC) (HDC hDC, UINT *uRate); +typedef BOOL (WINAPI * PFNWGLGENLOCKSOURCEDELAYI3DPROC) (HDC hDC, UINT uDelay); +typedef BOOL (WINAPI * PFNWGLGETGENLOCKSOURCEDELAYI3DPROC) (HDC hDC, UINT *uDelay); +typedef BOOL (WINAPI * PFNWGLQUERYGENLOCKMAXSOURCEDELAYI3DPROC) (HDC hDC, UINT *uMaxLineDelay, UINT *uMaxPixelDelay); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglEnableGenlockI3D (HDC hDC); +BOOL WINAPI wglDisableGenlockI3D (HDC hDC); +BOOL WINAPI wglIsEnabledGenlockI3D (HDC hDC, BOOL *pFlag); +BOOL WINAPI wglGenlockSourceI3D (HDC hDC, UINT uSource); +BOOL WINAPI wglGetGenlockSourceI3D (HDC hDC, UINT *uSource); +BOOL WINAPI wglGenlockSourceEdgeI3D (HDC hDC, UINT uEdge); +BOOL WINAPI wglGetGenlockSourceEdgeI3D (HDC hDC, UINT *uEdge); +BOOL WINAPI wglGenlockSampleRateI3D (HDC hDC, UINT uRate); +BOOL WINAPI wglGetGenlockSampleRateI3D (HDC hDC, UINT *uRate); +BOOL WINAPI wglGenlockSourceDelayI3D (HDC hDC, UINT uDelay); +BOOL WINAPI wglGetGenlockSourceDelayI3D (HDC hDC, UINT *uDelay); +BOOL WINAPI wglQueryGenlockMaxSourceDelayI3D (HDC hDC, UINT *uMaxLineDelay, UINT *uMaxPixelDelay); +#endif +#endif /* WGL_I3D_genlock */ + +#ifndef WGL_I3D_image_buffer +#define WGL_I3D_image_buffer 1 +#define WGL_IMAGE_BUFFER_MIN_ACCESS_I3D 0x00000001 +#define WGL_IMAGE_BUFFER_LOCK_I3D 0x00000002 +typedef LPVOID (WINAPI * PFNWGLCREATEIMAGEBUFFERI3DPROC) (HDC hDC, DWORD dwSize, UINT uFlags); +typedef BOOL (WINAPI * PFNWGLDESTROYIMAGEBUFFERI3DPROC) (HDC hDC, LPVOID pAddress); +typedef BOOL (WINAPI * PFNWGLASSOCIATEIMAGEBUFFEREVENTSI3DPROC) (HDC hDC, const HANDLE *pEvent, const LPVOID *pAddress, const DWORD *pSize, UINT count); +typedef BOOL (WINAPI * PFNWGLRELEASEIMAGEBUFFEREVENTSI3DPROC) (HDC hDC, const LPVOID *pAddress, UINT count); +#ifdef WGL_WGLEXT_PROTOTYPES +LPVOID WINAPI wglCreateImageBufferI3D (HDC hDC, DWORD dwSize, UINT uFlags); +BOOL WINAPI wglDestroyImageBufferI3D (HDC hDC, LPVOID pAddress); +BOOL WINAPI wglAssociateImageBufferEventsI3D (HDC hDC, const HANDLE *pEvent, const LPVOID *pAddress, const DWORD *pSize, UINT count); +BOOL WINAPI wglReleaseImageBufferEventsI3D (HDC hDC, const LPVOID *pAddress, UINT count); +#endif +#endif /* WGL_I3D_image_buffer */ + +#ifndef WGL_I3D_swap_frame_lock +#define WGL_I3D_swap_frame_lock 1 +typedef BOOL (WINAPI * PFNWGLENABLEFRAMELOCKI3DPROC) (void); +typedef BOOL (WINAPI * PFNWGLDISABLEFRAMELOCKI3DPROC) (void); +typedef BOOL (WINAPI * PFNWGLISENABLEDFRAMELOCKI3DPROC) (BOOL *pFlag); +typedef BOOL (WINAPI * PFNWGLQUERYFRAMELOCKMASTERI3DPROC) (BOOL *pFlag); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglEnableFrameLockI3D (void); +BOOL WINAPI wglDisableFrameLockI3D (void); +BOOL WINAPI wglIsEnabledFrameLockI3D (BOOL *pFlag); +BOOL WINAPI wglQueryFrameLockMasterI3D (BOOL *pFlag); +#endif +#endif /* WGL_I3D_swap_frame_lock */ + +#ifndef WGL_I3D_swap_frame_usage +#define WGL_I3D_swap_frame_usage 1 +typedef BOOL (WINAPI * PFNWGLGETFRAMEUSAGEI3DPROC) (float *pUsage); +typedef BOOL (WINAPI * PFNWGLBEGINFRAMETRACKINGI3DPROC) (void); +typedef BOOL (WINAPI * PFNWGLENDFRAMETRACKINGI3DPROC) (void); +typedef BOOL (WINAPI * PFNWGLQUERYFRAMETRACKINGI3DPROC) (DWORD *pFrameCount, DWORD *pMissedFrames, float *pLastMissedUsage); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglGetFrameUsageI3D (float *pUsage); +BOOL WINAPI wglBeginFrameTrackingI3D (void); +BOOL WINAPI wglEndFrameTrackingI3D (void); +BOOL WINAPI wglQueryFrameTrackingI3D (DWORD *pFrameCount, DWORD *pMissedFrames, float *pLastMissedUsage); +#endif +#endif /* WGL_I3D_swap_frame_usage */ + +#ifndef WGL_NV_DX_interop +#define WGL_NV_DX_interop 1 +#define WGL_ACCESS_READ_ONLY_NV 0x00000000 +#define WGL_ACCESS_READ_WRITE_NV 0x00000001 +#define WGL_ACCESS_WRITE_DISCARD_NV 0x00000002 +typedef BOOL (WINAPI * PFNWGLDXSETRESOURCESHAREHANDLENVPROC) (void *dxObject, HANDLE shareHandle); +typedef HANDLE (WINAPI * PFNWGLDXOPENDEVICENVPROC) (void *dxDevice); +typedef BOOL (WINAPI * PFNWGLDXCLOSEDEVICENVPROC) (HANDLE hDevice); +typedef HANDLE (WINAPI * PFNWGLDXREGISTEROBJECTNVPROC) (HANDLE hDevice, void *dxObject, GLuint name, GLenum type, GLenum access); +typedef BOOL (WINAPI * PFNWGLDXUNREGISTEROBJECTNVPROC) (HANDLE hDevice, HANDLE hObject); +typedef BOOL (WINAPI * PFNWGLDXOBJECTACCESSNVPROC) (HANDLE hObject, GLenum access); +typedef BOOL (WINAPI * PFNWGLDXLOCKOBJECTSNVPROC) (HANDLE hDevice, GLint count, HANDLE *hObjects); +typedef BOOL (WINAPI * PFNWGLDXUNLOCKOBJECTSNVPROC) (HANDLE hDevice, GLint count, HANDLE *hObjects); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglDXSetResourceShareHandleNV (void *dxObject, HANDLE shareHandle); +HANDLE WINAPI wglDXOpenDeviceNV (void *dxDevice); +BOOL WINAPI wglDXCloseDeviceNV (HANDLE hDevice); +HANDLE WINAPI wglDXRegisterObjectNV (HANDLE hDevice, void *dxObject, GLuint name, GLenum type, GLenum access); +BOOL WINAPI wglDXUnregisterObjectNV (HANDLE hDevice, HANDLE hObject); +BOOL WINAPI wglDXObjectAccessNV (HANDLE hObject, GLenum access); +BOOL WINAPI wglDXLockObjectsNV (HANDLE hDevice, GLint count, HANDLE *hObjects); +BOOL WINAPI wglDXUnlockObjectsNV (HANDLE hDevice, GLint count, HANDLE *hObjects); +#endif +#endif /* WGL_NV_DX_interop */ + +#ifndef WGL_NV_DX_interop2 +#define WGL_NV_DX_interop2 1 +#endif /* WGL_NV_DX_interop2 */ + +#ifndef WGL_NV_copy_image +#define WGL_NV_copy_image 1 +typedef BOOL (WINAPI * PFNWGLCOPYIMAGESUBDATANVPROC) (HGLRC hSrcRC, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, HGLRC hDstRC, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei width, GLsizei height, GLsizei depth); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglCopyImageSubDataNV (HGLRC hSrcRC, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, HGLRC hDstRC, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei width, GLsizei height, GLsizei depth); +#endif +#endif /* WGL_NV_copy_image */ + +#ifndef WGL_NV_delay_before_swap +#define WGL_NV_delay_before_swap 1 +typedef BOOL (WINAPI * PFNWGLDELAYBEFORESWAPNVPROC) (HDC hDC, GLfloat seconds); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglDelayBeforeSwapNV (HDC hDC, GLfloat seconds); +#endif +#endif /* WGL_NV_delay_before_swap */ + +#ifndef WGL_NV_float_buffer +#define WGL_NV_float_buffer 1 +#define WGL_FLOAT_COMPONENTS_NV 0x20B0 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_R_NV 0x20B1 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RG_NV 0x20B2 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RGB_NV 0x20B3 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RGBA_NV 0x20B4 +#define WGL_TEXTURE_FLOAT_R_NV 0x20B5 +#define WGL_TEXTURE_FLOAT_RG_NV 0x20B6 +#define WGL_TEXTURE_FLOAT_RGB_NV 0x20B7 +#define WGL_TEXTURE_FLOAT_RGBA_NV 0x20B8 +#endif /* WGL_NV_float_buffer */ + +#ifndef WGL_NV_gpu_affinity +#define WGL_NV_gpu_affinity 1 +DECLARE_HANDLE(HGPUNV); +struct _GPU_DEVICE { + DWORD cb; + CHAR DeviceName[32]; + CHAR DeviceString[128]; + DWORD Flags; + RECT rcVirtualScreen; +}; +typedef struct _GPU_DEVICE *PGPU_DEVICE; +#define ERROR_INCOMPATIBLE_AFFINITY_MASKS_NV 0x20D0 +#define ERROR_MISSING_AFFINITY_MASK_NV 0x20D1 +typedef BOOL (WINAPI * PFNWGLENUMGPUSNVPROC) (UINT iGpuIndex, HGPUNV *phGpu); +typedef BOOL (WINAPI * PFNWGLENUMGPUDEVICESNVPROC) (HGPUNV hGpu, UINT iDeviceIndex, PGPU_DEVICE lpGpuDevice); +typedef HDC (WINAPI * PFNWGLCREATEAFFINITYDCNVPROC) (const HGPUNV *phGpuList); +typedef BOOL (WINAPI * PFNWGLENUMGPUSFROMAFFINITYDCNVPROC) (HDC hAffinityDC, UINT iGpuIndex, HGPUNV *hGpu); +typedef BOOL (WINAPI * PFNWGLDELETEDCNVPROC) (HDC hdc); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglEnumGpusNV (UINT iGpuIndex, HGPUNV *phGpu); +BOOL WINAPI wglEnumGpuDevicesNV (HGPUNV hGpu, UINT iDeviceIndex, PGPU_DEVICE lpGpuDevice); +HDC WINAPI wglCreateAffinityDCNV (const HGPUNV *phGpuList); +BOOL WINAPI wglEnumGpusFromAffinityDCNV (HDC hAffinityDC, UINT iGpuIndex, HGPUNV *hGpu); +BOOL WINAPI wglDeleteDCNV (HDC hdc); +#endif +#endif /* WGL_NV_gpu_affinity */ + +#ifndef WGL_NV_multisample_coverage +#define WGL_NV_multisample_coverage 1 +#define WGL_COVERAGE_SAMPLES_NV 0x2042 +#define WGL_COLOR_SAMPLES_NV 0x20B9 +#endif /* WGL_NV_multisample_coverage */ + +#ifndef WGL_NV_present_video +#define WGL_NV_present_video 1 +DECLARE_HANDLE(HVIDEOOUTPUTDEVICENV); +#define WGL_NUM_VIDEO_SLOTS_NV 0x20F0 +typedef int (WINAPI * PFNWGLENUMERATEVIDEODEVICESNVPROC) (HDC hDC, HVIDEOOUTPUTDEVICENV *phDeviceList); +typedef BOOL (WINAPI * PFNWGLBINDVIDEODEVICENVPROC) (HDC hDC, unsigned int uVideoSlot, HVIDEOOUTPUTDEVICENV hVideoDevice, const int *piAttribList); +typedef BOOL (WINAPI * PFNWGLQUERYCURRENTCONTEXTNVPROC) (int iAttribute, int *piValue); +#ifdef WGL_WGLEXT_PROTOTYPES +int WINAPI wglEnumerateVideoDevicesNV (HDC hDC, HVIDEOOUTPUTDEVICENV *phDeviceList); +BOOL WINAPI wglBindVideoDeviceNV (HDC hDC, unsigned int uVideoSlot, HVIDEOOUTPUTDEVICENV hVideoDevice, const int *piAttribList); +BOOL WINAPI wglQueryCurrentContextNV (int iAttribute, int *piValue); +#endif +#endif /* WGL_NV_present_video */ + +#ifndef WGL_NV_render_depth_texture +#define WGL_NV_render_depth_texture 1 +#define WGL_BIND_TO_TEXTURE_DEPTH_NV 0x20A3 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_DEPTH_NV 0x20A4 +#define WGL_DEPTH_TEXTURE_FORMAT_NV 0x20A5 +#define WGL_TEXTURE_DEPTH_COMPONENT_NV 0x20A6 +#define WGL_DEPTH_COMPONENT_NV 0x20A7 +#endif /* WGL_NV_render_depth_texture */ + +#ifndef WGL_NV_render_texture_rectangle +#define WGL_NV_render_texture_rectangle 1 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_RGB_NV 0x20A0 +#define WGL_BIND_TO_TEXTURE_RECTANGLE_RGBA_NV 0x20A1 +#define WGL_TEXTURE_RECTANGLE_NV 0x20A2 +#endif /* WGL_NV_render_texture_rectangle */ + +#ifndef WGL_NV_swap_group +#define WGL_NV_swap_group 1 +typedef BOOL (WINAPI * PFNWGLJOINSWAPGROUPNVPROC) (HDC hDC, GLuint group); +typedef BOOL (WINAPI * PFNWGLBINDSWAPBARRIERNVPROC) (GLuint group, GLuint barrier); +typedef BOOL (WINAPI * PFNWGLQUERYSWAPGROUPNVPROC) (HDC hDC, GLuint *group, GLuint *barrier); +typedef BOOL (WINAPI * PFNWGLQUERYMAXSWAPGROUPSNVPROC) (HDC hDC, GLuint *maxGroups, GLuint *maxBarriers); +typedef BOOL (WINAPI * PFNWGLQUERYFRAMECOUNTNVPROC) (HDC hDC, GLuint *count); +typedef BOOL (WINAPI * PFNWGLRESETFRAMECOUNTNVPROC) (HDC hDC); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglJoinSwapGroupNV (HDC hDC, GLuint group); +BOOL WINAPI wglBindSwapBarrierNV (GLuint group, GLuint barrier); +BOOL WINAPI wglQuerySwapGroupNV (HDC hDC, GLuint *group, GLuint *barrier); +BOOL WINAPI wglQueryMaxSwapGroupsNV (HDC hDC, GLuint *maxGroups, GLuint *maxBarriers); +BOOL WINAPI wglQueryFrameCountNV (HDC hDC, GLuint *count); +BOOL WINAPI wglResetFrameCountNV (HDC hDC); +#endif +#endif /* WGL_NV_swap_group */ + +#ifndef WGL_NV_vertex_array_range +#define WGL_NV_vertex_array_range 1 +typedef void *(WINAPI * PFNWGLALLOCATEMEMORYNVPROC) (GLsizei size, GLfloat readfreq, GLfloat writefreq, GLfloat priority); +typedef void (WINAPI * PFNWGLFREEMEMORYNVPROC) (void *pointer); +#ifdef WGL_WGLEXT_PROTOTYPES +void *WINAPI wglAllocateMemoryNV (GLsizei size, GLfloat readfreq, GLfloat writefreq, GLfloat priority); +void WINAPI wglFreeMemoryNV (void *pointer); +#endif +#endif /* WGL_NV_vertex_array_range */ + +#ifndef WGL_NV_video_capture +#define WGL_NV_video_capture 1 +DECLARE_HANDLE(HVIDEOINPUTDEVICENV); +#define WGL_UNIQUE_ID_NV 0x20CE +#define WGL_NUM_VIDEO_CAPTURE_SLOTS_NV 0x20CF +typedef BOOL (WINAPI * PFNWGLBINDVIDEOCAPTUREDEVICENVPROC) (UINT uVideoSlot, HVIDEOINPUTDEVICENV hDevice); +typedef UINT (WINAPI * PFNWGLENUMERATEVIDEOCAPTUREDEVICESNVPROC) (HDC hDc, HVIDEOINPUTDEVICENV *phDeviceList); +typedef BOOL (WINAPI * PFNWGLLOCKVIDEOCAPTUREDEVICENVPROC) (HDC hDc, HVIDEOINPUTDEVICENV hDevice); +typedef BOOL (WINAPI * PFNWGLQUERYVIDEOCAPTUREDEVICENVPROC) (HDC hDc, HVIDEOINPUTDEVICENV hDevice, int iAttribute, int *piValue); +typedef BOOL (WINAPI * PFNWGLRELEASEVIDEOCAPTUREDEVICENVPROC) (HDC hDc, HVIDEOINPUTDEVICENV hDevice); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglBindVideoCaptureDeviceNV (UINT uVideoSlot, HVIDEOINPUTDEVICENV hDevice); +UINT WINAPI wglEnumerateVideoCaptureDevicesNV (HDC hDc, HVIDEOINPUTDEVICENV *phDeviceList); +BOOL WINAPI wglLockVideoCaptureDeviceNV (HDC hDc, HVIDEOINPUTDEVICENV hDevice); +BOOL WINAPI wglQueryVideoCaptureDeviceNV (HDC hDc, HVIDEOINPUTDEVICENV hDevice, int iAttribute, int *piValue); +BOOL WINAPI wglReleaseVideoCaptureDeviceNV (HDC hDc, HVIDEOINPUTDEVICENV hDevice); +#endif +#endif /* WGL_NV_video_capture */ + +#ifndef WGL_NV_video_output +#define WGL_NV_video_output 1 +DECLARE_HANDLE(HPVIDEODEV); +#define WGL_BIND_TO_VIDEO_RGB_NV 0x20C0 +#define WGL_BIND_TO_VIDEO_RGBA_NV 0x20C1 +#define WGL_BIND_TO_VIDEO_RGB_AND_DEPTH_NV 0x20C2 +#define WGL_VIDEO_OUT_COLOR_NV 0x20C3 +#define WGL_VIDEO_OUT_ALPHA_NV 0x20C4 +#define WGL_VIDEO_OUT_DEPTH_NV 0x20C5 +#define WGL_VIDEO_OUT_COLOR_AND_ALPHA_NV 0x20C6 +#define WGL_VIDEO_OUT_COLOR_AND_DEPTH_NV 0x20C7 +#define WGL_VIDEO_OUT_FRAME 0x20C8 +#define WGL_VIDEO_OUT_FIELD_1 0x20C9 +#define WGL_VIDEO_OUT_FIELD_2 0x20CA +#define WGL_VIDEO_OUT_STACKED_FIELDS_1_2 0x20CB +#define WGL_VIDEO_OUT_STACKED_FIELDS_2_1 0x20CC +typedef BOOL (WINAPI * PFNWGLGETVIDEODEVICENVPROC) (HDC hDC, int numDevices, HPVIDEODEV *hVideoDevice); +typedef BOOL (WINAPI * PFNWGLRELEASEVIDEODEVICENVPROC) (HPVIDEODEV hVideoDevice); +typedef BOOL (WINAPI * PFNWGLBINDVIDEOIMAGENVPROC) (HPVIDEODEV hVideoDevice, HPBUFFERARB hPbuffer, int iVideoBuffer); +typedef BOOL (WINAPI * PFNWGLRELEASEVIDEOIMAGENVPROC) (HPBUFFERARB hPbuffer, int iVideoBuffer); +typedef BOOL (WINAPI * PFNWGLSENDPBUFFERTOVIDEONVPROC) (HPBUFFERARB hPbuffer, int iBufferType, unsigned long *pulCounterPbuffer, BOOL bBlock); +typedef BOOL (WINAPI * PFNWGLGETVIDEOINFONVPROC) (HPVIDEODEV hpVideoDevice, unsigned long *pulCounterOutputPbuffer, unsigned long *pulCounterOutputVideo); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglGetVideoDeviceNV (HDC hDC, int numDevices, HPVIDEODEV *hVideoDevice); +BOOL WINAPI wglReleaseVideoDeviceNV (HPVIDEODEV hVideoDevice); +BOOL WINAPI wglBindVideoImageNV (HPVIDEODEV hVideoDevice, HPBUFFERARB hPbuffer, int iVideoBuffer); +BOOL WINAPI wglReleaseVideoImageNV (HPBUFFERARB hPbuffer, int iVideoBuffer); +BOOL WINAPI wglSendPbufferToVideoNV (HPBUFFERARB hPbuffer, int iBufferType, unsigned long *pulCounterPbuffer, BOOL bBlock); +BOOL WINAPI wglGetVideoInfoNV (HPVIDEODEV hpVideoDevice, unsigned long *pulCounterOutputPbuffer, unsigned long *pulCounterOutputVideo); +#endif +#endif /* WGL_NV_video_output */ + +#ifndef WGL_OML_sync_control +#define WGL_OML_sync_control 1 +typedef BOOL (WINAPI * PFNWGLGETSYNCVALUESOMLPROC) (HDC hdc, INT64 *ust, INT64 *msc, INT64 *sbc); +typedef BOOL (WINAPI * PFNWGLGETMSCRATEOMLPROC) (HDC hdc, INT32 *numerator, INT32 *denominator); +typedef INT64 (WINAPI * PFNWGLSWAPBUFFERSMSCOMLPROC) (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder); +typedef INT64 (WINAPI * PFNWGLSWAPLAYERBUFFERSMSCOMLPROC) (HDC hdc, int fuPlanes, INT64 target_msc, INT64 divisor, INT64 remainder); +typedef BOOL (WINAPI * PFNWGLWAITFORMSCOMLPROC) (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder, INT64 *ust, INT64 *msc, INT64 *sbc); +typedef BOOL (WINAPI * PFNWGLWAITFORSBCOMLPROC) (HDC hdc, INT64 target_sbc, INT64 *ust, INT64 *msc, INT64 *sbc); +#ifdef WGL_WGLEXT_PROTOTYPES +BOOL WINAPI wglGetSyncValuesOML (HDC hdc, INT64 *ust, INT64 *msc, INT64 *sbc); +BOOL WINAPI wglGetMscRateOML (HDC hdc, INT32 *numerator, INT32 *denominator); +INT64 WINAPI wglSwapBuffersMscOML (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder); +INT64 WINAPI wglSwapLayerBuffersMscOML (HDC hdc, int fuPlanes, INT64 target_msc, INT64 divisor, INT64 remainder); +BOOL WINAPI wglWaitForMscOML (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder, INT64 *ust, INT64 *msc, INT64 *sbc); +BOOL WINAPI wglWaitForSbcOML (HDC hdc, INT64 target_sbc, INT64 *ust, INT64 *msc, INT64 *sbc); +#endif +#endif /* WGL_OML_sync_control */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/gfx/angle/checkout/include/angle_gl.h b/gfx/angle/checkout/include/angle_gl.h new file mode 100644 index 0000000000..4ff294bf63 --- /dev/null +++ b/gfx/angle/checkout/include/angle_gl.h @@ -0,0 +1,27 @@ +// +// Copyright 2014 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// angle_gl.h: +// Includes all necessary GL headers and definitions for ANGLE. +// + +#ifndef ANGLEGL_H_ +#define ANGLEGL_H_ + +#include "GLES/gl.h" +#include "GLES/glext.h" +#include "GLES2/gl2.h" +#include "GLES2/gl2ext.h" +#include "GLES3/gl3.h" +#include "GLES3/gl31.h" +#include "GLES3/gl32.h" + +// TODO(http://anglebug.com/3730): Autogenerate these enums from gl.xml +// HACK: Defines for queries that are not in GLES +#define GL_CONTEXT_PROFILE_MASK 0x9126 +#define GL_CONTEXT_COMPATIBILITY_PROFILE_BIT 0x00000002 +#define GL_CONTEXT_CORE_PROFILE_BIT 0x00000001 + +#endif // ANGLEGL_H_ diff --git a/gfx/angle/checkout/include/export.h b/gfx/angle/checkout/include/export.h new file mode 100644 index 0000000000..6a8e30fd80 --- /dev/null +++ b/gfx/angle/checkout/include/export.h @@ -0,0 +1,40 @@ +// +// Copyright 2014 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// export.h : Defines ANGLE_EXPORT, a macro for exporting functions from the DLL + +#ifndef LIBGLESV2_EXPORT_H_ +#define LIBGLESV2_EXPORT_H_ + +#if !defined(ANGLE_EXPORT) +# if defined(_WIN32) +# if defined(LIBGLESV2_IMPLEMENTATION) || defined(LIBANGLE_IMPLEMENTATION) || \ + defined(LIBFEATURE_SUPPORT_IMPLEMENTATION) || defined(LIBCL_IMPLEMENTATION) +# define ANGLE_EXPORT __declspec(dllexport) +# else +# define ANGLE_EXPORT __declspec(dllimport) +# endif +# elif defined(__GNUC__) +# if defined(LIBGLESV2_IMPLEMENTATION) || defined(LIBANGLE_IMPLEMENTATION) || \ + defined(LIBFEATURE_SUPPORT_IMPLEMENTATION) || defined(LIBCL_IMPLEMENTATION) +# define ANGLE_EXPORT __attribute__((visibility("default"))) +# else +# define ANGLE_EXPORT +# endif +# else +# define ANGLE_EXPORT +# endif +#endif // !defined(ANGLE_EXPORT) + +#if !defined(ANGLE_NO_EXPORT) +# if defined(__GNUC__) +# define ANGLE_NO_EXPORT __attribute__((visibility("hidden"))) +# else +# define ANGLE_NO_EXPORT +# endif +#endif // !defined(ANGLE_NO_EXPORT) + +#endif // LIBGLESV2_EXPORT_H_ diff --git a/gfx/angle/checkout/include/platform/Feature.h b/gfx/angle/checkout/include/platform/Feature.h new file mode 100644 index 0000000000..c1de314e80 --- /dev/null +++ b/gfx/angle/checkout/include/platform/Feature.h @@ -0,0 +1,196 @@ +// +// Copyright 2019 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// Feature.h: Definition of structs to hold feature/workaround information. +// + +#ifndef ANGLE_PLATFORM_FEATURE_H_ +#define ANGLE_PLATFORM_FEATURE_H_ + +#include +#include +#include + +#define ANGLE_FEATURE_CONDITION(set, feature, cond) \ + do \ + { \ + (set)->feature.enabled = cond; \ + (set)->feature.condition = ANGLE_STRINGIFY(cond); \ + } while (0) + +namespace angle +{ + +enum class FeatureCategory +{ + FrontendFeatures, + FrontendWorkarounds, + OpenGLWorkarounds, + OpenGLFeatures, + D3DWorkarounds, + VulkanFeatures, + VulkanWorkarounds, + VulkanAppWorkarounds, + MetalFeatures, + MetalWorkarounds, +}; + +constexpr char kFeatureCategoryFrontendWorkarounds[] = "Frontend workarounds"; +constexpr char kFeatureCategoryFrontendFeatures[] = "Frontend features"; +constexpr char kFeatureCategoryOpenGLWorkarounds[] = "OpenGL workarounds"; +constexpr char kFeatureCategoryOpenGLFeatures[] = "OpenGL features"; +constexpr char kFeatureCategoryD3DWorkarounds[] = "D3D workarounds"; +constexpr char kFeatureCategoryVulkanAppWorkarounds[] = "Vulkan app workarounds"; +constexpr char kFeatureCategoryVulkanWorkarounds[] = "Vulkan workarounds"; +constexpr char kFeatureCategoryVulkanFeatures[] = "Vulkan features"; +constexpr char kFeatureCategoryMetalFeatures[] = "Metal features"; +constexpr char kFeatureCategoryMetalWorkarounds[] = "Metal workarounds"; +constexpr char kFeatureCategoryUnknown[] = "Unknown"; + +inline const char *FeatureCategoryToString(const FeatureCategory &fc) +{ + switch (fc) + { + case FeatureCategory::FrontendFeatures: + return kFeatureCategoryFrontendFeatures; + break; + + case FeatureCategory::FrontendWorkarounds: + return kFeatureCategoryFrontendWorkarounds; + break; + + case FeatureCategory::OpenGLWorkarounds: + return kFeatureCategoryOpenGLWorkarounds; + break; + + case FeatureCategory::OpenGLFeatures: + return kFeatureCategoryOpenGLFeatures; + break; + + case FeatureCategory::D3DWorkarounds: + return kFeatureCategoryD3DWorkarounds; + break; + + case FeatureCategory::VulkanFeatures: + return kFeatureCategoryVulkanFeatures; + break; + + case FeatureCategory::VulkanWorkarounds: + return kFeatureCategoryVulkanWorkarounds; + break; + + case FeatureCategory::VulkanAppWorkarounds: + return kFeatureCategoryVulkanAppWorkarounds; + break; + + case FeatureCategory::MetalFeatures: + return kFeatureCategoryMetalFeatures; + break; + + case FeatureCategory::MetalWorkarounds: + return kFeatureCategoryMetalWorkarounds; + break; + + default: + return kFeatureCategoryUnknown; + break; + } +} + +constexpr char kFeatureStatusEnabled[] = "enabled"; +constexpr char kFeatureStatusDisabled[] = "disabled"; + +inline const char *FeatureStatusToString(const bool &status) +{ + if (status) + { + return kFeatureStatusEnabled; + } + return kFeatureStatusDisabled; +} + +struct FeatureInfo; + +using FeatureMap = std::map; +using FeatureList = std::vector; + +struct FeatureInfo +{ + FeatureInfo(const FeatureInfo &other); + FeatureInfo(const char *name, + const FeatureCategory &category, + const char *description, + FeatureMap *const mapPtr, + const char *bug); + ~FeatureInfo(); + + // The name of the workaround, lowercase, camel_case + const char *const name; + + // The category that the workaround belongs to. Eg. "Vulkan workarounds" + const FeatureCategory category; + + // A short description to be read by the user. + const char *const description; + + // A link to the bug, if any + const char *const bug; + + // Whether the workaround is enabled or not. Determined by heuristics like vendor ID and + // version, but may be overriden to any value. + bool enabled = false; + + // A stringified version of the condition used to set 'enabled'. ie "IsNvidia() && IsApple()" + const char *condition; +}; + +inline FeatureInfo::FeatureInfo(const FeatureInfo &other) = default; +inline FeatureInfo::FeatureInfo(const char *name, + const FeatureCategory &category, + const char *description, + FeatureMap *const mapPtr, + const char *bug = "") + : name(name), + category(category), + description(description), + bug(bug), + enabled(false), + condition("") +{ + if (mapPtr != nullptr) + { + (*mapPtr)[std::string(name)] = this; + } +} + +inline FeatureInfo::~FeatureInfo() = default; + +struct FeatureSetBase +{ + public: + FeatureSetBase(); + ~FeatureSetBase(); + + private: + // Non-copyable + FeatureSetBase(const FeatureSetBase &other) = delete; + FeatureSetBase &operator=(const FeatureSetBase &other) = delete; + + protected: + FeatureMap members = FeatureMap(); + + public: + void overrideFeatures(const std::vector &featureNames, bool enabled); + void populateFeatureList(FeatureList *features) const; + + const FeatureMap &getFeatures() const { return members; } +}; + +inline FeatureSetBase::FeatureSetBase() = default; +inline FeatureSetBase::~FeatureSetBase() = default; + +} // namespace angle + +#endif // ANGLE_PLATFORM_WORKAROUND_H_ diff --git a/gfx/angle/checkout/include/platform/FeaturesD3D_autogen.h b/gfx/angle/checkout/include/platform/FeaturesD3D_autogen.h new file mode 100644 index 0000000000..0df072b497 --- /dev/null +++ b/gfx/angle/checkout/include/platform/FeaturesD3D_autogen.h @@ -0,0 +1,198 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by gen_features.py using data from d3d_features.json. +// +// Copyright 2022 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// FeaturesD3D_autogen.h: Features and workarounds for D3D driver bugs and other issues. + +#ifndef ANGLE_PLATFORM_FEATURESD3D_H_ +#define ANGLE_PLATFORM_FEATURESD3D_H_ + +#include "platform/Feature.h" + +namespace angle +{ + +struct FeaturesD3D : FeatureSetBase +{ + FeaturesD3D(); + ~FeaturesD3D(); + + FeatureInfo mrtPerfWorkaround = { + "mrtPerfWorkaround", + FeatureCategory::D3DWorkarounds, + "Some drivers have a bug where they ignore null render targets", + &members, + }; + + FeatureInfo setDataFasterThanImageUpload = { + "setDataFasterThanImageUpload", + FeatureCategory::D3DWorkarounds, + "Set data faster than image upload", + &members, + }; + + FeatureInfo setDataFasterThanImageUploadOn128bitFormats = { + "setDataFasterThanImageUploadOn128bitFormats", + FeatureCategory::D3DWorkarounds, + "Set data faster than image upload on 128bit formats", + &members, + }; + + FeatureInfo zeroMaxLodWorkaround = { + "zeroMaxLodWorkaround", + FeatureCategory::D3DWorkarounds, + "Missing an option to disable mipmaps on a mipmapped texture", + &members, + }; + + FeatureInfo useInstancedPointSpriteEmulation = { + "useInstancedPointSpriteEmulation", + FeatureCategory::D3DWorkarounds, + "Some D3D11 renderers do not support geometry shaders for pointsprite emulation", + &members, + }; + + FeatureInfo depthStencilBlitExtraCopy = { + "depthStencilBlitExtraCopy", FeatureCategory::D3DWorkarounds, + "Bug in some drivers triggers a TDR when using CopySubresourceRegion from a staging " + "texture to a depth/stencil", + &members, "http://anglebug.com/1452"}; + + FeatureInfo expandIntegerPowExpressions = { + "expandIntegerPowExpressions", + FeatureCategory::D3DWorkarounds, + "The HLSL optimizer has a bug with optimizing 'pow' in certain integer-valued expressions", + &members, + }; + + FeatureInfo flushAfterEndingTransformFeedback = { + "flushAfterEndingTransformFeedback", + FeatureCategory::D3DWorkarounds, + "Some drivers sometimes write out-of-order results to StreamOut buffers when transform " + "feedback is used to repeatedly write to the same buffer positions", + &members, + }; + + FeatureInfo getDimensionsIgnoresBaseLevel = { + "getDimensionsIgnoresBaseLevel", + FeatureCategory::D3DWorkarounds, + "Some drivers do not take into account the base level of the " + "texture in the results of the HLSL GetDimensions builtin", + &members, + }; + + FeatureInfo preAddTexelFetchOffsets = { + "preAddTexelFetchOffsets", + FeatureCategory::D3DWorkarounds, + "HLSL's function texture.Load returns 0 when the parameter Location is negative, even if " + "the sum of Offset and Location is in range", + &members, + }; + + FeatureInfo emulateTinyStencilTextures = { + "emulateTinyStencilTextures", + FeatureCategory::D3DWorkarounds, + "1x1 and 2x2 mips of depth/stencil textures aren't sampled correctly", + &members, + }; + + FeatureInfo disableB5G6R5Support = { + "disableB5G6R5Support", + FeatureCategory::D3DWorkarounds, + "Textures with the format " + "DXGI_FORMAT_B5G6R5_UNORM have incorrect data", + &members, + }; + + FeatureInfo rewriteUnaryMinusOperator = { + "rewriteUnaryMinusOperator", + FeatureCategory::D3DWorkarounds, + "Evaluating unary minus operator on integer may get wrong answer in vertex shaders", + &members, + }; + + FeatureInfo emulateIsnanFloat = {"emulateIsnanFloat", FeatureCategory::D3DWorkarounds, + "Using isnan() on highp float will get wrong answer", &members, + "https://crbug.com/650547"}; + + FeatureInfo callClearTwice = {"callClearTwice", FeatureCategory::D3DWorkarounds, + "Using clear() may not take effect", &members, + "https://crbug.com/655534"}; + + FeatureInfo emulateClearViewAfterDualSourceBlending = { + "emulateClearViewAfterDualSourceBlending", FeatureCategory::D3DWorkarounds, + "On Sandybridge, calling ClearView after using dual source blending causes hardware to " + "hang", + &members, "https://bugzilla.mozilla.org/show_bug.cgi?id=1633628"}; + + FeatureInfo scissoredClearArtifacts = { + "scissoredClearArtifacts", FeatureCategory::D3DWorkarounds, + "On Skylake, calling ClearView with a scissor rect that is not a multiple of 8x4 pixels " + "causes corruption of pixels in the 8x4 pixel tiles along the edge which resembles a " + "square wave", + &members, "https://bugzilla.mozilla.org/show_bug.cgi?id=1817240"}; + + FeatureInfo useSystemMemoryForConstantBuffers = { + "useSystemMemoryForConstantBuffers", FeatureCategory::D3DWorkarounds, + "Copying from staging storage to constant buffer " + "storage does not work", + &members, "https://crbug.com/593024"}; + + FeatureInfo selectViewInGeometryShader = { + "selectViewInGeometryShader", + FeatureCategory::D3DWorkarounds, + "The viewport or render target slice will be selected in the geometry shader stage for " + "the ANGLE_multiview extension", + &members, + }; + + FeatureInfo addMockTextureNoRenderTarget = { + "addMockTextureNoRenderTarget", FeatureCategory::D3DWorkarounds, + "On some drivers when rendering with no render target, two bugs lead to incorrect behavior", + &members, "http://anglebug.com/2152"}; + + FeatureInfo skipVSConstantRegisterZero = { + "skipVSConstantRegisterZero", + FeatureCategory::D3DWorkarounds, + "In specific cases the driver doesn't handle constant register zero correctly", + &members, + }; + + FeatureInfo forceAtomicValueResolution = { + "forceAtomicValueResolution", FeatureCategory::D3DWorkarounds, + "On some drivers the return value from RWByteAddressBuffer.InterlockedAdd does not resolve " + "when used in the .yzw components of a RWByteAddressBuffer.Store operation", + &members, "http://anglebug.com/3246"}; + + FeatureInfo allowClearForRobustResourceInit = { + "allowClearForRobustResourceInit", FeatureCategory::D3DWorkarounds, + "Some drivers corrupt texture data when clearing for robust resource initialization.", + &members, "http://crbug.com/941620"}; + + FeatureInfo allowTranslateUniformBlockToStructuredBuffer = { + "allowTranslateUniformBlockToStructuredBuffer", FeatureCategory::D3DWorkarounds, + "There is a slow fxc compile performance issue with dynamic uniform indexing if " + "translating a uniform block with a large array member to cbuffer.", + &members, "http://anglebug.com/3682"}; + + FeatureInfo allowES3OnFL100 = { + "allowES3OnFL100", + FeatureCategory::D3DWorkarounds, + "Allow ES3 on 10.0 devices", + &members, + }; + + FeatureInfo disableRasterizerOrderViews = { + "disableRasterizerOrderViews", FeatureCategory::D3DWorkarounds, "Disable ROVs for testing", + &members, "http://anglebug.com/7279"}; +}; + +inline FeaturesD3D::FeaturesD3D() = default; +inline FeaturesD3D::~FeaturesD3D() = default; + +} // namespace angle + +#endif // ANGLE_PLATFORM_FEATURESD3D_H_ diff --git a/gfx/angle/checkout/include/platform/FeaturesGL_autogen.h b/gfx/angle/checkout/include/platform/FeaturesGL_autogen.h new file mode 100644 index 0000000000..5376f3400a --- /dev/null +++ b/gfx/angle/checkout/include/platform/FeaturesGL_autogen.h @@ -0,0 +1,501 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by gen_features.py using data from gl_features.json. +// +// Copyright 2022 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// FeaturesGL_autogen.h: angle::Features and workarounds for GL driver bugs and other issues. + +#ifndef ANGLE_PLATFORM_FEATURESGL_H_ +#define ANGLE_PLATFORM_FEATURESGL_H_ + +#include "platform/Feature.h" + +namespace angle +{ + +struct FeaturesGL : FeatureSetBase +{ + FeaturesGL(); + ~FeaturesGL(); + + FeatureInfo avoid1BitAlphaTextureFormats = { + "avoid1BitAlphaTextureFormats", + FeatureCategory::OpenGLWorkarounds, + "Issue with 1-bit alpha framebuffer formats", + &members, + }; + + FeatureInfo RGBA4IsNotSupportedForColorRendering = { + "RGBA4IsNotSupportedForColorRendering", + FeatureCategory::OpenGLWorkarounds, + "GL_RGBA4 is not color renderable", + &members, + }; + + FeatureInfo allowETCFormats = { + "allowETCFormats", + FeatureCategory::OpenGLWorkarounds, + "Enable ETC2/EAC on desktop OpenGL", + &members, + }; + + FeatureInfo allowAstcFormats = { + "allowAstcFormats", + FeatureCategory::OpenGLWorkarounds, + "Enable ASTC on desktop OpenGL", + &members, + }; + + FeatureInfo doesSRGBClearsOnLinearFramebufferAttachments = { + "doesSRGBClearsOnLinearFramebufferAttachments", + FeatureCategory::OpenGLWorkarounds, + "Issue clearing framebuffers with linear attachments when GL_FRAMEBUFFER_SRGB is enabled", + &members, + }; + + FeatureInfo doWhileGLSLCausesGPUHang = { + "doWhileGLSLCausesGPUHang", FeatureCategory::OpenGLWorkarounds, + "Some GLSL constructs involving do-while loops cause GPU hangs", &members, + "http://crbug.com/644669"}; + + FeatureInfo vertexIDDoesNotIncludeBaseVertex = { + "vertexIDDoesNotIncludeBaseVertex", + FeatureCategory::OpenGLWorkarounds, + "gl_VertexID in GLSL vertex shader doesn't include base vertex value", + &members, + }; + + FeatureInfo finishDoesNotCauseQueriesToBeAvailable = { + "finishDoesNotCauseQueriesToBeAvailable", + FeatureCategory::OpenGLWorkarounds, + "glFinish doesn't cause all queries to report available result", + &members, + }; + + FeatureInfo alwaysCallUseProgramAfterLink = { + "alwaysCallUseProgramAfterLink", FeatureCategory::OpenGLWorkarounds, + "Always call useProgram after a successful link to avoid a driver bug", &members, + "http://crbug.com/110263"}; + + FeatureInfo unpackOverlappingRowsSeparatelyUnpackBuffer = { + "unpackOverlappingRowsSeparatelyUnpackBuffer", + FeatureCategory::OpenGLWorkarounds, + "In the case of unpacking from a pixel unpack buffer, unpack overlapping rows row by row", + &members, + }; + + FeatureInfo packOverlappingRowsSeparatelyPackBuffer = { + "packOverlappingRowsSeparatelyPackBuffer", + FeatureCategory::OpenGLWorkarounds, + "In the case of packing to a pixel pack buffer, pack overlapping rows row by row", + &members, + }; + + FeatureInfo initializeCurrentVertexAttributes = { + "initializeCurrentVertexAttributes", + FeatureCategory::OpenGLWorkarounds, + "During initialization, assign the current vertex attributes to the spec-mandated defaults", + &members, + }; + + FeatureInfo emulateAbsIntFunction = {"emulateAbsIntFunction", + FeatureCategory::OpenGLWorkarounds, + "abs(i) where i is an integer returns unexpected result", + &members, "http://crbug.com/642227"}; + + FeatureInfo addAndTrueToLoopCondition = { + "addAndTrueToLoopCondition", + FeatureCategory::OpenGLWorkarounds, + "Calculation of loop conditions in for and while loop has bug", + &members, + }; + + FeatureInfo unpackLastRowSeparatelyForPaddingInclusion = { + "unpackLastRowSeparatelyForPaddingInclusion", FeatureCategory::OpenGLWorkarounds, + "When uploading textures from an unpack buffer, some drivers count an extra row padding", + &members, "http://anglebug.com/1512"}; + + FeatureInfo packLastRowSeparatelyForPaddingInclusion = { + "packLastRowSeparatelyForPaddingInclusion", FeatureCategory::OpenGLWorkarounds, + "When uploading textures from an pack buffer, some drivers count an extra row padding", + &members, "http://anglebug.com/1512"}; + + FeatureInfo emulateIsnanFloat = {"emulateIsnanFloat", FeatureCategory::OpenGLWorkarounds, + "Using isnan() on highp float will get wrong answer", &members, + "http://crbug.com/650547"}; + + FeatureInfo useUnusedBlocksWithStandardOrSharedLayout = { + "useUnusedBlocksWithStandardOrSharedLayout", + FeatureCategory::OpenGLWorkarounds, + "Unused std140 or shared uniform blocks will be treated as inactive", + &members, + }; + + FeatureInfo removeInvariantAndCentroidForESSL3 = { + "removeInvariantAndCentroidForESSL3", + FeatureCategory::OpenGLWorkarounds, + "Fix spec difference between GLSL 4.1 or lower and ESSL3", + &members, + }; + + FeatureInfo rewriteFloatUnaryMinusOperator = { + "rewriteFloatUnaryMinusOperator", FeatureCategory::OpenGLWorkarounds, + "Using '-' will get wrong answer", &members, "http://crbug.com/308366"}; + + FeatureInfo emulateAtan2Float = {"emulateAtan2Float", FeatureCategory::OpenGLWorkarounds, + "atan(y, x) may return a wrong answer", &members, + "http://crbug.com/672380"}; + + FeatureInfo reapplyUBOBindingsAfterUsingBinaryProgram = { + "reapplyUBOBindingsAfterUsingBinaryProgram", FeatureCategory::OpenGLWorkarounds, + "Some drivers forget about UBO bindings when using program binaries", &members, + "http://anglebug.com/1637"}; + + FeatureInfo emulateMaxVertexAttribStride = { + "emulateMaxVertexAttribStride", FeatureCategory::OpenGLWorkarounds, + "Some drivers return 0 when MAX_VERTEX_ATTRIB_STRIED queried", &members, + "http://anglebug.com/1936"}; + + FeatureInfo dontInitializeUninitializedLocals = { + "dontInitializeUninitializedLocals", FeatureCategory::OpenGLWorkarounds, + "Initializing uninitialized locals caused odd behavior in a few WebGL 2 tests", &members, + "http://anglebug.com/2046"}; + + FeatureInfo clampPointSize = { + "clampPointSize", + FeatureCategory::OpenGLWorkarounds, + "The point size range reported from the API is inconsistent with the actual behavior", + &members, + }; + + FeatureInfo dontUseLoopsToInitializeVariables = { + "dontUseLoopsToInitializeVariables", FeatureCategory::OpenGLWorkarounds, + "For loops used to initialize variables hit native GLSL compiler bugs", &members, + "http://crbug.com/809422"}; + + FeatureInfo clampFragDepth = { + "clampFragDepth", + FeatureCategory::OpenGLWorkarounds, + "gl_FragDepth is not clamped correctly when rendering to a floating point depth buffer", + &members, + }; + + FeatureInfo rewriteRepeatedAssignToSwizzled = { + "rewriteRepeatedAssignToSwizzled", + FeatureCategory::OpenGLWorkarounds, + "Repeated assignment to swizzled values inside a " + "GLSL user-defined function have incorrect results", + &members, + }; + + FeatureInfo disableBlendFuncExtended = { + "disableBlendFuncExtended", FeatureCategory::OpenGLWorkarounds, + "ARB_blend_func_extended does not pass the tests", &members, "http://anglebug.com/1085"}; + + FeatureInfo unsizedSRGBReadPixelsDoesntTransform = { + "unsizedSRGBReadPixelsDoesntTransform", FeatureCategory::OpenGLWorkarounds, + "Drivers returning raw sRGB values instead of linearized values when calling glReadPixels " + "on unsized sRGB texture formats", + &members, "http://crbug.com/550292 http://crbug.com/565179"}; + + FeatureInfo queryCounterBitsGeneratesErrors = { + "queryCounterBitsGeneratesErrors", FeatureCategory::OpenGLWorkarounds, + "Drivers generate errors when querying the number of bits in timer queries", &members, + "http://anglebug.com/3027"}; + + FeatureInfo dontRelinkProgramsInParallel = { + "dontRelinkProgramsInParallel", FeatureCategory::OpenGLWorkarounds, + "Relinking a program in parallel is buggy", &members, "http://anglebug.com/3045"}; + + FeatureInfo disableWorkerContexts = {"disableWorkerContexts", + FeatureCategory::OpenGLWorkarounds, + "Some tests have been seen to fail using worker contexts", + &members, "http://crbug.com/849576"}; + + FeatureInfo limitWebglMaxTextureSizeTo4096 = { + "limitWebglMaxTextureSizeTo4096", FeatureCategory::OpenGLWorkarounds, + "Limit webgl max texture size to 4096 to avoid frequent " + "out-of-memory errors", + &members, "http://crbug.com/927470"}; + + FeatureInfo limitMaxMSAASamplesTo4 = { + "limitMaxMSAASamplesTo4", FeatureCategory::OpenGLWorkarounds, + "Various rendering bugs have been observed when using higher MSAA counts", &members, + "http://crbug.com/797243"}; + + FeatureInfo allowClearForRobustResourceInit = { + "allowClearForRobustResourceInit", FeatureCategory::OpenGLWorkarounds, + "Using glClear for robust resource initialization is buggy on some drivers and leads to " + "texture corruption. Default to data uploads except on MacOS where it is very slow.", + &members, "https://crbug.com/848952 http://crbug.com/883276"}; + + FeatureInfo clampArrayAccess = {"clampArrayAccess", FeatureCategory::OpenGLWorkarounds, + "Clamp uniform array access to avoid reading invalid memory.", + &members, "http://anglebug.com/2978"}; + + FeatureInfo resetTexImage2DBaseLevel = { + "resetTexImage2DBaseLevel", FeatureCategory::OpenGLWorkarounds, + "Reset texture base level before calling glTexImage2D to " + "work around pixel comparison failure.", + &members, "https://crbug.com/705865"}; + + FeatureInfo clearToZeroOrOneBroken = { + "clearToZeroOrOneBroken", FeatureCategory::OpenGLWorkarounds, + "Clears when the clear color is all zeros or ones do not work.", &members, + "https://crbug.com/710443"}; + + FeatureInfo limitMax3dArrayTextureSizeTo1024 = { + "limitMax3dArrayTextureSizeTo1024", FeatureCategory::OpenGLWorkarounds, + "Limit max 3d texture size and max array texture layers to 1024 to avoid system hang", + &members, "http://crbug.com/927470"}; + + FeatureInfo adjustSrcDstRegionForBlitFramebuffer = { + "adjustSrcDstRegionForBlitFramebuffer", FeatureCategory::OpenGLWorkarounds, + "Many platforms have issues with blitFramebuffer when the parameters are large.", &members, + "http://crbug.com/830046"}; + + FeatureInfo clipSrcRegionForBlitFramebuffer = { + "clipSrcRegionForBlitFramebuffer", FeatureCategory::OpenGLWorkarounds, + "Issues with blitFramebuffer when the parameters don't match the framebuffer size.", + &members, "http://crbug.com/830046"}; + + FeatureInfo RGBDXT1TexturesSampleZeroAlpha = { + "RGBDXT1TexturesSampleZeroAlpha", FeatureCategory::OpenGLWorkarounds, + "Sampling BLACK texels from RGB DXT1 textures returns transparent black on Mac.", &members, + "http://anglebug.com/3729"}; + + FeatureInfo unfoldShortCircuits = { + "unfoldShortCircuits", FeatureCategory::OpenGLWorkarounds, + "Mac incorrectly executes both sides of && and || expressions when they should " + "short-circuit.", + &members, "http://anglebug.com/482"}; + + FeatureInfo emulatePrimitiveRestartFixedIndex = { + "emulatePrimitiveRestartFixedIndex", FeatureCategory::OpenGLWorkarounds, + "When GL_PRIMITIVE_RESTART_FIXED_INDEX is not available, emulate it with " + "GL_PRIMITIVE_RESTART and glPrimitiveRestartIndex.", + &members, "http://anglebug.com/3997"}; + + FeatureInfo setPrimitiveRestartFixedIndexForDrawArrays = { + "setPrimitiveRestartFixedIndexForDrawArrays", FeatureCategory::OpenGLWorkarounds, + "Some drivers discard vertex data in DrawArrays calls when the fixed primitive restart " + "index is within the number of primitives being drawn.", + &members, "http://anglebug.com/3997"}; + + FeatureInfo removeDynamicIndexingOfSwizzledVector = { + "removeDynamicIndexingOfSwizzledVector", FeatureCategory::OpenGLWorkarounds, + "Dynamic indexing of swizzled l-values doesn't work correctly on various platforms.", + &members, "http://crbug.com/709351"}; + + FeatureInfo preAddTexelFetchOffsets = { + "preAddTexelFetchOffsets", FeatureCategory::OpenGLWorkarounds, + "Intel Mac drivers mistakenly consider the parameter position of nagative vaule as invalid " + "even if the sum of position and offset is in range, so we need to add workarounds by " + "rewriting texelFetchOffset(sampler, position, lod, offset) into texelFetch(sampler, " + "position + offset, lod).", + &members, "http://crbug.com/642605"}; + + FeatureInfo regenerateStructNames = { + "regenerateStructNames", FeatureCategory::OpenGLWorkarounds, + "All Mac drivers do not handle struct scopes correctly. This workaround overwrites a struct" + "name with a unique prefix.", + &members, "http://crbug.com/403957"}; + + FeatureInfo readPixelsUsingImplementationColorReadFormatForNorm16 = { + "readPixelsUsingImplementationColorReadFormatForNorm16", FeatureCategory::OpenGLWorkarounds, + "Quite some OpenGL ES drivers don't implement readPixels for RGBA/UNSIGNED_SHORT from " + "EXT_texture_norm16 correctly", + &members, "http://anglebug.com/4214"}; + + FeatureInfo flushBeforeDeleteTextureIfCopiedTo = { + "flushBeforeDeleteTextureIfCopiedTo", FeatureCategory::OpenGLWorkarounds, + "Some drivers track CopyTex{Sub}Image texture dependencies incorrectly. Flush" + " before glDeleteTextures in this case", + &members, "http://anglebug.com/4267"}; + + FeatureInfo rewriteRowMajorMatrices = { + "rewriteRowMajorMatrices", FeatureCategory::OpenGLWorkarounds, + "Rewrite row major matrices in shaders as column major as a driver bug workaround", + &members, "http://anglebug.com/2273"}; + + FeatureInfo disableDrawBuffersIndexed = { + "disableDrawBuffersIndexed", + FeatureCategory::OpenGLWorkarounds, + "Disable OES_draw_buffers_indexed extension.", + &members, + }; + + FeatureInfo disableSemaphoreFd = {"disableSemaphoreFd", FeatureCategory::OpenGLWorkarounds, + "Disable GL_EXT_semaphore_fd extension", &members, + "https://crbug.com/1046462"}; + + FeatureInfo disableTimestampQueries = { + "disableTimestampQueries", FeatureCategory::OpenGLWorkarounds, + "Disable GL_EXT_disjoint_timer_query extension", &members, "https://crbug.com/811661"}; + + FeatureInfo decodeEncodeSRGBForGenerateMipmap = { + "decodeEncodeSRGBForGenerateMipmap", FeatureCategory::OpenGLWorkarounds, + "Decode and encode before generateMipmap for srgb format textures.", &members, + "http://anglebug.com/4646"}; + + FeatureInfo emulateCopyTexImage2D = { + "emulateCopyTexImage2D", + FeatureCategory::OpenGLWorkarounds, + "Replace CopyTexImage2D with TexImage2D + CopyTexSubImage2D.", + &members, + }; + + FeatureInfo emulateCopyTexImage2DFromRenderbuffers = { + "emulateCopyTexImage2DFromRenderbuffers", FeatureCategory::OpenGLWorkarounds, + "CopyTexImage2D spuriously returns errors on iOS when copying from renderbuffers.", + &members, "https://anglebug.com/4674"}; + + FeatureInfo disableGPUSwitchingSupport = { + "disableGPUSwitchingSupport", FeatureCategory::OpenGLWorkarounds, + "Disable GPU switching support (use only the low-power GPU) on older MacBook Pros.", + &members, "https://crbug.com/1091824"}; + + FeatureInfo disableNativeParallelCompile = { + "disableNativeParallelCompile", FeatureCategory::OpenGLWorkarounds, + "Do not use native KHR_parallel_shader_compile even when available.", &members, + "http://crbug.com/1094869"}; + + FeatureInfo emulatePackSkipRowsAndPackSkipPixels = { + "emulatePackSkipRowsAndPackSkipPixels", FeatureCategory::OpenGLWorkarounds, + "GL_PACK_SKIP_ROWS and GL_PACK_SKIP_PIXELS are ignored in Apple's OpenGL driver.", &members, + "https://anglebug.com/4849"}; + + FeatureInfo clampMscRate = { + "clampMscRate", FeatureCategory::OpenGLWorkarounds, + "Some drivers return bogus values for GetMscRate, so we clamp it to 30Hz", &members, + "https://crbug.com/1042393"}; + + FeatureInfo bindTransformFeedbackBufferBeforeBindBufferRange = { + "bindTransformFeedbackBufferBeforeBindBufferRange", FeatureCategory::OpenGLWorkarounds, + "Bind transform feedback buffers to the generic binding point before calling " + "glBindBufferBase or glBindBufferRange.", + &members, "https://anglebug.com/5140"}; + + FeatureInfo disableSyncControlSupport = { + "disableSyncControlSupport", FeatureCategory::OpenGLWorkarounds, + "Speculative fix for issues on Linux/Wayland where exposing GLX_OML_sync_control renders " + "Chrome unusable", + &members, "https://crbug.com/1137851"}; + + FeatureInfo keepBufferShadowCopy = { + "keepBufferShadowCopy", + FeatureCategory::OpenGLWorkarounds, + "Maintain a shadow copy of buffer data when the GL API does not permit reading data back.", + &members, + }; + + FeatureInfo setZeroLevelBeforeGenerateMipmap = { + "setZeroLevelBeforeGenerateMipmap", + FeatureCategory::OpenGLWorkarounds, + "glGenerateMipmap fails if the zero texture level is not set on some Mac drivers.", + &members, + }; + + FeatureInfo promotePackedFormatsTo8BitPerChannel = { + "promotePackedFormatsTo8BitPerChannel", FeatureCategory::OpenGLWorkarounds, + "Packed color formats are buggy on Macs with AMD GPUs", &members, + "http://anglebug.com/5469"}; + + FeatureInfo initFragmentOutputVariables = { + "initFragmentOutputVariables", FeatureCategory::OpenGLWorkarounds, + "No init gl_FragColor causes context lost", &members, "http://crbug.com/1171371"}; + + FeatureInfo shiftInstancedArrayDataWithOffset = { + "shiftInstancedArrayDataWithOffset", FeatureCategory::OpenGLWorkarounds, + "glDrawArraysInstanced is buggy on certain new Mac Intel GPUs", &members, + "http://crbug.com/1144207"}; + + FeatureInfo syncVertexArraysToDefault = { + "syncVertexArraysToDefault", FeatureCategory::OpenGLWorkarounds, + "Only use the default VAO because of missing support or driver bugs", &members, + "http://anglebug.com/5577"}; + + FeatureInfo sanitizeAMDGPURendererString = { + "sanitizeAMDGPURendererString", FeatureCategory::OpenGLWorkarounds, + "Strip precise kernel and DRM version information from amdgpu renderer strings.", &members, + "http://crbug.com/1181193"}; + + FeatureInfo unbindFBOBeforeSwitchingContext = { + "unbindFBOBeforeSwitchingContext", FeatureCategory::OpenGLWorkarounds, + "Imagination GL drivers are buggy with context switching.", &members, + "http://crbug.com/1181193"}; + + FeatureInfo flushOnFramebufferChange = {"flushOnFramebufferChange", + FeatureCategory::OpenGLWorkarounds, + "Switching framebuffers without a flush can lead to " + "crashes on Intel 9th Generation GPU Macs.", + &members, "http://crbug.com/1181068"}; + + FeatureInfo disableMultisampledRenderToTexture = { + "disableMultisampledRenderToTexture", FeatureCategory::OpenGLWorkarounds, + "Many drivers have bugs when using GL_EXT_multisampled_render_to_texture", &members, + "http://anglebug.com/2894"}; + + FeatureInfo uploadTextureDataInChunks = { + "uploadTextureDataInChunks", FeatureCategory::OpenGLWorkarounds, + "Upload texture data in <120kb chunks to work around Mac driver hangs and crashes.", + &members, "http://crbug.com/1181068"}; + + FeatureInfo emulateImmutableCompressedTexture3D = { + "emulateImmutableCompressedTexture3D", FeatureCategory::OpenGLWorkarounds, + "Use non-immutable texture allocation to work around a driver bug.", &members, + "https://crbug.com/1060012"}; + + FeatureInfo emulateRGB10 = {"emulateRGB10", FeatureCategory::OpenGLWorkarounds, + "Emulate RGB10 support using RGB10_A2.", &members, + "https://crbug.com/1300575"}; + + FeatureInfo alwaysUnbindFramebufferTexture2D = { + "alwaysUnbindFramebufferTexture2D", FeatureCategory::OpenGLWorkarounds, + "Force unbind framebufferTexture2D before binding renderbuffer to work around driver bug.", + &members, "https://anglebug.com/5536"}; + + FeatureInfo disableTextureClampToBorder = { + "disableTextureClampToBorder", FeatureCategory::OpenGLWorkarounds, + "Imagination devices generate INVALID_ENUM when setting the texture border color.", + &members, "https://anglebug.com/7405"}; + + FeatureInfo passHighpToPackUnormSnormBuiltins = { + "passHighpToPackUnormSnormBuiltins", FeatureCategory::OpenGLWorkarounds, + "packUnorm4x8 fails on Pixel 4 if it is not passed a highp vec4.", &members, + "http://anglebug.com/7527"}; + + FeatureInfo supportsFragmentShaderInterlockNV = { + "supportsFragmentShaderInterlockNV", FeatureCategory::OpenGLFeatures, + "Backend GL context supports NV_fragment_shader_interlock extension", &members, + "http://anglebug.com/7279"}; + + FeatureInfo supportsFragmentShaderOrderingINTEL = { + "supportsFragmentShaderOrderingINTEL", FeatureCategory::OpenGLFeatures, + "Backend GL context supports GL_INTEL_fragment_shader_ordering extension", &members, + "http://anglebug.com/7279"}; + + FeatureInfo supportsFragmentShaderInterlockARB = { + "supportsFragmentShaderInterlockARB", FeatureCategory::OpenGLFeatures, + "Backend GL context supports ARB_fragment_shader_interlock extension", &members, + "http://anglebug.com/7279"}; + + FeatureInfo supportsShaderFramebufferFetchEXT = { + "supportsShaderFramebufferFetchEXT", FeatureCategory::OpenGLFeatures, + "Backend GL context supports EXT_shader_framebuffer_fetch extension", &members, + "http://anglebug.com/7279"}; + + FeatureInfo supportsShaderFramebufferFetchNonCoherentEXT = { + "supportsShaderFramebufferFetchNonCoherentEXT", FeatureCategory::OpenGLFeatures, + "Backend GL context supports EXT_shader_framebuffer_fetch_non_coherent extension", &members, + "http://anglebug.com/7279"}; +}; + +inline FeaturesGL::FeaturesGL() = default; +inline FeaturesGL::~FeaturesGL() = default; + +} // namespace angle + +#endif // ANGLE_PLATFORM_FEATURESGL_H_ diff --git a/gfx/angle/checkout/include/platform/FeaturesMtl_autogen.h b/gfx/angle/checkout/include/platform/FeaturesMtl_autogen.h new file mode 100644 index 0000000000..116a0ee8d7 --- /dev/null +++ b/gfx/angle/checkout/include/platform/FeaturesMtl_autogen.h @@ -0,0 +1,242 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by gen_features.py using data from mtl_features.json. +// +// Copyright 2022 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// FeaturesMtl_autogen.h: Optional features for the Metal renderer. + +#ifndef ANGLE_PLATFORM_FEATURESMTL_H_ +#define ANGLE_PLATFORM_FEATURESMTL_H_ + +#include "platform/Feature.h" + +namespace angle +{ + +struct FeaturesMtl : FeatureSetBase +{ + FeaturesMtl(); + ~FeaturesMtl(); + + FeatureInfo hasBaseVertexInstancedDraw = { + "hasBaseVertexInstancedDraw", + FeatureCategory::MetalFeatures, + "The renderer supports base vertex instanced draw", + &members, + }; + + FeatureInfo hasExplicitMemBarrier = { + "hasExplicitMemBarrier", + FeatureCategory::MetalFeatures, + "The renderer supports explicit memory barrier", + &members, + }; + + FeatureInfo hasCheapRenderPass = { + "hasCheapRenderPass", + FeatureCategory::MetalFeatures, + "The renderer can cheaply break a render pass.", + &members, + }; + + FeatureInfo hasNonUniformDispatch = { + "hasNonUniformDispatch", + FeatureCategory::MetalFeatures, + "The renderer supports non uniform compute shader dispatch's group size", + &members, + }; + + FeatureInfo hasShaderStencilOutput = { + "hasShaderStencilOutput", + FeatureCategory::MetalFeatures, + "The renderer supports stencil output from fragment shader", + &members, + }; + + FeatureInfo hasTextureSwizzle = { + "hasTextureSwizzle", + FeatureCategory::MetalFeatures, + "The renderer supports texture swizzle", + &members, + }; + + FeatureInfo hasDepthAutoResolve = { + "hasDepthAutoResolve", + FeatureCategory::MetalFeatures, + "The renderer supports MSAA depth auto resolve at the end of render pass", + &members, + }; + + FeatureInfo hasStencilAutoResolve = { + "hasStencilAutoResolve", + FeatureCategory::MetalFeatures, + "The renderer supports MSAA stencil auto resolve at the end of render pass", + &members, + }; + + FeatureInfo hasEvents = { + "hasEvents", + FeatureCategory::MetalFeatures, + "The renderer supports MTL(Shared)Event", + &members, + }; + + FeatureInfo allowInlineConstVertexData = { + "allowInlineConstVertexData", + FeatureCategory::MetalFeatures, + "The renderer supports using inline constant data for small client vertex data", + &members, + }; + + FeatureInfo allowSeparateDepthStencilBuffers = { + "allowSeparateDepthStencilBuffers", + FeatureCategory::MetalFeatures, + "Some Apple platforms such as iOS allows separate depth and stencil buffers, " + "whereas others such as macOS don't", + &members, + }; + + FeatureInfo allowRuntimeSamplerCompareMode = { + "allowRuntimeSamplerCompareMode", + FeatureCategory::MetalFeatures, + "The renderer supports changing sampler's compare mode outside shaders", + &members, + }; + + FeatureInfo allowSamplerCompareGradient = { + "allowSamplerCompareGradient", + FeatureCategory::MetalFeatures, + "The renderer supports sample_compare with gradients", + &members, + }; + + FeatureInfo allowSamplerCompareLod = { + "allowSamplerCompareLod", + FeatureCategory::MetalFeatures, + "The renderer supports sample_compare with lod", + &members, + }; + + FeatureInfo allowBufferReadWrite = { + "allowBufferReadWrite", + FeatureCategory::MetalFeatures, + "The renderer supports buffer read and write in the same shader", + &members, + }; + + FeatureInfo allowMultisampleStoreAndResolve = { + "allowMultisampleStoreAndResolve", + FeatureCategory::MetalFeatures, + "The renderer supports MSAA store and resolve in the same pass", + &members, + }; + + FeatureInfo allowGenMultipleMipsPerPass = { + "allowGenMultipleMipsPerPass", + FeatureCategory::MetalFeatures, + "The renderer supports generating multiple mipmaps per pass", + &members, + }; + + FeatureInfo forceD24S8AsUnsupported = { + "forceD24S8AsUnsupported", + FeatureCategory::MetalFeatures, + "Force Depth24Stencil8 format as unsupported.", + &members, + }; + + FeatureInfo forceBufferGPUStorage = { + "forceBufferGPUStorage", + FeatureCategory::MetalFeatures, + "On systems that support both buffer' memory allocation on GPU and shared memory (such as " + "macOS), force using GPU memory allocation for buffers everytime or not.", + &members, + }; + + FeatureInfo directMetalGeneration = {"directMetalGeneration", FeatureCategory::MetalFeatures, + "Direct translation to Metal.", &members, + "http://anglebug.com/5505"}; + + FeatureInfo forceNonCSBaseMipmapGeneration = { + "forceNonCSBaseMipmapGeneration", + FeatureCategory::MetalFeatures, + "Turn this feature on to disallow Compute Shader based mipmap generation. Compute Shader " + "based mipmap generation might cause GPU hang on some older iOS devices.", + &members, + }; + + FeatureInfo emulateTransformFeedback = { + "emulateTransformFeedback", + FeatureCategory::MetalFeatures, + "Turn this on to allow transform feedback in Metal using a 2-pass VS for GLES3.", + &members, + }; + + FeatureInfo rewriteRowMajorMatrices = { + "rewriteRowMajorMatrices", + FeatureCategory::MetalFeatures, + "Rewrite row major matrices in shaders as column major.", + &members, + }; + + FeatureInfo intelExplicitBoolCastWorkaround = { + "intelExplicitBoolCastWorkaround", + FeatureCategory::MetalWorkarounds, + "Insert explicit casts for float/double/unsigned/signed int on macOS 10.15 with Intel " + "driver", + &members, + }; + + FeatureInfo intelDisableFastMath = { + "intelDisableFastMath", + FeatureCategory::MetalWorkarounds, + "Disable fast math in atan and invariance cases when running below macOS 12.0", + &members, + }; + + FeatureInfo multisampleColorFormatShaderReadWorkaround = { + "multisampleColorFormatShaderReadWorkaround", FeatureCategory::MetalWorkarounds, + "Add shaderRead usage to some multisampled texture formats", &members, + "http://anglebug.com/7049"}; + + FeatureInfo copyIOSurfaceToNonIOSurfaceForReadOptimization = { + "copyIOSurfaceToNonIOSurfaceForReadOptimization", FeatureCategory::MetalWorkarounds, + "some GPUs are faster to read an IOSurface texture by first copying the texture to a " + "non-IOSurface texture", + &members, "http://anglebug.com/7117 http://anglebug.com/7573"}; + + FeatureInfo copyTextureToBufferForReadOptimization = { + "copyTextureToBufferForReadOptimization", FeatureCategory::MetalWorkarounds, + "some GPUs are faster to read a texture by first copying the texture to a buffer", &members, + "http://anglebug.com/7117"}; + + FeatureInfo limitMaxDrawBuffersForTesting = { + "limitMaxDrawBuffersForTesting", FeatureCategory::MetalFeatures, + "Used to check the backend works when the device's advertized limit is less than the " + "code's limit", + &members, "http://anglebug.com/7280"}; + + FeatureInfo limitMaxColorTargetBitsForTesting = { + "limitMaxColorTargetBitsForTesting", FeatureCategory::MetalFeatures, + "Metal iOS has a limit on the number of color target bits per pixel.", &members, + "http://anglebug.com/7280"}; + + FeatureInfo preemptivelyStartProvokingVertexCommandBuffer = { + "preemptivelyStartProvokingVertexCommandBuffer", FeatureCategory::MetalFeatures, + "AMD Metal Drivers appear to have a bug this works around", &members, + "http://anglebug.com/7635"}; + + FeatureInfo uploadDataToIosurfacesWithStagingBuffers = { + "uploadDataToIosurfacesWithStagingBuffers", FeatureCategory::MetalWorkarounds, + "When uploading data to IOSurface-backed textures, use a staging buffer.", &members, + "http://anglebug.com/7573"}; +}; + +inline FeaturesMtl::FeaturesMtl() = default; +inline FeaturesMtl::~FeaturesMtl() = default; + +} // namespace angle + +#endif // ANGLE_PLATFORM_FEATURESMTL_H_ diff --git a/gfx/angle/checkout/include/platform/FeaturesVk_autogen.h b/gfx/angle/checkout/include/platform/FeaturesVk_autogen.h new file mode 100644 index 0000000000..dadd64c49b --- /dev/null +++ b/gfx/angle/checkout/include/platform/FeaturesVk_autogen.h @@ -0,0 +1,786 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by gen_features.py using data from vk_features.json. +// +// Copyright 2022 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// FeaturesVk_autogen.h: Optional features for the Vulkan renderer. + +#ifndef ANGLE_PLATFORM_FEATURESVK_H_ +#define ANGLE_PLATFORM_FEATURESVK_H_ + +#include "platform/Feature.h" + +namespace angle +{ + +struct FeaturesVk : FeatureSetBase +{ + FeaturesVk(); + ~FeaturesVk(); + + FeatureInfo bresenhamLineRasterization = { + "bresenhamLineRasterization", + FeatureCategory::VulkanFeatures, + "Enable Bresenham line rasterization via VK_EXT_line_rasterization extension", + &members, + }; + + FeatureInfo provokingVertex = { + "provokingVertex", + FeatureCategory::VulkanFeatures, + "Enable provoking vertex mode via VK_EXT_provoking_vertex extension", + &members, + }; + + FeatureInfo forceFallbackFormat = { + "forceFallbackFormat", + FeatureCategory::VulkanWorkarounds, + "Force a fallback format for angle_end2end_tests", + &members, + }; + + FeatureInfo clampPointSize = { + "clampPointSize", FeatureCategory::VulkanWorkarounds, + "The point size range reported from the API is inconsistent with the actual behavior", + &members, "http://anglebug.com/2970"}; + + FeatureInfo depthClamping = { + "depthClamping", FeatureCategory::VulkanWorkarounds, + "The depth value is not clamped to [0,1] for floating point depth buffers.", &members, + "http://anglebug.com/3970"}; + + FeatureInfo mutableMipmapTextureUpload = { + "mutableMipmapTextureUpload", FeatureCategory::VulkanFeatures, + "Enable uploading the previously defined mutable mipmap texture.", &members, + "https://anglebug.com/7308"}; + + FeatureInfo supportsRenderpass2 = { + "supportsRenderpass2", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_KHR_create_renderpass2 extension", + &members, + }; + + FeatureInfo supportsIncrementalPresent = { + "supportsIncrementalPresent", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_KHR_incremental_present extension", + &members, + }; + + FeatureInfo supportsAndroidHardwareBuffer = { + "supportsAndroidHardwareBuffer", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_ANDROID_external_memory_android_hardware_buffer extension", + &members, + }; + + FeatureInfo supportsGGPFrameToken = { + "supportsGGPFrameToken", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_GGP_frame_token extension", + &members, + }; + + FeatureInfo supportsExternalMemoryFd = { + "supportsExternalMemoryFd", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_KHR_external_memory_fd extension", + &members, + }; + + FeatureInfo supportsExternalMemoryFuchsia = { + "supportsExternalMemoryFuchsia", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_FUCHSIA_external_memory extension", + &members, + }; + + FeatureInfo supportsFilteringPrecision = { + "supportsFilteringPrecision", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_GOOGLE_sampler_filtering_precision extension", + &members, + }; + + FeatureInfo supportsExternalFenceCapabilities = { + "supportsExternalFenceCapabilities", + FeatureCategory::VulkanFeatures, + "VkInstance supports the VK_KHR_external_fence_capabilities extension", + &members, + }; + + FeatureInfo supportsExternalSemaphoreCapabilities = { + "supportsExternalSemaphoreCapabilities", + FeatureCategory::VulkanFeatures, + "VkInstance supports the VK_KHR_external_semaphore_capabilities extension", + &members, + }; + + FeatureInfo supportsExternalSemaphoreFd = { + "supportsExternalSemaphoreFd", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_KHR_external_semaphore_fd extension", + &members, + }; + + FeatureInfo supportsExternalSemaphoreFuchsia = { + "supportsExternalSemaphoreFuchsia", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_FUCHSIA_external_semaphore extension", + &members, + }; + + FeatureInfo supportsExternalFenceFd = { + "supportsExternalFenceFd", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_KHR_external_fence_fd extension", &members, + "http://anglebug.com/2517"}; + + FeatureInfo supportsAndroidNativeFenceSync = { + "supportsAndroidNativeFenceSync", FeatureCategory::VulkanFeatures, + "VkDevice supports the EGL_ANDROID_native_fence_sync extension", &members, + "http://anglebug.com/2517"}; + + FeatureInfo supportsImageCubeArray = {"supportsImageCubeArray", FeatureCategory::VulkanFeatures, + "VkDevice supports the imageCubeArray feature properly", + &members, "http://anglebug.com/3584"}; + + FeatureInfo supportsPipelineStatisticsQuery = { + "supportsPipelineStatisticsQuery", FeatureCategory::VulkanFeatures, + "VkDevice supports the pipelineStatisticsQuery feature", &members, + "http://anglebug.com/5430"}; + + FeatureInfo supportsShaderStencilExport = { + "supportsShaderStencilExport", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_EXT_shader_stencil_export extension", + &members, + }; + + FeatureInfo supportsYUVSamplerConversion = { + "supportsYUVSamplerConversion", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_KHR_sampler_ycbcr_conversion extension", + &members, + }; + + FeatureInfo emulateTransformFeedback = { + "emulateTransformFeedback", FeatureCategory::VulkanFeatures, + "Emulate transform feedback as the VK_EXT_transform_feedback is not present.", &members, + "http://anglebug.com/3205"}; + + FeatureInfo supportsTransformFeedbackExtension = { + "supportsTransformFeedbackExtension", FeatureCategory::VulkanFeatures, + "Transform feedback uses the VK_EXT_transform_feedback extension.", &members, + "http://anglebug.com/3206"}; + + FeatureInfo supportsGeometryStreamsCapability = { + "supportsGeometryStreamsCapability", FeatureCategory::VulkanFeatures, + "Implementation supports the GeometryStreams SPIR-V capability.", &members, + "http://anglebug.com/3206"}; + + FeatureInfo supportsIndexTypeUint8 = {"supportsIndexTypeUint8", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_EXT_index_type_uint8 extension", + &members, "http://anglebug.com/4405"}; + + FeatureInfo supportsCustomBorderColor = { + "supportsCustomBorderColor", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_EXT_custom_border_color extension", &members, + "http://anglebug.com/3577"}; + + FeatureInfo supportsMultiDrawIndirect = { + "supportsMultiDrawIndirect", FeatureCategory::VulkanFeatures, + "VkDevice supports the multiDrawIndirect extension", &members, "http://anglebug.com/6439"}; + + FeatureInfo supportsDepthStencilResolve = {"supportsDepthStencilResolve", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_KHR_depth_stencil_resolve " + "extension with the independentResolveNone feature", + &members, "http://anglebug.com/4836"}; + + FeatureInfo supportsMultisampledRenderToSingleSampledGOOGLEX = { + "supportsMultisampledRenderToSingleSampledGOOGLEX", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_GOOGLEX_multisampled_render_to_single_sampled extension", + &members, "http://anglebug.com/4836"}; + + FeatureInfo supportsMultisampledRenderToSingleSampled = { + "supportsMultisampledRenderToSingleSampled", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_EXT_multisampled_render_to_single_sampled extension", &members, + "http://anglebug.com/4836"}; + + FeatureInfo supportsMultiview = {"supportsMultiview", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_KHR_multiview extension", &members, + "http://anglebug.com/6048"}; + + FeatureInfo disableFifoPresentMode = { + "disableFifoPresentMode", FeatureCategory::VulkanWorkarounds, + "VK_PRESENT_MODE_FIFO_KHR causes random timeouts", &members, "http://anglebug.com/3153"}; + + FeatureInfo forceD16TexFilter = { + "forceD16TexFilter", FeatureCategory::VulkanWorkarounds, + "VK_FORMAT_D16_UNORM does not support VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_LINEAR_BIT, " + "which prevents OES_depth_texture from being supported.", + &members, "http://anglebug.com/3452"}; + + FeatureInfo disableFlippingBlitWithCommand = { + "disableFlippingBlitWithCommand", FeatureCategory::VulkanWorkarounds, + "vkCmdBlitImage with flipped coordinates blits incorrectly.", &members, + "http://anglebug.com/3498"}; + + FeatureInfo perFrameWindowSizeQuery = { + "perFrameWindowSizeQuery", FeatureCategory::VulkanWorkarounds, + "Vulkan swapchain is not returning VK_ERROR_OUT_OF_DATE when window resizing", &members, + "http://anglebug.com/3623, http://anglebug.com/3624, http://anglebug.com/3625"}; + + FeatureInfo padBuffersToMaxVertexAttribStride = { + "padBuffersToMaxVertexAttribStride", FeatureCategory::VulkanWorkarounds, + "Vulkan considers vertex attribute accesses to count up to the last multiple of the " + "stride. This additional access supports AMD's robust buffer access implementation. " + "AMDVLK in particular will return incorrect values when the vertex access extends into " + "the range that would be the stride padding and the buffer is too small. " + "This workaround limits GL_MAX_VERTEX_ATTRIB_STRIDE to a maximum value and " + "pads up every buffer allocation size to be a multiple of the maximum stride.", + &members, "http://anglebug.com/4428"}; + + FeatureInfo supportsExternalMemoryDmaBufAndModifiers = { + "supportsExternalMemoryDmaBufAndModifiers", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_EXT_external_memory_dma_buf and VK_EXT_image_drm_format_modifier " + "extensions", + &members, "http://anglebug.com/6248"}; + + FeatureInfo supportsExternalMemoryHost = { + "supportsExternalMemoryHost", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_EXT_external_memory_host extension", + &members, + }; + + FeatureInfo allocateNonZeroMemory = { + "allocateNonZeroMemory", FeatureCategory::VulkanFeatures, + "Fill new allocations with non-zero values to flush out errors.", &members, + "http://anglebug.com/4384"}; + + FeatureInfo logMemoryReportCallbacks = { + "logMemoryReportCallbacks", + FeatureCategory::VulkanFeatures, + "Log each callback from VK_EXT_device_memory_report", + &members, + }; + + FeatureInfo logMemoryReportStats = { + "logMemoryReportStats", + FeatureCategory::VulkanFeatures, + "Log stats from VK_EXT_device_memory_report each swap", + &members, + }; + + FeatureInfo shadowBuffers = { + "shadowBuffers", FeatureCategory::VulkanFeatures, + "Allocate a shadow buffer for GL buffer objects to reduce glMap* latency.", &members, + "http://anglebug.com/4339"}; + + FeatureInfo preferCPUForBufferSubData = { + "preferCPUForBufferSubData", FeatureCategory::VulkanFeatures, + "Prefer use CPU to do bufferSubData instead of staged update.", &members, + "http://issuetracker.google.com/200067929"}; + + FeatureInfo persistentlyMappedBuffers = { + "persistentlyMappedBuffers", FeatureCategory::VulkanFeatures, + "Persistently map buffer memory to reduce map/unmap IOCTL overhead.", &members, + "http://anglebug.com/2162"}; + + FeatureInfo enablePreRotateSurfaces = {"enablePreRotateSurfaces", + FeatureCategory::VulkanFeatures, + "Enable Android pre-rotation for landscape applications", + &members, "http://anglebug.com/3502"}; + + FeatureInfo enablePrecisionQualifiers = { + "enablePrecisionQualifiers", FeatureCategory::VulkanFeatures, + "Enable precision qualifiers in shaders", &members, "http://anglebug.com/3078"}; + + FeatureInfo preferAggregateBarrierCalls = { + "preferAggregateBarrierCalls", FeatureCategory::VulkanWorkarounds, + "Single barrier call is preferred over multiple calls with " + "fine grained pipeline stage dependency information", + &members, "http://anglebug.com/4633"}; + + FeatureInfo preferSkippingInvalidateForEmulatedFormats = { + "preferSkippingInvalidateForEmulatedFormats", FeatureCategory::VulkanWorkarounds, + "Skipping invalidate is preferred for emulated formats that have extra channels over " + "re-clearing the image", + &members, "http://anglebug.com/6860"}; + + FeatureInfo asyncCommandQueue = {"asyncCommandQueue", FeatureCategory::VulkanFeatures, + "Use CommandQueue worker thread to dispatch work to GPU.", + &members, "http://anglebug.com/4324"}; + + FeatureInfo supportsShaderFloat16 = { + "supportsShaderFloat16", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_KHR_shader_float16_int8 extension " + "and has the shaderFloat16 feature", + &members, "http://anglebug.com/4551"}; + + FeatureInfo allowGenerateMipmapWithCompute = { + "allowGenerateMipmapWithCompute", FeatureCategory::VulkanFeatures, + "Use the compute path to generate mipmaps on devices that meet the minimum requirements, " + "and the performance is better.", + &members, "http://anglebug.com/4551"}; + + FeatureInfo supportsRenderPassStoreOpNone = { + "supportsRenderPassStoreOpNone", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_QCOM_render_pass_store_ops extension.", &members, + "http://anglebug.com/5055"}; + + FeatureInfo supportsRenderPassLoadStoreOpNone = { + "supportsRenderPassLoadStoreOpNone", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_load_store_op_none extension.", &members, + "http://anglebug.com/5371"}; + + FeatureInfo disallowMixedDepthStencilLoadOpNoneAndLoad = { + "disallowMixedDepthStencilLoadOpNoneAndLoad", FeatureCategory::VulkanWorkarounds, + "Disallow use of LOAD_OP_NONE for only one of the depth or stencil aspects of a " + "depth/stencil attachment", + &members, "http://anglebug.com/7370"}; + + FeatureInfo supportsDepthClipControl = { + "supportsDepthClipControl", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_depth_clip_control extension.", &members, + "http://anglebug.com/5421"}; + + FeatureInfo supportsPrimitiveTopologyListRestart = { + "supportsPrimitiveTopologyListRestart", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_primitive_topology_list_restart extension.", &members, + "http://anglebug.com/3832"}; + + FeatureInfo supportsBlendOperationAdvanced = { + "supportsBlendOperationAdvanced", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_blend_operation_advanced extension.", &members, + "http://anglebug.com/3586"}; + + FeatureInfo forceMaxUniformBufferSize16KB = { + "forceMaxUniformBufferSize16KB", FeatureCategory::VulkanWorkarounds, + "Force max uniform buffer size to 16K on some device due to bug", &members, + "https://issuetracker.google.com/161903006"}; + + FeatureInfo supportsImageFormatList = { + "supportsImageFormatList", FeatureCategory::VulkanFeatures, + "Enable VK_IMAGE_CREATE_MUTABLE_FORMAT_BIT by default for ICDs " + "that support VK_KHR_image_format_list", + &members, "http://anglebug.com/5281"}; + + FeatureInfo enableMultisampledRenderToTexture = { + "enableMultisampledRenderToTexture", FeatureCategory::VulkanWorkarounds, + "Expose EXT_multisampled_render_to_texture", &members, "http://anglebug.com/4937"}; + + FeatureInfo deferFlushUntilEndRenderPass = { + "deferFlushUntilEndRenderPass", FeatureCategory::VulkanWorkarounds, + "Allow glFlush to be deferred until renderpass ends", &members, + "https://issuetracker.google.com/issues/166475273"}; + + FeatureInfo waitIdleBeforeSwapchainRecreation = { + "waitIdleBeforeSwapchainRecreation", FeatureCategory::VulkanWorkarounds, + "Before passing an oldSwapchain to VkSwapchainCreateInfoKHR, wait for queue to be idle. " + "Works around a bug on platforms which destroy oldSwapchain in vkCreateSwapchainKHR.", + &members, "http://anglebug.com/5061"}; + + FeatureInfo forceTextureLodOffset1 = { + "forceTextureLodOffset1", + FeatureCategory::VulkanWorkarounds, + "Increase the minimum texture level-of-detail by 1 when sampling.", + &members, + }; + + FeatureInfo forceTextureLodOffset2 = { + "forceTextureLodOffset2", + FeatureCategory::VulkanWorkarounds, + "Increase the minimum texture level-of-detail by 2 when sampling.", + &members, + }; + + FeatureInfo forceTextureLodOffset3 = { + "forceTextureLodOffset3", + FeatureCategory::VulkanWorkarounds, + "Increase the minimum texture level-of-detail by 3 when sampling.", + &members, + }; + + FeatureInfo forceTextureLodOffset4 = { + "forceTextureLodOffset4", + FeatureCategory::VulkanWorkarounds, + "Increase the minimum texture level-of-detail by 4 when sampling.", + &members, + }; + + FeatureInfo forceNearestFiltering = { + "forceNearestFiltering", + FeatureCategory::VulkanWorkarounds, + "Force nearest filtering when sampling.", + &members, + }; + + FeatureInfo forceNearestMipFiltering = { + "forceNearestMipFiltering", + FeatureCategory::VulkanWorkarounds, + "Force nearest mip filtering when sampling.", + &members, + }; + + FeatureInfo compressVertexData = { + "compressVertexData", + FeatureCategory::VulkanWorkarounds, + "Compress vertex data to smaller data types when " + "possible. Using this feature makes ANGLE non-conformant.", + &members, + }; + + FeatureInfo preferDrawClearOverVkCmdClearAttachments = { + "preferDrawClearOverVkCmdClearAttachments", FeatureCategory::VulkanWorkarounds, + "On some hardware, clear using a draw call instead of vkCmdClearAttachments in the middle " + "of render pass due to bugs", + &members, "https://issuetracker.google.com/166809097"}; + + FeatureInfo emulatedPrerotation90 = {"emulatedPrerotation90", FeatureCategory::VulkanFeatures, + "Emulate 90-degree prerotation.", &members, + "http://anglebug.com/4901"}; + + FeatureInfo emulatedPrerotation180 = {"emulatedPrerotation180", FeatureCategory::VulkanFeatures, + "Emulate 180-degree prerotation.", &members, + "http://anglebug.com/4901"}; + + FeatureInfo emulatedPrerotation270 = {"emulatedPrerotation270", FeatureCategory::VulkanFeatures, + "Emulate 270-degree prerotation.", &members, + "http://anglebug.com/4901"}; + + FeatureInfo generateSPIRVThroughGlslang = { + "generateSPIRVThroughGlslang", FeatureCategory::VulkanFeatures, + "Translate SPIR-V through glslang.", &members, "http://anglebug.com/4889"}; + + FeatureInfo preferDriverUniformOverSpecConst = { + "preferDriverUniformOverSpecConst", FeatureCategory::VulkanFeatures, + "Prefer using driver uniforms instead of specialization constants.", &members, + "http://anglebug.com/7406"}; + + FeatureInfo exposeNonConformantExtensionsAndVersions = { + "exposeNonConformantExtensionsAndVersions", FeatureCategory::VulkanWorkarounds, + "Expose GLES versions and extensions that are not conformant.", &members, + "http://anglebug.com/5375"}; + + FeatureInfo emulateR32fImageAtomicExchange = { + "emulateR32fImageAtomicExchange", FeatureCategory::VulkanWorkarounds, + "Emulate r32f images with r32ui to support imageAtomicExchange.", &members, + "http://anglebug.com/5535"}; + + FeatureInfo supportsNegativeViewport = { + "supportsNegativeViewport", + FeatureCategory::VulkanFeatures, + "The driver supports inverting the viewport with a negative height.", + &members, + }; + + FeatureInfo forceFragmentShaderPrecisionHighpToMediump = { + "forceFragmentShaderPrecisionHighpToMediump", FeatureCategory::VulkanWorkarounds, + "Forces highp precision in fragment shader to mediump.", &members, + "https://issuetracker.google.com/184850002"}; + + FeatureInfo preferSubmitAtFBOBoundary = { + "preferSubmitAtFBOBoundary", FeatureCategory::VulkanWorkarounds, + "Submit commands to driver at each FBO boundary for performance improvements.", &members, + "https://issuetracker.google.com/187425444"}; + + FeatureInfo useMultipleDescriptorsForExternalFormats = { + "useMultipleDescriptorsForExternalFormats", FeatureCategory::VulkanWorkarounds, + "Return a default descriptor count for external formats.", &members, + "http://anglebug.com/6141"}; + + FeatureInfo supportsProtectedMemory = { + "supportsProtectedMemory", FeatureCategory::VulkanFeatures, + "VkDevice supports protected memory", &members, "http://anglebug.com/3965"}; + + FeatureInfo supportsHostQueryReset = {"supportsHostQueryReset", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_host_query_reset extension", + &members, "http://anglebug.com/6692"}; + + FeatureInfo supportsPipelineCreationCacheControl = { + "supportsPipelineCreationCacheControl", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_pipeline_creation_cache_control extension", &members, + "http://anglebug.com/5881"}; + + FeatureInfo supportsPipelineCreationFeedback = { + "supportsPipelineCreationFeedback", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_pipeline_creation_feedback extension", &members, + "http://anglebug.com/5881"}; + + FeatureInfo supportsPrimitivesGeneratedQuery = { + "supportsPrimitivesGeneratedQuery", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_primitives_generated_query extension", &members, + "http://anglebug.com/5430"}; + + FeatureInfo supportsSurfaceCapabilities2Extension = { + "supportsSurfaceCapabilities2Extension", + FeatureCategory::VulkanFeatures, + "VkInstance supports the VK_KHR_get_surface_capabilities2 extension", + &members, + }; + + FeatureInfo supportsSurfaceProtectedCapabilitiesExtension = { + "supportsSurfaceProtectedCapabilitiesExtension", + FeatureCategory::VulkanFeatures, + "VkInstance supports the VK_KHR_surface_protected_capabilities extension", + &members, + }; + + FeatureInfo supportsSurfacelessQueryExtension = { + "supportsSurfacelessQueryExtension", + FeatureCategory::VulkanFeatures, + "VkInstance supports the VK_GOOGLE_surfaceless_query extension", + &members, + }; + + FeatureInfo supportsSurfaceProtectedSwapchains = { + "supportsSurfaceProtectedSwapchains", + FeatureCategory::VulkanFeatures, + "VkSurface supportsProtected for protected swapchains", + &members, + }; + + FeatureInfo overrideSurfaceFormatRGB8ToRGBA8 = { + "overrideSurfaceFormatRGB8ToRGBA8", FeatureCategory::VulkanWorkarounds, + "Override surface format GL_RGB8 to GL_RGBA8", &members, "http://anglebug.com/6651"}; + + FeatureInfo supportsSharedPresentableImageExtension = { + "supportsSharedPresentableImageExtension", + FeatureCategory::VulkanFeatures, + "VkSurface supports the VK_KHR_shared_presentable_images extension", + &members, + }; + + FeatureInfo supportsShaderFramebufferFetch = { + "supportsShaderFramebufferFetch", + FeatureCategory::VulkanFeatures, + "Whether the Vulkan backend supports coherent framebuffer fetch", + &members, + }; + + FeatureInfo supportsShaderFramebufferFetchNonCoherent = { + "supportsShaderFramebufferFetchNonCoherent", + FeatureCategory::VulkanFeatures, + "Whether the Vulkan backend supports non-coherent framebuffer fetch", + &members, + }; + + FeatureInfo permanentlySwitchToFramebufferFetchMode = { + "permanentlySwitchToFramebufferFetchMode", + FeatureCategory::VulkanFeatures, + "Whether the context should permanently switch to framebuffer fetch mode on first" + "encounter", + &members, + }; + + FeatureInfo supportsLockSurfaceExtension = { + "supportsLockSurfaceExtension", + FeatureCategory::VulkanFeatures, + "Surface supports the EGL_KHR_lock_surface3 extension", + &members, + }; + + FeatureInfo swapbuffersOnFlushOrFinishWithSingleBuffer = { + "swapbuffersOnFlushOrFinishWithSingleBuffer", FeatureCategory::VulkanFeatures, + "Bypass deferredFlush with calling swapbuffers on flush or finish when in Shared " + "Present mode", + &members, "http://anglebug.com/6878"}; + + FeatureInfo emulateDithering = {"emulateDithering", FeatureCategory::VulkanFeatures, + "Emulate OpenGL dithering", &members, + "http://anglebug.com/6755"}; + + FeatureInfo roundOutputAfterDithering = { + "roundOutputAfterDithering", FeatureCategory::VulkanWorkarounds, + "Round output after dithering to workaround a driver bug that rounds the output up", + &members, "http://anglebug.com/6953"}; + + FeatureInfo emulateAdvancedBlendEquations = { + "emulateAdvancedBlendEquations", FeatureCategory::VulkanFeatures, + "Emulate GL_KHR_blend_equation_advanced", &members, "http://anglebug.com/3586"}; + + FeatureInfo precisionSafeDivision = { + "precisionSafeDivision", + FeatureCategory::VulkanWorkarounds, + "Special case handling for platforms that do not generate 1.0f even when the dividend and" + "divisor have the same value", + &members, + }; + + FeatureInfo bottomLeftOriginPresentRegionRectangles = { + "bottomLeftOriginPresentRegionRectangles", + FeatureCategory::VulkanWorkarounds, + "On some platforms present region rectangles are expected to have a bottom-left origin, " + "instead of top-left origin as from spec", + &members, + }; + + FeatureInfo forceSubmitImmutableTextureUpdates = { + "forceSubmitImmutableTextureUpdates", FeatureCategory::VulkanAppWorkarounds, + "Force submit updates to immutable textures", &members, "http://anglebug.com/6929"}; + + FeatureInfo retainSPIRVDebugInfo = {"retainSPIRVDebugInfo", FeatureCategory::VulkanFeatures, + "Retain debug info in SPIR-V blob.", &members, + "http://anglebug.com/5901"}; + + FeatureInfo warmUpPipelineCacheAtLink = { + "warmUpPipelineCacheAtLink", FeatureCategory::VulkanFeatures, + "Warm up the Vulkan pipeline cache at link time", &members, "http://anglebug.com/5881"}; + + FeatureInfo preferDeviceLocalMemoryHostVisible = { + "preferDeviceLocalMemoryHostVisible", FeatureCategory::VulkanFeatures, + "Prefer adding HOST_VISIBLE flag for DEVICE_LOCAL memory when picking memory types", + &members, "http://anglebug.com/7047"}; + + FeatureInfo forceStaticVertexStrideState = { + "forceStaticVertexStrideState", FeatureCategory::VulkanWorkarounds, + "Force static state for VK_DYNAMIC_STATE_VERTEX_INPUT_BINDING_STRIDE_EXT due to" + "driver bugs", + &members, "https://bugs.fuchsia.dev/p/fuchsia/issues/detail?id=107106"}; + + FeatureInfo supportsExtendedDynamicState = { + "supportsExtendedDynamicState", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_extended_dynamic_state extension", &members, + "http://anglebug.com/5906"}; + + FeatureInfo supportsExtendedDynamicState2 = { + "supportsExtendedDynamicState2", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_extended_dynamic_state2 extension", &members, + "http://anglebug.com/5906"}; + + FeatureInfo supportsLogicOpDynamicState = { + "supportsLogicOpDynamicState", FeatureCategory::VulkanFeatures, + "VkDevice supports the logicOp feature of VK_EXT_extended_dynamic_state2 extension", + &members, "http://anglebug.com/3862"}; + + FeatureInfo supportsFragmentShadingRate = { + "supportsFragmentShadingRate", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_KHR_fragment_shading_rate extension", &members, + "http://anglebug.com/7172"}; + + FeatureInfo supportsFragmentShaderPixelInterlock = { + "supportsFragmentShaderPixelInterlock", + FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_EXT_fragment_shader_interlock extension " + "and has the fragmentShaderPixelInterlock feature", + &members, + }; + + FeatureInfo explicitlyEnablePerSampleShading = { + "explicitlyEnablePerSampleShading", FeatureCategory::VulkanWorkarounds, + "Explicitly enable per-sample shading if the fragment shader contains the " + "sample qualifier", + &members, "http://anglebug.com/6876"}; + + FeatureInfo forceContinuousRefreshOnSharedPresent = { + "forceContinuousRefreshOnSharedPresent", FeatureCategory::VulkanFeatures, + "Force to create vulkan swapchain with continuous refresh on shared present", &members, + "https://issuetracker.google.com/229267970"}; + + FeatureInfo supportsImage2dViewOf3d = { + "supportsImage2dViewOf3d", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_image_2d_view_of_3d", &members, "https://anglebug.com/7320"}; + + FeatureInfo supportsImagelessFramebuffer = { + "supportsImagelessFramebuffer", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_KHR_imageless_framebuffer extension", &members, + "http://anglebug.com/7553"}; + + FeatureInfo preferLinearFilterForYUV = { + "preferLinearFilterForYUV", FeatureCategory::VulkanFeatures, + "Prefer to use VK_FILTER_LINEAR for VkSamplerYcbcrConversion", &members, + "https://anglebug.com/7382"}; + + FeatureInfo supportsYuvTarget = { + "supportsYuvTarget", + FeatureCategory::VulkanFeatures, + "VkDevice supports VK_ANDROID_render_to_external_format and VK_EXT_ycbcr_attachment", + &members, + }; + + FeatureInfo useNonZeroStencilWriteMaskStaticState = { + "useNonZeroStencilWriteMaskStaticState", FeatureCategory::VulkanWorkarounds, + "Work around a driver bug where 0 in stencil write mask static state would make the" + "corresponding dynamic state malfunction in the presence of discard or alpha to coverage", + &members, "http://anglebug.com/7556"}; + + FeatureInfo mapUnspecifiedColorSpaceToPassThrough = { + "mapUnspecifiedColorSpaceToPassThrough", + FeatureCategory::VulkanFeatures, + "Use VK_COLOR_SPACE_PASS_THROUGH_EXT for EGL_NONE or unspecifed color " + "spaces", + &members, + }; + + FeatureInfo supportsTimestampSurfaceAttribute = { + "supportsTimestampSurfaceAttribute", FeatureCategory::VulkanFeatures, + "Platform supports setting frame timestamp surface attribute", &members, + "https://anglebug.com/7489"}; + + FeatureInfo supportsRasterizationOrderAttachmentAccess = { + "supportsRasterizationOrderAttachmentAccess", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_rasterization_order_attachment_access extension", &members, + "https://anglebug.com/7604"}; + + FeatureInfo eglColorspaceAttributePassthrough = { + "eglColorspaceAttributePassthrough", FeatureCategory::VulkanFeatures, + "Support passthrough of EGL colorspace attribute values", &members, + "https://anglebug.com/7319"}; + + FeatureInfo supportsPipelineRobustness = { + "supportsPipelineRobustness", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_pipeline_robustness extension", &members, + "https://anglebug.com/5845"}; + + FeatureInfo supportsVertexInputDynamicState = { + "supportsVertexInputDynamicState", FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_vertex_input_dynamic_state extension", &members, + "https://anglebug.com/7162"}; + + FeatureInfo supportsColorWriteEnable = {"supportsColorWriteEnable", + FeatureCategory::VulkanFeatures, + "VkDevice supports VK_EXT_color_write_enable extension", + &members, "https://anglebug.com/7161"}; + + FeatureInfo supportsPresentation = { + "supportsPresentation", + FeatureCategory::VulkanFeatures, + "VkDisplay supports presentation through a present family queue", + &members, + }; + + FeatureInfo supportsComputeTranscodeEtcToBc = { + "supportsComputeTranscodeEtcToBc", + FeatureCategory::VulkanFeatures, + "supports compute shader transcode etc format to bc format", + &members, + }; + + FeatureInfo supportsGraphicsPipelineLibrary = { + "supportsGraphicsPipelineLibrary", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_EXT_graphics_pipeline_library extension", &members, + "https://anglebug.com/7369"}; + + FeatureInfo supportsPipelineProtectedAccess = { + "supportsPipelineProtectedAccess", FeatureCategory::VulkanFeatures, + "VkDevice supports the VK_EXT_pipeline_protected_access extension", &members, + "https://anglebug.com/7714"}; + + FeatureInfo preferSubmitOnAnySamplesPassedQueryEnd = { + "preferSubmitOnAnySamplesPassedQueryEnd", FeatureCategory::VulkanWorkarounds, + "Submit commands to driver when last GL_ANY_SAMPLES_PASSED query is made for performance " + "improvements.", + &members, "https://issuetracker.google.com/250706693"}; +}; + +inline FeaturesVk::FeaturesVk() = default; +inline FeaturesVk::~FeaturesVk() = default; + +} // namespace angle + +#endif // ANGLE_PLATFORM_FEATURESVK_H_ diff --git a/gfx/angle/checkout/include/platform/FrontendFeatures_autogen.h b/gfx/angle/checkout/include/platform/FrontendFeatures_autogen.h new file mode 100644 index 0000000000..4cb5fa8afa --- /dev/null +++ b/gfx/angle/checkout/include/platform/FrontendFeatures_autogen.h @@ -0,0 +1,115 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by gen_features.py using data from frontend_features.json. +// +// Copyright 2022 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// FrontendFeatures_autogen.h: Features/workarounds for driver bugs and other behaviors seen +// on all platforms. + +#ifndef ANGLE_PLATFORM_FRONTENDFEATURES_H_ +#define ANGLE_PLATFORM_FRONTENDFEATURES_H_ + +#include "platform/Feature.h" + +namespace angle +{ + +struct FrontendFeatures : FeatureSetBase +{ + FrontendFeatures(); + ~FrontendFeatures(); + + FeatureInfo loseContextOnOutOfMemory = { + "loseContextOnOutOfMemory", + FeatureCategory::FrontendWorkarounds, + "Some users rely on a lost context notification if a GL_OUT_OF_MEMORY error occurs", + &members, + }; + + FeatureInfo disableProgramCachingForTransformFeedback = { + "disableProgramCachingForTransformFeedback", + FeatureCategory::FrontendWorkarounds, + "On some GPUs, program binaries don't contain transform feedback varyings", + &members, + }; + + FeatureInfo scalarizeVecAndMatConstructorArgs = { + "scalarizeVecAndMatConstructorArgs", FeatureCategory::FrontendWorkarounds, + "Always rewrite vec/mat constructors to be consistent", &members, + "http://crbug.com/1165751"}; + + FeatureInfo disableProgramBinary = {"disableProgramBinary", FeatureCategory::FrontendFeatures, + "Disable support for GL_OES_get_program_binary", &members, + "http://anglebug.com/5007"}; + + FeatureInfo disableDrawBuffersIndexed = { + "disableDrawBuffersIndexed", FeatureCategory::FrontendFeatures, + "Disable support for OES_draw_buffers_indexed and EXT_draw_buffers_indexed", &members, + "http://anglebug.com/7724"}; + + FeatureInfo disableAnisotropicFiltering = { + "disableAnisotropicFiltering", + FeatureCategory::FrontendWorkarounds, + "Disable support for anisotropic filtering", + &members, + }; + + FeatureInfo allowCompressedFormats = { + "allowCompressedFormats", + FeatureCategory::FrontendWorkarounds, + "Allow compressed formats", + &members, + }; + + FeatureInfo forceDepthAttachmentInitOnClear = { + "forceDepthAttachmentInitOnClear", FeatureCategory::FrontendWorkarounds, + "Force depth attachment initialization on clear ops", &members, + "https://anglebug.com/7246"}; + + FeatureInfo enableCaptureLimits = {"enableCaptureLimits", FeatureCategory::FrontendFeatures, + "Set the context limits like frame capturing was enabled", + &members, "http://anglebug.com/5750"}; + + FeatureInfo enableCompressingPipelineCacheInThreadPool = { + "enableCompressingPipelineCacheInThreadPool", FeatureCategory::FrontendWorkarounds, + "Enable compressing pipeline cache in thread pool.", &members, "http://anglebug.com/4722"}; + + FeatureInfo forceRobustResourceInit = { + "forceRobustResourceInit", FeatureCategory::FrontendFeatures, + "Force-enable robust resource init", &members, "http://anglebug.com/6041"}; + + FeatureInfo forceInitShaderVariables = { + "forceInitShaderVariables", + FeatureCategory::FrontendFeatures, + "Force-enable shader variable initialization", + &members, + }; + + FeatureInfo enableProgramBinaryForCapture = { + "enableProgramBinaryForCapture", FeatureCategory::FrontendFeatures, + "Even if FrameCapture is enabled, enable GL_OES_get_program_binary", &members, + "http://anglebug.com/5658"}; + + FeatureInfo forceGlErrorChecking = { + "forceGlErrorChecking", FeatureCategory::FrontendFeatures, + "Force GL error checking (i.e. prevent applications from disabling error checking", + &members, "https://issuetracker.google.com/220069903"}; + + FeatureInfo emulatePixelLocalStorage = { + "emulatePixelLocalStorage", FeatureCategory::FrontendFeatures, + "Emulate ANGLE_shader_pixel_local_storage using shader images", &members, + "http://anglebug.com/7279"}; + + FeatureInfo cacheCompiledShader = {"cacheCompiledShader", FeatureCategory::FrontendFeatures, + "Enable to cache compiled shaders", &members, + "http://anglebug.com/7036"}; +}; + +inline FrontendFeatures::FrontendFeatures() = default; +inline FrontendFeatures::~FrontendFeatures() = default; + +} // namespace angle + +#endif // ANGLE_PLATFORM_FRONTENDFEATURES_H_ diff --git a/gfx/angle/checkout/include/platform/PlatformMethods.h b/gfx/angle/checkout/include/platform/PlatformMethods.h new file mode 100644 index 0000000000..48ef335796 --- /dev/null +++ b/gfx/angle/checkout/include/platform/PlatformMethods.h @@ -0,0 +1,334 @@ +// +// Copyright 2015 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// PlatformMethods.h: The public interface ANGLE exposes to the API layer, for +// doing platform-specific tasks like gathering data, or for tracing. + +#ifndef ANGLE_PLATFORMMETHODS_H +#define ANGLE_PLATFORMMETHODS_H + +#include +#include +#include + +#define EGL_PLATFORM_ANGLE_PLATFORM_METHODS_ANGLEX 0x6AFB + +#if !defined(ANGLE_PLATFORM_EXPORT) +# if defined(_WIN32) +# if !defined(LIBANGLE_IMPLEMENTATION) +# define ANGLE_PLATFORM_EXPORT __declspec(dllimport) +# else +# define ANGLE_PLATFORM_EXPORT __declspec(dllexport) +# endif +# elif defined(__GNUC__) || defined(__clang__) +# define ANGLE_PLATFORM_EXPORT __attribute__((visibility("default"))) +# endif +#endif +#if !defined(ANGLE_PLATFORM_EXPORT) +# define ANGLE_PLATFORM_EXPORT +#endif + +#if defined(_WIN32) +# define ANGLE_APIENTRY __stdcall +#else +# define ANGLE_APIENTRY +#endif + +namespace angle +{ +struct FeaturesD3D; +struct FeaturesVk; +struct FeaturesMtl; +using TraceEventHandle = uint64_t; +using EGLDisplayType = void *; +struct PlatformMethods; + +// Use a C-like API to not trigger undefined calling behaviour. +// Avoid using decltype here to work around sanitizer limitations. +// TODO(jmadill): Use decltype here if/when UBSAN is fixed. + +// System -------------------------------------------------------------- + +// Wall clock time in seconds since the epoch. +// TODO(jmadill): investigate using an ANGLE internal time library +using CurrentTimeFunc = double (*)(PlatformMethods *platform); +inline double DefaultCurrentTime(PlatformMethods *platform) +{ + return 0.0; +} + +// Monotonically increasing time in seconds from an arbitrary fixed point in the past. +// This function is expected to return at least millisecond-precision values. For this reason, +// it is recommended that the fixed point be no further in the past than the epoch. +using MonotonicallyIncreasingTimeFunc = double (*)(PlatformMethods *platform); +inline double DefaultMonotonicallyIncreasingTime(PlatformMethods *platform) +{ + return 0.0; +} + +// Logging ------------------------------------------------------------ + +// Log an error message within the platform implementation. +using LogErrorFunc = void (*)(PlatformMethods *platform, const char *errorMessage); +inline void DefaultLogError(PlatformMethods *platform, const char *errorMessage) {} + +// Log a warning message within the platform implementation. +using LogWarningFunc = void (*)(PlatformMethods *platform, const char *warningMessage); +inline void DefaultLogWarning(PlatformMethods *platform, const char *warningMessage) {} + +// Log an info message within the platform implementation. +using LogInfoFunc = void (*)(PlatformMethods *platform, const char *infoMessage); +inline void DefaultLogInfo(PlatformMethods *platform, const char *infoMessage) {} + +// Tracing -------- + +// Get a pointer to the enabled state of the given trace category. The +// embedder can dynamically change the enabled state as trace event +// recording is started and stopped by the application. Only long-lived +// literal strings should be given as the category name. The implementation +// expects the returned pointer to be held permanently in a local static. If +// the unsigned char is non-zero, tracing is enabled. If tracing is enabled, +// addTraceEvent is expected to be called by the trace event macros. +using GetTraceCategoryEnabledFlagFunc = const unsigned char *(*)(PlatformMethods *platform, + const char *categoryName); +inline const unsigned char *DefaultGetTraceCategoryEnabledFlag(PlatformMethods *platform, + const char *categoryName) +{ + return nullptr; +} + +// +// Add a trace event to the platform tracing system. Depending on the actual +// enabled state, this event may be recorded or dropped. +// - phase specifies the type of event: +// - BEGIN ('B'): Marks the beginning of a scoped event. +// - END ('E'): Marks the end of a scoped event. +// - COMPLETE ('X'): Marks the beginning of a scoped event, but doesn't +// need a matching END event. Instead, at the end of the scope, +// updateTraceEventDuration() must be called with the TraceEventHandle +// returned from addTraceEvent(). +// - INSTANT ('I'): Standalone, instantaneous event. +// - START ('S'): Marks the beginning of an asynchronous event (the end +// event can occur in a different scope or thread). The id parameter is +// used to match START/FINISH pairs. +// - FINISH ('F'): Marks the end of an asynchronous event. +// - COUNTER ('C'): Used to trace integer quantities that change over +// time. The argument values are expected to be of type int. +// - METADATA ('M'): Reserved for internal use. +// - categoryEnabled is the pointer returned by getTraceCategoryEnabledFlag. +// - name is the name of the event. Also used to match BEGIN/END and +// START/FINISH pairs. +// - id optionally allows events of the same name to be distinguished from +// each other. For example, to trace the construction and destruction of +// objects, specify the pointer as the id parameter. +// - timestamp should be a time value returned from monotonicallyIncreasingTime. +// - numArgs specifies the number of elements in argNames, argTypes, and +// argValues. +// - argNames is the array of argument names. Use long-lived literal strings +// or specify the COPY flag. +// - argTypes is the array of argument types: +// - BOOL (1): bool +// - UINT (2): unsigned long long +// - INT (3): long long +// - DOUBLE (4): double +// - POINTER (5): void* +// - STRING (6): char* (long-lived null-terminated char* string) +// - COPY_STRING (7): char* (temporary null-terminated char* string) +// - CONVERTABLE (8): WebConvertableToTraceFormat +// - argValues is the array of argument values. Each value is the unsigned +// long long member of a union of all supported types. +// - flags can be 0 or one or more of the following, ORed together: +// - COPY (0x1): treat all strings (name, argNames and argValues of type +// string) as temporary so that they will be copied by addTraceEvent. +// - HAS_ID (0x2): use the id argument to uniquely identify the event for +// matching with other events of the same name. +// - MANGLE_ID (0x4): specify this flag if the id parameter is the value +// of a pointer. +using AddTraceEventFunc = angle::TraceEventHandle (*)(PlatformMethods *platform, + char phase, + const unsigned char *categoryEnabledFlag, + const char *name, + unsigned long long id, + double timestamp, + int numArgs, + const char **argNames, + const unsigned char *argTypes, + const unsigned long long *argValues, + unsigned char flags); +inline angle::TraceEventHandle DefaultAddTraceEvent(PlatformMethods *platform, + char phase, + const unsigned char *categoryEnabledFlag, + const char *name, + unsigned long long id, + double timestamp, + int numArgs, + const char **argNames, + const unsigned char *argTypes, + const unsigned long long *argValues, + unsigned char flags) +{ + return 0; +} + +// Set the duration field of a COMPLETE trace event. +using UpdateTraceEventDurationFunc = void (*)(PlatformMethods *platform, + const unsigned char *categoryEnabledFlag, + const char *name, + angle::TraceEventHandle eventHandle); +inline void DefaultUpdateTraceEventDuration(PlatformMethods *platform, + const unsigned char *categoryEnabledFlag, + const char *name, + angle::TraceEventHandle eventHandle) +{} + +// Callbacks for reporting histogram data. +// CustomCounts histogram has exponential bucket sizes, so that min=1, max=1000000, bucketCount=50 +// would do. +using HistogramCustomCountsFunc = void (*)(PlatformMethods *platform, + const char *name, + int sample, + int min, + int max, + int bucketCount); +inline void DefaultHistogramCustomCounts(PlatformMethods *platform, + const char *name, + int sample, + int min, + int max, + int bucketCount) +{} +// Enumeration histogram buckets are linear, boundaryValue should be larger than any possible sample +// value. +using HistogramEnumerationFunc = void (*)(PlatformMethods *platform, + const char *name, + int sample, + int boundaryValue); +inline void DefaultHistogramEnumeration(PlatformMethods *platform, + const char *name, + int sample, + int boundaryValue) +{} +// Unlike enumeration histograms, sparse histograms only allocate memory for non-empty buckets. +using HistogramSparseFunc = void (*)(PlatformMethods *platform, const char *name, int sample); +inline void DefaultHistogramSparse(PlatformMethods *platform, const char *name, int sample) {} +// Boolean histograms track two-state variables. +using HistogramBooleanFunc = void (*)(PlatformMethods *platform, const char *name, bool sample); +inline void DefaultHistogramBoolean(PlatformMethods *platform, const char *name, bool sample) {} + +// Callback on a successful program link with the program binary. Can be used to store +// shaders to disk. Keys are a 160-bit SHA-1 hash. +using ProgramKeyType = std::array; +using CacheProgramFunc = void (*)(PlatformMethods *platform, + const ProgramKeyType &key, + size_t programSize, + const uint8_t *programBytes); +inline void DefaultCacheProgram(PlatformMethods *platform, + const ProgramKeyType &key, + size_t programSize, + const uint8_t *programBytes) +{} + +using PostWorkerTaskCallback = void (*)(void *userData); +using PostWorkerTaskFunc = void (*)(PlatformMethods *platform, + PostWorkerTaskCallback callback, + void *userData); +constexpr PostWorkerTaskFunc DefaultPostWorkerTask = nullptr; + +// Placeholder values where feature override callbacks used to be. They are deprecated in favor of +// EGL_ANGLE_feature_control. The placeholders are there to keep the layout of the PlatformMethods +// constant to support drop-in replacement of ANGLE's .so files in applications built with an older +// header. +using PlaceholderCallbackFunc = void (*)(...); +inline void DefaultPlaceholderCallback(...) {} + +// Platform methods are enumerated here once. +#define ANGLE_PLATFORM_OP(OP) \ + OP(currentTime, CurrentTime) \ + OP(monotonicallyIncreasingTime, MonotonicallyIncreasingTime) \ + OP(logError, LogError) \ + OP(logWarning, LogWarning) \ + OP(logInfo, LogInfo) \ + OP(getTraceCategoryEnabledFlag, GetTraceCategoryEnabledFlag) \ + OP(addTraceEvent, AddTraceEvent) \ + OP(updateTraceEventDuration, UpdateTraceEventDuration) \ + OP(histogramCustomCounts, HistogramCustomCounts) \ + OP(histogramEnumeration, HistogramEnumeration) \ + OP(histogramSparse, HistogramSparse) \ + OP(histogramBoolean, HistogramBoolean) \ + OP(placeholder1, PlaceholderCallback) \ + OP(placeholder2, PlaceholderCallback) \ + OP(cacheProgram, CacheProgram) \ + OP(placeholder3, PlaceholderCallback) \ + OP(postWorkerTask, PostWorkerTask) + +#define ANGLE_PLATFORM_METHOD_DEF(Name, CapsName) CapsName##Func Name = Default##CapsName; + +struct ANGLE_PLATFORM_EXPORT PlatformMethods +{ + inline PlatformMethods(); + + // User data pointer for any implementation specific members. Put it at the start of the + // platform structure so it doesn't become overwritten if one version of the platform + // adds or removes new members. + void *context = 0; + + ANGLE_PLATFORM_OP(ANGLE_PLATFORM_METHOD_DEF) +}; + +inline PlatformMethods::PlatformMethods() = default; + +#undef ANGLE_PLATFORM_METHOD_DEF + +// Subtract one to account for the context pointer. +constexpr unsigned int g_NumPlatformMethods = (sizeof(PlatformMethods) / sizeof(uintptr_t)) - 1; + +// No further uses of platform methods is allowed. EGL extensions should be used instead. While +// methods are being removed, use PlaceholderCallback to keep the layout of PlatformMethods +// constant. +static_assert(g_NumPlatformMethods == 17, "Avoid adding methods to PlatformMethods"); + +#define ANGLE_PLATFORM_METHOD_STRING(Name) #Name +#define ANGLE_PLATFORM_METHOD_STRING2(Name, CapsName) ANGLE_PLATFORM_METHOD_STRING(Name), + +constexpr const char *const g_PlatformMethodNames[g_NumPlatformMethods] = { + ANGLE_PLATFORM_OP(ANGLE_PLATFORM_METHOD_STRING2)}; + +#undef ANGLE_PLATFORM_METHOD_STRING2 +#undef ANGLE_PLATFORM_METHOD_STRING + +} // namespace angle + +extern "C" { + +// Gets the platform methods on the passed-in EGL display. If the method name signature does not +// match the compiled signature for this ANGLE, false is returned. On success true is returned. +// The application should set any platform methods it cares about on the returned pointer. +// If display is not valid, behaviour is undefined. + +ANGLE_PLATFORM_EXPORT bool ANGLE_APIENTRY ANGLEGetDisplayPlatform(angle::EGLDisplayType display, + const char *const methodNames[], + unsigned int methodNameCount, + void *context, + void *platformMethodsOut); + +// Sets the platform methods back to their defaults. +// If display is not valid, behaviour is undefined. +ANGLE_PLATFORM_EXPORT void ANGLE_APIENTRY ANGLEResetDisplayPlatform(angle::EGLDisplayType display); +} // extern "C" + +namespace angle +{ +typedef bool(ANGLE_APIENTRY *GetDisplayPlatformFunc)(angle::EGLDisplayType, + const char *const *, + unsigned int, + void *, + void *); +typedef void(ANGLE_APIENTRY *ResetDisplayPlatformFunc)(angle::EGLDisplayType); +} // namespace angle + +// This function is not exported +angle::PlatformMethods *ANGLEPlatformCurrent(); + +#endif // ANGLE_PLATFORMMETHODS_H diff --git a/gfx/angle/checkout/include/vulkan/vulkan_fuchsia_ext.h b/gfx/angle/checkout/include/vulkan/vulkan_fuchsia_ext.h new file mode 100644 index 0000000000..f5c3cf629b --- /dev/null +++ b/gfx/angle/checkout/include/vulkan/vulkan_fuchsia_ext.h @@ -0,0 +1,31 @@ +// +// Copyright 2019 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// vulkan_fuchsia_ext: +// Defines Fuchsia-specific Vulkan extensions when compiling on other +// platforms. +// + +#ifndef COMMON_VULKAN_FUCHSIA_EXT_H_ +#define COMMON_VULKAN_FUCHSIA_EXT_H_ + +#if !defined(VK_NO_PROTOTYPES) +# define VK_NO_PROTOTYPES +#endif + +#include + +// If this is not Fuchsia then define Fuchsia-specific types explicitly and include +// vulkan_fuchsia.h to make it possible to compile the code on other platforms. +// +// TODO(https://anglebug.com/6040): Update all code to avoid dependencies on +// Fuchsia-specific types when compiling on other platforms. Then remove this header. +#if !defined(ANGLE_PLATFORM_FUCHSIA) +typedef uint32_t zx_handle_t; +# define ZX_HANDLE_INVALID ((zx_handle_t)0) +# include +#endif + +#endif // COMMON_VULKAN_FUCHSIA_EXT_H_ diff --git a/gfx/angle/checkout/out/gen/angle/angle_commit.h b/gfx/angle/checkout/out/gen/angle/angle_commit.h new file mode 100644 index 0000000000..7001cc3309 --- /dev/null +++ b/gfx/angle/checkout/out/gen/angle/angle_commit.h @@ -0,0 +1,5 @@ +#define ANGLE_COMMIT_HASH "ddaf44ac75d5" +#define ANGLE_COMMIT_HASH_SIZE 12 +#define ANGLE_COMMIT_DATE "2024-01-02 15:01:34 -0800" +#define ANGLE_COMMIT_POSITION 19736 +#define ANGLE_HAS_BINARY_LOADING diff --git a/gfx/angle/checkout/src/common/CircularBuffer.h b/gfx/angle/checkout/src/common/CircularBuffer.h new file mode 100644 index 0000000000..3ff5f14d1b --- /dev/null +++ b/gfx/angle/checkout/src/common/CircularBuffer.h @@ -0,0 +1,175 @@ +// +// Copyright 2021 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// CircularBuffer.h: +// An array class with an index that loops through the elements. +// + +#ifndef COMMON_CIRCULARBUFFER_H_ +#define COMMON_CIRCULARBUFFER_H_ + +#include "common/debug.h" + +#include +#include + +namespace angle +{ +template > +class CircularBuffer final +{ + public: + using value_type = typename Storage::value_type; + using size_type = typename Storage::size_type; + using reference = typename Storage::reference; + using const_reference = typename Storage::const_reference; + using pointer = typename Storage::pointer; + using const_pointer = typename Storage::const_pointer; + using iterator = typename Storage::iterator; + using const_iterator = typename Storage::const_iterator; + + CircularBuffer(); + CircularBuffer(const value_type &value); + + CircularBuffer(const CircularBuffer &other); + CircularBuffer(CircularBuffer &&other); + + CircularBuffer &operator=(const CircularBuffer &other); + CircularBuffer &operator=(CircularBuffer &&other); + + ~CircularBuffer(); + + // begin() and end() are used to iterate over all elements regardless of the current position of + // the front of the buffer. Useful for initialization and clean up, as otherwise only the front + // element is expected to be accessed. + iterator begin(); + const_iterator begin() const; + + iterator end(); + const_iterator end() const; + + size_type size() const; + + reference front(); + const_reference front() const; + + void swap(CircularBuffer &other); + + // Move the front forward to the next index, looping back to the beginning if the end of the + // array is reached. + void next(); + + private: + Storage mData; + size_type mFrontIndex; +}; + +template +CircularBuffer::CircularBuffer() : mFrontIndex(0) +{} + +template +CircularBuffer::CircularBuffer(const value_type &value) : CircularBuffer() +{ + std::fill(begin(), end(), value); +} + +template +CircularBuffer::CircularBuffer(const CircularBuffer &other) +{ + *this = other; +} + +template +CircularBuffer::CircularBuffer(CircularBuffer &&other) + : CircularBuffer() +{ + swap(other); +} + +template +CircularBuffer &CircularBuffer::operator=( + const CircularBuffer &other) +{ + std::copy(other.begin(), other.end(), begin()); + mFrontIndex = other.mFrontIndex; + return *this; +} + +template +CircularBuffer &CircularBuffer::operator=( + CircularBuffer &&other) +{ + swap(other); + return *this; +} + +template +CircularBuffer::~CircularBuffer() = default; + +template +ANGLE_INLINE typename CircularBuffer::iterator CircularBuffer::begin() +{ + return mData.begin(); +} + +template +ANGLE_INLINE typename CircularBuffer::const_iterator +CircularBuffer::begin() const +{ + return mData.begin(); +} + +template +ANGLE_INLINE typename CircularBuffer::iterator CircularBuffer::end() +{ + return mData.end(); +} + +template +ANGLE_INLINE typename CircularBuffer::const_iterator +CircularBuffer::end() const +{ + return mData.end(); +} + +template +ANGLE_INLINE typename CircularBuffer::size_type CircularBuffer::size() + const +{ + return N; +} + +template +ANGLE_INLINE typename CircularBuffer::reference +CircularBuffer::front() +{ + ASSERT(mFrontIndex < size()); + return mData[mFrontIndex]; +} + +template +ANGLE_INLINE typename CircularBuffer::const_reference +CircularBuffer::front() const +{ + ASSERT(mFrontIndex < size()); + return mData[mFrontIndex]; +} + +template +void CircularBuffer::swap(CircularBuffer &other) +{ + std::swap(mData, other.mData); + std::swap(mFrontIndex, other.mFrontIndex); +} + +template +void CircularBuffer::next() +{ + mFrontIndex = (mFrontIndex + 1) % size(); +} +} // namespace angle + +#endif // COMMON_CIRCULARBUFFER_H_ diff --git a/gfx/angle/checkout/src/common/Color.h b/gfx/angle/checkout/src/common/Color.h new file mode 100644 index 0000000000..b228d8e8c5 --- /dev/null +++ b/gfx/angle/checkout/src/common/Color.h @@ -0,0 +1,104 @@ +// +// Copyright 2016 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// Color.h : Defines the Color type used throughout the ANGLE libraries + +#ifndef COMMON_COLOR_H_ +#define COMMON_COLOR_H_ + +#include + +namespace angle +{ + +template +struct Color +{ + Color(); + constexpr Color(T r, T g, T b, T a); + + const T *data() const { return &red; } + T *ptr() { return &red; } + + static Color fromData(const T *data) { return Color(data[0], data[1], data[2], data[3]); } + void writeData(T *data) const + { + data[0] = red; + data[1] = green; + data[2] = blue; + data[3] = alpha; + } + + T red; + T green; + T blue; + T alpha; +}; + +template +bool operator==(const Color &a, const Color &b); + +template +bool operator!=(const Color &a, const Color &b); + +typedef Color ColorF; +typedef Color ColorI; +typedef Color ColorUI; + +struct ColorGeneric +{ + inline ColorGeneric(); + inline ColorGeneric(const ColorF &color); + inline ColorGeneric(const ColorI &color); + inline ColorGeneric(const ColorUI &color); + + enum class Type : uint8_t + { + Float = 0, + Int = 1, + UInt = 2 + }; + + union + { + ColorF colorF; + ColorI colorI; + ColorUI colorUI; + }; + + Type type; +}; + +inline bool operator==(const ColorGeneric &a, const ColorGeneric &b); + +inline bool operator!=(const ColorGeneric &a, const ColorGeneric &b); + +struct DepthStencil +{ + DepthStencil() : depth(0), stencil(0) {} + + // Double is needed to represent the 32-bit integer range of GL_DEPTH_COMPONENT32. + double depth; + uint32_t stencil; +}; +} // namespace angle + +// TODO: Move this fully into the angle namespace +namespace gl +{ + +template +using Color = angle::Color; +using ColorF = angle::ColorF; +using ColorI = angle::ColorI; +using ColorUI = angle::ColorUI; +using ColorGeneric = angle::ColorGeneric; + +} // namespace gl + +#include "Color.inc" + +#endif // COMMON_COLOR_H_ diff --git a/gfx/angle/checkout/src/common/Color.inc b/gfx/angle/checkout/src/common/Color.inc new file mode 100644 index 0000000000..0e1445111b --- /dev/null +++ b/gfx/angle/checkout/src/common/Color.inc @@ -0,0 +1,69 @@ +// +// Copyright 2016 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// Color.inc : Inline definitions of some functions from Color.h + +namespace angle +{ + +template +Color::Color() : Color(0, 0, 0, 0) +{ +} + +template +constexpr Color::Color(T r, T g, T b, T a) : red(r), green(g), blue(b), alpha(a) +{ +} + +template +bool operator==(const Color &a, const Color &b) +{ + return a.red == b.red && + a.green == b.green && + a.blue == b.blue && + a.alpha == b.alpha; +} + +template +bool operator!=(const Color &a, const Color &b) +{ + return !(a == b); +} + + +ColorGeneric::ColorGeneric() : colorF(), type(Type::Float) {} + +ColorGeneric::ColorGeneric(const ColorF &color) : colorF(color), type(Type::Float) {} + +ColorGeneric::ColorGeneric(const ColorI &color) : colorI(color), type(Type::Int) {} + +ColorGeneric::ColorGeneric(const ColorUI &color) : colorUI(color), type(Type::UInt) {} + +bool operator==(const ColorGeneric &a, const ColorGeneric &b) +{ + if (a.type != b.type) + { + return false; + } + switch (a.type) + { + default: + case ColorGeneric::Type::Float: + return a.colorF == b.colorF; + case ColorGeneric::Type::Int: + return a.colorI == b.colorI; + case ColorGeneric::Type::UInt: + return a.colorUI == b.colorUI; + } +} + +bool operator!=(const ColorGeneric &a, const ColorGeneric &b) +{ + return !(a == b); +} + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/FastVector.h b/gfx/angle/checkout/src/common/FastVector.h new file mode 100644 index 0000000000..6991adf715 --- /dev/null +++ b/gfx/angle/checkout/src/common/FastVector.h @@ -0,0 +1,891 @@ +// +// Copyright 2018 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// FastVector.h: +// A vector class with a initial fixed size and variable growth. +// Based on FixedVector. +// + +#ifndef COMMON_FASTVECTOR_H_ +#define COMMON_FASTVECTOR_H_ + +#include "bitset_utils.h" +#include "common/debug.h" + +#include +#include +#include +#include + +namespace angle +{ + +template +class WrapIter +{ + public: + typedef Iter iterator_type; + typedef typename std::iterator_traits::value_type value_type; + typedef typename std::iterator_traits::difference_type difference_type; + typedef typename std::iterator_traits::pointer pointer; + typedef typename std::iterator_traits::reference reference; + typedef typename std::iterator_traits::iterator_category iterator_category; + + WrapIter() : mIter() {} + WrapIter(const Iter &iter) : mIter(iter) {} + ~WrapIter() = default; + + WrapIter &operator=(const WrapIter &x) + { + mIter = x.mIter; + return *this; + } + + bool operator==(const WrapIter &x) const { return mIter == x.mIter; } + bool operator!=(const WrapIter &x) const { return mIter != x.mIter; } + bool operator<(const WrapIter &x) const { return mIter < x.mIter; } + bool operator<=(const WrapIter &x) const { return mIter <= x.mIter; } + bool operator>(const WrapIter &x) const { return mIter > x.mIter; } + bool operator>=(const WrapIter &x) const { return mIter >= x.mIter; } + + WrapIter &operator++() + { + mIter++; + return *this; + } + + WrapIter operator++(int) + { + WrapIter tmp(mIter); + mIter++; + return tmp; + } + + WrapIter operator+(difference_type n) + { + WrapIter tmp(mIter); + tmp.mIter += n; + return tmp; + } + + WrapIter operator-(difference_type n) + { + WrapIter tmp(mIter); + tmp.mIter -= n; + return tmp; + } + + difference_type operator-(const WrapIter &x) const { return mIter - x.mIter; } + + iterator_type operator->() const { return mIter; } + + reference operator*() const { return *mIter; } + + private: + iterator_type mIter; +}; + +template > +class FastVector final +{ + public: + using value_type = typename Storage::value_type; + using size_type = typename Storage::size_type; + using reference = typename Storage::reference; + using const_reference = typename Storage::const_reference; + using pointer = typename Storage::pointer; + using const_pointer = typename Storage::const_pointer; + using iterator = WrapIter; + using const_iterator = WrapIter; + + FastVector(); + FastVector(size_type count, const value_type &value); + FastVector(size_type count); + + FastVector(const FastVector &other); + FastVector(FastVector &&other); + FastVector(std::initializer_list init); + + template ::value, bool> = true> + FastVector(InputIt first, InputIt last); + + FastVector &operator=(const FastVector &other); + FastVector &operator=(FastVector &&other); + FastVector &operator=(std::initializer_list init); + + ~FastVector(); + + reference at(size_type pos); + const_reference at(size_type pos) const; + + reference operator[](size_type pos); + const_reference operator[](size_type pos) const; + + pointer data(); + const_pointer data() const; + + iterator begin(); + const_iterator begin() const; + + iterator end(); + const_iterator end() const; + + bool empty() const; + size_type size() const; + + void clear(); + + void push_back(const value_type &value); + void push_back(value_type &&value); + + template + void emplace_back(Args &&...args); + + void pop_back(); + + reference front(); + const_reference front() const; + + reference back(); + const_reference back() const; + + void swap(FastVector &other); + + void resize(size_type count); + void resize(size_type count, const value_type &value); + + void reserve(size_type count); + + // Specialty function that removes a known element and might shuffle the list. + void remove_and_permute(const value_type &element); + void remove_and_permute(iterator pos); + + private: + void assign_from_initializer_list(std::initializer_list init); + void ensure_capacity(size_t capacity); + bool uses_fixed_storage() const; + + Storage mFixedStorage; + pointer mData = mFixedStorage.data(); + size_type mSize = 0; + size_type mReservedSize = N; +}; + +template +bool operator==(const FastVector &a, const FastVector &b) +{ + return a.size() == b.size() && std::equal(a.begin(), a.end(), b.begin()); +} + +template +bool operator!=(const FastVector &a, const FastVector &b) +{ + return !(a == b); +} + +template +ANGLE_INLINE bool FastVector::uses_fixed_storage() const +{ + return mData == mFixedStorage.data(); +} + +template +FastVector::FastVector() +{} + +template +FastVector::FastVector(size_type count, const value_type &value) +{ + ensure_capacity(count); + mSize = count; + std::fill(begin(), end(), value); +} + +template +FastVector::FastVector(size_type count) +{ + ensure_capacity(count); + mSize = count; +} + +template +FastVector::FastVector(const FastVector &other) + : FastVector(other.begin(), other.end()) +{} + +template +FastVector::FastVector(FastVector &&other) : FastVector() +{ + swap(other); +} + +template +FastVector::FastVector(std::initializer_list init) +{ + assign_from_initializer_list(init); +} + +template +template ::value, bool>> +FastVector::FastVector(InputIt first, InputIt last) +{ + size_t newSize = last - first; + ensure_capacity(newSize); + mSize = newSize; + std::copy(first, last, begin()); +} + +template +FastVector &FastVector::operator=( + const FastVector &other) +{ + ensure_capacity(other.mSize); + mSize = other.mSize; + std::copy(other.begin(), other.end(), begin()); + return *this; +} + +template +FastVector &FastVector::operator=(FastVector &&other) +{ + swap(other); + return *this; +} + +template +FastVector &FastVector::operator=( + std::initializer_list init) +{ + assign_from_initializer_list(init); + return *this; +} + +template +FastVector::~FastVector() +{ + clear(); + if (!uses_fixed_storage()) + { + delete[] mData; + } +} + +template +typename FastVector::reference FastVector::at(size_type pos) +{ + ASSERT(pos < mSize); + return mData[pos]; +} + +template +typename FastVector::const_reference FastVector::at( + size_type pos) const +{ + ASSERT(pos < mSize); + return mData[pos]; +} + +template +ANGLE_INLINE typename FastVector::reference FastVector::operator[]( + size_type pos) +{ + ASSERT(pos < mSize); + return mData[pos]; +} + +template +ANGLE_INLINE typename FastVector::const_reference +FastVector::operator[](size_type pos) const +{ + ASSERT(pos < mSize); + return mData[pos]; +} + +template +ANGLE_INLINE typename FastVector::const_pointer +angle::FastVector::data() const +{ + return mData; +} + +template +ANGLE_INLINE typename FastVector::pointer angle::FastVector::data() +{ + return mData; +} + +template +ANGLE_INLINE typename FastVector::iterator FastVector::begin() +{ + return mData; +} + +template +ANGLE_INLINE typename FastVector::const_iterator FastVector::begin() + const +{ + return mData; +} + +template +ANGLE_INLINE typename FastVector::iterator FastVector::end() +{ + return mData + mSize; +} + +template +ANGLE_INLINE typename FastVector::const_iterator FastVector::end() + const +{ + return mData + mSize; +} + +template +ANGLE_INLINE bool FastVector::empty() const +{ + return mSize == 0; +} + +template +ANGLE_INLINE typename FastVector::size_type FastVector::size() const +{ + return mSize; +} + +template +void FastVector::clear() +{ + resize(0); +} + +template +ANGLE_INLINE void FastVector::push_back(const value_type &value) +{ + if (mSize == mReservedSize) + ensure_capacity(mSize + 1); + mData[mSize++] = value; +} + +template +ANGLE_INLINE void FastVector::push_back(value_type &&value) +{ + emplace_back(std::move(value)); +} + +template +template +ANGLE_INLINE void FastVector::emplace_back(Args &&...args) +{ + if (mSize == mReservedSize) + ensure_capacity(mSize + 1); + mData[mSize++] = std::move(T(std::forward(args)...)); +} + +template +ANGLE_INLINE void FastVector::pop_back() +{ + ASSERT(mSize > 0); + mSize--; +} + +template +ANGLE_INLINE typename FastVector::reference FastVector::front() +{ + ASSERT(mSize > 0); + return mData[0]; +} + +template +ANGLE_INLINE typename FastVector::const_reference FastVector::front() + const +{ + ASSERT(mSize > 0); + return mData[0]; +} + +template +ANGLE_INLINE typename FastVector::reference FastVector::back() +{ + ASSERT(mSize > 0); + return mData[mSize - 1]; +} + +template +ANGLE_INLINE typename FastVector::const_reference FastVector::back() + const +{ + ASSERT(mSize > 0); + return mData[mSize - 1]; +} + +template +void FastVector::swap(FastVector &other) +{ + std::swap(mSize, other.mSize); + + pointer tempData = other.mData; + if (uses_fixed_storage()) + other.mData = other.mFixedStorage.data(); + else + other.mData = mData; + if (tempData == other.mFixedStorage.data()) + mData = mFixedStorage.data(); + else + mData = tempData; + std::swap(mReservedSize, other.mReservedSize); + + if (uses_fixed_storage() || other.uses_fixed_storage()) + std::swap(mFixedStorage, other.mFixedStorage); +} + +template +void FastVector::resize(size_type count) +{ + if (count > mSize) + { + ensure_capacity(count); + } + mSize = count; +} + +template +void FastVector::resize(size_type count, const value_type &value) +{ + if (count > mSize) + { + ensure_capacity(count); + std::fill(mData + mSize, mData + count, value); + } + mSize = count; +} + +template +void FastVector::reserve(size_type count) +{ + ensure_capacity(count); +} + +template +void FastVector::assign_from_initializer_list(std::initializer_list init) +{ + ensure_capacity(init.size()); + mSize = init.size(); + size_t index = 0; + for (auto &value : init) + { + mData[index++] = value; + } +} + +template +ANGLE_INLINE void FastVector::remove_and_permute(const value_type &element) +{ + size_t len = mSize - 1; + for (size_t index = 0; index < len; ++index) + { + if (mData[index] == element) + { + mData[index] = std::move(mData[len]); + break; + } + } + pop_back(); +} + +template +ANGLE_INLINE void FastVector::remove_and_permute(iterator pos) +{ + ASSERT(pos >= begin()); + ASSERT(pos < end()); + size_t len = mSize - 1; + *pos = std::move(mData[len]); + pop_back(); +} + +template +void FastVector::ensure_capacity(size_t capacity) +{ + // We have a minimum capacity of N. + if (mReservedSize < capacity) + { + ASSERT(capacity > N); + size_type newSize = std::max(mReservedSize, N); + while (newSize < capacity) + { + newSize *= 2; + } + + pointer newData = new value_type[newSize]; + + if (mSize > 0) + { + std::move(begin(), end(), newData); + } + + if (!uses_fixed_storage()) + { + delete[] mData; + } + + mData = newData; + mReservedSize = newSize; + } +} + +template +class FastMap final +{ + public: + FastMap() {} + ~FastMap() {} + + Value &operator[](uint32_t key) + { + if (mData.size() <= key) + { + mData.resize(key + 1, {}); + } + return mData[key]; + } + + const Value &operator[](uint32_t key) const + { + ASSERT(key < mData.size()); + return mData[key]; + } + + void clear() { mData.clear(); } + + bool empty() const { return mData.empty(); } + size_t size() const { return mData.size(); } + + const Value *data() const { return mData.data(); } + + bool operator==(const FastMap &other) const + { + return (size() == other.size()) && + (memcmp(data(), other.data(), size() * sizeof(Value)) == 0); + } + + private: + FastVector mData; +}; + +template +class FlatUnorderedMap final +{ + public: + using Pair = std::pair; + using Storage = FastVector; + using iterator = typename Storage::iterator; + using const_iterator = typename Storage::const_iterator; + + FlatUnorderedMap() = default; + ~FlatUnorderedMap() = default; + + iterator begin() { return mData.begin(); } + const_iterator begin() const { return mData.begin(); } + iterator end() { return mData.end(); } + const_iterator end() const { return mData.end(); } + + iterator find(const Key &key) + { + for (auto it = mData.begin(); it != mData.end(); ++it) + { + if (it->first == key) + { + return it; + } + } + return mData.end(); + } + + const_iterator find(const Key &key) const + { + for (auto it = mData.begin(); it != mData.end(); ++it) + { + if (it->first == key) + { + return it; + } + } + return mData.end(); + } + + Value &operator[](const Key &key) + { + iterator it = find(key); + if (it != end()) + { + return it->second; + } + + mData.push_back(Pair(key, {})); + return mData.back().second; + } + + void insert(Pair pair) + { + ASSERT(!contains(pair.first)); + mData.push_back(std::move(pair)); + } + + void insert(const Key &key, Value value) { insert(Pair(key, value)); } + + void erase(iterator pos) { mData.remove_and_permute(pos); } + + bool contains(const Key &key) const { return find(key) != end(); } + + void clear() { mData.clear(); } + + bool get(const Key &key, Value *value) const + { + auto it = find(key); + if (it != end()) + { + *value = it->second; + return true; + } + return false; + } + + bool empty() const { return mData.empty(); } + size_t size() const { return mData.size(); } + + private: + FastVector mData; +}; + +template +class FlatUnorderedSet final +{ + public: + using Storage = FastVector; + using iterator = typename Storage::iterator; + using const_iterator = typename Storage::const_iterator; + + FlatUnorderedSet() = default; + ~FlatUnorderedSet() = default; + + iterator begin() { return mData.begin(); } + const_iterator begin() const { return mData.begin(); } + iterator end() { return mData.end(); } + const_iterator end() const { return mData.end(); } + + iterator find(const T &value) + { + for (auto it = mData.begin(); it != mData.end(); ++it) + { + if (*it == value) + { + return it; + } + } + return mData.end(); + } + + const_iterator find(const T &value) const + { + for (auto it = mData.begin(); it != mData.end(); ++it) + { + if (*it == value) + { + return it; + } + } + return mData.end(); + } + + bool empty() const { return mData.empty(); } + + void insert(const T &value) + { + ASSERT(!contains(value)); + mData.push_back(value); + } + + void erase(const T &value) + { + ASSERT(contains(value)); + mData.remove_and_permute(value); + } + + void remove(const T &value) { erase(value); } + + bool contains(const T &value) const { return find(value) != end(); } + + void clear() { mData.clear(); } + + bool operator==(const FlatUnorderedSet &other) const { return mData == other.mData; } + + private: + Storage mData; +}; + +class FastIntegerSet final +{ + public: + static constexpr size_t kWindowSize = 64; + static constexpr size_t kOneLessThanKWindowSize = kWindowSize - 1; + static constexpr size_t kShiftForDivision = + static_cast(rx::Log2(static_cast(kWindowSize))); + using KeyBitSet = angle::BitSet64; + + ANGLE_INLINE FastIntegerSet(); + ANGLE_INLINE ~FastIntegerSet(); + + ANGLE_INLINE void ensureCapacity(size_t size) + { + if (capacity() <= size) + { + reserve(size * 2); + } + } + + ANGLE_INLINE void insert(uint64_t key) + { + size_t sizedKey = static_cast(key); + + ASSERT(!contains(sizedKey)); + ensureCapacity(sizedKey); + ASSERT(capacity() > sizedKey); + + size_t index = sizedKey >> kShiftForDivision; + size_t offset = sizedKey & kOneLessThanKWindowSize; + + mKeyData[index].set(offset, true); + } + + ANGLE_INLINE bool contains(uint64_t key) const + { + size_t sizedKey = static_cast(key); + + size_t index = sizedKey >> kShiftForDivision; + size_t offset = sizedKey & kOneLessThanKWindowSize; + + return (sizedKey < capacity()) && (mKeyData[index].test(offset)); + } + + ANGLE_INLINE void clear() + { + for (KeyBitSet &it : mKeyData) + { + it.reset(); + } + } + + ANGLE_INLINE bool empty() const + { + for (const KeyBitSet &it : mKeyData) + { + if (it.any()) + { + return false; + } + } + return true; + } + + ANGLE_INLINE size_t size() const + { + size_t valid_entries = 0; + for (const KeyBitSet &it : mKeyData) + { + valid_entries += it.count(); + } + return valid_entries; + } + + private: + ANGLE_INLINE size_t capacity() const { return kWindowSize * mKeyData.size(); } + + ANGLE_INLINE void reserve(size_t newSize) + { + size_t alignedSize = rx::roundUpPow2(newSize, kWindowSize); + size_t count = alignedSize >> kShiftForDivision; + + mKeyData.resize(count, KeyBitSet::Zero()); + } + + std::vector mKeyData; +}; + +// This is needed to accommodate the chromium style guide error - +// [chromium-style] Complex constructor has an inlined body. +ANGLE_INLINE FastIntegerSet::FastIntegerSet() {} +ANGLE_INLINE FastIntegerSet::~FastIntegerSet() {} + +template +class FastIntegerMap final +{ + public: + FastIntegerMap() {} + ~FastIntegerMap() {} + + ANGLE_INLINE void ensureCapacity(size_t size) + { + // Ensure key set has capacity + mKeySet.ensureCapacity(size); + + // Ensure value vector has capacity + ensureCapacityImpl(size); + } + + ANGLE_INLINE void insert(uint64_t key, Value value) + { + // Insert key + ASSERT(!mKeySet.contains(key)); + mKeySet.insert(key); + + // Insert value + size_t sizedKey = static_cast(key); + ensureCapacityImpl(sizedKey); + ASSERT(capacity() > sizedKey); + mValueData[sizedKey] = value; + } + + ANGLE_INLINE bool contains(uint64_t key) const { return mKeySet.contains(key); } + + ANGLE_INLINE bool get(uint64_t key, Value *out) const + { + if (!mKeySet.contains(key)) + { + return false; + } + + size_t sizedKey = static_cast(key); + *out = mValueData[sizedKey]; + return true; + } + + ANGLE_INLINE void clear() { mKeySet.clear(); } + + ANGLE_INLINE bool empty() const { return mKeySet.empty(); } + + ANGLE_INLINE size_t size() const { return mKeySet.size(); } + + private: + ANGLE_INLINE size_t capacity() const { return mValueData.size(); } + + ANGLE_INLINE void ensureCapacityImpl(size_t size) + { + if (capacity() <= size) + { + reserve(size * 2); + } + } + + ANGLE_INLINE void reserve(size_t newSize) + { + size_t alignedSize = rx::roundUpPow2(newSize, FastIntegerSet::kWindowSize); + mValueData.resize(alignedSize); + } + + FastIntegerSet mKeySet; + std::vector mValueData; +}; +} // namespace angle + +#endif // COMMON_FASTVECTOR_H_ diff --git a/gfx/angle/checkout/src/common/FixedVector.h b/gfx/angle/checkout/src/common/FixedVector.h new file mode 100644 index 0000000000..bff87fc969 --- /dev/null +++ b/gfx/angle/checkout/src/common/FixedVector.h @@ -0,0 +1,353 @@ +// +// Copyright 2018 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// FixedVector.h: +// A vector class with a maximum size and fixed storage. +// + +#ifndef COMMON_FIXEDVECTOR_H_ +#define COMMON_FIXEDVECTOR_H_ + +#include "common/debug.h" + +#include +#include +#include + +namespace angle +{ +template > +class FixedVector final +{ + public: + using value_type = typename Storage::value_type; + using size_type = typename Storage::size_type; + using reference = typename Storage::reference; + using const_reference = typename Storage::const_reference; + using pointer = typename Storage::pointer; + using const_pointer = typename Storage::const_pointer; + using iterator = typename Storage::iterator; + using const_iterator = typename Storage::const_iterator; + using reverse_iterator = typename Storage::reverse_iterator; + using const_reverse_iterator = typename Storage::const_reverse_iterator; + + FixedVector(); + FixedVector(size_type count, const value_type &value); + FixedVector(size_type count); + + FixedVector(const FixedVector &other); + FixedVector(FixedVector &&other); + FixedVector(std::initializer_list init); + + FixedVector &operator=(const FixedVector &other); + FixedVector &operator=(FixedVector &&other); + FixedVector &operator=(std::initializer_list init); + + ~FixedVector(); + + reference at(size_type pos); + const_reference at(size_type pos) const; + + reference operator[](size_type pos); + const_reference operator[](size_type pos) const; + + pointer data(); + const_pointer data() const; + + iterator begin(); + const_iterator begin() const; + + iterator end(); + const_iterator end() const; + + bool empty() const; + size_type size() const; + static constexpr size_type max_size(); + + void clear(); + + void push_back(const value_type &value); + void push_back(value_type &&value); + + template + void emplace_back(Args &&... args); + + void pop_back(); + reference back(); + const_reference back() const; + + void swap(FixedVector &other); + + void resize(size_type count); + void resize(size_type count, const value_type &value); + + bool full() const; + + private: + void assign_from_initializer_list(std::initializer_list init); + + Storage mStorage; + size_type mSize = 0; +}; + +template +bool operator==(const FixedVector &a, const FixedVector &b) +{ + return a.size() == b.size() && std::equal(a.begin(), a.end(), b.begin()); +} + +template +bool operator!=(const FixedVector &a, const FixedVector &b) +{ + return !(a == b); +} + +template +FixedVector::FixedVector() = default; + +template +FixedVector::FixedVector(size_type count, const value_type &value) : mSize(count) +{ + ASSERT(count <= N); + std::fill(mStorage.begin(), mStorage.begin() + count, value); +} + +template +FixedVector::FixedVector(size_type count) : mSize(count) +{ + ASSERT(count <= N); +} + +template +FixedVector::FixedVector(const FixedVector &other) = default; + +template +FixedVector::FixedVector(FixedVector &&other) = default; + +template +FixedVector::FixedVector(std::initializer_list init) +{ + ASSERT(init.size() <= N); + assign_from_initializer_list(init); +} + +template +FixedVector &FixedVector::operator=( + const FixedVector &other) = default; + +template +FixedVector &FixedVector::operator=( + FixedVector &&other) = default; + +template +FixedVector &FixedVector::operator=( + std::initializer_list init) +{ + clear(); + ASSERT(init.size() <= N); + assign_from_initializer_list(init); + return this; +} + +template +FixedVector::~FixedVector() +{ + clear(); +} + +template +typename FixedVector::reference FixedVector::at(size_type pos) +{ + ASSERT(pos < N); + return mStorage.at(pos); +} + +template +typename FixedVector::const_reference FixedVector::at( + size_type pos) const +{ + ASSERT(pos < N); + return mStorage.at(pos); +} + +template +typename FixedVector::reference FixedVector::operator[](size_type pos) +{ + ASSERT(pos < N); + return mStorage[pos]; +} + +template +typename FixedVector::const_reference FixedVector::operator[]( + size_type pos) const +{ + ASSERT(pos < N); + return mStorage[pos]; +} + +template +typename FixedVector::const_pointer angle::FixedVector::data() const +{ + return mStorage.data(); +} + +template +typename FixedVector::pointer angle::FixedVector::data() +{ + return mStorage.data(); +} + +template +typename FixedVector::iterator FixedVector::begin() +{ + return mStorage.begin(); +} + +template +typename FixedVector::const_iterator FixedVector::begin() const +{ + return mStorage.begin(); +} + +template +typename FixedVector::iterator FixedVector::end() +{ + return mStorage.begin() + mSize; +} + +template +typename FixedVector::const_iterator FixedVector::end() const +{ + return mStorage.begin() + mSize; +} + +template +bool FixedVector::empty() const +{ + return mSize == 0; +} + +template +typename FixedVector::size_type FixedVector::size() const +{ + return mSize; +} + +template +constexpr typename FixedVector::size_type FixedVector::max_size() +{ + return N; +} + +template +void FixedVector::clear() +{ + resize(0); +} + +template +void FixedVector::push_back(const value_type &value) +{ + ASSERT(mSize < N); + mStorage[mSize] = value; + mSize++; +} + +template +void FixedVector::push_back(value_type &&value) +{ + ASSERT(mSize < N); + mStorage[mSize] = std::move(value); + mSize++; +} + +template +template +void FixedVector::emplace_back(Args &&... args) +{ + ASSERT(mSize < N); + new (&mStorage[mSize]) T{std::forward(args)...}; + mSize++; +} + +template +void FixedVector::pop_back() +{ + ASSERT(mSize > 0); + mSize--; +} + +template +typename FixedVector::reference FixedVector::back() +{ + ASSERT(mSize > 0); + return mStorage[mSize - 1]; +} + +template +typename FixedVector::const_reference FixedVector::back() const +{ + ASSERT(mSize > 0); + return mStorage[mSize - 1]; +} + +template +void FixedVector::swap(FixedVector &other) +{ + std::swap(mSize, other.mSize); + std::swap(mStorage, other.mStorage); +} + +template +void FixedVector::resize(size_type count) +{ + ASSERT(count <= N); + while (mSize > count) + { + mSize--; + mStorage[mSize] = value_type(); + } + while (mSize < count) + { + mStorage[mSize] = value_type(); + mSize++; + } +} + +template +void FixedVector::resize(size_type count, const value_type &value) +{ + ASSERT(count <= N); + while (mSize > count) + { + mSize--; + mStorage[mSize] = value_type(); + } + while (mSize < count) + { + mStorage[mSize] = value; + mSize++; + } +} + +template +void FixedVector::assign_from_initializer_list( + std::initializer_list init) +{ + for (auto element : init) + { + mStorage[mSize] = std::move(element); + mSize++; + } +} + +template +bool FixedVector::full() const +{ + return (mSize == N); +} +} // namespace angle + +#endif // COMMON_FIXEDVECTOR_H_ diff --git a/gfx/angle/checkout/src/common/Float16ToFloat32.cpp b/gfx/angle/checkout/src/common/Float16ToFloat32.cpp new file mode 100644 index 0000000000..f9dfe23307 --- /dev/null +++ b/gfx/angle/checkout/src/common/Float16ToFloat32.cpp @@ -0,0 +1,300 @@ +// +// Copyright 2012 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// This file is automatically generated. + +#include "common/mathutil.h" + +namespace gl +{ + +const static unsigned g_mantissa[2048] = { + 0x00000000, 0x33800000, 0x34000000, 0x34400000, 0x34800000, 0x34a00000, 0x34c00000, 0x34e00000, + 0x35000000, 0x35100000, 0x35200000, 0x35300000, 0x35400000, 0x35500000, 0x35600000, 0x35700000, + 0x35800000, 0x35880000, 0x35900000, 0x35980000, 0x35a00000, 0x35a80000, 0x35b00000, 0x35b80000, + 0x35c00000, 0x35c80000, 0x35d00000, 0x35d80000, 0x35e00000, 0x35e80000, 0x35f00000, 0x35f80000, + 0x36000000, 0x36040000, 0x36080000, 0x360c0000, 0x36100000, 0x36140000, 0x36180000, 0x361c0000, + 0x36200000, 0x36240000, 0x36280000, 0x362c0000, 0x36300000, 0x36340000, 0x36380000, 0x363c0000, + 0x36400000, 0x36440000, 0x36480000, 0x364c0000, 0x36500000, 0x36540000, 0x36580000, 0x365c0000, + 0x36600000, 0x36640000, 0x36680000, 0x366c0000, 0x36700000, 0x36740000, 0x36780000, 0x367c0000, + 0x36800000, 0x36820000, 0x36840000, 0x36860000, 0x36880000, 0x368a0000, 0x368c0000, 0x368e0000, + 0x36900000, 0x36920000, 0x36940000, 0x36960000, 0x36980000, 0x369a0000, 0x369c0000, 0x369e0000, + 0x36a00000, 0x36a20000, 0x36a40000, 0x36a60000, 0x36a80000, 0x36aa0000, 0x36ac0000, 0x36ae0000, + 0x36b00000, 0x36b20000, 0x36b40000, 0x36b60000, 0x36b80000, 0x36ba0000, 0x36bc0000, 0x36be0000, + 0x36c00000, 0x36c20000, 0x36c40000, 0x36c60000, 0x36c80000, 0x36ca0000, 0x36cc0000, 0x36ce0000, + 0x36d00000, 0x36d20000, 0x36d40000, 0x36d60000, 0x36d80000, 0x36da0000, 0x36dc0000, 0x36de0000, + 0x36e00000, 0x36e20000, 0x36e40000, 0x36e60000, 0x36e80000, 0x36ea0000, 0x36ec0000, 0x36ee0000, + 0x36f00000, 0x36f20000, 0x36f40000, 0x36f60000, 0x36f80000, 0x36fa0000, 0x36fc0000, 0x36fe0000, + 0x37000000, 0x37010000, 0x37020000, 0x37030000, 0x37040000, 0x37050000, 0x37060000, 0x37070000, + 0x37080000, 0x37090000, 0x370a0000, 0x370b0000, 0x370c0000, 0x370d0000, 0x370e0000, 0x370f0000, + 0x37100000, 0x37110000, 0x37120000, 0x37130000, 0x37140000, 0x37150000, 0x37160000, 0x37170000, + 0x37180000, 0x37190000, 0x371a0000, 0x371b0000, 0x371c0000, 0x371d0000, 0x371e0000, 0x371f0000, + 0x37200000, 0x37210000, 0x37220000, 0x37230000, 0x37240000, 0x37250000, 0x37260000, 0x37270000, + 0x37280000, 0x37290000, 0x372a0000, 0x372b0000, 0x372c0000, 0x372d0000, 0x372e0000, 0x372f0000, + 0x37300000, 0x37310000, 0x37320000, 0x37330000, 0x37340000, 0x37350000, 0x37360000, 0x37370000, + 0x37380000, 0x37390000, 0x373a0000, 0x373b0000, 0x373c0000, 0x373d0000, 0x373e0000, 0x373f0000, + 0x37400000, 0x37410000, 0x37420000, 0x37430000, 0x37440000, 0x37450000, 0x37460000, 0x37470000, + 0x37480000, 0x37490000, 0x374a0000, 0x374b0000, 0x374c0000, 0x374d0000, 0x374e0000, 0x374f0000, + 0x37500000, 0x37510000, 0x37520000, 0x37530000, 0x37540000, 0x37550000, 0x37560000, 0x37570000, + 0x37580000, 0x37590000, 0x375a0000, 0x375b0000, 0x375c0000, 0x375d0000, 0x375e0000, 0x375f0000, + 0x37600000, 0x37610000, 0x37620000, 0x37630000, 0x37640000, 0x37650000, 0x37660000, 0x37670000, + 0x37680000, 0x37690000, 0x376a0000, 0x376b0000, 0x376c0000, 0x376d0000, 0x376e0000, 0x376f0000, + 0x37700000, 0x37710000, 0x37720000, 0x37730000, 0x37740000, 0x37750000, 0x37760000, 0x37770000, + 0x37780000, 0x37790000, 0x377a0000, 0x377b0000, 0x377c0000, 0x377d0000, 0x377e0000, 0x377f0000, + 0x37800000, 0x37808000, 0x37810000, 0x37818000, 0x37820000, 0x37828000, 0x37830000, 0x37838000, + 0x37840000, 0x37848000, 0x37850000, 0x37858000, 0x37860000, 0x37868000, 0x37870000, 0x37878000, + 0x37880000, 0x37888000, 0x37890000, 0x37898000, 0x378a0000, 0x378a8000, 0x378b0000, 0x378b8000, + 0x378c0000, 0x378c8000, 0x378d0000, 0x378d8000, 0x378e0000, 0x378e8000, 0x378f0000, 0x378f8000, + 0x37900000, 0x37908000, 0x37910000, 0x37918000, 0x37920000, 0x37928000, 0x37930000, 0x37938000, + 0x37940000, 0x37948000, 0x37950000, 0x37958000, 0x37960000, 0x37968000, 0x37970000, 0x37978000, + 0x37980000, 0x37988000, 0x37990000, 0x37998000, 0x379a0000, 0x379a8000, 0x379b0000, 0x379b8000, + 0x379c0000, 0x379c8000, 0x379d0000, 0x379d8000, 0x379e0000, 0x379e8000, 0x379f0000, 0x379f8000, + 0x37a00000, 0x37a08000, 0x37a10000, 0x37a18000, 0x37a20000, 0x37a28000, 0x37a30000, 0x37a38000, + 0x37a40000, 0x37a48000, 0x37a50000, 0x37a58000, 0x37a60000, 0x37a68000, 0x37a70000, 0x37a78000, + 0x37a80000, 0x37a88000, 0x37a90000, 0x37a98000, 0x37aa0000, 0x37aa8000, 0x37ab0000, 0x37ab8000, + 0x37ac0000, 0x37ac8000, 0x37ad0000, 0x37ad8000, 0x37ae0000, 0x37ae8000, 0x37af0000, 0x37af8000, + 0x37b00000, 0x37b08000, 0x37b10000, 0x37b18000, 0x37b20000, 0x37b28000, 0x37b30000, 0x37b38000, + 0x37b40000, 0x37b48000, 0x37b50000, 0x37b58000, 0x37b60000, 0x37b68000, 0x37b70000, 0x37b78000, + 0x37b80000, 0x37b88000, 0x37b90000, 0x37b98000, 0x37ba0000, 0x37ba8000, 0x37bb0000, 0x37bb8000, + 0x37bc0000, 0x37bc8000, 0x37bd0000, 0x37bd8000, 0x37be0000, 0x37be8000, 0x37bf0000, 0x37bf8000, + 0x37c00000, 0x37c08000, 0x37c10000, 0x37c18000, 0x37c20000, 0x37c28000, 0x37c30000, 0x37c38000, + 0x37c40000, 0x37c48000, 0x37c50000, 0x37c58000, 0x37c60000, 0x37c68000, 0x37c70000, 0x37c78000, + 0x37c80000, 0x37c88000, 0x37c90000, 0x37c98000, 0x37ca0000, 0x37ca8000, 0x37cb0000, 0x37cb8000, + 0x37cc0000, 0x37cc8000, 0x37cd0000, 0x37cd8000, 0x37ce0000, 0x37ce8000, 0x37cf0000, 0x37cf8000, + 0x37d00000, 0x37d08000, 0x37d10000, 0x37d18000, 0x37d20000, 0x37d28000, 0x37d30000, 0x37d38000, + 0x37d40000, 0x37d48000, 0x37d50000, 0x37d58000, 0x37d60000, 0x37d68000, 0x37d70000, 0x37d78000, + 0x37d80000, 0x37d88000, 0x37d90000, 0x37d98000, 0x37da0000, 0x37da8000, 0x37db0000, 0x37db8000, + 0x37dc0000, 0x37dc8000, 0x37dd0000, 0x37dd8000, 0x37de0000, 0x37de8000, 0x37df0000, 0x37df8000, + 0x37e00000, 0x37e08000, 0x37e10000, 0x37e18000, 0x37e20000, 0x37e28000, 0x37e30000, 0x37e38000, + 0x37e40000, 0x37e48000, 0x37e50000, 0x37e58000, 0x37e60000, 0x37e68000, 0x37e70000, 0x37e78000, + 0x37e80000, 0x37e88000, 0x37e90000, 0x37e98000, 0x37ea0000, 0x37ea8000, 0x37eb0000, 0x37eb8000, + 0x37ec0000, 0x37ec8000, 0x37ed0000, 0x37ed8000, 0x37ee0000, 0x37ee8000, 0x37ef0000, 0x37ef8000, + 0x37f00000, 0x37f08000, 0x37f10000, 0x37f18000, 0x37f20000, 0x37f28000, 0x37f30000, 0x37f38000, + 0x37f40000, 0x37f48000, 0x37f50000, 0x37f58000, 0x37f60000, 0x37f68000, 0x37f70000, 0x37f78000, + 0x37f80000, 0x37f88000, 0x37f90000, 0x37f98000, 0x37fa0000, 0x37fa8000, 0x37fb0000, 0x37fb8000, + 0x37fc0000, 0x37fc8000, 0x37fd0000, 0x37fd8000, 0x37fe0000, 0x37fe8000, 0x37ff0000, 0x37ff8000, + 0x38000000, 0x38004000, 0x38008000, 0x3800c000, 0x38010000, 0x38014000, 0x38018000, 0x3801c000, + 0x38020000, 0x38024000, 0x38028000, 0x3802c000, 0x38030000, 0x38034000, 0x38038000, 0x3803c000, + 0x38040000, 0x38044000, 0x38048000, 0x3804c000, 0x38050000, 0x38054000, 0x38058000, 0x3805c000, + 0x38060000, 0x38064000, 0x38068000, 0x3806c000, 0x38070000, 0x38074000, 0x38078000, 0x3807c000, + 0x38080000, 0x38084000, 0x38088000, 0x3808c000, 0x38090000, 0x38094000, 0x38098000, 0x3809c000, + 0x380a0000, 0x380a4000, 0x380a8000, 0x380ac000, 0x380b0000, 0x380b4000, 0x380b8000, 0x380bc000, + 0x380c0000, 0x380c4000, 0x380c8000, 0x380cc000, 0x380d0000, 0x380d4000, 0x380d8000, 0x380dc000, + 0x380e0000, 0x380e4000, 0x380e8000, 0x380ec000, 0x380f0000, 0x380f4000, 0x380f8000, 0x380fc000, + 0x38100000, 0x38104000, 0x38108000, 0x3810c000, 0x38110000, 0x38114000, 0x38118000, 0x3811c000, + 0x38120000, 0x38124000, 0x38128000, 0x3812c000, 0x38130000, 0x38134000, 0x38138000, 0x3813c000, + 0x38140000, 0x38144000, 0x38148000, 0x3814c000, 0x38150000, 0x38154000, 0x38158000, 0x3815c000, + 0x38160000, 0x38164000, 0x38168000, 0x3816c000, 0x38170000, 0x38174000, 0x38178000, 0x3817c000, + 0x38180000, 0x38184000, 0x38188000, 0x3818c000, 0x38190000, 0x38194000, 0x38198000, 0x3819c000, + 0x381a0000, 0x381a4000, 0x381a8000, 0x381ac000, 0x381b0000, 0x381b4000, 0x381b8000, 0x381bc000, + 0x381c0000, 0x381c4000, 0x381c8000, 0x381cc000, 0x381d0000, 0x381d4000, 0x381d8000, 0x381dc000, + 0x381e0000, 0x381e4000, 0x381e8000, 0x381ec000, 0x381f0000, 0x381f4000, 0x381f8000, 0x381fc000, + 0x38200000, 0x38204000, 0x38208000, 0x3820c000, 0x38210000, 0x38214000, 0x38218000, 0x3821c000, + 0x38220000, 0x38224000, 0x38228000, 0x3822c000, 0x38230000, 0x38234000, 0x38238000, 0x3823c000, + 0x38240000, 0x38244000, 0x38248000, 0x3824c000, 0x38250000, 0x38254000, 0x38258000, 0x3825c000, + 0x38260000, 0x38264000, 0x38268000, 0x3826c000, 0x38270000, 0x38274000, 0x38278000, 0x3827c000, + 0x38280000, 0x38284000, 0x38288000, 0x3828c000, 0x38290000, 0x38294000, 0x38298000, 0x3829c000, + 0x382a0000, 0x382a4000, 0x382a8000, 0x382ac000, 0x382b0000, 0x382b4000, 0x382b8000, 0x382bc000, + 0x382c0000, 0x382c4000, 0x382c8000, 0x382cc000, 0x382d0000, 0x382d4000, 0x382d8000, 0x382dc000, + 0x382e0000, 0x382e4000, 0x382e8000, 0x382ec000, 0x382f0000, 0x382f4000, 0x382f8000, 0x382fc000, + 0x38300000, 0x38304000, 0x38308000, 0x3830c000, 0x38310000, 0x38314000, 0x38318000, 0x3831c000, + 0x38320000, 0x38324000, 0x38328000, 0x3832c000, 0x38330000, 0x38334000, 0x38338000, 0x3833c000, + 0x38340000, 0x38344000, 0x38348000, 0x3834c000, 0x38350000, 0x38354000, 0x38358000, 0x3835c000, + 0x38360000, 0x38364000, 0x38368000, 0x3836c000, 0x38370000, 0x38374000, 0x38378000, 0x3837c000, + 0x38380000, 0x38384000, 0x38388000, 0x3838c000, 0x38390000, 0x38394000, 0x38398000, 0x3839c000, + 0x383a0000, 0x383a4000, 0x383a8000, 0x383ac000, 0x383b0000, 0x383b4000, 0x383b8000, 0x383bc000, + 0x383c0000, 0x383c4000, 0x383c8000, 0x383cc000, 0x383d0000, 0x383d4000, 0x383d8000, 0x383dc000, + 0x383e0000, 0x383e4000, 0x383e8000, 0x383ec000, 0x383f0000, 0x383f4000, 0x383f8000, 0x383fc000, + 0x38400000, 0x38404000, 0x38408000, 0x3840c000, 0x38410000, 0x38414000, 0x38418000, 0x3841c000, + 0x38420000, 0x38424000, 0x38428000, 0x3842c000, 0x38430000, 0x38434000, 0x38438000, 0x3843c000, + 0x38440000, 0x38444000, 0x38448000, 0x3844c000, 0x38450000, 0x38454000, 0x38458000, 0x3845c000, + 0x38460000, 0x38464000, 0x38468000, 0x3846c000, 0x38470000, 0x38474000, 0x38478000, 0x3847c000, + 0x38480000, 0x38484000, 0x38488000, 0x3848c000, 0x38490000, 0x38494000, 0x38498000, 0x3849c000, + 0x384a0000, 0x384a4000, 0x384a8000, 0x384ac000, 0x384b0000, 0x384b4000, 0x384b8000, 0x384bc000, + 0x384c0000, 0x384c4000, 0x384c8000, 0x384cc000, 0x384d0000, 0x384d4000, 0x384d8000, 0x384dc000, + 0x384e0000, 0x384e4000, 0x384e8000, 0x384ec000, 0x384f0000, 0x384f4000, 0x384f8000, 0x384fc000, + 0x38500000, 0x38504000, 0x38508000, 0x3850c000, 0x38510000, 0x38514000, 0x38518000, 0x3851c000, + 0x38520000, 0x38524000, 0x38528000, 0x3852c000, 0x38530000, 0x38534000, 0x38538000, 0x3853c000, + 0x38540000, 0x38544000, 0x38548000, 0x3854c000, 0x38550000, 0x38554000, 0x38558000, 0x3855c000, + 0x38560000, 0x38564000, 0x38568000, 0x3856c000, 0x38570000, 0x38574000, 0x38578000, 0x3857c000, + 0x38580000, 0x38584000, 0x38588000, 0x3858c000, 0x38590000, 0x38594000, 0x38598000, 0x3859c000, + 0x385a0000, 0x385a4000, 0x385a8000, 0x385ac000, 0x385b0000, 0x385b4000, 0x385b8000, 0x385bc000, + 0x385c0000, 0x385c4000, 0x385c8000, 0x385cc000, 0x385d0000, 0x385d4000, 0x385d8000, 0x385dc000, + 0x385e0000, 0x385e4000, 0x385e8000, 0x385ec000, 0x385f0000, 0x385f4000, 0x385f8000, 0x385fc000, + 0x38600000, 0x38604000, 0x38608000, 0x3860c000, 0x38610000, 0x38614000, 0x38618000, 0x3861c000, + 0x38620000, 0x38624000, 0x38628000, 0x3862c000, 0x38630000, 0x38634000, 0x38638000, 0x3863c000, + 0x38640000, 0x38644000, 0x38648000, 0x3864c000, 0x38650000, 0x38654000, 0x38658000, 0x3865c000, + 0x38660000, 0x38664000, 0x38668000, 0x3866c000, 0x38670000, 0x38674000, 0x38678000, 0x3867c000, + 0x38680000, 0x38684000, 0x38688000, 0x3868c000, 0x38690000, 0x38694000, 0x38698000, 0x3869c000, + 0x386a0000, 0x386a4000, 0x386a8000, 0x386ac000, 0x386b0000, 0x386b4000, 0x386b8000, 0x386bc000, + 0x386c0000, 0x386c4000, 0x386c8000, 0x386cc000, 0x386d0000, 0x386d4000, 0x386d8000, 0x386dc000, + 0x386e0000, 0x386e4000, 0x386e8000, 0x386ec000, 0x386f0000, 0x386f4000, 0x386f8000, 0x386fc000, + 0x38700000, 0x38704000, 0x38708000, 0x3870c000, 0x38710000, 0x38714000, 0x38718000, 0x3871c000, + 0x38720000, 0x38724000, 0x38728000, 0x3872c000, 0x38730000, 0x38734000, 0x38738000, 0x3873c000, + 0x38740000, 0x38744000, 0x38748000, 0x3874c000, 0x38750000, 0x38754000, 0x38758000, 0x3875c000, + 0x38760000, 0x38764000, 0x38768000, 0x3876c000, 0x38770000, 0x38774000, 0x38778000, 0x3877c000, + 0x38780000, 0x38784000, 0x38788000, 0x3878c000, 0x38790000, 0x38794000, 0x38798000, 0x3879c000, + 0x387a0000, 0x387a4000, 0x387a8000, 0x387ac000, 0x387b0000, 0x387b4000, 0x387b8000, 0x387bc000, + 0x387c0000, 0x387c4000, 0x387c8000, 0x387cc000, 0x387d0000, 0x387d4000, 0x387d8000, 0x387dc000, + 0x387e0000, 0x387e4000, 0x387e8000, 0x387ec000, 0x387f0000, 0x387f4000, 0x387f8000, 0x387fc000, + 0x38000000, 0x38002000, 0x38004000, 0x38006000, 0x38008000, 0x3800a000, 0x3800c000, 0x3800e000, + 0x38010000, 0x38012000, 0x38014000, 0x38016000, 0x38018000, 0x3801a000, 0x3801c000, 0x3801e000, + 0x38020000, 0x38022000, 0x38024000, 0x38026000, 0x38028000, 0x3802a000, 0x3802c000, 0x3802e000, + 0x38030000, 0x38032000, 0x38034000, 0x38036000, 0x38038000, 0x3803a000, 0x3803c000, 0x3803e000, + 0x38040000, 0x38042000, 0x38044000, 0x38046000, 0x38048000, 0x3804a000, 0x3804c000, 0x3804e000, + 0x38050000, 0x38052000, 0x38054000, 0x38056000, 0x38058000, 0x3805a000, 0x3805c000, 0x3805e000, + 0x38060000, 0x38062000, 0x38064000, 0x38066000, 0x38068000, 0x3806a000, 0x3806c000, 0x3806e000, + 0x38070000, 0x38072000, 0x38074000, 0x38076000, 0x38078000, 0x3807a000, 0x3807c000, 0x3807e000, + 0x38080000, 0x38082000, 0x38084000, 0x38086000, 0x38088000, 0x3808a000, 0x3808c000, 0x3808e000, + 0x38090000, 0x38092000, 0x38094000, 0x38096000, 0x38098000, 0x3809a000, 0x3809c000, 0x3809e000, + 0x380a0000, 0x380a2000, 0x380a4000, 0x380a6000, 0x380a8000, 0x380aa000, 0x380ac000, 0x380ae000, + 0x380b0000, 0x380b2000, 0x380b4000, 0x380b6000, 0x380b8000, 0x380ba000, 0x380bc000, 0x380be000, + 0x380c0000, 0x380c2000, 0x380c4000, 0x380c6000, 0x380c8000, 0x380ca000, 0x380cc000, 0x380ce000, + 0x380d0000, 0x380d2000, 0x380d4000, 0x380d6000, 0x380d8000, 0x380da000, 0x380dc000, 0x380de000, + 0x380e0000, 0x380e2000, 0x380e4000, 0x380e6000, 0x380e8000, 0x380ea000, 0x380ec000, 0x380ee000, + 0x380f0000, 0x380f2000, 0x380f4000, 0x380f6000, 0x380f8000, 0x380fa000, 0x380fc000, 0x380fe000, + 0x38100000, 0x38102000, 0x38104000, 0x38106000, 0x38108000, 0x3810a000, 0x3810c000, 0x3810e000, + 0x38110000, 0x38112000, 0x38114000, 0x38116000, 0x38118000, 0x3811a000, 0x3811c000, 0x3811e000, + 0x38120000, 0x38122000, 0x38124000, 0x38126000, 0x38128000, 0x3812a000, 0x3812c000, 0x3812e000, + 0x38130000, 0x38132000, 0x38134000, 0x38136000, 0x38138000, 0x3813a000, 0x3813c000, 0x3813e000, + 0x38140000, 0x38142000, 0x38144000, 0x38146000, 0x38148000, 0x3814a000, 0x3814c000, 0x3814e000, + 0x38150000, 0x38152000, 0x38154000, 0x38156000, 0x38158000, 0x3815a000, 0x3815c000, 0x3815e000, + 0x38160000, 0x38162000, 0x38164000, 0x38166000, 0x38168000, 0x3816a000, 0x3816c000, 0x3816e000, + 0x38170000, 0x38172000, 0x38174000, 0x38176000, 0x38178000, 0x3817a000, 0x3817c000, 0x3817e000, + 0x38180000, 0x38182000, 0x38184000, 0x38186000, 0x38188000, 0x3818a000, 0x3818c000, 0x3818e000, + 0x38190000, 0x38192000, 0x38194000, 0x38196000, 0x38198000, 0x3819a000, 0x3819c000, 0x3819e000, + 0x381a0000, 0x381a2000, 0x381a4000, 0x381a6000, 0x381a8000, 0x381aa000, 0x381ac000, 0x381ae000, + 0x381b0000, 0x381b2000, 0x381b4000, 0x381b6000, 0x381b8000, 0x381ba000, 0x381bc000, 0x381be000, + 0x381c0000, 0x381c2000, 0x381c4000, 0x381c6000, 0x381c8000, 0x381ca000, 0x381cc000, 0x381ce000, + 0x381d0000, 0x381d2000, 0x381d4000, 0x381d6000, 0x381d8000, 0x381da000, 0x381dc000, 0x381de000, + 0x381e0000, 0x381e2000, 0x381e4000, 0x381e6000, 0x381e8000, 0x381ea000, 0x381ec000, 0x381ee000, + 0x381f0000, 0x381f2000, 0x381f4000, 0x381f6000, 0x381f8000, 0x381fa000, 0x381fc000, 0x381fe000, + 0x38200000, 0x38202000, 0x38204000, 0x38206000, 0x38208000, 0x3820a000, 0x3820c000, 0x3820e000, + 0x38210000, 0x38212000, 0x38214000, 0x38216000, 0x38218000, 0x3821a000, 0x3821c000, 0x3821e000, + 0x38220000, 0x38222000, 0x38224000, 0x38226000, 0x38228000, 0x3822a000, 0x3822c000, 0x3822e000, + 0x38230000, 0x38232000, 0x38234000, 0x38236000, 0x38238000, 0x3823a000, 0x3823c000, 0x3823e000, + 0x38240000, 0x38242000, 0x38244000, 0x38246000, 0x38248000, 0x3824a000, 0x3824c000, 0x3824e000, + 0x38250000, 0x38252000, 0x38254000, 0x38256000, 0x38258000, 0x3825a000, 0x3825c000, 0x3825e000, + 0x38260000, 0x38262000, 0x38264000, 0x38266000, 0x38268000, 0x3826a000, 0x3826c000, 0x3826e000, + 0x38270000, 0x38272000, 0x38274000, 0x38276000, 0x38278000, 0x3827a000, 0x3827c000, 0x3827e000, + 0x38280000, 0x38282000, 0x38284000, 0x38286000, 0x38288000, 0x3828a000, 0x3828c000, 0x3828e000, + 0x38290000, 0x38292000, 0x38294000, 0x38296000, 0x38298000, 0x3829a000, 0x3829c000, 0x3829e000, + 0x382a0000, 0x382a2000, 0x382a4000, 0x382a6000, 0x382a8000, 0x382aa000, 0x382ac000, 0x382ae000, + 0x382b0000, 0x382b2000, 0x382b4000, 0x382b6000, 0x382b8000, 0x382ba000, 0x382bc000, 0x382be000, + 0x382c0000, 0x382c2000, 0x382c4000, 0x382c6000, 0x382c8000, 0x382ca000, 0x382cc000, 0x382ce000, + 0x382d0000, 0x382d2000, 0x382d4000, 0x382d6000, 0x382d8000, 0x382da000, 0x382dc000, 0x382de000, + 0x382e0000, 0x382e2000, 0x382e4000, 0x382e6000, 0x382e8000, 0x382ea000, 0x382ec000, 0x382ee000, + 0x382f0000, 0x382f2000, 0x382f4000, 0x382f6000, 0x382f8000, 0x382fa000, 0x382fc000, 0x382fe000, + 0x38300000, 0x38302000, 0x38304000, 0x38306000, 0x38308000, 0x3830a000, 0x3830c000, 0x3830e000, + 0x38310000, 0x38312000, 0x38314000, 0x38316000, 0x38318000, 0x3831a000, 0x3831c000, 0x3831e000, + 0x38320000, 0x38322000, 0x38324000, 0x38326000, 0x38328000, 0x3832a000, 0x3832c000, 0x3832e000, + 0x38330000, 0x38332000, 0x38334000, 0x38336000, 0x38338000, 0x3833a000, 0x3833c000, 0x3833e000, + 0x38340000, 0x38342000, 0x38344000, 0x38346000, 0x38348000, 0x3834a000, 0x3834c000, 0x3834e000, + 0x38350000, 0x38352000, 0x38354000, 0x38356000, 0x38358000, 0x3835a000, 0x3835c000, 0x3835e000, + 0x38360000, 0x38362000, 0x38364000, 0x38366000, 0x38368000, 0x3836a000, 0x3836c000, 0x3836e000, + 0x38370000, 0x38372000, 0x38374000, 0x38376000, 0x38378000, 0x3837a000, 0x3837c000, 0x3837e000, + 0x38380000, 0x38382000, 0x38384000, 0x38386000, 0x38388000, 0x3838a000, 0x3838c000, 0x3838e000, + 0x38390000, 0x38392000, 0x38394000, 0x38396000, 0x38398000, 0x3839a000, 0x3839c000, 0x3839e000, + 0x383a0000, 0x383a2000, 0x383a4000, 0x383a6000, 0x383a8000, 0x383aa000, 0x383ac000, 0x383ae000, + 0x383b0000, 0x383b2000, 0x383b4000, 0x383b6000, 0x383b8000, 0x383ba000, 0x383bc000, 0x383be000, + 0x383c0000, 0x383c2000, 0x383c4000, 0x383c6000, 0x383c8000, 0x383ca000, 0x383cc000, 0x383ce000, + 0x383d0000, 0x383d2000, 0x383d4000, 0x383d6000, 0x383d8000, 0x383da000, 0x383dc000, 0x383de000, + 0x383e0000, 0x383e2000, 0x383e4000, 0x383e6000, 0x383e8000, 0x383ea000, 0x383ec000, 0x383ee000, + 0x383f0000, 0x383f2000, 0x383f4000, 0x383f6000, 0x383f8000, 0x383fa000, 0x383fc000, 0x383fe000, + 0x38400000, 0x38402000, 0x38404000, 0x38406000, 0x38408000, 0x3840a000, 0x3840c000, 0x3840e000, + 0x38410000, 0x38412000, 0x38414000, 0x38416000, 0x38418000, 0x3841a000, 0x3841c000, 0x3841e000, + 0x38420000, 0x38422000, 0x38424000, 0x38426000, 0x38428000, 0x3842a000, 0x3842c000, 0x3842e000, + 0x38430000, 0x38432000, 0x38434000, 0x38436000, 0x38438000, 0x3843a000, 0x3843c000, 0x3843e000, + 0x38440000, 0x38442000, 0x38444000, 0x38446000, 0x38448000, 0x3844a000, 0x3844c000, 0x3844e000, + 0x38450000, 0x38452000, 0x38454000, 0x38456000, 0x38458000, 0x3845a000, 0x3845c000, 0x3845e000, + 0x38460000, 0x38462000, 0x38464000, 0x38466000, 0x38468000, 0x3846a000, 0x3846c000, 0x3846e000, + 0x38470000, 0x38472000, 0x38474000, 0x38476000, 0x38478000, 0x3847a000, 0x3847c000, 0x3847e000, + 0x38480000, 0x38482000, 0x38484000, 0x38486000, 0x38488000, 0x3848a000, 0x3848c000, 0x3848e000, + 0x38490000, 0x38492000, 0x38494000, 0x38496000, 0x38498000, 0x3849a000, 0x3849c000, 0x3849e000, + 0x384a0000, 0x384a2000, 0x384a4000, 0x384a6000, 0x384a8000, 0x384aa000, 0x384ac000, 0x384ae000, + 0x384b0000, 0x384b2000, 0x384b4000, 0x384b6000, 0x384b8000, 0x384ba000, 0x384bc000, 0x384be000, + 0x384c0000, 0x384c2000, 0x384c4000, 0x384c6000, 0x384c8000, 0x384ca000, 0x384cc000, 0x384ce000, + 0x384d0000, 0x384d2000, 0x384d4000, 0x384d6000, 0x384d8000, 0x384da000, 0x384dc000, 0x384de000, + 0x384e0000, 0x384e2000, 0x384e4000, 0x384e6000, 0x384e8000, 0x384ea000, 0x384ec000, 0x384ee000, + 0x384f0000, 0x384f2000, 0x384f4000, 0x384f6000, 0x384f8000, 0x384fa000, 0x384fc000, 0x384fe000, + 0x38500000, 0x38502000, 0x38504000, 0x38506000, 0x38508000, 0x3850a000, 0x3850c000, 0x3850e000, + 0x38510000, 0x38512000, 0x38514000, 0x38516000, 0x38518000, 0x3851a000, 0x3851c000, 0x3851e000, + 0x38520000, 0x38522000, 0x38524000, 0x38526000, 0x38528000, 0x3852a000, 0x3852c000, 0x3852e000, + 0x38530000, 0x38532000, 0x38534000, 0x38536000, 0x38538000, 0x3853a000, 0x3853c000, 0x3853e000, + 0x38540000, 0x38542000, 0x38544000, 0x38546000, 0x38548000, 0x3854a000, 0x3854c000, 0x3854e000, + 0x38550000, 0x38552000, 0x38554000, 0x38556000, 0x38558000, 0x3855a000, 0x3855c000, 0x3855e000, + 0x38560000, 0x38562000, 0x38564000, 0x38566000, 0x38568000, 0x3856a000, 0x3856c000, 0x3856e000, + 0x38570000, 0x38572000, 0x38574000, 0x38576000, 0x38578000, 0x3857a000, 0x3857c000, 0x3857e000, + 0x38580000, 0x38582000, 0x38584000, 0x38586000, 0x38588000, 0x3858a000, 0x3858c000, 0x3858e000, + 0x38590000, 0x38592000, 0x38594000, 0x38596000, 0x38598000, 0x3859a000, 0x3859c000, 0x3859e000, + 0x385a0000, 0x385a2000, 0x385a4000, 0x385a6000, 0x385a8000, 0x385aa000, 0x385ac000, 0x385ae000, + 0x385b0000, 0x385b2000, 0x385b4000, 0x385b6000, 0x385b8000, 0x385ba000, 0x385bc000, 0x385be000, + 0x385c0000, 0x385c2000, 0x385c4000, 0x385c6000, 0x385c8000, 0x385ca000, 0x385cc000, 0x385ce000, + 0x385d0000, 0x385d2000, 0x385d4000, 0x385d6000, 0x385d8000, 0x385da000, 0x385dc000, 0x385de000, + 0x385e0000, 0x385e2000, 0x385e4000, 0x385e6000, 0x385e8000, 0x385ea000, 0x385ec000, 0x385ee000, + 0x385f0000, 0x385f2000, 0x385f4000, 0x385f6000, 0x385f8000, 0x385fa000, 0x385fc000, 0x385fe000, + 0x38600000, 0x38602000, 0x38604000, 0x38606000, 0x38608000, 0x3860a000, 0x3860c000, 0x3860e000, + 0x38610000, 0x38612000, 0x38614000, 0x38616000, 0x38618000, 0x3861a000, 0x3861c000, 0x3861e000, + 0x38620000, 0x38622000, 0x38624000, 0x38626000, 0x38628000, 0x3862a000, 0x3862c000, 0x3862e000, + 0x38630000, 0x38632000, 0x38634000, 0x38636000, 0x38638000, 0x3863a000, 0x3863c000, 0x3863e000, + 0x38640000, 0x38642000, 0x38644000, 0x38646000, 0x38648000, 0x3864a000, 0x3864c000, 0x3864e000, + 0x38650000, 0x38652000, 0x38654000, 0x38656000, 0x38658000, 0x3865a000, 0x3865c000, 0x3865e000, + 0x38660000, 0x38662000, 0x38664000, 0x38666000, 0x38668000, 0x3866a000, 0x3866c000, 0x3866e000, + 0x38670000, 0x38672000, 0x38674000, 0x38676000, 0x38678000, 0x3867a000, 0x3867c000, 0x3867e000, + 0x38680000, 0x38682000, 0x38684000, 0x38686000, 0x38688000, 0x3868a000, 0x3868c000, 0x3868e000, + 0x38690000, 0x38692000, 0x38694000, 0x38696000, 0x38698000, 0x3869a000, 0x3869c000, 0x3869e000, + 0x386a0000, 0x386a2000, 0x386a4000, 0x386a6000, 0x386a8000, 0x386aa000, 0x386ac000, 0x386ae000, + 0x386b0000, 0x386b2000, 0x386b4000, 0x386b6000, 0x386b8000, 0x386ba000, 0x386bc000, 0x386be000, + 0x386c0000, 0x386c2000, 0x386c4000, 0x386c6000, 0x386c8000, 0x386ca000, 0x386cc000, 0x386ce000, + 0x386d0000, 0x386d2000, 0x386d4000, 0x386d6000, 0x386d8000, 0x386da000, 0x386dc000, 0x386de000, + 0x386e0000, 0x386e2000, 0x386e4000, 0x386e6000, 0x386e8000, 0x386ea000, 0x386ec000, 0x386ee000, + 0x386f0000, 0x386f2000, 0x386f4000, 0x386f6000, 0x386f8000, 0x386fa000, 0x386fc000, 0x386fe000, + 0x38700000, 0x38702000, 0x38704000, 0x38706000, 0x38708000, 0x3870a000, 0x3870c000, 0x3870e000, + 0x38710000, 0x38712000, 0x38714000, 0x38716000, 0x38718000, 0x3871a000, 0x3871c000, 0x3871e000, + 0x38720000, 0x38722000, 0x38724000, 0x38726000, 0x38728000, 0x3872a000, 0x3872c000, 0x3872e000, + 0x38730000, 0x38732000, 0x38734000, 0x38736000, 0x38738000, 0x3873a000, 0x3873c000, 0x3873e000, + 0x38740000, 0x38742000, 0x38744000, 0x38746000, 0x38748000, 0x3874a000, 0x3874c000, 0x3874e000, + 0x38750000, 0x38752000, 0x38754000, 0x38756000, 0x38758000, 0x3875a000, 0x3875c000, 0x3875e000, + 0x38760000, 0x38762000, 0x38764000, 0x38766000, 0x38768000, 0x3876a000, 0x3876c000, 0x3876e000, + 0x38770000, 0x38772000, 0x38774000, 0x38776000, 0x38778000, 0x3877a000, 0x3877c000, 0x3877e000, + 0x38780000, 0x38782000, 0x38784000, 0x38786000, 0x38788000, 0x3878a000, 0x3878c000, 0x3878e000, + 0x38790000, 0x38792000, 0x38794000, 0x38796000, 0x38798000, 0x3879a000, 0x3879c000, 0x3879e000, + 0x387a0000, 0x387a2000, 0x387a4000, 0x387a6000, 0x387a8000, 0x387aa000, 0x387ac000, 0x387ae000, + 0x387b0000, 0x387b2000, 0x387b4000, 0x387b6000, 0x387b8000, 0x387ba000, 0x387bc000, 0x387be000, + 0x387c0000, 0x387c2000, 0x387c4000, 0x387c6000, 0x387c8000, 0x387ca000, 0x387cc000, 0x387ce000, + 0x387d0000, 0x387d2000, 0x387d4000, 0x387d6000, 0x387d8000, 0x387da000, 0x387dc000, 0x387de000, + 0x387e0000, 0x387e2000, 0x387e4000, 0x387e6000, 0x387e8000, 0x387ea000, 0x387ec000, 0x387ee000, + 0x387f0000, 0x387f2000, 0x387f4000, 0x387f6000, 0x387f8000, 0x387fa000, 0x387fc000, 0x387fe000, +}; + +const static unsigned g_exponent[64] = { + 0x00000000, 0x00800000, 0x01000000, 0x01800000, 0x02000000, 0x02800000, 0x03000000, 0x03800000, + 0x04000000, 0x04800000, 0x05000000, 0x05800000, 0x06000000, 0x06800000, 0x07000000, 0x07800000, + 0x08000000, 0x08800000, 0x09000000, 0x09800000, 0x0a000000, 0x0a800000, 0x0b000000, 0x0b800000, + 0x0c000000, 0x0c800000, 0x0d000000, 0x0d800000, 0x0e000000, 0x0e800000, 0x0f000000, 0x47800000, + 0x80000000, 0x80800000, 0x81000000, 0x81800000, 0x82000000, 0x82800000, 0x83000000, 0x83800000, + 0x84000000, 0x84800000, 0x85000000, 0x85800000, 0x86000000, 0x86800000, 0x87000000, 0x87800000, + 0x88000000, 0x88800000, 0x89000000, 0x89800000, 0x8a000000, 0x8a800000, 0x8b000000, 0x8b800000, + 0x8c000000, 0x8c800000, 0x8d000000, 0x8d800000, 0x8e000000, 0x8e800000, 0x8f000000, 0xc7800000, +}; + +const static unsigned g_offset[64] = { + 0x00000000, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, + 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, + 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, + 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, + 0x00000000, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, + 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, + 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, + 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, 0x00000400, +}; + +float float16ToFloat32(unsigned short h) +{ + unsigned i32 = g_mantissa[g_offset[h >> 10] + (h & 0x3ff)] + g_exponent[h >> 10]; + return bitCast(i32); +} +} // namespace gl diff --git a/gfx/angle/checkout/src/common/MemoryBuffer.cpp b/gfx/angle/checkout/src/common/MemoryBuffer.cpp new file mode 100644 index 0000000000..aadffe8bbe --- /dev/null +++ b/gfx/angle/checkout/src/common/MemoryBuffer.cpp @@ -0,0 +1,179 @@ +// +// Copyright 2014 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +#include "common/MemoryBuffer.h" + +#include +#include + +#include "common/debug.h" + +namespace angle +{ + +// MemoryBuffer implementation. +MemoryBuffer::~MemoryBuffer() +{ + if (mData) + { + free(mData); + mData = nullptr; + } +} + +bool MemoryBuffer::resize(size_t size) +{ + if (size == 0) + { + if (mData) + { + free(mData); + mData = nullptr; + } + mSize = 0; + return true; + } + + if (size == mSize) + { + return true; + } + + // Only reallocate if the size has changed. + uint8_t *newMemory = static_cast(malloc(sizeof(uint8_t) * size)); + if (newMemory == nullptr) + { + return false; + } + + if (mData) + { + // Copy the intersection of the old data and the new data + std::copy(mData, mData + std::min(mSize, size), newMemory); + free(mData); + } + + mData = newMemory; + mSize = size; + + return true; +} + +void MemoryBuffer::fill(uint8_t datum) +{ + if (!empty()) + { + std::fill(mData, mData + mSize, datum); + } +} + +MemoryBuffer::MemoryBuffer(MemoryBuffer &&other) : MemoryBuffer() +{ + *this = std::move(other); +} + +MemoryBuffer &MemoryBuffer::operator=(MemoryBuffer &&other) +{ + std::swap(mSize, other.mSize); + std::swap(mData, other.mData); + return *this; +} + +namespace +{ +static constexpr uint32_t kDefaultScratchBufferLifetime = 1000u; + +} // anonymous namespace + +// ScratchBuffer implementation. +ScratchBuffer::ScratchBuffer() : ScratchBuffer(kDefaultScratchBufferLifetime) {} + +ScratchBuffer::ScratchBuffer(uint32_t lifetime) : mLifetime(lifetime), mResetCounter(lifetime) {} + +ScratchBuffer::~ScratchBuffer() {} + +ScratchBuffer::ScratchBuffer(ScratchBuffer &&other) +{ + *this = std::move(other); +} + +ScratchBuffer &ScratchBuffer::operator=(ScratchBuffer &&other) +{ + std::swap(mLifetime, other.mLifetime); + std::swap(mResetCounter, other.mResetCounter); + std::swap(mScratchMemory, other.mScratchMemory); + return *this; +} + +bool ScratchBuffer::get(size_t requestedSize, MemoryBuffer **memoryBufferOut) +{ + return getImpl(requestedSize, memoryBufferOut, Optional::Invalid()); +} + +bool ScratchBuffer::getInitialized(size_t requestedSize, + MemoryBuffer **memoryBufferOut, + uint8_t initValue) +{ + return getImpl(requestedSize, memoryBufferOut, Optional(initValue)); +} + +bool ScratchBuffer::getImpl(size_t requestedSize, + MemoryBuffer **memoryBufferOut, + Optional initValue) +{ + if (mScratchMemory.size() == requestedSize) + { + mResetCounter = mLifetime; + *memoryBufferOut = &mScratchMemory; + return true; + } + + if (mScratchMemory.size() > requestedSize) + { + tick(); + } + + if (mScratchMemory.size() < requestedSize) + { + if (!mScratchMemory.resize(requestedSize)) + { + return false; + } + mResetCounter = mLifetime; + if (initValue.valid()) + { + mScratchMemory.fill(initValue.value()); + } + } + + ASSERT(mScratchMemory.size() >= requestedSize); + + *memoryBufferOut = &mScratchMemory; + return true; +} + +void ScratchBuffer::tick() +{ + if (mResetCounter > 0) + { + --mResetCounter; + if (mResetCounter == 0) + { + clear(); + } + } +} + +void ScratchBuffer::clear() +{ + mResetCounter = mLifetime; + if (mScratchMemory.size() > 0) + { + mScratchMemory.clear(); + } +} + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/MemoryBuffer.h b/gfx/angle/checkout/src/common/MemoryBuffer.h new file mode 100644 index 0000000000..bcd3aab7a9 --- /dev/null +++ b/gfx/angle/checkout/src/common/MemoryBuffer.h @@ -0,0 +1,93 @@ +// +// Copyright 2014 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +#ifndef COMMON_MEMORYBUFFER_H_ +#define COMMON_MEMORYBUFFER_H_ + +#include "common/Optional.h" +#include "common/angleutils.h" +#include "common/debug.h" + +#include +#include + +namespace angle +{ + +class MemoryBuffer final : NonCopyable +{ + public: + MemoryBuffer() = default; + ~MemoryBuffer(); + + MemoryBuffer(MemoryBuffer &&other); + MemoryBuffer &operator=(MemoryBuffer &&other); + + [[nodiscard]] bool resize(size_t size); + void clear() { (void)resize(0); } + size_t size() const { return mSize; } + bool empty() const { return mSize == 0; } + + const uint8_t *data() const { return mData; } + uint8_t *data() + { + ASSERT(mData); + return mData; + } + + uint8_t &operator[](size_t pos) + { + ASSERT(pos < mSize); + return mData[pos]; + } + const uint8_t &operator[](size_t pos) const + { + ASSERT(pos < mSize); + return mData[pos]; + } + + void fill(uint8_t datum); + + private: + size_t mSize = 0; + uint8_t *mData = nullptr; +}; + +class ScratchBuffer final : NonCopyable +{ + public: + // If we request a scratch buffer requesting a smaller size this many times, release and + // recreate the scratch buffer. This ensures we don't have a degenerate case where we are stuck + // hogging memory. + ScratchBuffer(); + ScratchBuffer(uint32_t lifetime); + ~ScratchBuffer(); + + ScratchBuffer(ScratchBuffer &&other); + ScratchBuffer &operator=(ScratchBuffer &&other); + + // Returns true with a memory buffer of the requested size, or false on failure. + bool get(size_t requestedSize, MemoryBuffer **memoryBufferOut); + + // Same as get, but ensures new values are initialized to a fixed constant. + bool getInitialized(size_t requestedSize, MemoryBuffer **memoryBufferOut, uint8_t initValue); + + // Ticks the release counter for the scratch buffer. Also done implicitly in get(). + void tick(); + + void clear(); + + private: + bool getImpl(size_t requestedSize, MemoryBuffer **memoryBufferOut, Optional initValue); + + uint32_t mLifetime; + uint32_t mResetCounter; + MemoryBuffer mScratchMemory; +}; + +} // namespace angle + +#endif // COMMON_MEMORYBUFFER_H_ diff --git a/gfx/angle/checkout/src/common/Optional.h b/gfx/angle/checkout/src/common/Optional.h new file mode 100644 index 0000000000..46c65dde4e --- /dev/null +++ b/gfx/angle/checkout/src/common/Optional.h @@ -0,0 +1,74 @@ +// +// Copyright 2015 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// Optional.h: +// Represents a type that may be invalid, similar to std::optional. +// + +#ifndef COMMON_OPTIONAL_H_ +#define COMMON_OPTIONAL_H_ + +#include + +template +struct Optional +{ + Optional() : mValid(false), mValue(T()) {} + + Optional(const T &valueIn) : mValid(true), mValue(valueIn) {} + + Optional(const Optional &other) : mValid(other.mValid), mValue(other.mValue) {} + + Optional &operator=(const Optional &other) + { + this->mValid = other.mValid; + this->mValue = other.mValue; + return *this; + } + + Optional &operator=(const T &value) + { + mValue = value; + mValid = true; + return *this; + } + + Optional &operator=(T &&value) + { + mValue = std::move(value); + mValid = true; + return *this; + } + + void reset() { mValid = false; } + T &&release() + { + mValid = false; + return std::move(mValue); + } + + static Optional Invalid() { return Optional(); } + + bool valid() const { return mValid; } + T &value() { return mValue; } + const T &value() const { return mValue; } + + bool operator==(const Optional &other) const + { + return ((mValid == other.mValid) && (!mValid || (mValue == other.mValue))); + } + + bool operator!=(const Optional &other) const { return !(*this == other); } + + bool operator==(const T &value) const { return mValid && (mValue == value); } + + bool operator!=(const T &value) const { return !(*this == value); } + + private: + bool mValid; + T mValue; +}; + +#endif // COMMON_OPTIONAL_H_ diff --git a/gfx/angle/checkout/src/common/PackedEGLEnums_autogen.cpp b/gfx/angle/checkout/src/common/PackedEGLEnums_autogen.cpp new file mode 100644 index 0000000000..738254bd18 --- /dev/null +++ b/gfx/angle/checkout/src/common/PackedEGLEnums_autogen.cpp @@ -0,0 +1,452 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by gen_packed_gl_enums.py using data from packed_egl_enums.json. +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// PackedEGLEnums_autogen.cpp: +// Implements ANGLE-specific enums classes for EGLenums and functions operating +// on them. + +#include "common/PackedEGLEnums_autogen.h" +#include "common/debug.h" + +namespace egl +{ + +template <> +ColorSpace FromEGLenum(EGLenum from) +{ + switch (from) + { + case EGL_COLORSPACE_sRGB: + return ColorSpace::sRGB; + case EGL_COLORSPACE_LINEAR: + return ColorSpace::Linear; + default: + return ColorSpace::InvalidEnum; + } +} + +EGLenum ToEGLenum(ColorSpace from) +{ + switch (from) + { + case ColorSpace::sRGB: + return EGL_COLORSPACE_sRGB; + case ColorSpace::Linear: + return EGL_COLORSPACE_LINEAR; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, ColorSpace value) +{ + switch (value) + { + case ColorSpace::sRGB: + os << "EGL_COLORSPACE_sRGB"; + break; + case ColorSpace::Linear: + os << "EGL_COLORSPACE_LINEAR"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +CompositorTiming FromEGLenum(EGLenum from) +{ + switch (from) + { + case EGL_COMPOSITE_DEADLINE_ANDROID: + return CompositorTiming::CompositeDeadline; + case EGL_COMPOSITE_INTERVAL_ANDROID: + return CompositorTiming::CompositInterval; + case EGL_COMPOSITE_TO_PRESENT_LATENCY_ANDROID: + return CompositorTiming::CompositToPresentLatency; + default: + return CompositorTiming::InvalidEnum; + } +} + +EGLenum ToEGLenum(CompositorTiming from) +{ + switch (from) + { + case CompositorTiming::CompositeDeadline: + return EGL_COMPOSITE_DEADLINE_ANDROID; + case CompositorTiming::CompositInterval: + return EGL_COMPOSITE_INTERVAL_ANDROID; + case CompositorTiming::CompositToPresentLatency: + return EGL_COMPOSITE_TO_PRESENT_LATENCY_ANDROID; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, CompositorTiming value) +{ + switch (value) + { + case CompositorTiming::CompositeDeadline: + os << "EGL_COMPOSITE_DEADLINE_ANDROID"; + break; + case CompositorTiming::CompositInterval: + os << "EGL_COMPOSITE_INTERVAL_ANDROID"; + break; + case CompositorTiming::CompositToPresentLatency: + os << "EGL_COMPOSITE_TO_PRESENT_LATENCY_ANDROID"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +ContextPriority FromEGLenum(EGLenum from) +{ + switch (from) + { + case EGL_CONTEXT_PRIORITY_LOW_IMG: + return ContextPriority::Low; + case EGL_CONTEXT_PRIORITY_MEDIUM_IMG: + return ContextPriority::Medium; + case EGL_CONTEXT_PRIORITY_HIGH_IMG: + return ContextPriority::High; + default: + return ContextPriority::InvalidEnum; + } +} + +EGLenum ToEGLenum(ContextPriority from) +{ + switch (from) + { + case ContextPriority::Low: + return EGL_CONTEXT_PRIORITY_LOW_IMG; + case ContextPriority::Medium: + return EGL_CONTEXT_PRIORITY_MEDIUM_IMG; + case ContextPriority::High: + return EGL_CONTEXT_PRIORITY_HIGH_IMG; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, ContextPriority value) +{ + switch (value) + { + case ContextPriority::Low: + os << "EGL_CONTEXT_PRIORITY_LOW_IMG"; + break; + case ContextPriority::Medium: + os << "EGL_CONTEXT_PRIORITY_MEDIUM_IMG"; + break; + case ContextPriority::High: + os << "EGL_CONTEXT_PRIORITY_HIGH_IMG"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +MessageType FromEGLenum(EGLenum from) +{ + switch (from) + { + case EGL_DEBUG_MSG_CRITICAL_KHR: + return MessageType::Critical; + case EGL_DEBUG_MSG_ERROR_KHR: + return MessageType::Error; + case EGL_DEBUG_MSG_WARN_KHR: + return MessageType::Warn; + case EGL_DEBUG_MSG_INFO_KHR: + return MessageType::Info; + default: + return MessageType::InvalidEnum; + } +} + +EGLenum ToEGLenum(MessageType from) +{ + switch (from) + { + case MessageType::Critical: + return EGL_DEBUG_MSG_CRITICAL_KHR; + case MessageType::Error: + return EGL_DEBUG_MSG_ERROR_KHR; + case MessageType::Warn: + return EGL_DEBUG_MSG_WARN_KHR; + case MessageType::Info: + return EGL_DEBUG_MSG_INFO_KHR; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, MessageType value) +{ + switch (value) + { + case MessageType::Critical: + os << "EGL_DEBUG_MSG_CRITICAL_KHR"; + break; + case MessageType::Error: + os << "EGL_DEBUG_MSG_ERROR_KHR"; + break; + case MessageType::Warn: + os << "EGL_DEBUG_MSG_WARN_KHR"; + break; + case MessageType::Info: + os << "EGL_DEBUG_MSG_INFO_KHR"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +ObjectType FromEGLenum(EGLenum from) +{ + switch (from) + { + case EGL_OBJECT_THREAD_KHR: + return ObjectType::Thread; + case EGL_OBJECT_DISPLAY_KHR: + return ObjectType::Display; + case EGL_OBJECT_CONTEXT_KHR: + return ObjectType::Context; + case EGL_OBJECT_SURFACE_KHR: + return ObjectType::Surface; + case EGL_OBJECT_IMAGE_KHR: + return ObjectType::Image; + case EGL_OBJECT_SYNC_KHR: + return ObjectType::Sync; + case EGL_OBJECT_STREAM_KHR: + return ObjectType::Stream; + default: + return ObjectType::InvalidEnum; + } +} + +EGLenum ToEGLenum(ObjectType from) +{ + switch (from) + { + case ObjectType::Thread: + return EGL_OBJECT_THREAD_KHR; + case ObjectType::Display: + return EGL_OBJECT_DISPLAY_KHR; + case ObjectType::Context: + return EGL_OBJECT_CONTEXT_KHR; + case ObjectType::Surface: + return EGL_OBJECT_SURFACE_KHR; + case ObjectType::Image: + return EGL_OBJECT_IMAGE_KHR; + case ObjectType::Sync: + return EGL_OBJECT_SYNC_KHR; + case ObjectType::Stream: + return EGL_OBJECT_STREAM_KHR; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, ObjectType value) +{ + switch (value) + { + case ObjectType::Thread: + os << "EGL_OBJECT_THREAD_KHR"; + break; + case ObjectType::Display: + os << "EGL_OBJECT_DISPLAY_KHR"; + break; + case ObjectType::Context: + os << "EGL_OBJECT_CONTEXT_KHR"; + break; + case ObjectType::Surface: + os << "EGL_OBJECT_SURFACE_KHR"; + break; + case ObjectType::Image: + os << "EGL_OBJECT_IMAGE_KHR"; + break; + case ObjectType::Sync: + os << "EGL_OBJECT_SYNC_KHR"; + break; + case ObjectType::Stream: + os << "EGL_OBJECT_STREAM_KHR"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +TextureFormat FromEGLenum(EGLenum from) +{ + switch (from) + { + case EGL_NO_TEXTURE: + return TextureFormat::NoTexture; + case EGL_TEXTURE_RGB: + return TextureFormat::RGB; + case EGL_TEXTURE_RGBA: + return TextureFormat::RGBA; + default: + return TextureFormat::InvalidEnum; + } +} + +EGLenum ToEGLenum(TextureFormat from) +{ + switch (from) + { + case TextureFormat::NoTexture: + return EGL_NO_TEXTURE; + case TextureFormat::RGB: + return EGL_TEXTURE_RGB; + case TextureFormat::RGBA: + return EGL_TEXTURE_RGBA; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, TextureFormat value) +{ + switch (value) + { + case TextureFormat::NoTexture: + os << "EGL_NO_TEXTURE"; + break; + case TextureFormat::RGB: + os << "EGL_TEXTURE_RGB"; + break; + case TextureFormat::RGBA: + os << "EGL_TEXTURE_RGBA"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +Timestamp FromEGLenum(EGLenum from) +{ + switch (from) + { + case EGL_REQUESTED_PRESENT_TIME_ANDROID: + return Timestamp::RequestedPresentTime; + case EGL_RENDERING_COMPLETE_TIME_ANDROID: + return Timestamp::RenderingCompleteTime; + case EGL_COMPOSITION_LATCH_TIME_ANDROID: + return Timestamp::CompositionLatchTime; + case EGL_FIRST_COMPOSITION_START_TIME_ANDROID: + return Timestamp::FirstCompositionStartTime; + case EGL_LAST_COMPOSITION_START_TIME_ANDROID: + return Timestamp::LastCompositionStartTime; + case EGL_FIRST_COMPOSITION_GPU_FINISHED_TIME_ANDROID: + return Timestamp::FirstCompositionGPUFinishedTime; + case EGL_DISPLAY_PRESENT_TIME_ANDROID: + return Timestamp::DisplayPresentTime; + case EGL_DEQUEUE_READY_TIME_ANDROID: + return Timestamp::DequeueReadyTime; + case EGL_READS_DONE_TIME_ANDROID: + return Timestamp::ReadsDoneTime; + default: + return Timestamp::InvalidEnum; + } +} + +EGLenum ToEGLenum(Timestamp from) +{ + switch (from) + { + case Timestamp::RequestedPresentTime: + return EGL_REQUESTED_PRESENT_TIME_ANDROID; + case Timestamp::RenderingCompleteTime: + return EGL_RENDERING_COMPLETE_TIME_ANDROID; + case Timestamp::CompositionLatchTime: + return EGL_COMPOSITION_LATCH_TIME_ANDROID; + case Timestamp::FirstCompositionStartTime: + return EGL_FIRST_COMPOSITION_START_TIME_ANDROID; + case Timestamp::LastCompositionStartTime: + return EGL_LAST_COMPOSITION_START_TIME_ANDROID; + case Timestamp::FirstCompositionGPUFinishedTime: + return EGL_FIRST_COMPOSITION_GPU_FINISHED_TIME_ANDROID; + case Timestamp::DisplayPresentTime: + return EGL_DISPLAY_PRESENT_TIME_ANDROID; + case Timestamp::DequeueReadyTime: + return EGL_DEQUEUE_READY_TIME_ANDROID; + case Timestamp::ReadsDoneTime: + return EGL_READS_DONE_TIME_ANDROID; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, Timestamp value) +{ + switch (value) + { + case Timestamp::RequestedPresentTime: + os << "EGL_REQUESTED_PRESENT_TIME_ANDROID"; + break; + case Timestamp::RenderingCompleteTime: + os << "EGL_RENDERING_COMPLETE_TIME_ANDROID"; + break; + case Timestamp::CompositionLatchTime: + os << "EGL_COMPOSITION_LATCH_TIME_ANDROID"; + break; + case Timestamp::FirstCompositionStartTime: + os << "EGL_FIRST_COMPOSITION_START_TIME_ANDROID"; + break; + case Timestamp::LastCompositionStartTime: + os << "EGL_LAST_COMPOSITION_START_TIME_ANDROID"; + break; + case Timestamp::FirstCompositionGPUFinishedTime: + os << "EGL_FIRST_COMPOSITION_GPU_FINISHED_TIME_ANDROID"; + break; + case Timestamp::DisplayPresentTime: + os << "EGL_DISPLAY_PRESENT_TIME_ANDROID"; + break; + case Timestamp::DequeueReadyTime: + os << "EGL_DEQUEUE_READY_TIME_ANDROID"; + break; + case Timestamp::ReadsDoneTime: + os << "EGL_READS_DONE_TIME_ANDROID"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +} // namespace egl diff --git a/gfx/angle/checkout/src/common/PackedEGLEnums_autogen.h b/gfx/angle/checkout/src/common/PackedEGLEnums_autogen.h new file mode 100644 index 0000000000..7794e8509e --- /dev/null +++ b/gfx/angle/checkout/src/common/PackedEGLEnums_autogen.h @@ -0,0 +1,144 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by gen_packed_gl_enums.py using data from packed_egl_enums.json. +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// PackedEGLEnums_autogen.h: +// Declares ANGLE-specific enums classes for EGLenums and functions operating +// on them. + +#ifndef COMMON_PACKEDEGLENUMS_AUTOGEN_H_ +#define COMMON_PACKEDEGLENUMS_AUTOGEN_H_ + +#include +#include + +#include +#include + +namespace egl +{ + +template +Enum FromEGLenum(EGLenum from); + +enum class ColorSpace : uint8_t +{ + sRGB = 0, + Linear = 1, + + InvalidEnum = 2, + EnumCount = 2, +}; + +template <> +ColorSpace FromEGLenum(EGLenum from); +EGLenum ToEGLenum(ColorSpace from); +std::ostream &operator<<(std::ostream &os, ColorSpace value); + +enum class CompositorTiming : uint8_t +{ + CompositeDeadline = 0, + CompositInterval = 1, + CompositToPresentLatency = 2, + + InvalidEnum = 3, + EnumCount = 3, +}; + +template <> +CompositorTiming FromEGLenum(EGLenum from); +EGLenum ToEGLenum(CompositorTiming from); +std::ostream &operator<<(std::ostream &os, CompositorTiming value); + +enum class ContextPriority : uint8_t +{ + Low = 0, + Medium = 1, + High = 2, + + InvalidEnum = 3, + EnumCount = 3, +}; + +template <> +ContextPriority FromEGLenum(EGLenum from); +EGLenum ToEGLenum(ContextPriority from); +std::ostream &operator<<(std::ostream &os, ContextPriority value); + +enum class MessageType : uint8_t +{ + Critical = 0, + Error = 1, + Warn = 2, + Info = 3, + + InvalidEnum = 4, + EnumCount = 4, +}; + +template <> +MessageType FromEGLenum(EGLenum from); +EGLenum ToEGLenum(MessageType from); +std::ostream &operator<<(std::ostream &os, MessageType value); + +enum class ObjectType : uint8_t +{ + Thread = 0, + Display = 1, + Context = 2, + Surface = 3, + Image = 4, + Sync = 5, + Stream = 6, + + InvalidEnum = 7, + EnumCount = 7, +}; + +template <> +ObjectType FromEGLenum(EGLenum from); +EGLenum ToEGLenum(ObjectType from); +std::ostream &operator<<(std::ostream &os, ObjectType value); + +enum class TextureFormat : uint8_t +{ + NoTexture = 0, + RGB = 1, + RGBA = 2, + + InvalidEnum = 3, + EnumCount = 3, +}; + +template <> +TextureFormat FromEGLenum(EGLenum from); +EGLenum ToEGLenum(TextureFormat from); +std::ostream &operator<<(std::ostream &os, TextureFormat value); + +enum class Timestamp : uint8_t +{ + RequestedPresentTime = 0, + RenderingCompleteTime = 1, + CompositionLatchTime = 2, + FirstCompositionStartTime = 3, + LastCompositionStartTime = 4, + FirstCompositionGPUFinishedTime = 5, + DisplayPresentTime = 6, + DequeueReadyTime = 7, + ReadsDoneTime = 8, + + InvalidEnum = 9, + EnumCount = 9, +}; + +template <> +Timestamp FromEGLenum(EGLenum from); +EGLenum ToEGLenum(Timestamp from); +std::ostream &operator<<(std::ostream &os, Timestamp value); + +} // namespace egl + +#endif // COMMON_PACKEDEGLENUMS_AUTOGEN_H_ diff --git a/gfx/angle/checkout/src/common/PackedEnums.cpp b/gfx/angle/checkout/src/common/PackedEnums.cpp new file mode 100644 index 0000000000..e13a502a42 --- /dev/null +++ b/gfx/angle/checkout/src/common/PackedEnums.cpp @@ -0,0 +1,673 @@ +// Copyright 2018 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// PackedGLEnums.cpp: +// Declares ANGLE-specific enums classes for GLEnum and functions operating +// on them. + +#include "common/PackedEnums.h" + +#include "common/utilities.h" + +namespace gl +{ + +TextureType TextureTargetToType(TextureTarget target) +{ + switch (target) + { + case TextureTarget::CubeMapNegativeX: + case TextureTarget::CubeMapNegativeY: + case TextureTarget::CubeMapNegativeZ: + case TextureTarget::CubeMapPositiveX: + case TextureTarget::CubeMapPositiveY: + case TextureTarget::CubeMapPositiveZ: + return TextureType::CubeMap; + case TextureTarget::CubeMapArray: + return TextureType::CubeMapArray; + case TextureTarget::External: + return TextureType::External; + case TextureTarget::Rectangle: + return TextureType::Rectangle; + case TextureTarget::_2D: + return TextureType::_2D; + case TextureTarget::_2DArray: + return TextureType::_2DArray; + case TextureTarget::_2DMultisample: + return TextureType::_2DMultisample; + case TextureTarget::_2DMultisampleArray: + return TextureType::_2DMultisampleArray; + case TextureTarget::_3D: + return TextureType::_3D; + case TextureTarget::VideoImage: + return TextureType::VideoImage; + case TextureTarget::Buffer: + return TextureType::Buffer; + case TextureTarget::InvalidEnum: + return TextureType::InvalidEnum; + default: + UNREACHABLE(); + return TextureType::InvalidEnum; + } +} + +bool IsCubeMapFaceTarget(TextureTarget target) +{ + return TextureTargetToType(target) == TextureType::CubeMap; +} + +TextureTarget NonCubeTextureTypeToTarget(TextureType type) +{ + switch (type) + { + case TextureType::External: + return TextureTarget::External; + case TextureType::Rectangle: + return TextureTarget::Rectangle; + case TextureType::_2D: + return TextureTarget::_2D; + case TextureType::_2DArray: + return TextureTarget::_2DArray; + case TextureType::_2DMultisample: + return TextureTarget::_2DMultisample; + case TextureType::_2DMultisampleArray: + return TextureTarget::_2DMultisampleArray; + case TextureType::_3D: + return TextureTarget::_3D; + case TextureType::CubeMapArray: + return TextureTarget::CubeMapArray; + case TextureType::VideoImage: + return TextureTarget::VideoImage; + case TextureType::Buffer: + return TextureTarget::Buffer; + default: + UNREACHABLE(); + return TextureTarget::InvalidEnum; + } +} + +// Check that we can do arithmetic on TextureTarget to convert from / to cube map faces +static_assert(static_cast(TextureTarget::CubeMapNegativeX) - + static_cast(TextureTarget::CubeMapPositiveX) == + 1u, + ""); +static_assert(static_cast(TextureTarget::CubeMapPositiveY) - + static_cast(TextureTarget::CubeMapPositiveX) == + 2u, + ""); +static_assert(static_cast(TextureTarget::CubeMapNegativeY) - + static_cast(TextureTarget::CubeMapPositiveX) == + 3u, + ""); +static_assert(static_cast(TextureTarget::CubeMapPositiveZ) - + static_cast(TextureTarget::CubeMapPositiveX) == + 4u, + ""); +static_assert(static_cast(TextureTarget::CubeMapNegativeZ) - + static_cast(TextureTarget::CubeMapPositiveX) == + 5u, + ""); + +TextureTarget CubeFaceIndexToTextureTarget(size_t face) +{ + ASSERT(face < 6u); + return static_cast(static_cast(TextureTarget::CubeMapPositiveX) + face); +} + +size_t CubeMapTextureTargetToFaceIndex(TextureTarget target) +{ + ASSERT(IsCubeMapFaceTarget(target)); + return static_cast(target) - static_cast(TextureTarget::CubeMapPositiveX); +} + +TextureType SamplerTypeToTextureType(GLenum samplerType) +{ + switch (samplerType) + { + case GL_SAMPLER_2D: + case GL_INT_SAMPLER_2D: + case GL_UNSIGNED_INT_SAMPLER_2D: + case GL_SAMPLER_2D_SHADOW: + return TextureType::_2D; + + case GL_SAMPLER_EXTERNAL_OES: + case GL_SAMPLER_EXTERNAL_2D_Y2Y_EXT: + return TextureType::External; + + case GL_SAMPLER_CUBE: + case GL_INT_SAMPLER_CUBE: + case GL_UNSIGNED_INT_SAMPLER_CUBE: + case GL_SAMPLER_CUBE_SHADOW: + return TextureType::CubeMap; + + case GL_SAMPLER_CUBE_MAP_ARRAY: + case GL_INT_SAMPLER_CUBE_MAP_ARRAY: + case GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY: + case GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW: + return TextureType::CubeMapArray; + + case GL_SAMPLER_2D_ARRAY: + case GL_INT_SAMPLER_2D_ARRAY: + case GL_UNSIGNED_INT_SAMPLER_2D_ARRAY: + case GL_SAMPLER_2D_ARRAY_SHADOW: + return TextureType::_2DArray; + + case GL_SAMPLER_3D: + case GL_INT_SAMPLER_3D: + case GL_UNSIGNED_INT_SAMPLER_3D: + return TextureType::_3D; + + case GL_SAMPLER_2D_MULTISAMPLE: + case GL_INT_SAMPLER_2D_MULTISAMPLE: + case GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE: + return TextureType::_2DMultisample; + + case GL_SAMPLER_2D_MULTISAMPLE_ARRAY: + case GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY: + case GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY: + return TextureType::_2DMultisampleArray; + + case GL_SAMPLER_BUFFER: + case GL_INT_SAMPLER_BUFFER: + case GL_UNSIGNED_INT_SAMPLER_BUFFER: + return TextureType::Buffer; + + case GL_SAMPLER_2D_RECT_ANGLE: + return TextureType::Rectangle; + + case GL_SAMPLER_VIDEO_IMAGE_WEBGL: + return TextureType::VideoImage; + + default: + UNREACHABLE(); + return TextureType::InvalidEnum; + } +} + +TextureType ImageTypeToTextureType(GLenum imageType) +{ + switch (imageType) + { + case GL_IMAGE_2D: + case GL_INT_IMAGE_2D: + case GL_UNSIGNED_INT_IMAGE_2D: + return TextureType::_2D; + + case GL_IMAGE_CUBE: + case GL_INT_IMAGE_CUBE: + case GL_UNSIGNED_INT_IMAGE_CUBE: + return TextureType::CubeMap; + + case GL_IMAGE_CUBE_MAP_ARRAY: + case GL_INT_IMAGE_CUBE_MAP_ARRAY: + case GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY: + return TextureType::CubeMapArray; + + case GL_IMAGE_2D_ARRAY: + case GL_INT_IMAGE_2D_ARRAY: + case GL_UNSIGNED_INT_IMAGE_2D_ARRAY: + return TextureType::_2DArray; + + case GL_IMAGE_3D: + case GL_INT_IMAGE_3D: + case GL_UNSIGNED_INT_IMAGE_3D: + return TextureType::_3D; + + case GL_IMAGE_BUFFER: + case GL_INT_IMAGE_BUFFER: + case GL_UNSIGNED_INT_IMAGE_BUFFER: + return TextureType::Buffer; + + default: + UNREACHABLE(); + return TextureType::InvalidEnum; + } +} + +bool IsMultisampled(TextureType type) +{ + switch (type) + { + case TextureType::_2DMultisample: + case TextureType::_2DMultisampleArray: + return true; + default: + return false; + } +} + +bool IsArrayTextureType(TextureType type) +{ + switch (type) + { + case TextureType::_2DArray: + case TextureType::_2DMultisampleArray: + case TextureType::CubeMapArray: + return true; + default: + return false; + } +} + +bool IsStaticBufferUsage(BufferUsage useage) +{ + switch (useage) + { + case BufferUsage::StaticCopy: + case BufferUsage::StaticDraw: + case BufferUsage::StaticRead: + return true; + default: + return false; + } +} + +std::ostream &operator<<(std::ostream &os, PrimitiveMode value) +{ + switch (value) + { + case PrimitiveMode::LineLoop: + os << "GL_LINE_LOOP"; + break; + case PrimitiveMode::Lines: + os << "GL_LINES"; + break; + case PrimitiveMode::LinesAdjacency: + os << "GL_LINES_ADJACENCY"; + break; + case PrimitiveMode::LineStrip: + os << "GL_LINE_STRIP"; + break; + case PrimitiveMode::LineStripAdjacency: + os << "GL_LINE_STRIP_ADJANCENCY"; + break; + case PrimitiveMode::Patches: + os << "GL_PATCHES"; + break; + case PrimitiveMode::Points: + os << "GL_POINTS"; + break; + case PrimitiveMode::TriangleFan: + os << "GL_TRIANGLE_FAN"; + break; + case PrimitiveMode::Triangles: + os << "GL_TRIANGLES"; + break; + case PrimitiveMode::TrianglesAdjacency: + os << "GL_TRIANGLES_ADJANCENCY"; + break; + case PrimitiveMode::TriangleStrip: + os << "GL_TRIANGLE_STRIP"; + break; + case PrimitiveMode::TriangleStripAdjacency: + os << "GL_TRIANGLE_STRIP_ADJACENCY"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +std::ostream &operator<<(std::ostream &os, DrawElementsType value) +{ + switch (value) + { + case DrawElementsType::UnsignedByte: + os << "GL_UNSIGNED_BYTE"; + break; + case DrawElementsType::UnsignedShort: + os << "GL_UNSIGNED_SHORT"; + break; + case DrawElementsType::UnsignedInt: + os << "GL_UNSIGNED_INT"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + + return os; +} + +std::ostream &operator<<(std::ostream &os, BlendEquationType value) +{ + switch (value) + { + case BlendEquationType::Add: + os << "GL_FUNC_ADD"; + break; + case BlendEquationType::Min: + os << "GL_MIN"; + break; + case BlendEquationType::Max: + os << "GL_MAX"; + break; + case BlendEquationType::Subtract: + os << "GL_FUNC_SUBTRACT"; + break; + case BlendEquationType::ReverseSubtract: + os << "GL_FUNC_REVERSE_SUBTRACT"; + break; + case BlendEquationType::Multiply: + os << "GL_MULTIPLY_KHR"; + break; + case BlendEquationType::Screen: + os << "GL_SCREEN_KHR"; + break; + case BlendEquationType::Overlay: + os << "GL_OVERLAY_KHR"; + break; + case BlendEquationType::Darken: + os << "GL_DARKEN_KHR"; + break; + case BlendEquationType::Lighten: + os << "GL_LIGHTEN_KHR"; + break; + case BlendEquationType::Colordodge: + os << "GL_COLORDODGE_KHR"; + break; + case BlendEquationType::Colorburn: + os << "GL_COLORBURN_KHR"; + break; + case BlendEquationType::Hardlight: + os << "GL_HARDLIGHT_KHR"; + break; + case BlendEquationType::Softlight: + os << "GL_SOFTLIGHT_KHR"; + break; + case BlendEquationType::Difference: + os << "GL_DIFFERENCE_KHR"; + break; + case BlendEquationType::Exclusion: + os << "GL_EXCLUSION_KHR"; + break; + case BlendEquationType::HslHue: + os << "GL_HSL_HUE_KHR"; + break; + case BlendEquationType::HslSaturation: + os << "GL_HSL_SATURATION_KHR"; + break; + case BlendEquationType::HslColor: + os << "GL_HSL_COLOR_KHR"; + break; + case BlendEquationType::HslLuminosity: + os << "GL_HSL_LUMINOSITY_KHR"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + + return os; +} + +std::ostream &operator<<(std::ostream &os, BlendFactorType value) +{ + switch (value) + { + case BlendFactorType::Zero: + os << "GL_ZERO"; + break; + case BlendFactorType::One: + os << "GL_ONE"; + break; + case BlendFactorType::SrcColor: + os << "GL_SRC_COLOR"; + break; + case BlendFactorType::OneMinusSrcColor: + os << "GL_ONE_MINUS_SRC_COLOR"; + break; + case BlendFactorType::SrcAlpha: + os << "GL_SRC_ALPHA"; + break; + case BlendFactorType::OneMinusSrcAlpha: + os << "GL_ONE_MINUS_SRC_ALPHA"; + break; + case BlendFactorType::DstAlpha: + os << "GL_DST_ALPHA"; + break; + case BlendFactorType::OneMinusDstAlpha: + os << "GL_ONE_MINUS_DST_ALPHA"; + break; + case BlendFactorType::DstColor: + os << "GL_DST_COLOR"; + break; + case BlendFactorType::OneMinusDstColor: + os << "GL_ONE_MINUS_DST_COLOR"; + break; + case BlendFactorType::SrcAlphaSaturate: + os << "GL_SRC_ALPHA_SATURATE"; + break; + case BlendFactorType::ConstantColor: + os << "GL_CONSTANT_COLOR"; + break; + case BlendFactorType::OneMinusConstantColor: + os << "GL_ONE_MINUS_CONSTANT_COLOR"; + break; + case BlendFactorType::ConstantAlpha: + os << "GL_CONSTANT_ALPHA"; + break; + case BlendFactorType::OneMinusConstantAlpha: + os << "GL_ONE_MINUS_CONSTANT_ALPHA"; + break; + case BlendFactorType::Src1Alpha: + os << "GL_SRC1_ALPHA_EXT"; + break; + case BlendFactorType::Src1Color: + os << "GL_SRC1_COLOR_EXT"; + break; + case BlendFactorType::OneMinusSrc1Color: + os << "GL_ONE_MINUS_SRC1_COLOR_EXT"; + break; + case BlendFactorType::OneMinusSrc1Alpha: + os << "GL_ONE_MINUS_SRC1_ALPHA_EXT"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + + return os; +} + +std::ostream &operator<<(std::ostream &os, VertexAttribType value) +{ + switch (value) + { + case VertexAttribType::Byte: + os << "GL_BYTE"; + break; + case VertexAttribType::Fixed: + os << "GL_FIXED"; + break; + case VertexAttribType::Float: + os << "GL_FLOAT"; + break; + case VertexAttribType::HalfFloat: + os << "GL_HALF_FLOAT"; + break; + case VertexAttribType::HalfFloatOES: + os << "GL_HALF_FLOAT_OES"; + break; + case VertexAttribType::Int: + os << "GL_INT"; + break; + case VertexAttribType::Int2101010: + os << "GL_INT_2_10_10_10_REV"; + break; + case VertexAttribType::Int1010102: + os << "GL_INT_10_10_10_2_OES"; + break; + case VertexAttribType::Short: + os << "GL_SHORT"; + break; + case VertexAttribType::UnsignedByte: + os << "GL_UNSIGNED_BYTE"; + break; + case VertexAttribType::UnsignedInt: + os << "GL_UNSIGNED_INT"; + break; + case VertexAttribType::UnsignedInt2101010: + os << "GL_UNSIGNED_INT_2_10_10_10_REV"; + break; + case VertexAttribType::UnsignedInt1010102: + os << "GL_UNSIGNED_INT_10_10_10_2_OES"; + break; + case VertexAttribType::UnsignedShort: + os << "GL_UNSIGNED_SHORT"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +std::ostream &operator<<(std::ostream &os, TessEvaluationType value) +{ + switch (value) + { + case TessEvaluationType::Triangles: + os << "GL_TRIANGLES"; + break; + case TessEvaluationType::Quads: + os << "GL_QUADS"; + break; + case TessEvaluationType::Isolines: + os << "GL_ISOLINES"; + break; + case TessEvaluationType::EqualSpacing: + os << "GL_EQUAL"; + break; + case TessEvaluationType::FractionalEvenSpacing: + os << "GL_FRACTIONAL_EVEN"; + break; + case TessEvaluationType::FractionalOddSpacing: + os << "GL_FRACTIONAL_ODD"; + break; + case TessEvaluationType::Cw: + os << "GL_CW"; + break; + case TessEvaluationType::Ccw: + os << "GL_CCW"; + break; + case TessEvaluationType::PointMode: + os << "GL_TESS_GEN_POINT_MODE"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +const char *ShaderTypeToString(ShaderType shaderType) +{ + constexpr ShaderMap kShaderTypeNameMap = { + {ShaderType::Vertex, "Vertex"}, + {ShaderType::TessControl, "Tessellation control"}, + {ShaderType::TessEvaluation, "Tessellation evaluation"}, + {ShaderType::Geometry, "Geometry"}, + {ShaderType::Fragment, "Fragment"}, + {ShaderType::Compute, "Compute"}}; + return kShaderTypeNameMap[shaderType]; +} + +bool operator<(const UniformLocation &lhs, const UniformLocation &rhs) +{ + return lhs.value < rhs.value; +} + +bool IsEmulatedCompressedFormat(GLenum format) +{ + // TODO(anglebug.com/6177): Check for all formats ANGLE will use to emulate a compressed texture + return format == GL_RGBA || format == GL_RG || format == GL_RED; +} +} // namespace gl + +namespace egl +{ +MessageType ErrorCodeToMessageType(EGLint errorCode) +{ + switch (errorCode) + { + case EGL_BAD_ALLOC: + case EGL_CONTEXT_LOST: + case EGL_NOT_INITIALIZED: + return MessageType::Critical; + + case EGL_BAD_ACCESS: + case EGL_BAD_ATTRIBUTE: + case EGL_BAD_CONFIG: + case EGL_BAD_CONTEXT: + case EGL_BAD_CURRENT_SURFACE: + case EGL_BAD_DISPLAY: + case EGL_BAD_MATCH: + case EGL_BAD_NATIVE_PIXMAP: + case EGL_BAD_NATIVE_WINDOW: + case EGL_BAD_PARAMETER: + case EGL_BAD_SURFACE: + case EGL_BAD_STREAM_KHR: + case EGL_BAD_STATE_KHR: + case EGL_BAD_DEVICE_EXT: + return MessageType::Error; + + case EGL_SUCCESS: + default: + UNREACHABLE(); + return MessageType::InvalidEnum; + } +} +} // namespace egl + +namespace egl_gl +{ + +gl::TextureTarget EGLCubeMapTargetToCubeMapTarget(EGLenum eglTarget) +{ + ASSERT(egl::IsCubeMapTextureTarget(eglTarget)); + return gl::CubeFaceIndexToTextureTarget(egl::CubeMapTextureTargetToLayerIndex(eglTarget)); +} + +gl::TextureTarget EGLImageTargetToTextureTarget(EGLenum eglTarget) +{ + switch (eglTarget) + { + case EGL_GL_TEXTURE_2D_KHR: + return gl::TextureTarget::_2D; + + case EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_X_KHR: + case EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_X_KHR: + case EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Y_KHR: + case EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_KHR: + case EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Z_KHR: + case EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_KHR: + return EGLCubeMapTargetToCubeMapTarget(eglTarget); + + case EGL_GL_TEXTURE_3D_KHR: + return gl::TextureTarget::_3D; + + default: + UNREACHABLE(); + return gl::TextureTarget::InvalidEnum; + } +} + +gl::TextureType EGLTextureTargetToTextureType(EGLenum eglTarget) +{ + switch (eglTarget) + { + case EGL_TEXTURE_2D: + return gl::TextureType::_2D; + + case EGL_TEXTURE_RECTANGLE_ANGLE: + return gl::TextureType::Rectangle; + + default: + UNREACHABLE(); + return gl::TextureType::InvalidEnum; + } +} +} // namespace egl_gl diff --git a/gfx/angle/checkout/src/common/PackedEnums.h b/gfx/angle/checkout/src/common/PackedEnums.h new file mode 100644 index 0000000000..81fa6d6f42 --- /dev/null +++ b/gfx/angle/checkout/src/common/PackedEnums.h @@ -0,0 +1,859 @@ +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// PackedGLEnums_autogen.h: +// Declares ANGLE-specific enums classes for GLEnum and functions operating +// on them. + +#ifndef COMMON_PACKEDGLENUMS_H_ +#define COMMON_PACKEDGLENUMS_H_ + +#include "common/PackedEGLEnums_autogen.h" +#include "common/PackedGLEnums_autogen.h" + +#include +#include +#include + +#include + +#include "common/bitset_utils.h" + +namespace angle +{ + +// Return the number of elements of a packed enum, including the InvalidEnum element. +template +constexpr size_t EnumSize() +{ + using UnderlyingType = typename std::underlying_type::type; + return static_cast(E::EnumCount); +} + +// Implementation of AllEnums which allows iterating over all the possible values for a packed enums +// like so: +// for (auto value : AllEnums()) { +// // Do something with the enum. +// } + +template +class EnumIterator final +{ + private: + using UnderlyingType = typename std::underlying_type::type; + + public: + EnumIterator(E value) : mValue(static_cast(value)) {} + EnumIterator &operator++() + { + mValue++; + return *this; + } + bool operator==(const EnumIterator &other) const { return mValue == other.mValue; } + bool operator!=(const EnumIterator &other) const { return mValue != other.mValue; } + E operator*() const { return static_cast(mValue); } + + private: + UnderlyingType mValue; +}; + +template ()> +struct AllEnums +{ + EnumIterator begin() const { return {static_cast(0)}; } + EnumIterator end() const { return {static_cast(MaxSize)}; } +}; + +// PackedEnumMap is like an std::array but is indexed with enum values. It +// implements all of the std::array interface except with enum values instead of indices. +template ()> +class PackedEnumMap +{ + using UnderlyingType = typename std::underlying_type::type; + using Storage = std::array; + + public: + using InitPair = std::pair; + + constexpr PackedEnumMap() = default; + + constexpr PackedEnumMap(std::initializer_list init) : mPrivateData{} + { + // We use a for loop instead of range-for to work around a limitation in MSVC. + for (const InitPair *it = init.begin(); it != init.end(); ++it) + { + mPrivateData[static_cast(it->first)] = it->second; + } + } + + // types: + using value_type = T; + using pointer = T *; + using const_pointer = const T *; + using reference = T &; + using const_reference = const T &; + + using size_type = size_t; + using difference_type = ptrdiff_t; + + using iterator = typename Storage::iterator; + using const_iterator = typename Storage::const_iterator; + using reverse_iterator = std::reverse_iterator; + using const_reverse_iterator = std::reverse_iterator; + + // No explicit construct/copy/destroy for aggregate type + void fill(const T &u) { mPrivateData.fill(u); } + void swap(PackedEnumMap &a) noexcept { mPrivateData.swap(a.mPrivateData); } + + // iterators: + iterator begin() noexcept { return mPrivateData.begin(); } + const_iterator begin() const noexcept { return mPrivateData.begin(); } + iterator end() noexcept { return mPrivateData.end(); } + const_iterator end() const noexcept { return mPrivateData.end(); } + + reverse_iterator rbegin() noexcept { return mPrivateData.rbegin(); } + const_reverse_iterator rbegin() const noexcept { return mPrivateData.rbegin(); } + reverse_iterator rend() noexcept { return mPrivateData.rend(); } + const_reverse_iterator rend() const noexcept { return mPrivateData.rend(); } + + // capacity: + constexpr size_type size() const noexcept { return mPrivateData.size(); } + constexpr size_type max_size() const noexcept { return mPrivateData.max_size(); } + constexpr bool empty() const noexcept { return mPrivateData.empty(); } + + // element access: + reference operator[](E n) + { + ASSERT(static_cast(n) < mPrivateData.size()); + return mPrivateData[static_cast(n)]; + } + + constexpr const_reference operator[](E n) const + { + ASSERT(static_cast(n) < mPrivateData.size()); + return mPrivateData[static_cast(n)]; + } + + const_reference at(E n) const { return mPrivateData.at(static_cast(n)); } + reference at(E n) { return mPrivateData.at(static_cast(n)); } + + reference front() { return mPrivateData.front(); } + const_reference front() const { return mPrivateData.front(); } + reference back() { return mPrivateData.back(); } + const_reference back() const { return mPrivateData.back(); } + + T *data() noexcept { return mPrivateData.data(); } + const T *data() const noexcept { return mPrivateData.data(); } + + bool operator==(const PackedEnumMap &rhs) const { return mPrivateData == rhs.mPrivateData; } + bool operator!=(const PackedEnumMap &rhs) const { return mPrivateData != rhs.mPrivateData; } + + template + typename std::enable_if::value>::type operator+=( + const PackedEnumMap &rhs) + { + for (E e : AllEnums()) + { + at(e) += rhs[e]; + } + } + + private: + Storage mPrivateData; +}; + +// PackedEnumBitSetE> is like an std::bitset but is indexed with enum values. It +// implements the std::bitset interface except with enum values instead of indices. +template +using PackedEnumBitSet = BitSetT(), DataT, E>; + +} // namespace angle + +namespace gl +{ + +TextureType TextureTargetToType(TextureTarget target); +TextureTarget NonCubeTextureTypeToTarget(TextureType type); + +TextureTarget CubeFaceIndexToTextureTarget(size_t face); +size_t CubeMapTextureTargetToFaceIndex(TextureTarget target); +bool IsCubeMapFaceTarget(TextureTarget target); + +constexpr TextureTarget kCubeMapTextureTargetMin = TextureTarget::CubeMapPositiveX; +constexpr TextureTarget kCubeMapTextureTargetMax = TextureTarget::CubeMapNegativeZ; +constexpr TextureTarget kAfterCubeMapTextureTargetMax = + static_cast(static_cast(kCubeMapTextureTargetMax) + 1); +struct AllCubeFaceTextureTargets +{ + angle::EnumIterator begin() const { return kCubeMapTextureTargetMin; } + angle::EnumIterator end() const { return kAfterCubeMapTextureTargetMax; } +}; + +constexpr std::array kAllGLES2ShaderTypes = {ShaderType::Vertex, + ShaderType::Fragment}; + +constexpr ShaderType kShaderTypeMin = ShaderType::Vertex; +constexpr ShaderType kShaderTypeMax = ShaderType::Compute; +constexpr ShaderType kAfterShaderTypeMax = + static_cast(static_cast(kShaderTypeMax) + 1); +struct AllShaderTypes +{ + angle::EnumIterator begin() const { return kShaderTypeMin; } + angle::EnumIterator end() const { return kAfterShaderTypeMax; } +}; + +constexpr size_t kGraphicsShaderCount = static_cast(ShaderType::EnumCount) - 1u; +// Arrange the shader types in the order of rendering pipeline +constexpr std::array kAllGraphicsShaderTypes = { + ShaderType::Vertex, ShaderType::TessControl, ShaderType::TessEvaluation, ShaderType::Geometry, + ShaderType::Fragment}; + +using ShaderBitSet = angle::PackedEnumBitSet; +static_assert(sizeof(ShaderBitSet) == sizeof(uint8_t), "Unexpected size"); + +template +using ShaderMap = angle::PackedEnumMap; + +const char *ShaderTypeToString(ShaderType shaderType); + +TextureType SamplerTypeToTextureType(GLenum samplerType); +TextureType ImageTypeToTextureType(GLenum imageType); + +bool IsMultisampled(gl::TextureType type); +bool IsArrayTextureType(gl::TextureType type); + +bool IsStaticBufferUsage(BufferUsage useage); + +enum class PrimitiveMode : uint8_t +{ + Points = 0x0, + Lines = 0x1, + LineLoop = 0x2, + LineStrip = 0x3, + Triangles = 0x4, + TriangleStrip = 0x5, + TriangleFan = 0x6, + Unused1 = 0x7, + Unused2 = 0x8, + Unused3 = 0x9, + LinesAdjacency = 0xA, + LineStripAdjacency = 0xB, + TrianglesAdjacency = 0xC, + TriangleStripAdjacency = 0xD, + Patches = 0xE, + + InvalidEnum = 0xF, + EnumCount = 0xF, +}; + +template <> +constexpr PrimitiveMode FromGLenum(GLenum from) +{ + if (from >= static_cast(PrimitiveMode::EnumCount)) + { + return PrimitiveMode::InvalidEnum; + } + + return static_cast(from); +} + +constexpr GLenum ToGLenum(PrimitiveMode from) +{ + return static_cast(from); +} + +static_assert(ToGLenum(PrimitiveMode::Points) == GL_POINTS, "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::Lines) == GL_LINES, "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::LineLoop) == GL_LINE_LOOP, "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::LineStrip) == GL_LINE_STRIP, "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::Triangles) == GL_TRIANGLES, "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::TriangleStrip) == GL_TRIANGLE_STRIP, + "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::TriangleFan) == GL_TRIANGLE_FAN, "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::LinesAdjacency) == GL_LINES_ADJACENCY, + "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::LineStripAdjacency) == GL_LINE_STRIP_ADJACENCY, + "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::TrianglesAdjacency) == GL_TRIANGLES_ADJACENCY, + "PrimitiveMode violation"); +static_assert(ToGLenum(PrimitiveMode::TriangleStripAdjacency) == GL_TRIANGLE_STRIP_ADJACENCY, + "PrimitiveMode violation"); + +std::ostream &operator<<(std::ostream &os, PrimitiveMode value); + +enum class DrawElementsType : size_t +{ + UnsignedByte = 0, + UnsignedShort = 1, + UnsignedInt = 2, + InvalidEnum = 3, + EnumCount = 3, +}; + +template <> +constexpr DrawElementsType FromGLenum(GLenum from) +{ + + GLenum scaled = (from - GL_UNSIGNED_BYTE); + // This code sequence generates a ROR instruction on x86/arm. We want to check if the lowest bit + // of scaled is set and if (scaled >> 1) is greater than a non-pot value. If we rotate the + // lowest bit to the hightest bit both conditions can be checked with a single test. + static_assert(sizeof(GLenum) == 4, "Update (scaled << 31) to sizeof(GLenum) * 8 - 1"); + GLenum packed = (scaled >> 1) | (scaled << 31); + + // operator ? with a simple assignment usually translates to a cmov instruction and thus avoids + // a branch. + packed = (packed >= static_cast(DrawElementsType::EnumCount)) + ? static_cast(DrawElementsType::InvalidEnum) + : packed; + + return static_cast(packed); +} + +constexpr GLenum ToGLenum(DrawElementsType from) +{ + return ((static_cast(from) << 1) + GL_UNSIGNED_BYTE); +} + +#define ANGLE_VALIDATE_PACKED_ENUM(type, packed, glenum) \ + static_assert(ToGLenum(type::packed) == glenum, #type " violation"); \ + static_assert(FromGLenum(glenum) == type::packed, #type " violation") + +ANGLE_VALIDATE_PACKED_ENUM(DrawElementsType, UnsignedByte, GL_UNSIGNED_BYTE); +ANGLE_VALIDATE_PACKED_ENUM(DrawElementsType, UnsignedShort, GL_UNSIGNED_SHORT); +ANGLE_VALIDATE_PACKED_ENUM(DrawElementsType, UnsignedInt, GL_UNSIGNED_INT); + +std::ostream &operator<<(std::ostream &os, DrawElementsType value); + +enum class BlendEquationType +{ + Add = 0, // GLenum == 0x8006 + Min = 1, // GLenum == 0x8007 + Max = 2, // GLenum == 0x8008 + Unused = 3, + Subtract = 4, // GLenum == 0x800A + ReverseSubtract = 5, // GLenum == 0x800B + + Multiply = 6, // GLenum == 0x9294 + Screen = 7, // GLenum == 0x9295 + Overlay = 8, // GLenum == 0x9296 + Darken = 9, // GLenum == 0x9297 + Lighten = 10, // GLenum == 0x9298 + Colordodge = 11, // GLenum == 0x9299 + Colorburn = 12, // GLenum == 0x929A + Hardlight = 13, // GLenum == 0x929B + Softlight = 14, // GLenum == 0x929C + Unused2 = 15, + Difference = 16, // GLenum == 0x929E + Unused3 = 17, + Exclusion = 18, // GLenum == 0x92A0 + + HslHue = 19, // GLenum == 0x92AD + HslSaturation = 20, // GLenum == 0x92AE + HslColor = 21, // GLenum == 0x92AF + HslLuminosity = 22, // GLenum == 0x92B0 + + InvalidEnum = 23, + EnumCount = InvalidEnum +}; + +using BlendEquationBitSet = angle::PackedEnumBitSet; + +template <> +constexpr BlendEquationType FromGLenum(GLenum from) +{ + if (from <= GL_FUNC_REVERSE_SUBTRACT) + { + const GLenum scaled = (from - GL_FUNC_ADD); + return (scaled == static_cast(BlendEquationType::Unused)) + ? BlendEquationType::InvalidEnum + : static_cast(scaled); + } + if (from <= GL_EXCLUSION_KHR) + { + const GLenum scaled = + (from - GL_MULTIPLY_KHR + static_cast(BlendEquationType::Multiply)); + return (scaled == static_cast(BlendEquationType::Unused2) || + scaled == static_cast(BlendEquationType::Unused3)) + ? BlendEquationType::InvalidEnum + : static_cast(scaled); + } + if (from <= GL_HSL_LUMINOSITY_KHR) + { + return static_cast(from - GL_HSL_HUE_KHR + + static_cast(BlendEquationType::HslHue)); + } + return BlendEquationType::InvalidEnum; +} + +constexpr GLenum ToGLenum(BlendEquationType from) +{ + if (from <= BlendEquationType::ReverseSubtract) + { + return static_cast(from) + GL_FUNC_ADD; + } + if (from <= BlendEquationType::Exclusion) + { + return static_cast(from) - static_cast(BlendEquationType::Multiply) + + GL_MULTIPLY_KHR; + } + return static_cast(from) - static_cast(BlendEquationType::HslHue) + + GL_HSL_HUE_KHR; +} + +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Add, GL_FUNC_ADD); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Min, GL_MIN); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Max, GL_MAX); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Subtract, GL_FUNC_SUBTRACT); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, ReverseSubtract, GL_FUNC_REVERSE_SUBTRACT); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Multiply, GL_MULTIPLY_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Screen, GL_SCREEN_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Overlay, GL_OVERLAY_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Darken, GL_DARKEN_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Lighten, GL_LIGHTEN_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Colordodge, GL_COLORDODGE_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Colorburn, GL_COLORBURN_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Hardlight, GL_HARDLIGHT_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Softlight, GL_SOFTLIGHT_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Difference, GL_DIFFERENCE_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, Exclusion, GL_EXCLUSION_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, HslHue, GL_HSL_HUE_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, HslSaturation, GL_HSL_SATURATION_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, HslColor, GL_HSL_COLOR_KHR); +ANGLE_VALIDATE_PACKED_ENUM(BlendEquationType, HslLuminosity, GL_HSL_LUMINOSITY_KHR); + +std::ostream &operator<<(std::ostream &os, BlendEquationType value); + +enum class BlendFactorType +{ + Zero = 0, // GLenum == 0 + One = 1, // GLenum == 1 + + MinSrcDstType = 2, + SrcColor = 2, // GLenum == 0x0300 + OneMinusSrcColor = 3, // GLenum == 0x0301 + SrcAlpha = 4, // GLenum == 0x0302 + OneMinusSrcAlpha = 5, // GLenum == 0x0303 + DstAlpha = 6, // GLenum == 0x0304 + OneMinusDstAlpha = 7, // GLenum == 0x0305 + DstColor = 8, // GLenum == 0x0306 + OneMinusDstColor = 9, // GLenum == 0x0307 + SrcAlphaSaturate = 10, // GLenum == 0x0308 + MaxSrcDstType = 10, + + MinConstantType = 11, + ConstantColor = 11, // GLenum == 0x8001 + OneMinusConstantColor = 12, // GLenum == 0x8002 + ConstantAlpha = 13, // GLenum == 0x8003 + OneMinusConstantAlpha = 14, // GLenum == 0x8004 + MaxConstantType = 14, + + // GL_EXT_blend_func_extended + + Src1Alpha = 15, // GLenum == 0x8589 + + Src1Color = 16, // GLenum == 0x88F9 + OneMinusSrc1Color = 17, // GLenum == 0x88FA + OneMinusSrc1Alpha = 18, // GLenum == 0x88FB + + InvalidEnum = 19, + EnumCount = 19 +}; + +template <> +constexpr BlendFactorType FromGLenum(GLenum from) +{ + if (from <= 1) + return static_cast(from); + if (from >= GL_SRC_COLOR && from <= GL_SRC_ALPHA_SATURATE) + return static_cast(from - GL_SRC_COLOR + 2); + if (from >= GL_CONSTANT_COLOR && from <= GL_ONE_MINUS_CONSTANT_ALPHA) + return static_cast(from - GL_CONSTANT_COLOR + 11); + if (from == GL_SRC1_ALPHA_EXT) + return BlendFactorType::Src1Alpha; + if (from >= GL_SRC1_COLOR_EXT && from <= GL_ONE_MINUS_SRC1_ALPHA_EXT) + return static_cast(from - GL_SRC1_COLOR_EXT + 16); + return BlendFactorType::InvalidEnum; +} + +constexpr GLenum ToGLenum(BlendFactorType from) +{ + const GLenum value = static_cast(from); + if (value <= 1) + return value; + if (from >= BlendFactorType::MinSrcDstType && from <= BlendFactorType::MaxSrcDstType) + return value - 2 + GL_SRC_COLOR; + if (from >= BlendFactorType::MinConstantType && from <= BlendFactorType::MaxConstantType) + return value - 11 + GL_CONSTANT_COLOR; + if (from == BlendFactorType::Src1Alpha) + return GL_SRC1_ALPHA_EXT; + return value - 16 + GL_SRC1_COLOR_EXT; +} + +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, Zero, GL_ZERO); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, One, GL_ONE); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, SrcColor, GL_SRC_COLOR); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, OneMinusSrcColor, GL_ONE_MINUS_SRC_COLOR); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, SrcAlpha, GL_SRC_ALPHA); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, OneMinusSrcAlpha, GL_ONE_MINUS_SRC_ALPHA); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, DstAlpha, GL_DST_ALPHA); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, OneMinusDstAlpha, GL_ONE_MINUS_DST_ALPHA); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, DstColor, GL_DST_COLOR); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, OneMinusDstColor, GL_ONE_MINUS_DST_COLOR); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, SrcAlphaSaturate, GL_SRC_ALPHA_SATURATE); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, ConstantColor, GL_CONSTANT_COLOR); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, OneMinusConstantColor, GL_ONE_MINUS_CONSTANT_COLOR); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, ConstantAlpha, GL_CONSTANT_ALPHA); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, OneMinusConstantAlpha, GL_ONE_MINUS_CONSTANT_ALPHA); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, Src1Alpha, GL_SRC1_ALPHA_EXT); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, Src1Color, GL_SRC1_COLOR_EXT); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, OneMinusSrc1Color, GL_ONE_MINUS_SRC1_COLOR_EXT); +ANGLE_VALIDATE_PACKED_ENUM(BlendFactorType, OneMinusSrc1Alpha, GL_ONE_MINUS_SRC1_ALPHA_EXT); + +std::ostream &operator<<(std::ostream &os, BlendFactorType value); + +enum class VertexAttribType +{ + Byte = 0, // GLenum == 0x1400 + UnsignedByte = 1, // GLenum == 0x1401 + Short = 2, // GLenum == 0x1402 + UnsignedShort = 3, // GLenum == 0x1403 + Int = 4, // GLenum == 0x1404 + UnsignedInt = 5, // GLenum == 0x1405 + Float = 6, // GLenum == 0x1406 + Unused1 = 7, // GLenum == 0x1407 + Unused2 = 8, // GLenum == 0x1408 + Unused3 = 9, // GLenum == 0x1409 + Unused4 = 10, // GLenum == 0x140A + HalfFloat = 11, // GLenum == 0x140B + Fixed = 12, // GLenum == 0x140C + MaxBasicType = 12, + UnsignedInt2101010 = 13, // GLenum == 0x8368 + HalfFloatOES = 14, // GLenum == 0x8D61 + Int2101010 = 15, // GLenum == 0x8D9F + UnsignedInt1010102 = 16, // GLenum == 0x8DF6 + Int1010102 = 17, // GLenum == 0x8DF7 + InvalidEnum = 18, + EnumCount = 18, +}; + +template <> +constexpr VertexAttribType FromGLenum(GLenum from) +{ + GLenum packed = from - GL_BYTE; + if (packed <= static_cast(VertexAttribType::MaxBasicType)) + return static_cast(packed); + if (from == GL_UNSIGNED_INT_2_10_10_10_REV) + return VertexAttribType::UnsignedInt2101010; + if (from == GL_HALF_FLOAT_OES) + return VertexAttribType::HalfFloatOES; + if (from == GL_INT_2_10_10_10_REV) + return VertexAttribType::Int2101010; + if (from == GL_UNSIGNED_INT_10_10_10_2_OES) + return VertexAttribType::UnsignedInt1010102; + if (from == GL_INT_10_10_10_2_OES) + return VertexAttribType::Int1010102; + return VertexAttribType::InvalidEnum; +} + +constexpr GLenum ToGLenum(VertexAttribType from) +{ + // This could be optimized using a constexpr table. + if (from == VertexAttribType::Int2101010) + return GL_INT_2_10_10_10_REV; + if (from == VertexAttribType::HalfFloatOES) + return GL_HALF_FLOAT_OES; + if (from == VertexAttribType::UnsignedInt2101010) + return GL_UNSIGNED_INT_2_10_10_10_REV; + if (from == VertexAttribType::UnsignedInt1010102) + return GL_UNSIGNED_INT_10_10_10_2_OES; + if (from == VertexAttribType::Int1010102) + return GL_INT_10_10_10_2_OES; + return static_cast(from) + GL_BYTE; +} + +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, Byte, GL_BYTE); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, UnsignedByte, GL_UNSIGNED_BYTE); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, Short, GL_SHORT); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, UnsignedShort, GL_UNSIGNED_SHORT); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, Int, GL_INT); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, UnsignedInt, GL_UNSIGNED_INT); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, Float, GL_FLOAT); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, HalfFloat, GL_HALF_FLOAT); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, Fixed, GL_FIXED); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, Int2101010, GL_INT_2_10_10_10_REV); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, HalfFloatOES, GL_HALF_FLOAT_OES); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, UnsignedInt2101010, GL_UNSIGNED_INT_2_10_10_10_REV); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, Int1010102, GL_INT_10_10_10_2_OES); +ANGLE_VALIDATE_PACKED_ENUM(VertexAttribType, UnsignedInt1010102, GL_UNSIGNED_INT_10_10_10_2_OES); + +std::ostream &operator<<(std::ostream &os, VertexAttribType value); + +enum class TessEvaluationType +{ + Triangles = 0, + Quads = 1, + Isolines = 2, + EqualSpacing = 3, + FractionalEvenSpacing = 4, + FractionalOddSpacing = 5, + Cw = 6, + Ccw = 7, + PointMode = 8, + InvalidEnum = 9, + EnumCount = 9 +}; + +template <> +constexpr TessEvaluationType FromGLenum(GLenum from) +{ + if (from == GL_TRIANGLES) + return TessEvaluationType::Triangles; + if (from == GL_QUADS) + return TessEvaluationType::Quads; + if (from == GL_ISOLINES) + return TessEvaluationType::Isolines; + if (from == GL_EQUAL) + return TessEvaluationType::EqualSpacing; + if (from == GL_FRACTIONAL_EVEN) + return TessEvaluationType::FractionalEvenSpacing; + if (from == GL_FRACTIONAL_ODD) + return TessEvaluationType::FractionalOddSpacing; + if (from == GL_CW) + return TessEvaluationType::Cw; + if (from == GL_CCW) + return TessEvaluationType::Ccw; + if (from == GL_TESS_GEN_POINT_MODE) + return TessEvaluationType::PointMode; + return TessEvaluationType::InvalidEnum; +} + +constexpr GLenum ToGLenum(TessEvaluationType from) +{ + switch (from) + { + case TessEvaluationType::Triangles: + return GL_TRIANGLES; + case TessEvaluationType::Quads: + return GL_QUADS; + case TessEvaluationType::Isolines: + return GL_ISOLINES; + case TessEvaluationType::EqualSpacing: + return GL_EQUAL; + case TessEvaluationType::FractionalEvenSpacing: + return GL_FRACTIONAL_EVEN; + case TessEvaluationType::FractionalOddSpacing: + return GL_FRACTIONAL_ODD; + case TessEvaluationType::Cw: + return GL_CW; + case TessEvaluationType::Ccw: + return GL_CCW; + case TessEvaluationType::PointMode: + return GL_TESS_GEN_POINT_MODE; + default: + return GL_INVALID_ENUM; + } +} + +ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Triangles, GL_TRIANGLES); +ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Quads, GL_QUADS); +ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Isolines, GL_ISOLINES); +ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, EqualSpacing, GL_EQUAL); +ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, FractionalEvenSpacing, GL_FRACTIONAL_EVEN); +ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, FractionalOddSpacing, GL_FRACTIONAL_ODD); +ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Cw, GL_CW); +ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, Ccw, GL_CCW); +ANGLE_VALIDATE_PACKED_ENUM(TessEvaluationType, PointMode, GL_TESS_GEN_POINT_MODE); + +std::ostream &operator<<(std::ostream &os, TessEvaluationType value); + +// Typesafe object handles. + +template +struct ResourceTypeToID; + +template +struct IsResourceIDType; + +// Clang Format doesn't like the following X macro. +// clang-format off +#define ANGLE_ID_TYPES_OP(X) \ + X(Buffer) \ + X(FenceNV) \ + X(Framebuffer) \ + X(MemoryObject) \ + X(Path) \ + X(ProgramPipeline) \ + X(Query) \ + X(Renderbuffer) \ + X(Sampler) \ + X(Semaphore) \ + X(Texture) \ + X(TransformFeedback) \ + X(VertexArray) +// clang-format on + +#define ANGLE_DEFINE_ID_TYPE(Type) \ + class Type; \ + struct Type##ID \ + { \ + GLuint value; \ + }; \ + template <> \ + struct ResourceTypeToID \ + { \ + using IDType = Type##ID; \ + }; \ + template <> \ + struct IsResourceIDType \ + { \ + static constexpr bool value = true; \ + }; + +ANGLE_ID_TYPES_OP(ANGLE_DEFINE_ID_TYPE) + +#undef ANGLE_DEFINE_ID_TYPE +#undef ANGLE_ID_TYPES_OP + +// Shaders and programs are a bit special as they share IDs. +struct ShaderProgramID +{ + GLuint value; +}; + +template <> +struct IsResourceIDType +{ + constexpr static bool value = true; +}; + +class Shader; +template <> +struct ResourceTypeToID +{ + using IDType = ShaderProgramID; +}; + +class Program; +template <> +struct ResourceTypeToID +{ + using IDType = ShaderProgramID; +}; + +template +struct ResourceTypeToID +{ + using IDType = void; +}; + +template +struct IsResourceIDType +{ + static constexpr bool value = false; +}; + +template +bool ValueEquals(T lhs, T rhs) +{ + return lhs.value == rhs.value; +} + +// Util funcs for resourceIDs +template +typename std::enable_if::value, bool>::type operator==(const T &lhs, + const T &rhs) +{ + return lhs.value == rhs.value; +} + +template +typename std::enable_if::value, bool>::type operator!=(const T &lhs, + const T &rhs) +{ + return lhs.value != rhs.value; +} + +template +typename std::enable_if::value, bool>::type operator<(const T &lhs, + const T &rhs) +{ + return lhs.value < rhs.value; +} + +// Used to unbox typed values. +template +GLuint GetIDValue(ResourceIDType id); + +template <> +inline GLuint GetIDValue(GLuint id) +{ + return id; +} + +template +inline GLuint GetIDValue(ResourceIDType id) +{ + return id.value; +} + +// First case: handling packed enums. +template +typename std::enable_if::value, EnumT>::type PackParam(FromT from) +{ + return FromGLenum(from); +} + +// Second case: handling non-pointer resource ids. +template +typename std::enable_if::value && !std::is_enum::value, EnumT>::type +PackParam(FromT from) +{ + return {from}; +} + +// Third case: handling pointer resource ids. +template +typename std::enable_if::value && !std::is_enum::value, EnumT>::type +PackParam(FromT from) +{ + static_assert(sizeof(typename std::remove_pointer::type) == + sizeof(typename std::remove_pointer::type), + "Types have different sizes"); + static_assert( + std::is_same< + decltype(std::remove_pointer::type::value), + typename std::remove_const::type>::type>::value, + "Data types are different"); + return reinterpret_cast(from); +} + +struct UniformLocation +{ + int value; +}; + +bool operator<(const UniformLocation &lhs, const UniformLocation &rhs); + +struct UniformBlockIndex +{ + uint32_t value; +}; + +bool IsEmulatedCompressedFormat(GLenum format); +} // namespace gl + +namespace egl +{ +MessageType ErrorCodeToMessageType(EGLint errorCode); +} // namespace egl + +namespace egl_gl +{ +gl::TextureTarget EGLCubeMapTargetToCubeMapTarget(EGLenum eglTarget); +gl::TextureTarget EGLImageTargetToTextureTarget(EGLenum eglTarget); +gl::TextureType EGLTextureTargetToTextureType(EGLenum eglTarget); +} // namespace egl_gl + +#endif // COMMON_PACKEDGLENUMS_H_ diff --git a/gfx/angle/checkout/src/common/PackedGLEnums_autogen.cpp b/gfx/angle/checkout/src/common/PackedGLEnums_autogen.cpp new file mode 100644 index 0000000000..d025b11a14 --- /dev/null +++ b/gfx/angle/checkout/src/common/PackedGLEnums_autogen.cpp @@ -0,0 +1,2449 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by gen_packed_gl_enums.py using data from packed_gl_enums.json. +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// PackedGLEnums_autogen.cpp: +// Implements ANGLE-specific enums classes for GLenums and functions operating +// on them. + +#include "common/PackedGLEnums_autogen.h" +#include "common/debug.h" + +namespace gl +{ + +template <> +AlphaTestFunc FromGLenum(GLenum from) +{ + switch (from) + { + case GL_ALWAYS: + return AlphaTestFunc::AlwaysPass; + case GL_EQUAL: + return AlphaTestFunc::Equal; + case GL_GEQUAL: + return AlphaTestFunc::Gequal; + case GL_GREATER: + return AlphaTestFunc::Greater; + case GL_LEQUAL: + return AlphaTestFunc::Lequal; + case GL_LESS: + return AlphaTestFunc::Less; + case GL_NEVER: + return AlphaTestFunc::Never; + case GL_NOTEQUAL: + return AlphaTestFunc::NotEqual; + default: + return AlphaTestFunc::InvalidEnum; + } +} + +GLenum ToGLenum(AlphaTestFunc from) +{ + switch (from) + { + case AlphaTestFunc::AlwaysPass: + return GL_ALWAYS; + case AlphaTestFunc::Equal: + return GL_EQUAL; + case AlphaTestFunc::Gequal: + return GL_GEQUAL; + case AlphaTestFunc::Greater: + return GL_GREATER; + case AlphaTestFunc::Lequal: + return GL_LEQUAL; + case AlphaTestFunc::Less: + return GL_LESS; + case AlphaTestFunc::Never: + return GL_NEVER; + case AlphaTestFunc::NotEqual: + return GL_NOTEQUAL; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, AlphaTestFunc value) +{ + switch (value) + { + case AlphaTestFunc::AlwaysPass: + os << "GL_ALWAYS"; + break; + case AlphaTestFunc::Equal: + os << "GL_EQUAL"; + break; + case AlphaTestFunc::Gequal: + os << "GL_GEQUAL"; + break; + case AlphaTestFunc::Greater: + os << "GL_GREATER"; + break; + case AlphaTestFunc::Lequal: + os << "GL_LEQUAL"; + break; + case AlphaTestFunc::Less: + os << "GL_LESS"; + break; + case AlphaTestFunc::Never: + os << "GL_NEVER"; + break; + case AlphaTestFunc::NotEqual: + os << "GL_NOTEQUAL"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +BufferBinding FromGLenum(GLenum from) +{ + switch (from) + { + case GL_ARRAY_BUFFER: + return BufferBinding::Array; + case GL_ATOMIC_COUNTER_BUFFER: + return BufferBinding::AtomicCounter; + case GL_COPY_READ_BUFFER: + return BufferBinding::CopyRead; + case GL_COPY_WRITE_BUFFER: + return BufferBinding::CopyWrite; + case GL_DISPATCH_INDIRECT_BUFFER: + return BufferBinding::DispatchIndirect; + case GL_DRAW_INDIRECT_BUFFER: + return BufferBinding::DrawIndirect; + case GL_ELEMENT_ARRAY_BUFFER: + return BufferBinding::ElementArray; + case GL_PIXEL_PACK_BUFFER: + return BufferBinding::PixelPack; + case GL_PIXEL_UNPACK_BUFFER: + return BufferBinding::PixelUnpack; + case GL_SHADER_STORAGE_BUFFER: + return BufferBinding::ShaderStorage; + case GL_TEXTURE_BUFFER: + return BufferBinding::Texture; + case GL_TRANSFORM_FEEDBACK_BUFFER: + return BufferBinding::TransformFeedback; + case GL_UNIFORM_BUFFER: + return BufferBinding::Uniform; + default: + return BufferBinding::InvalidEnum; + } +} + +GLenum ToGLenum(BufferBinding from) +{ + switch (from) + { + case BufferBinding::Array: + return GL_ARRAY_BUFFER; + case BufferBinding::AtomicCounter: + return GL_ATOMIC_COUNTER_BUFFER; + case BufferBinding::CopyRead: + return GL_COPY_READ_BUFFER; + case BufferBinding::CopyWrite: + return GL_COPY_WRITE_BUFFER; + case BufferBinding::DispatchIndirect: + return GL_DISPATCH_INDIRECT_BUFFER; + case BufferBinding::DrawIndirect: + return GL_DRAW_INDIRECT_BUFFER; + case BufferBinding::ElementArray: + return GL_ELEMENT_ARRAY_BUFFER; + case BufferBinding::PixelPack: + return GL_PIXEL_PACK_BUFFER; + case BufferBinding::PixelUnpack: + return GL_PIXEL_UNPACK_BUFFER; + case BufferBinding::ShaderStorage: + return GL_SHADER_STORAGE_BUFFER; + case BufferBinding::Texture: + return GL_TEXTURE_BUFFER; + case BufferBinding::TransformFeedback: + return GL_TRANSFORM_FEEDBACK_BUFFER; + case BufferBinding::Uniform: + return GL_UNIFORM_BUFFER; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, BufferBinding value) +{ + switch (value) + { + case BufferBinding::Array: + os << "GL_ARRAY_BUFFER"; + break; + case BufferBinding::AtomicCounter: + os << "GL_ATOMIC_COUNTER_BUFFER"; + break; + case BufferBinding::CopyRead: + os << "GL_COPY_READ_BUFFER"; + break; + case BufferBinding::CopyWrite: + os << "GL_COPY_WRITE_BUFFER"; + break; + case BufferBinding::DispatchIndirect: + os << "GL_DISPATCH_INDIRECT_BUFFER"; + break; + case BufferBinding::DrawIndirect: + os << "GL_DRAW_INDIRECT_BUFFER"; + break; + case BufferBinding::ElementArray: + os << "GL_ELEMENT_ARRAY_BUFFER"; + break; + case BufferBinding::PixelPack: + os << "GL_PIXEL_PACK_BUFFER"; + break; + case BufferBinding::PixelUnpack: + os << "GL_PIXEL_UNPACK_BUFFER"; + break; + case BufferBinding::ShaderStorage: + os << "GL_SHADER_STORAGE_BUFFER"; + break; + case BufferBinding::Texture: + os << "GL_TEXTURE_BUFFER"; + break; + case BufferBinding::TransformFeedback: + os << "GL_TRANSFORM_FEEDBACK_BUFFER"; + break; + case BufferBinding::Uniform: + os << "GL_UNIFORM_BUFFER"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +BufferUsage FromGLenum(GLenum from) +{ + switch (from) + { + case GL_DYNAMIC_COPY: + return BufferUsage::DynamicCopy; + case GL_DYNAMIC_DRAW: + return BufferUsage::DynamicDraw; + case GL_DYNAMIC_READ: + return BufferUsage::DynamicRead; + case GL_STATIC_COPY: + return BufferUsage::StaticCopy; + case GL_STATIC_DRAW: + return BufferUsage::StaticDraw; + case GL_STATIC_READ: + return BufferUsage::StaticRead; + case GL_STREAM_COPY: + return BufferUsage::StreamCopy; + case GL_STREAM_DRAW: + return BufferUsage::StreamDraw; + case GL_STREAM_READ: + return BufferUsage::StreamRead; + default: + return BufferUsage::InvalidEnum; + } +} + +GLenum ToGLenum(BufferUsage from) +{ + switch (from) + { + case BufferUsage::DynamicCopy: + return GL_DYNAMIC_COPY; + case BufferUsage::DynamicDraw: + return GL_DYNAMIC_DRAW; + case BufferUsage::DynamicRead: + return GL_DYNAMIC_READ; + case BufferUsage::StaticCopy: + return GL_STATIC_COPY; + case BufferUsage::StaticDraw: + return GL_STATIC_DRAW; + case BufferUsage::StaticRead: + return GL_STATIC_READ; + case BufferUsage::StreamCopy: + return GL_STREAM_COPY; + case BufferUsage::StreamDraw: + return GL_STREAM_DRAW; + case BufferUsage::StreamRead: + return GL_STREAM_READ; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, BufferUsage value) +{ + switch (value) + { + case BufferUsage::DynamicCopy: + os << "GL_DYNAMIC_COPY"; + break; + case BufferUsage::DynamicDraw: + os << "GL_DYNAMIC_DRAW"; + break; + case BufferUsage::DynamicRead: + os << "GL_DYNAMIC_READ"; + break; + case BufferUsage::StaticCopy: + os << "GL_STATIC_COPY"; + break; + case BufferUsage::StaticDraw: + os << "GL_STATIC_DRAW"; + break; + case BufferUsage::StaticRead: + os << "GL_STATIC_READ"; + break; + case BufferUsage::StreamCopy: + os << "GL_STREAM_COPY"; + break; + case BufferUsage::StreamDraw: + os << "GL_STREAM_DRAW"; + break; + case BufferUsage::StreamRead: + os << "GL_STREAM_READ"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +ClientVertexArrayType FromGLenum(GLenum from) +{ + switch (from) + { + case GL_COLOR_ARRAY: + return ClientVertexArrayType::Color; + case GL_NORMAL_ARRAY: + return ClientVertexArrayType::Normal; + case GL_POINT_SIZE_ARRAY_OES: + return ClientVertexArrayType::PointSize; + case GL_TEXTURE_COORD_ARRAY: + return ClientVertexArrayType::TextureCoord; + case GL_VERTEX_ARRAY: + return ClientVertexArrayType::Vertex; + default: + return ClientVertexArrayType::InvalidEnum; + } +} + +GLenum ToGLenum(ClientVertexArrayType from) +{ + switch (from) + { + case ClientVertexArrayType::Color: + return GL_COLOR_ARRAY; + case ClientVertexArrayType::Normal: + return GL_NORMAL_ARRAY; + case ClientVertexArrayType::PointSize: + return GL_POINT_SIZE_ARRAY_OES; + case ClientVertexArrayType::TextureCoord: + return GL_TEXTURE_COORD_ARRAY; + case ClientVertexArrayType::Vertex: + return GL_VERTEX_ARRAY; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, ClientVertexArrayType value) +{ + switch (value) + { + case ClientVertexArrayType::Color: + os << "GL_COLOR_ARRAY"; + break; + case ClientVertexArrayType::Normal: + os << "GL_NORMAL_ARRAY"; + break; + case ClientVertexArrayType::PointSize: + os << "GL_POINT_SIZE_ARRAY_OES"; + break; + case ClientVertexArrayType::TextureCoord: + os << "GL_TEXTURE_COORD_ARRAY"; + break; + case ClientVertexArrayType::Vertex: + os << "GL_VERTEX_ARRAY"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +CullFaceMode FromGLenum(GLenum from) +{ + switch (from) + { + case GL_BACK: + return CullFaceMode::Back; + case GL_FRONT: + return CullFaceMode::Front; + case GL_FRONT_AND_BACK: + return CullFaceMode::FrontAndBack; + default: + return CullFaceMode::InvalidEnum; + } +} + +GLenum ToGLenum(CullFaceMode from) +{ + switch (from) + { + case CullFaceMode::Back: + return GL_BACK; + case CullFaceMode::Front: + return GL_FRONT; + case CullFaceMode::FrontAndBack: + return GL_FRONT_AND_BACK; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, CullFaceMode value) +{ + switch (value) + { + case CullFaceMode::Back: + os << "GL_BACK"; + break; + case CullFaceMode::Front: + os << "GL_FRONT"; + break; + case CullFaceMode::FrontAndBack: + os << "GL_FRONT_AND_BACK"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +FilterMode FromGLenum(GLenum from) +{ + switch (from) + { + case GL_NEAREST: + return FilterMode::Nearest; + case GL_LINEAR: + return FilterMode::Linear; + case GL_NEAREST_MIPMAP_NEAREST: + return FilterMode::NearestMipmapNearest; + case GL_NEAREST_MIPMAP_LINEAR: + return FilterMode::NearestMipmapLinear; + case GL_LINEAR_MIPMAP_LINEAR: + return FilterMode::LinearMipmapLinear; + default: + return FilterMode::InvalidEnum; + } +} + +GLenum ToGLenum(FilterMode from) +{ + switch (from) + { + case FilterMode::Nearest: + return GL_NEAREST; + case FilterMode::Linear: + return GL_LINEAR; + case FilterMode::NearestMipmapNearest: + return GL_NEAREST_MIPMAP_NEAREST; + case FilterMode::NearestMipmapLinear: + return GL_NEAREST_MIPMAP_LINEAR; + case FilterMode::LinearMipmapLinear: + return GL_LINEAR_MIPMAP_LINEAR; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, FilterMode value) +{ + switch (value) + { + case FilterMode::Nearest: + os << "GL_NEAREST"; + break; + case FilterMode::Linear: + os << "GL_LINEAR"; + break; + case FilterMode::NearestMipmapNearest: + os << "GL_NEAREST_MIPMAP_NEAREST"; + break; + case FilterMode::NearestMipmapLinear: + os << "GL_NEAREST_MIPMAP_LINEAR"; + break; + case FilterMode::LinearMipmapLinear: + os << "GL_LINEAR_MIPMAP_LINEAR"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +FogMode FromGLenum(GLenum from) +{ + switch (from) + { + case GL_EXP: + return FogMode::Exp; + case GL_EXP2: + return FogMode::Exp2; + case GL_LINEAR: + return FogMode::Linear; + default: + return FogMode::InvalidEnum; + } +} + +GLenum ToGLenum(FogMode from) +{ + switch (from) + { + case FogMode::Exp: + return GL_EXP; + case FogMode::Exp2: + return GL_EXP2; + case FogMode::Linear: + return GL_LINEAR; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, FogMode value) +{ + switch (value) + { + case FogMode::Exp: + os << "GL_EXP"; + break; + case FogMode::Exp2: + os << "GL_EXP2"; + break; + case FogMode::Linear: + os << "GL_LINEAR"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +GraphicsResetStatus FromGLenum(GLenum from) +{ + switch (from) + { + case GL_NO_ERROR: + return GraphicsResetStatus::NoError; + case GL_GUILTY_CONTEXT_RESET: + return GraphicsResetStatus::GuiltyContextReset; + case GL_INNOCENT_CONTEXT_RESET: + return GraphicsResetStatus::InnocentContextReset; + case GL_UNKNOWN_CONTEXT_RESET: + return GraphicsResetStatus::UnknownContextReset; + case GL_PURGED_CONTEXT_RESET_NV: + return GraphicsResetStatus::PurgedContextResetNV; + default: + return GraphicsResetStatus::InvalidEnum; + } +} + +GLenum ToGLenum(GraphicsResetStatus from) +{ + switch (from) + { + case GraphicsResetStatus::NoError: + return GL_NO_ERROR; + case GraphicsResetStatus::GuiltyContextReset: + return GL_GUILTY_CONTEXT_RESET; + case GraphicsResetStatus::InnocentContextReset: + return GL_INNOCENT_CONTEXT_RESET; + case GraphicsResetStatus::UnknownContextReset: + return GL_UNKNOWN_CONTEXT_RESET; + case GraphicsResetStatus::PurgedContextResetNV: + return GL_PURGED_CONTEXT_RESET_NV; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, GraphicsResetStatus value) +{ + switch (value) + { + case GraphicsResetStatus::NoError: + os << "GL_NO_ERROR"; + break; + case GraphicsResetStatus::GuiltyContextReset: + os << "GL_GUILTY_CONTEXT_RESET"; + break; + case GraphicsResetStatus::InnocentContextReset: + os << "GL_INNOCENT_CONTEXT_RESET"; + break; + case GraphicsResetStatus::UnknownContextReset: + os << "GL_UNKNOWN_CONTEXT_RESET"; + break; + case GraphicsResetStatus::PurgedContextResetNV: + os << "GL_PURGED_CONTEXT_RESET_NV"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +HandleType FromGLenum(GLenum from) +{ + switch (from) + { + case GL_HANDLE_TYPE_OPAQUE_FD_EXT: + return HandleType::OpaqueFd; + case GL_HANDLE_TYPE_ZIRCON_VMO_ANGLE: + return HandleType::ZirconVmo; + case GL_HANDLE_TYPE_ZIRCON_EVENT_ANGLE: + return HandleType::ZirconEvent; + default: + return HandleType::InvalidEnum; + } +} + +GLenum ToGLenum(HandleType from) +{ + switch (from) + { + case HandleType::OpaqueFd: + return GL_HANDLE_TYPE_OPAQUE_FD_EXT; + case HandleType::ZirconVmo: + return GL_HANDLE_TYPE_ZIRCON_VMO_ANGLE; + case HandleType::ZirconEvent: + return GL_HANDLE_TYPE_ZIRCON_EVENT_ANGLE; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, HandleType value) +{ + switch (value) + { + case HandleType::OpaqueFd: + os << "GL_HANDLE_TYPE_OPAQUE_FD_EXT"; + break; + case HandleType::ZirconVmo: + os << "GL_HANDLE_TYPE_ZIRCON_VMO_ANGLE"; + break; + case HandleType::ZirconEvent: + os << "GL_HANDLE_TYPE_ZIRCON_EVENT_ANGLE"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +HintSetting FromGLenum(GLenum from) +{ + switch (from) + { + case GL_DONT_CARE: + return HintSetting::DontCare; + case GL_FASTEST: + return HintSetting::Fastest; + case GL_NICEST: + return HintSetting::Nicest; + default: + return HintSetting::InvalidEnum; + } +} + +GLenum ToGLenum(HintSetting from) +{ + switch (from) + { + case HintSetting::DontCare: + return GL_DONT_CARE; + case HintSetting::Fastest: + return GL_FASTEST; + case HintSetting::Nicest: + return GL_NICEST; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, HintSetting value) +{ + switch (value) + { + case HintSetting::DontCare: + os << "GL_DONT_CARE"; + break; + case HintSetting::Fastest: + os << "GL_FASTEST"; + break; + case HintSetting::Nicest: + os << "GL_NICEST"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +ImageLayout FromGLenum(GLenum from) +{ + switch (from) + { + case GL_NONE: + return ImageLayout::Undefined; + case GL_LAYOUT_GENERAL_EXT: + return ImageLayout::General; + case GL_LAYOUT_COLOR_ATTACHMENT_EXT: + return ImageLayout::ColorAttachment; + case GL_LAYOUT_DEPTH_STENCIL_ATTACHMENT_EXT: + return ImageLayout::DepthStencilAttachment; + case GL_LAYOUT_DEPTH_STENCIL_READ_ONLY_EXT: + return ImageLayout::DepthStencilReadOnlyAttachment; + case GL_LAYOUT_SHADER_READ_ONLY_EXT: + return ImageLayout::ShaderReadOnly; + case GL_LAYOUT_TRANSFER_SRC_EXT: + return ImageLayout::TransferSrc; + case GL_LAYOUT_TRANSFER_DST_EXT: + return ImageLayout::TransferDst; + case GL_LAYOUT_DEPTH_READ_ONLY_STENCIL_ATTACHMENT_EXT: + return ImageLayout::DepthReadOnlyStencilAttachment; + case GL_LAYOUT_DEPTH_ATTACHMENT_STENCIL_READ_ONLY_EXT: + return ImageLayout::DepthAttachmentStencilReadOnly; + default: + return ImageLayout::InvalidEnum; + } +} + +GLenum ToGLenum(ImageLayout from) +{ + switch (from) + { + case ImageLayout::Undefined: + return GL_NONE; + case ImageLayout::General: + return GL_LAYOUT_GENERAL_EXT; + case ImageLayout::ColorAttachment: + return GL_LAYOUT_COLOR_ATTACHMENT_EXT; + case ImageLayout::DepthStencilAttachment: + return GL_LAYOUT_DEPTH_STENCIL_ATTACHMENT_EXT; + case ImageLayout::DepthStencilReadOnlyAttachment: + return GL_LAYOUT_DEPTH_STENCIL_READ_ONLY_EXT; + case ImageLayout::ShaderReadOnly: + return GL_LAYOUT_SHADER_READ_ONLY_EXT; + case ImageLayout::TransferSrc: + return GL_LAYOUT_TRANSFER_SRC_EXT; + case ImageLayout::TransferDst: + return GL_LAYOUT_TRANSFER_DST_EXT; + case ImageLayout::DepthReadOnlyStencilAttachment: + return GL_LAYOUT_DEPTH_READ_ONLY_STENCIL_ATTACHMENT_EXT; + case ImageLayout::DepthAttachmentStencilReadOnly: + return GL_LAYOUT_DEPTH_ATTACHMENT_STENCIL_READ_ONLY_EXT; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, ImageLayout value) +{ + switch (value) + { + case ImageLayout::Undefined: + os << "GL_NONE"; + break; + case ImageLayout::General: + os << "GL_LAYOUT_GENERAL_EXT"; + break; + case ImageLayout::ColorAttachment: + os << "GL_LAYOUT_COLOR_ATTACHMENT_EXT"; + break; + case ImageLayout::DepthStencilAttachment: + os << "GL_LAYOUT_DEPTH_STENCIL_ATTACHMENT_EXT"; + break; + case ImageLayout::DepthStencilReadOnlyAttachment: + os << "GL_LAYOUT_DEPTH_STENCIL_READ_ONLY_EXT"; + break; + case ImageLayout::ShaderReadOnly: + os << "GL_LAYOUT_SHADER_READ_ONLY_EXT"; + break; + case ImageLayout::TransferSrc: + os << "GL_LAYOUT_TRANSFER_SRC_EXT"; + break; + case ImageLayout::TransferDst: + os << "GL_LAYOUT_TRANSFER_DST_EXT"; + break; + case ImageLayout::DepthReadOnlyStencilAttachment: + os << "GL_LAYOUT_DEPTH_READ_ONLY_STENCIL_ATTACHMENT_EXT"; + break; + case ImageLayout::DepthAttachmentStencilReadOnly: + os << "GL_LAYOUT_DEPTH_ATTACHMENT_STENCIL_READ_ONLY_EXT"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +LightParameter FromGLenum(GLenum from) +{ + switch (from) + { + case GL_AMBIENT: + return LightParameter::Ambient; + case GL_AMBIENT_AND_DIFFUSE: + return LightParameter::AmbientAndDiffuse; + case GL_CONSTANT_ATTENUATION: + return LightParameter::ConstantAttenuation; + case GL_DIFFUSE: + return LightParameter::Diffuse; + case GL_LINEAR_ATTENUATION: + return LightParameter::LinearAttenuation; + case GL_POSITION: + return LightParameter::Position; + case GL_QUADRATIC_ATTENUATION: + return LightParameter::QuadraticAttenuation; + case GL_SPECULAR: + return LightParameter::Specular; + case GL_SPOT_CUTOFF: + return LightParameter::SpotCutoff; + case GL_SPOT_DIRECTION: + return LightParameter::SpotDirection; + case GL_SPOT_EXPONENT: + return LightParameter::SpotExponent; + default: + return LightParameter::InvalidEnum; + } +} + +GLenum ToGLenum(LightParameter from) +{ + switch (from) + { + case LightParameter::Ambient: + return GL_AMBIENT; + case LightParameter::AmbientAndDiffuse: + return GL_AMBIENT_AND_DIFFUSE; + case LightParameter::ConstantAttenuation: + return GL_CONSTANT_ATTENUATION; + case LightParameter::Diffuse: + return GL_DIFFUSE; + case LightParameter::LinearAttenuation: + return GL_LINEAR_ATTENUATION; + case LightParameter::Position: + return GL_POSITION; + case LightParameter::QuadraticAttenuation: + return GL_QUADRATIC_ATTENUATION; + case LightParameter::Specular: + return GL_SPECULAR; + case LightParameter::SpotCutoff: + return GL_SPOT_CUTOFF; + case LightParameter::SpotDirection: + return GL_SPOT_DIRECTION; + case LightParameter::SpotExponent: + return GL_SPOT_EXPONENT; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, LightParameter value) +{ + switch (value) + { + case LightParameter::Ambient: + os << "GL_AMBIENT"; + break; + case LightParameter::AmbientAndDiffuse: + os << "GL_AMBIENT_AND_DIFFUSE"; + break; + case LightParameter::ConstantAttenuation: + os << "GL_CONSTANT_ATTENUATION"; + break; + case LightParameter::Diffuse: + os << "GL_DIFFUSE"; + break; + case LightParameter::LinearAttenuation: + os << "GL_LINEAR_ATTENUATION"; + break; + case LightParameter::Position: + os << "GL_POSITION"; + break; + case LightParameter::QuadraticAttenuation: + os << "GL_QUADRATIC_ATTENUATION"; + break; + case LightParameter::Specular: + os << "GL_SPECULAR"; + break; + case LightParameter::SpotCutoff: + os << "GL_SPOT_CUTOFF"; + break; + case LightParameter::SpotDirection: + os << "GL_SPOT_DIRECTION"; + break; + case LightParameter::SpotExponent: + os << "GL_SPOT_EXPONENT"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +LogicalOperation FromGLenum(GLenum from) +{ + switch (from) + { + case GL_AND: + return LogicalOperation::And; + case GL_AND_INVERTED: + return LogicalOperation::AndInverted; + case GL_AND_REVERSE: + return LogicalOperation::AndReverse; + case GL_CLEAR: + return LogicalOperation::Clear; + case GL_COPY: + return LogicalOperation::Copy; + case GL_COPY_INVERTED: + return LogicalOperation::CopyInverted; + case GL_EQUIV: + return LogicalOperation::Equiv; + case GL_INVERT: + return LogicalOperation::Invert; + case GL_NAND: + return LogicalOperation::Nand; + case GL_NOOP: + return LogicalOperation::Noop; + case GL_NOR: + return LogicalOperation::Nor; + case GL_OR: + return LogicalOperation::Or; + case GL_OR_INVERTED: + return LogicalOperation::OrInverted; + case GL_OR_REVERSE: + return LogicalOperation::OrReverse; + case GL_SET: + return LogicalOperation::Set; + case GL_XOR: + return LogicalOperation::Xor; + default: + return LogicalOperation::InvalidEnum; + } +} + +GLenum ToGLenum(LogicalOperation from) +{ + switch (from) + { + case LogicalOperation::And: + return GL_AND; + case LogicalOperation::AndInverted: + return GL_AND_INVERTED; + case LogicalOperation::AndReverse: + return GL_AND_REVERSE; + case LogicalOperation::Clear: + return GL_CLEAR; + case LogicalOperation::Copy: + return GL_COPY; + case LogicalOperation::CopyInverted: + return GL_COPY_INVERTED; + case LogicalOperation::Equiv: + return GL_EQUIV; + case LogicalOperation::Invert: + return GL_INVERT; + case LogicalOperation::Nand: + return GL_NAND; + case LogicalOperation::Noop: + return GL_NOOP; + case LogicalOperation::Nor: + return GL_NOR; + case LogicalOperation::Or: + return GL_OR; + case LogicalOperation::OrInverted: + return GL_OR_INVERTED; + case LogicalOperation::OrReverse: + return GL_OR_REVERSE; + case LogicalOperation::Set: + return GL_SET; + case LogicalOperation::Xor: + return GL_XOR; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, LogicalOperation value) +{ + switch (value) + { + case LogicalOperation::And: + os << "GL_AND"; + break; + case LogicalOperation::AndInverted: + os << "GL_AND_INVERTED"; + break; + case LogicalOperation::AndReverse: + os << "GL_AND_REVERSE"; + break; + case LogicalOperation::Clear: + os << "GL_CLEAR"; + break; + case LogicalOperation::Copy: + os << "GL_COPY"; + break; + case LogicalOperation::CopyInverted: + os << "GL_COPY_INVERTED"; + break; + case LogicalOperation::Equiv: + os << "GL_EQUIV"; + break; + case LogicalOperation::Invert: + os << "GL_INVERT"; + break; + case LogicalOperation::Nand: + os << "GL_NAND"; + break; + case LogicalOperation::Noop: + os << "GL_NOOP"; + break; + case LogicalOperation::Nor: + os << "GL_NOR"; + break; + case LogicalOperation::Or: + os << "GL_OR"; + break; + case LogicalOperation::OrInverted: + os << "GL_OR_INVERTED"; + break; + case LogicalOperation::OrReverse: + os << "GL_OR_REVERSE"; + break; + case LogicalOperation::Set: + os << "GL_SET"; + break; + case LogicalOperation::Xor: + os << "GL_XOR"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +MaterialParameter FromGLenum(GLenum from) +{ + switch (from) + { + case GL_AMBIENT: + return MaterialParameter::Ambient; + case GL_AMBIENT_AND_DIFFUSE: + return MaterialParameter::AmbientAndDiffuse; + case GL_DIFFUSE: + return MaterialParameter::Diffuse; + case GL_EMISSION: + return MaterialParameter::Emission; + case GL_SHININESS: + return MaterialParameter::Shininess; + case GL_SPECULAR: + return MaterialParameter::Specular; + default: + return MaterialParameter::InvalidEnum; + } +} + +GLenum ToGLenum(MaterialParameter from) +{ + switch (from) + { + case MaterialParameter::Ambient: + return GL_AMBIENT; + case MaterialParameter::AmbientAndDiffuse: + return GL_AMBIENT_AND_DIFFUSE; + case MaterialParameter::Diffuse: + return GL_DIFFUSE; + case MaterialParameter::Emission: + return GL_EMISSION; + case MaterialParameter::Shininess: + return GL_SHININESS; + case MaterialParameter::Specular: + return GL_SPECULAR; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, MaterialParameter value) +{ + switch (value) + { + case MaterialParameter::Ambient: + os << "GL_AMBIENT"; + break; + case MaterialParameter::AmbientAndDiffuse: + os << "GL_AMBIENT_AND_DIFFUSE"; + break; + case MaterialParameter::Diffuse: + os << "GL_DIFFUSE"; + break; + case MaterialParameter::Emission: + os << "GL_EMISSION"; + break; + case MaterialParameter::Shininess: + os << "GL_SHININESS"; + break; + case MaterialParameter::Specular: + os << "GL_SPECULAR"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +MatrixType FromGLenum(GLenum from) +{ + switch (from) + { + case GL_MODELVIEW: + return MatrixType::Modelview; + case GL_PROJECTION: + return MatrixType::Projection; + case GL_TEXTURE: + return MatrixType::Texture; + default: + return MatrixType::InvalidEnum; + } +} + +GLenum ToGLenum(MatrixType from) +{ + switch (from) + { + case MatrixType::Modelview: + return GL_MODELVIEW; + case MatrixType::Projection: + return GL_PROJECTION; + case MatrixType::Texture: + return GL_TEXTURE; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, MatrixType value) +{ + switch (value) + { + case MatrixType::Modelview: + os << "GL_MODELVIEW"; + break; + case MatrixType::Projection: + os << "GL_PROJECTION"; + break; + case MatrixType::Texture: + os << "GL_TEXTURE"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +PointParameter FromGLenum(GLenum from) +{ + switch (from) + { + case GL_POINT_SIZE_MIN: + return PointParameter::PointSizeMin; + case GL_POINT_SIZE_MAX: + return PointParameter::PointSizeMax; + case GL_POINT_FADE_THRESHOLD_SIZE: + return PointParameter::PointFadeThresholdSize; + case GL_POINT_DISTANCE_ATTENUATION: + return PointParameter::PointDistanceAttenuation; + default: + return PointParameter::InvalidEnum; + } +} + +GLenum ToGLenum(PointParameter from) +{ + switch (from) + { + case PointParameter::PointSizeMin: + return GL_POINT_SIZE_MIN; + case PointParameter::PointSizeMax: + return GL_POINT_SIZE_MAX; + case PointParameter::PointFadeThresholdSize: + return GL_POINT_FADE_THRESHOLD_SIZE; + case PointParameter::PointDistanceAttenuation: + return GL_POINT_DISTANCE_ATTENUATION; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, PointParameter value) +{ + switch (value) + { + case PointParameter::PointSizeMin: + os << "GL_POINT_SIZE_MIN"; + break; + case PointParameter::PointSizeMax: + os << "GL_POINT_SIZE_MAX"; + break; + case PointParameter::PointFadeThresholdSize: + os << "GL_POINT_FADE_THRESHOLD_SIZE"; + break; + case PointParameter::PointDistanceAttenuation: + os << "GL_POINT_DISTANCE_ATTENUATION"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +ProvokingVertexConvention FromGLenum(GLenum from) +{ + switch (from) + { + case GL_FIRST_VERTEX_CONVENTION: + return ProvokingVertexConvention::FirstVertexConvention; + case GL_LAST_VERTEX_CONVENTION: + return ProvokingVertexConvention::LastVertexConvention; + default: + return ProvokingVertexConvention::InvalidEnum; + } +} + +GLenum ToGLenum(ProvokingVertexConvention from) +{ + switch (from) + { + case ProvokingVertexConvention::FirstVertexConvention: + return GL_FIRST_VERTEX_CONVENTION; + case ProvokingVertexConvention::LastVertexConvention: + return GL_LAST_VERTEX_CONVENTION; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, ProvokingVertexConvention value) +{ + switch (value) + { + case ProvokingVertexConvention::FirstVertexConvention: + os << "GL_FIRST_VERTEX_CONVENTION"; + break; + case ProvokingVertexConvention::LastVertexConvention: + os << "GL_LAST_VERTEX_CONVENTION"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +QueryType FromGLenum(GLenum from) +{ + switch (from) + { + case GL_ANY_SAMPLES_PASSED: + return QueryType::AnySamples; + case GL_ANY_SAMPLES_PASSED_CONSERVATIVE: + return QueryType::AnySamplesConservative; + case GL_COMMANDS_COMPLETED_CHROMIUM: + return QueryType::CommandsCompleted; + case GL_PRIMITIVES_GENERATED_EXT: + return QueryType::PrimitivesGenerated; + case GL_TIME_ELAPSED_EXT: + return QueryType::TimeElapsed; + case GL_TIMESTAMP_EXT: + return QueryType::Timestamp; + case GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN: + return QueryType::TransformFeedbackPrimitivesWritten; + default: + return QueryType::InvalidEnum; + } +} + +GLenum ToGLenum(QueryType from) +{ + switch (from) + { + case QueryType::AnySamples: + return GL_ANY_SAMPLES_PASSED; + case QueryType::AnySamplesConservative: + return GL_ANY_SAMPLES_PASSED_CONSERVATIVE; + case QueryType::CommandsCompleted: + return GL_COMMANDS_COMPLETED_CHROMIUM; + case QueryType::PrimitivesGenerated: + return GL_PRIMITIVES_GENERATED_EXT; + case QueryType::TimeElapsed: + return GL_TIME_ELAPSED_EXT; + case QueryType::Timestamp: + return GL_TIMESTAMP_EXT; + case QueryType::TransformFeedbackPrimitivesWritten: + return GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, QueryType value) +{ + switch (value) + { + case QueryType::AnySamples: + os << "GL_ANY_SAMPLES_PASSED"; + break; + case QueryType::AnySamplesConservative: + os << "GL_ANY_SAMPLES_PASSED_CONSERVATIVE"; + break; + case QueryType::CommandsCompleted: + os << "GL_COMMANDS_COMPLETED_CHROMIUM"; + break; + case QueryType::PrimitivesGenerated: + os << "GL_PRIMITIVES_GENERATED_EXT"; + break; + case QueryType::TimeElapsed: + os << "GL_TIME_ELAPSED_EXT"; + break; + case QueryType::Timestamp: + os << "GL_TIMESTAMP_EXT"; + break; + case QueryType::TransformFeedbackPrimitivesWritten: + os << "GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +ShaderType FromGLenum(GLenum from) +{ + switch (from) + { + case GL_VERTEX_SHADER: + return ShaderType::Vertex; + case GL_TESS_CONTROL_SHADER_EXT: + return ShaderType::TessControl; + case GL_TESS_EVALUATION_SHADER_EXT: + return ShaderType::TessEvaluation; + case GL_GEOMETRY_SHADER_EXT: + return ShaderType::Geometry; + case GL_FRAGMENT_SHADER: + return ShaderType::Fragment; + case GL_COMPUTE_SHADER: + return ShaderType::Compute; + default: + return ShaderType::InvalidEnum; + } +} + +GLenum ToGLenum(ShaderType from) +{ + switch (from) + { + case ShaderType::Vertex: + return GL_VERTEX_SHADER; + case ShaderType::TessControl: + return GL_TESS_CONTROL_SHADER_EXT; + case ShaderType::TessEvaluation: + return GL_TESS_EVALUATION_SHADER_EXT; + case ShaderType::Geometry: + return GL_GEOMETRY_SHADER_EXT; + case ShaderType::Fragment: + return GL_FRAGMENT_SHADER; + case ShaderType::Compute: + return GL_COMPUTE_SHADER; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, ShaderType value) +{ + switch (value) + { + case ShaderType::Vertex: + os << "GL_VERTEX_SHADER"; + break; + case ShaderType::TessControl: + os << "GL_TESS_CONTROL_SHADER_EXT"; + break; + case ShaderType::TessEvaluation: + os << "GL_TESS_EVALUATION_SHADER_EXT"; + break; + case ShaderType::Geometry: + os << "GL_GEOMETRY_SHADER_EXT"; + break; + case ShaderType::Fragment: + os << "GL_FRAGMENT_SHADER"; + break; + case ShaderType::Compute: + os << "GL_COMPUTE_SHADER"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +ShadingModel FromGLenum(GLenum from) +{ + switch (from) + { + case GL_FLAT: + return ShadingModel::Flat; + case GL_SMOOTH: + return ShadingModel::Smooth; + default: + return ShadingModel::InvalidEnum; + } +} + +GLenum ToGLenum(ShadingModel from) +{ + switch (from) + { + case ShadingModel::Flat: + return GL_FLAT; + case ShadingModel::Smooth: + return GL_SMOOTH; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, ShadingModel value) +{ + switch (value) + { + case ShadingModel::Flat: + os << "GL_FLAT"; + break; + case ShadingModel::Smooth: + os << "GL_SMOOTH"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +ShadingRate FromGLenum(GLenum from) +{ + switch (from) + { + case GL_NONE: + return ShadingRate::Undefined; + case GL_SHADING_RATE_1X1_PIXELS_QCOM: + return ShadingRate::_1x1; + case GL_SHADING_RATE_1X2_PIXELS_QCOM: + return ShadingRate::_1x2; + case GL_SHADING_RATE_2X1_PIXELS_QCOM: + return ShadingRate::_2x1; + case GL_SHADING_RATE_2X2_PIXELS_QCOM: + return ShadingRate::_2x2; + case GL_SHADING_RATE_4X2_PIXELS_QCOM: + return ShadingRate::_4x2; + case GL_SHADING_RATE_4X4_PIXELS_QCOM: + return ShadingRate::_4x4; + default: + return ShadingRate::InvalidEnum; + } +} + +GLenum ToGLenum(ShadingRate from) +{ + switch (from) + { + case ShadingRate::Undefined: + return GL_NONE; + case ShadingRate::_1x1: + return GL_SHADING_RATE_1X1_PIXELS_QCOM; + case ShadingRate::_1x2: + return GL_SHADING_RATE_1X2_PIXELS_QCOM; + case ShadingRate::_2x1: + return GL_SHADING_RATE_2X1_PIXELS_QCOM; + case ShadingRate::_2x2: + return GL_SHADING_RATE_2X2_PIXELS_QCOM; + case ShadingRate::_4x2: + return GL_SHADING_RATE_4X2_PIXELS_QCOM; + case ShadingRate::_4x4: + return GL_SHADING_RATE_4X4_PIXELS_QCOM; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, ShadingRate value) +{ + switch (value) + { + case ShadingRate::Undefined: + os << "GL_NONE"; + break; + case ShadingRate::_1x1: + os << "GL_SHADING_RATE_1X1_PIXELS_QCOM"; + break; + case ShadingRate::_1x2: + os << "GL_SHADING_RATE_1X2_PIXELS_QCOM"; + break; + case ShadingRate::_2x1: + os << "GL_SHADING_RATE_2X1_PIXELS_QCOM"; + break; + case ShadingRate::_2x2: + os << "GL_SHADING_RATE_2X2_PIXELS_QCOM"; + break; + case ShadingRate::_4x2: + os << "GL_SHADING_RATE_4X2_PIXELS_QCOM"; + break; + case ShadingRate::_4x4: + os << "GL_SHADING_RATE_4X4_PIXELS_QCOM"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +TextureCombine FromGLenum(GLenum from) +{ + switch (from) + { + case GL_ADD: + return TextureCombine::Add; + case GL_ADD_SIGNED: + return TextureCombine::AddSigned; + case GL_DOT3_RGB: + return TextureCombine::Dot3Rgb; + case GL_DOT3_RGBA: + return TextureCombine::Dot3Rgba; + case GL_INTERPOLATE: + return TextureCombine::Interpolate; + case GL_MODULATE: + return TextureCombine::Modulate; + case GL_REPLACE: + return TextureCombine::Replace; + case GL_SUBTRACT: + return TextureCombine::Subtract; + default: + return TextureCombine::InvalidEnum; + } +} + +GLenum ToGLenum(TextureCombine from) +{ + switch (from) + { + case TextureCombine::Add: + return GL_ADD; + case TextureCombine::AddSigned: + return GL_ADD_SIGNED; + case TextureCombine::Dot3Rgb: + return GL_DOT3_RGB; + case TextureCombine::Dot3Rgba: + return GL_DOT3_RGBA; + case TextureCombine::Interpolate: + return GL_INTERPOLATE; + case TextureCombine::Modulate: + return GL_MODULATE; + case TextureCombine::Replace: + return GL_REPLACE; + case TextureCombine::Subtract: + return GL_SUBTRACT; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, TextureCombine value) +{ + switch (value) + { + case TextureCombine::Add: + os << "GL_ADD"; + break; + case TextureCombine::AddSigned: + os << "GL_ADD_SIGNED"; + break; + case TextureCombine::Dot3Rgb: + os << "GL_DOT3_RGB"; + break; + case TextureCombine::Dot3Rgba: + os << "GL_DOT3_RGBA"; + break; + case TextureCombine::Interpolate: + os << "GL_INTERPOLATE"; + break; + case TextureCombine::Modulate: + os << "GL_MODULATE"; + break; + case TextureCombine::Replace: + os << "GL_REPLACE"; + break; + case TextureCombine::Subtract: + os << "GL_SUBTRACT"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +TextureEnvMode FromGLenum(GLenum from) +{ + switch (from) + { + case GL_ADD: + return TextureEnvMode::Add; + case GL_BLEND: + return TextureEnvMode::Blend; + case GL_COMBINE: + return TextureEnvMode::Combine; + case GL_DECAL: + return TextureEnvMode::Decal; + case GL_MODULATE: + return TextureEnvMode::Modulate; + case GL_REPLACE: + return TextureEnvMode::Replace; + default: + return TextureEnvMode::InvalidEnum; + } +} + +GLenum ToGLenum(TextureEnvMode from) +{ + switch (from) + { + case TextureEnvMode::Add: + return GL_ADD; + case TextureEnvMode::Blend: + return GL_BLEND; + case TextureEnvMode::Combine: + return GL_COMBINE; + case TextureEnvMode::Decal: + return GL_DECAL; + case TextureEnvMode::Modulate: + return GL_MODULATE; + case TextureEnvMode::Replace: + return GL_REPLACE; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, TextureEnvMode value) +{ + switch (value) + { + case TextureEnvMode::Add: + os << "GL_ADD"; + break; + case TextureEnvMode::Blend: + os << "GL_BLEND"; + break; + case TextureEnvMode::Combine: + os << "GL_COMBINE"; + break; + case TextureEnvMode::Decal: + os << "GL_DECAL"; + break; + case TextureEnvMode::Modulate: + os << "GL_MODULATE"; + break; + case TextureEnvMode::Replace: + os << "GL_REPLACE"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +TextureEnvParameter FromGLenum(GLenum from) +{ + switch (from) + { + case GL_TEXTURE_ENV_MODE: + return TextureEnvParameter::Mode; + case GL_TEXTURE_ENV_COLOR: + return TextureEnvParameter::Color; + case GL_COMBINE_RGB: + return TextureEnvParameter::CombineRgb; + case GL_COMBINE_ALPHA: + return TextureEnvParameter::CombineAlpha; + case GL_RGB_SCALE: + return TextureEnvParameter::RgbScale; + case GL_ALPHA_SCALE: + return TextureEnvParameter::AlphaScale; + case GL_SRC0_RGB: + return TextureEnvParameter::Src0Rgb; + case GL_SRC1_RGB: + return TextureEnvParameter::Src1Rgb; + case GL_SRC2_RGB: + return TextureEnvParameter::Src2Rgb; + case GL_SRC0_ALPHA: + return TextureEnvParameter::Src0Alpha; + case GL_SRC1_ALPHA: + return TextureEnvParameter::Src1Alpha; + case GL_SRC2_ALPHA: + return TextureEnvParameter::Src2Alpha; + case GL_OPERAND0_RGB: + return TextureEnvParameter::Op0Rgb; + case GL_OPERAND1_RGB: + return TextureEnvParameter::Op1Rgb; + case GL_OPERAND2_RGB: + return TextureEnvParameter::Op2Rgb; + case GL_OPERAND0_ALPHA: + return TextureEnvParameter::Op0Alpha; + case GL_OPERAND1_ALPHA: + return TextureEnvParameter::Op1Alpha; + case GL_OPERAND2_ALPHA: + return TextureEnvParameter::Op2Alpha; + case GL_COORD_REPLACE_OES: + return TextureEnvParameter::PointCoordReplace; + default: + return TextureEnvParameter::InvalidEnum; + } +} + +GLenum ToGLenum(TextureEnvParameter from) +{ + switch (from) + { + case TextureEnvParameter::Mode: + return GL_TEXTURE_ENV_MODE; + case TextureEnvParameter::Color: + return GL_TEXTURE_ENV_COLOR; + case TextureEnvParameter::CombineRgb: + return GL_COMBINE_RGB; + case TextureEnvParameter::CombineAlpha: + return GL_COMBINE_ALPHA; + case TextureEnvParameter::RgbScale: + return GL_RGB_SCALE; + case TextureEnvParameter::AlphaScale: + return GL_ALPHA_SCALE; + case TextureEnvParameter::Src0Rgb: + return GL_SRC0_RGB; + case TextureEnvParameter::Src1Rgb: + return GL_SRC1_RGB; + case TextureEnvParameter::Src2Rgb: + return GL_SRC2_RGB; + case TextureEnvParameter::Src0Alpha: + return GL_SRC0_ALPHA; + case TextureEnvParameter::Src1Alpha: + return GL_SRC1_ALPHA; + case TextureEnvParameter::Src2Alpha: + return GL_SRC2_ALPHA; + case TextureEnvParameter::Op0Rgb: + return GL_OPERAND0_RGB; + case TextureEnvParameter::Op1Rgb: + return GL_OPERAND1_RGB; + case TextureEnvParameter::Op2Rgb: + return GL_OPERAND2_RGB; + case TextureEnvParameter::Op0Alpha: + return GL_OPERAND0_ALPHA; + case TextureEnvParameter::Op1Alpha: + return GL_OPERAND1_ALPHA; + case TextureEnvParameter::Op2Alpha: + return GL_OPERAND2_ALPHA; + case TextureEnvParameter::PointCoordReplace: + return GL_COORD_REPLACE_OES; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, TextureEnvParameter value) +{ + switch (value) + { + case TextureEnvParameter::Mode: + os << "GL_TEXTURE_ENV_MODE"; + break; + case TextureEnvParameter::Color: + os << "GL_TEXTURE_ENV_COLOR"; + break; + case TextureEnvParameter::CombineRgb: + os << "GL_COMBINE_RGB"; + break; + case TextureEnvParameter::CombineAlpha: + os << "GL_COMBINE_ALPHA"; + break; + case TextureEnvParameter::RgbScale: + os << "GL_RGB_SCALE"; + break; + case TextureEnvParameter::AlphaScale: + os << "GL_ALPHA_SCALE"; + break; + case TextureEnvParameter::Src0Rgb: + os << "GL_SRC0_RGB"; + break; + case TextureEnvParameter::Src1Rgb: + os << "GL_SRC1_RGB"; + break; + case TextureEnvParameter::Src2Rgb: + os << "GL_SRC2_RGB"; + break; + case TextureEnvParameter::Src0Alpha: + os << "GL_SRC0_ALPHA"; + break; + case TextureEnvParameter::Src1Alpha: + os << "GL_SRC1_ALPHA"; + break; + case TextureEnvParameter::Src2Alpha: + os << "GL_SRC2_ALPHA"; + break; + case TextureEnvParameter::Op0Rgb: + os << "GL_OPERAND0_RGB"; + break; + case TextureEnvParameter::Op1Rgb: + os << "GL_OPERAND1_RGB"; + break; + case TextureEnvParameter::Op2Rgb: + os << "GL_OPERAND2_RGB"; + break; + case TextureEnvParameter::Op0Alpha: + os << "GL_OPERAND0_ALPHA"; + break; + case TextureEnvParameter::Op1Alpha: + os << "GL_OPERAND1_ALPHA"; + break; + case TextureEnvParameter::Op2Alpha: + os << "GL_OPERAND2_ALPHA"; + break; + case TextureEnvParameter::PointCoordReplace: + os << "GL_COORD_REPLACE_OES"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +TextureEnvTarget FromGLenum(GLenum from) +{ + switch (from) + { + case GL_TEXTURE_ENV: + return TextureEnvTarget::Env; + case GL_POINT_SPRITE_OES: + return TextureEnvTarget::PointSprite; + default: + return TextureEnvTarget::InvalidEnum; + } +} + +GLenum ToGLenum(TextureEnvTarget from) +{ + switch (from) + { + case TextureEnvTarget::Env: + return GL_TEXTURE_ENV; + case TextureEnvTarget::PointSprite: + return GL_POINT_SPRITE_OES; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, TextureEnvTarget value) +{ + switch (value) + { + case TextureEnvTarget::Env: + os << "GL_TEXTURE_ENV"; + break; + case TextureEnvTarget::PointSprite: + os << "GL_POINT_SPRITE_OES"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +TextureOp FromGLenum(GLenum from) +{ + switch (from) + { + case GL_ONE_MINUS_SRC_ALPHA: + return TextureOp::OneMinusSrcAlpha; + case GL_ONE_MINUS_SRC_COLOR: + return TextureOp::OneMinusSrcColor; + case GL_SRC_ALPHA: + return TextureOp::SrcAlpha; + case GL_SRC_COLOR: + return TextureOp::SrcColor; + default: + return TextureOp::InvalidEnum; + } +} + +GLenum ToGLenum(TextureOp from) +{ + switch (from) + { + case TextureOp::OneMinusSrcAlpha: + return GL_ONE_MINUS_SRC_ALPHA; + case TextureOp::OneMinusSrcColor: + return GL_ONE_MINUS_SRC_COLOR; + case TextureOp::SrcAlpha: + return GL_SRC_ALPHA; + case TextureOp::SrcColor: + return GL_SRC_COLOR; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, TextureOp value) +{ + switch (value) + { + case TextureOp::OneMinusSrcAlpha: + os << "GL_ONE_MINUS_SRC_ALPHA"; + break; + case TextureOp::OneMinusSrcColor: + os << "GL_ONE_MINUS_SRC_COLOR"; + break; + case TextureOp::SrcAlpha: + os << "GL_SRC_ALPHA"; + break; + case TextureOp::SrcColor: + os << "GL_SRC_COLOR"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +TextureSrc FromGLenum(GLenum from) +{ + switch (from) + { + case GL_CONSTANT: + return TextureSrc::Constant; + case GL_PREVIOUS: + return TextureSrc::Previous; + case GL_PRIMARY_COLOR: + return TextureSrc::PrimaryColor; + case GL_TEXTURE: + return TextureSrc::Texture; + default: + return TextureSrc::InvalidEnum; + } +} + +GLenum ToGLenum(TextureSrc from) +{ + switch (from) + { + case TextureSrc::Constant: + return GL_CONSTANT; + case TextureSrc::Previous: + return GL_PREVIOUS; + case TextureSrc::PrimaryColor: + return GL_PRIMARY_COLOR; + case TextureSrc::Texture: + return GL_TEXTURE; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, TextureSrc value) +{ + switch (value) + { + case TextureSrc::Constant: + os << "GL_CONSTANT"; + break; + case TextureSrc::Previous: + os << "GL_PREVIOUS"; + break; + case TextureSrc::PrimaryColor: + os << "GL_PRIMARY_COLOR"; + break; + case TextureSrc::Texture: + os << "GL_TEXTURE"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +TextureTarget FromGLenum(GLenum from) +{ + switch (from) + { + case GL_TEXTURE_2D: + return TextureTarget::_2D; + case GL_TEXTURE_2D_ARRAY: + return TextureTarget::_2DArray; + case GL_TEXTURE_2D_MULTISAMPLE: + return TextureTarget::_2DMultisample; + case GL_TEXTURE_2D_MULTISAMPLE_ARRAY_OES: + return TextureTarget::_2DMultisampleArray; + case GL_TEXTURE_3D: + return TextureTarget::_3D; + case GL_TEXTURE_EXTERNAL_OES: + return TextureTarget::External; + case GL_TEXTURE_RECTANGLE_ANGLE: + return TextureTarget::Rectangle; + case GL_TEXTURE_CUBE_MAP_POSITIVE_X: + return TextureTarget::CubeMapPositiveX; + case GL_TEXTURE_CUBE_MAP_NEGATIVE_X: + return TextureTarget::CubeMapNegativeX; + case GL_TEXTURE_CUBE_MAP_POSITIVE_Y: + return TextureTarget::CubeMapPositiveY; + case GL_TEXTURE_CUBE_MAP_NEGATIVE_Y: + return TextureTarget::CubeMapNegativeY; + case GL_TEXTURE_CUBE_MAP_POSITIVE_Z: + return TextureTarget::CubeMapPositiveZ; + case GL_TEXTURE_CUBE_MAP_NEGATIVE_Z: + return TextureTarget::CubeMapNegativeZ; + case GL_TEXTURE_CUBE_MAP_ARRAY: + return TextureTarget::CubeMapArray; + case GL_TEXTURE_VIDEO_IMAGE_WEBGL: + return TextureTarget::VideoImage; + case GL_TEXTURE_BUFFER: + return TextureTarget::Buffer; + default: + return TextureTarget::InvalidEnum; + } +} + +GLenum ToGLenum(TextureTarget from) +{ + switch (from) + { + case TextureTarget::_2D: + return GL_TEXTURE_2D; + case TextureTarget::_2DArray: + return GL_TEXTURE_2D_ARRAY; + case TextureTarget::_2DMultisample: + return GL_TEXTURE_2D_MULTISAMPLE; + case TextureTarget::_2DMultisampleArray: + return GL_TEXTURE_2D_MULTISAMPLE_ARRAY_OES; + case TextureTarget::_3D: + return GL_TEXTURE_3D; + case TextureTarget::External: + return GL_TEXTURE_EXTERNAL_OES; + case TextureTarget::Rectangle: + return GL_TEXTURE_RECTANGLE_ANGLE; + case TextureTarget::CubeMapPositiveX: + return GL_TEXTURE_CUBE_MAP_POSITIVE_X; + case TextureTarget::CubeMapNegativeX: + return GL_TEXTURE_CUBE_MAP_NEGATIVE_X; + case TextureTarget::CubeMapPositiveY: + return GL_TEXTURE_CUBE_MAP_POSITIVE_Y; + case TextureTarget::CubeMapNegativeY: + return GL_TEXTURE_CUBE_MAP_NEGATIVE_Y; + case TextureTarget::CubeMapPositiveZ: + return GL_TEXTURE_CUBE_MAP_POSITIVE_Z; + case TextureTarget::CubeMapNegativeZ: + return GL_TEXTURE_CUBE_MAP_NEGATIVE_Z; + case TextureTarget::CubeMapArray: + return GL_TEXTURE_CUBE_MAP_ARRAY; + case TextureTarget::VideoImage: + return GL_TEXTURE_VIDEO_IMAGE_WEBGL; + case TextureTarget::Buffer: + return GL_TEXTURE_BUFFER; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, TextureTarget value) +{ + switch (value) + { + case TextureTarget::_2D: + os << "GL_TEXTURE_2D"; + break; + case TextureTarget::_2DArray: + os << "GL_TEXTURE_2D_ARRAY"; + break; + case TextureTarget::_2DMultisample: + os << "GL_TEXTURE_2D_MULTISAMPLE"; + break; + case TextureTarget::_2DMultisampleArray: + os << "GL_TEXTURE_2D_MULTISAMPLE_ARRAY_OES"; + break; + case TextureTarget::_3D: + os << "GL_TEXTURE_3D"; + break; + case TextureTarget::External: + os << "GL_TEXTURE_EXTERNAL_OES"; + break; + case TextureTarget::Rectangle: + os << "GL_TEXTURE_RECTANGLE_ANGLE"; + break; + case TextureTarget::CubeMapPositiveX: + os << "GL_TEXTURE_CUBE_MAP_POSITIVE_X"; + break; + case TextureTarget::CubeMapNegativeX: + os << "GL_TEXTURE_CUBE_MAP_NEGATIVE_X"; + break; + case TextureTarget::CubeMapPositiveY: + os << "GL_TEXTURE_CUBE_MAP_POSITIVE_Y"; + break; + case TextureTarget::CubeMapNegativeY: + os << "GL_TEXTURE_CUBE_MAP_NEGATIVE_Y"; + break; + case TextureTarget::CubeMapPositiveZ: + os << "GL_TEXTURE_CUBE_MAP_POSITIVE_Z"; + break; + case TextureTarget::CubeMapNegativeZ: + os << "GL_TEXTURE_CUBE_MAP_NEGATIVE_Z"; + break; + case TextureTarget::CubeMapArray: + os << "GL_TEXTURE_CUBE_MAP_ARRAY"; + break; + case TextureTarget::VideoImage: + os << "GL_TEXTURE_VIDEO_IMAGE_WEBGL"; + break; + case TextureTarget::Buffer: + os << "GL_TEXTURE_BUFFER"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +TextureType FromGLenum(GLenum from) +{ + switch (from) + { + case GL_TEXTURE_2D: + return TextureType::_2D; + case GL_TEXTURE_2D_ARRAY: + return TextureType::_2DArray; + case GL_TEXTURE_2D_MULTISAMPLE: + return TextureType::_2DMultisample; + case GL_TEXTURE_2D_MULTISAMPLE_ARRAY_OES: + return TextureType::_2DMultisampleArray; + case GL_TEXTURE_3D: + return TextureType::_3D; + case GL_TEXTURE_EXTERNAL_OES: + return TextureType::External; + case GL_TEXTURE_RECTANGLE_ANGLE: + return TextureType::Rectangle; + case GL_TEXTURE_CUBE_MAP: + return TextureType::CubeMap; + case GL_TEXTURE_CUBE_MAP_ARRAY: + return TextureType::CubeMapArray; + case GL_TEXTURE_VIDEO_IMAGE_WEBGL: + return TextureType::VideoImage; + case GL_TEXTURE_BUFFER: + return TextureType::Buffer; + default: + return TextureType::InvalidEnum; + } +} + +GLenum ToGLenum(TextureType from) +{ + switch (from) + { + case TextureType::_2D: + return GL_TEXTURE_2D; + case TextureType::_2DArray: + return GL_TEXTURE_2D_ARRAY; + case TextureType::_2DMultisample: + return GL_TEXTURE_2D_MULTISAMPLE; + case TextureType::_2DMultisampleArray: + return GL_TEXTURE_2D_MULTISAMPLE_ARRAY_OES; + case TextureType::_3D: + return GL_TEXTURE_3D; + case TextureType::External: + return GL_TEXTURE_EXTERNAL_OES; + case TextureType::Rectangle: + return GL_TEXTURE_RECTANGLE_ANGLE; + case TextureType::CubeMap: + return GL_TEXTURE_CUBE_MAP; + case TextureType::CubeMapArray: + return GL_TEXTURE_CUBE_MAP_ARRAY; + case TextureType::VideoImage: + return GL_TEXTURE_VIDEO_IMAGE_WEBGL; + case TextureType::Buffer: + return GL_TEXTURE_BUFFER; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, TextureType value) +{ + switch (value) + { + case TextureType::_2D: + os << "GL_TEXTURE_2D"; + break; + case TextureType::_2DArray: + os << "GL_TEXTURE_2D_ARRAY"; + break; + case TextureType::_2DMultisample: + os << "GL_TEXTURE_2D_MULTISAMPLE"; + break; + case TextureType::_2DMultisampleArray: + os << "GL_TEXTURE_2D_MULTISAMPLE_ARRAY_OES"; + break; + case TextureType::_3D: + os << "GL_TEXTURE_3D"; + break; + case TextureType::External: + os << "GL_TEXTURE_EXTERNAL_OES"; + break; + case TextureType::Rectangle: + os << "GL_TEXTURE_RECTANGLE_ANGLE"; + break; + case TextureType::CubeMap: + os << "GL_TEXTURE_CUBE_MAP"; + break; + case TextureType::CubeMapArray: + os << "GL_TEXTURE_CUBE_MAP_ARRAY"; + break; + case TextureType::VideoImage: + os << "GL_TEXTURE_VIDEO_IMAGE_WEBGL"; + break; + case TextureType::Buffer: + os << "GL_TEXTURE_BUFFER"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +VertexArrayType FromGLenum(GLenum from) +{ + switch (from) + { + case GL_COLOR_ARRAY: + return VertexArrayType::Color; + case GL_NORMAL_ARRAY: + return VertexArrayType::Normal; + case GL_POINT_SIZE_ARRAY_OES: + return VertexArrayType::PointSize; + case GL_TEXTURE_COORD_ARRAY: + return VertexArrayType::TextureCoord; + case GL_VERTEX_ARRAY: + return VertexArrayType::Vertex; + default: + return VertexArrayType::InvalidEnum; + } +} + +GLenum ToGLenum(VertexArrayType from) +{ + switch (from) + { + case VertexArrayType::Color: + return GL_COLOR_ARRAY; + case VertexArrayType::Normal: + return GL_NORMAL_ARRAY; + case VertexArrayType::PointSize: + return GL_POINT_SIZE_ARRAY_OES; + case VertexArrayType::TextureCoord: + return GL_TEXTURE_COORD_ARRAY; + case VertexArrayType::Vertex: + return GL_VERTEX_ARRAY; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, VertexArrayType value) +{ + switch (value) + { + case VertexArrayType::Color: + os << "GL_COLOR_ARRAY"; + break; + case VertexArrayType::Normal: + os << "GL_NORMAL_ARRAY"; + break; + case VertexArrayType::PointSize: + os << "GL_POINT_SIZE_ARRAY_OES"; + break; + case VertexArrayType::TextureCoord: + os << "GL_TEXTURE_COORD_ARRAY"; + break; + case VertexArrayType::Vertex: + os << "GL_VERTEX_ARRAY"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +template <> +WrapMode FromGLenum(GLenum from) +{ + switch (from) + { + case GL_CLAMP_TO_EDGE: + return WrapMode::ClampToEdge; + case GL_CLAMP_TO_BORDER: + return WrapMode::ClampToBorder; + case GL_MIRRORED_REPEAT: + return WrapMode::MirroredRepeat; + case GL_REPEAT: + return WrapMode::Repeat; + default: + return WrapMode::InvalidEnum; + } +} + +GLenum ToGLenum(WrapMode from) +{ + switch (from) + { + case WrapMode::ClampToEdge: + return GL_CLAMP_TO_EDGE; + case WrapMode::ClampToBorder: + return GL_CLAMP_TO_BORDER; + case WrapMode::MirroredRepeat: + return GL_MIRRORED_REPEAT; + case WrapMode::Repeat: + return GL_REPEAT; + default: + UNREACHABLE(); + return 0; + } +} + +std::ostream &operator<<(std::ostream &os, WrapMode value) +{ + switch (value) + { + case WrapMode::ClampToEdge: + os << "GL_CLAMP_TO_EDGE"; + break; + case WrapMode::ClampToBorder: + os << "GL_CLAMP_TO_BORDER"; + break; + case WrapMode::MirroredRepeat: + os << "GL_MIRRORED_REPEAT"; + break; + case WrapMode::Repeat: + os << "GL_REPEAT"; + break; + default: + os << "GL_INVALID_ENUM"; + break; + } + return os; +} + +} // namespace gl diff --git a/gfx/angle/checkout/src/common/PackedGLEnums_autogen.h b/gfx/angle/checkout/src/common/PackedGLEnums_autogen.h new file mode 100644 index 0000000000..452dca344e --- /dev/null +++ b/gfx/angle/checkout/src/common/PackedGLEnums_autogen.h @@ -0,0 +1,610 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by gen_packed_gl_enums.py using data from packed_gl_enums.json. +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// PackedGLEnums_autogen.h: +// Declares ANGLE-specific enums classes for GLenums and functions operating +// on them. + +#ifndef COMMON_PACKEDGLENUMS_AUTOGEN_H_ +#define COMMON_PACKEDGLENUMS_AUTOGEN_H_ + +#include + +#include +#include + +namespace gl +{ + +template +Enum FromGLenum(GLenum from); + +enum class AlphaTestFunc : uint8_t +{ + AlwaysPass = 0, + Equal = 1, + Gequal = 2, + Greater = 3, + Lequal = 4, + Less = 5, + Never = 6, + NotEqual = 7, + + InvalidEnum = 8, + EnumCount = 8, +}; + +template <> +AlphaTestFunc FromGLenum(GLenum from); +GLenum ToGLenum(AlphaTestFunc from); +std::ostream &operator<<(std::ostream &os, AlphaTestFunc value); + +enum class BufferBinding : uint8_t +{ + Array = 0, + AtomicCounter = 1, + CopyRead = 2, + CopyWrite = 3, + DispatchIndirect = 4, + DrawIndirect = 5, + ElementArray = 6, + PixelPack = 7, + PixelUnpack = 8, + ShaderStorage = 9, + Texture = 10, + TransformFeedback = 11, + Uniform = 12, + + InvalidEnum = 13, + EnumCount = 13, +}; + +template <> +BufferBinding FromGLenum(GLenum from); +GLenum ToGLenum(BufferBinding from); +std::ostream &operator<<(std::ostream &os, BufferBinding value); + +enum class BufferUsage : uint8_t +{ + DynamicCopy = 0, + DynamicDraw = 1, + DynamicRead = 2, + StaticCopy = 3, + StaticDraw = 4, + StaticRead = 5, + StreamCopy = 6, + StreamDraw = 7, + StreamRead = 8, + + InvalidEnum = 9, + EnumCount = 9, +}; + +template <> +BufferUsage FromGLenum(GLenum from); +GLenum ToGLenum(BufferUsage from); +std::ostream &operator<<(std::ostream &os, BufferUsage value); + +enum class ClientVertexArrayType : uint8_t +{ + Color = 0, + Normal = 1, + PointSize = 2, + TextureCoord = 3, + Vertex = 4, + + InvalidEnum = 5, + EnumCount = 5, +}; + +template <> +ClientVertexArrayType FromGLenum(GLenum from); +GLenum ToGLenum(ClientVertexArrayType from); +std::ostream &operator<<(std::ostream &os, ClientVertexArrayType value); + +enum class CullFaceMode : uint8_t +{ + Back = 0, + Front = 1, + FrontAndBack = 2, + + InvalidEnum = 3, + EnumCount = 3, +}; + +template <> +CullFaceMode FromGLenum(GLenum from); +GLenum ToGLenum(CullFaceMode from); +std::ostream &operator<<(std::ostream &os, CullFaceMode value); + +enum class FilterMode : uint8_t +{ + Nearest = 0, + Linear = 1, + NearestMipmapNearest = 2, + NearestMipmapLinear = 3, + LinearMipmapLinear = 4, + + InvalidEnum = 5, + EnumCount = 5, +}; + +template <> +FilterMode FromGLenum(GLenum from); +GLenum ToGLenum(FilterMode from); +std::ostream &operator<<(std::ostream &os, FilterMode value); + +enum class FogMode : uint8_t +{ + Exp = 0, + Exp2 = 1, + Linear = 2, + + InvalidEnum = 3, + EnumCount = 3, +}; + +template <> +FogMode FromGLenum(GLenum from); +GLenum ToGLenum(FogMode from); +std::ostream &operator<<(std::ostream &os, FogMode value); + +enum class GraphicsResetStatus : uint8_t +{ + NoError = 0, + GuiltyContextReset = 1, + InnocentContextReset = 2, + UnknownContextReset = 3, + PurgedContextResetNV = 4, + + InvalidEnum = 5, + EnumCount = 5, +}; + +template <> +GraphicsResetStatus FromGLenum(GLenum from); +GLenum ToGLenum(GraphicsResetStatus from); +std::ostream &operator<<(std::ostream &os, GraphicsResetStatus value); + +enum class HandleType : uint8_t +{ + OpaqueFd = 0, + ZirconVmo = 1, + ZirconEvent = 2, + + InvalidEnum = 3, + EnumCount = 3, +}; + +template <> +HandleType FromGLenum(GLenum from); +GLenum ToGLenum(HandleType from); +std::ostream &operator<<(std::ostream &os, HandleType value); + +enum class HintSetting : uint8_t +{ + DontCare = 0, + Fastest = 1, + Nicest = 2, + + InvalidEnum = 3, + EnumCount = 3, +}; + +template <> +HintSetting FromGLenum(GLenum from); +GLenum ToGLenum(HintSetting from); +std::ostream &operator<<(std::ostream &os, HintSetting value); + +enum class ImageLayout : uint8_t +{ + Undefined = 0, + General = 1, + ColorAttachment = 2, + DepthStencilAttachment = 3, + DepthStencilReadOnlyAttachment = 4, + ShaderReadOnly = 5, + TransferSrc = 6, + TransferDst = 7, + DepthReadOnlyStencilAttachment = 8, + DepthAttachmentStencilReadOnly = 9, + + InvalidEnum = 10, + EnumCount = 10, +}; + +template <> +ImageLayout FromGLenum(GLenum from); +GLenum ToGLenum(ImageLayout from); +std::ostream &operator<<(std::ostream &os, ImageLayout value); + +enum class LightParameter : uint8_t +{ + Ambient = 0, + AmbientAndDiffuse = 1, + ConstantAttenuation = 2, + Diffuse = 3, + LinearAttenuation = 4, + Position = 5, + QuadraticAttenuation = 6, + Specular = 7, + SpotCutoff = 8, + SpotDirection = 9, + SpotExponent = 10, + + InvalidEnum = 11, + EnumCount = 11, +}; + +template <> +LightParameter FromGLenum(GLenum from); +GLenum ToGLenum(LightParameter from); +std::ostream &operator<<(std::ostream &os, LightParameter value); + +enum class LogicalOperation : uint8_t +{ + And = 0, + AndInverted = 1, + AndReverse = 2, + Clear = 3, + Copy = 4, + CopyInverted = 5, + Equiv = 6, + Invert = 7, + Nand = 8, + Noop = 9, + Nor = 10, + Or = 11, + OrInverted = 12, + OrReverse = 13, + Set = 14, + Xor = 15, + + InvalidEnum = 16, + EnumCount = 16, +}; + +template <> +LogicalOperation FromGLenum(GLenum from); +GLenum ToGLenum(LogicalOperation from); +std::ostream &operator<<(std::ostream &os, LogicalOperation value); + +enum class MaterialParameter : uint8_t +{ + Ambient = 0, + AmbientAndDiffuse = 1, + Diffuse = 2, + Emission = 3, + Shininess = 4, + Specular = 5, + + InvalidEnum = 6, + EnumCount = 6, +}; + +template <> +MaterialParameter FromGLenum(GLenum from); +GLenum ToGLenum(MaterialParameter from); +std::ostream &operator<<(std::ostream &os, MaterialParameter value); + +enum class MatrixType : uint8_t +{ + Modelview = 0, + Projection = 1, + Texture = 2, + + InvalidEnum = 3, + EnumCount = 3, +}; + +template <> +MatrixType FromGLenum(GLenum from); +GLenum ToGLenum(MatrixType from); +std::ostream &operator<<(std::ostream &os, MatrixType value); + +enum class PointParameter : uint8_t +{ + PointSizeMin = 0, + PointSizeMax = 1, + PointFadeThresholdSize = 2, + PointDistanceAttenuation = 3, + + InvalidEnum = 4, + EnumCount = 4, +}; + +template <> +PointParameter FromGLenum(GLenum from); +GLenum ToGLenum(PointParameter from); +std::ostream &operator<<(std::ostream &os, PointParameter value); + +enum class ProvokingVertexConvention : uint8_t +{ + FirstVertexConvention = 0, + LastVertexConvention = 1, + + InvalidEnum = 2, + EnumCount = 2, +}; + +template <> +ProvokingVertexConvention FromGLenum(GLenum from); +GLenum ToGLenum(ProvokingVertexConvention from); +std::ostream &operator<<(std::ostream &os, ProvokingVertexConvention value); + +enum class QueryType : uint8_t +{ + AnySamples = 0, + AnySamplesConservative = 1, + CommandsCompleted = 2, + PrimitivesGenerated = 3, + TimeElapsed = 4, + Timestamp = 5, + TransformFeedbackPrimitivesWritten = 6, + + InvalidEnum = 7, + EnumCount = 7, +}; + +template <> +QueryType FromGLenum(GLenum from); +GLenum ToGLenum(QueryType from); +std::ostream &operator<<(std::ostream &os, QueryType value); + +enum class ShaderType : uint8_t +{ + Vertex = 0, + TessControl = 1, + TessEvaluation = 2, + Geometry = 3, + Fragment = 4, + Compute = 5, + + InvalidEnum = 6, + EnumCount = 6, +}; + +template <> +ShaderType FromGLenum(GLenum from); +GLenum ToGLenum(ShaderType from); +std::ostream &operator<<(std::ostream &os, ShaderType value); + +enum class ShadingModel : uint8_t +{ + Flat = 0, + Smooth = 1, + + InvalidEnum = 2, + EnumCount = 2, +}; + +template <> +ShadingModel FromGLenum(GLenum from); +GLenum ToGLenum(ShadingModel from); +std::ostream &operator<<(std::ostream &os, ShadingModel value); + +enum class ShadingRate : uint8_t +{ + Undefined = 0, + _1x1 = 1, + _1x2 = 2, + _2x1 = 3, + _2x2 = 4, + _4x2 = 5, + _4x4 = 6, + + InvalidEnum = 7, + EnumCount = 7, +}; + +template <> +ShadingRate FromGLenum(GLenum from); +GLenum ToGLenum(ShadingRate from); +std::ostream &operator<<(std::ostream &os, ShadingRate value); + +enum class TextureCombine : uint8_t +{ + Add = 0, + AddSigned = 1, + Dot3Rgb = 2, + Dot3Rgba = 3, + Interpolate = 4, + Modulate = 5, + Replace = 6, + Subtract = 7, + + InvalidEnum = 8, + EnumCount = 8, +}; + +template <> +TextureCombine FromGLenum(GLenum from); +GLenum ToGLenum(TextureCombine from); +std::ostream &operator<<(std::ostream &os, TextureCombine value); + +enum class TextureEnvMode : uint8_t +{ + Add = 0, + Blend = 1, + Combine = 2, + Decal = 3, + Modulate = 4, + Replace = 5, + + InvalidEnum = 6, + EnumCount = 6, +}; + +template <> +TextureEnvMode FromGLenum(GLenum from); +GLenum ToGLenum(TextureEnvMode from); +std::ostream &operator<<(std::ostream &os, TextureEnvMode value); + +enum class TextureEnvParameter : uint8_t +{ + Mode = 0, + Color = 1, + CombineRgb = 2, + CombineAlpha = 3, + RgbScale = 4, + AlphaScale = 5, + Src0Rgb = 6, + Src1Rgb = 7, + Src2Rgb = 8, + Src0Alpha = 9, + Src1Alpha = 10, + Src2Alpha = 11, + Op0Rgb = 12, + Op1Rgb = 13, + Op2Rgb = 14, + Op0Alpha = 15, + Op1Alpha = 16, + Op2Alpha = 17, + PointCoordReplace = 18, + + InvalidEnum = 19, + EnumCount = 19, +}; + +template <> +TextureEnvParameter FromGLenum(GLenum from); +GLenum ToGLenum(TextureEnvParameter from); +std::ostream &operator<<(std::ostream &os, TextureEnvParameter value); + +enum class TextureEnvTarget : uint8_t +{ + Env = 0, + PointSprite = 1, + + InvalidEnum = 2, + EnumCount = 2, +}; + +template <> +TextureEnvTarget FromGLenum(GLenum from); +GLenum ToGLenum(TextureEnvTarget from); +std::ostream &operator<<(std::ostream &os, TextureEnvTarget value); + +enum class TextureOp : uint8_t +{ + OneMinusSrcAlpha = 0, + OneMinusSrcColor = 1, + SrcAlpha = 2, + SrcColor = 3, + + InvalidEnum = 4, + EnumCount = 4, +}; + +template <> +TextureOp FromGLenum(GLenum from); +GLenum ToGLenum(TextureOp from); +std::ostream &operator<<(std::ostream &os, TextureOp value); + +enum class TextureSrc : uint8_t +{ + Constant = 0, + Previous = 1, + PrimaryColor = 2, + Texture = 3, + + InvalidEnum = 4, + EnumCount = 4, +}; + +template <> +TextureSrc FromGLenum(GLenum from); +GLenum ToGLenum(TextureSrc from); +std::ostream &operator<<(std::ostream &os, TextureSrc value); + +enum class TextureTarget : uint8_t +{ + _2D = 0, + _2DArray = 1, + _2DMultisample = 2, + _2DMultisampleArray = 3, + _3D = 4, + External = 5, + Rectangle = 6, + CubeMapPositiveX = 7, + CubeMapNegativeX = 8, + CubeMapPositiveY = 9, + CubeMapNegativeY = 10, + CubeMapPositiveZ = 11, + CubeMapNegativeZ = 12, + CubeMapArray = 13, + VideoImage = 14, + Buffer = 15, + + InvalidEnum = 16, + EnumCount = 16, +}; + +template <> +TextureTarget FromGLenum(GLenum from); +GLenum ToGLenum(TextureTarget from); +std::ostream &operator<<(std::ostream &os, TextureTarget value); + +enum class TextureType : uint8_t +{ + _2D = 0, + _2DArray = 1, + _2DMultisample = 2, + _2DMultisampleArray = 3, + _3D = 4, + External = 5, + Rectangle = 6, + CubeMap = 7, + CubeMapArray = 8, + VideoImage = 9, + Buffer = 10, + + InvalidEnum = 11, + EnumCount = 11, +}; + +template <> +TextureType FromGLenum(GLenum from); +GLenum ToGLenum(TextureType from); +std::ostream &operator<<(std::ostream &os, TextureType value); + +enum class VertexArrayType : uint8_t +{ + Color = 0, + Normal = 1, + PointSize = 2, + TextureCoord = 3, + Vertex = 4, + + InvalidEnum = 5, + EnumCount = 5, +}; + +template <> +VertexArrayType FromGLenum(GLenum from); +GLenum ToGLenum(VertexArrayType from); +std::ostream &operator<<(std::ostream &os, VertexArrayType value); + +enum class WrapMode : uint8_t +{ + ClampToEdge = 0, + ClampToBorder = 1, + MirroredRepeat = 2, + Repeat = 3, + + InvalidEnum = 4, + EnumCount = 4, +}; + +template <> +WrapMode FromGLenum(GLenum from); +GLenum ToGLenum(WrapMode from); +std::ostream &operator<<(std::ostream &os, WrapMode value); + +} // namespace gl + +#endif // COMMON_PACKEDGLENUMS_AUTOGEN_H_ diff --git a/gfx/angle/checkout/src/common/PoolAlloc.cpp b/gfx/angle/checkout/src/common/PoolAlloc.cpp new file mode 100644 index 0000000000..eef033ca04 --- /dev/null +++ b/gfx/angle/checkout/src/common/PoolAlloc.cpp @@ -0,0 +1,487 @@ +// +// Copyright 2019 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// PoolAlloc.cpp: +// Implements the class methods for PoolAllocator and Allocation classes. +// + +#include "common/PoolAlloc.h" + +#include +#include +#include + +#include "common/angleutils.h" +#include "common/debug.h" +#include "common/mathutil.h" +#include "common/platform.h" +#include "common/tls.h" + +namespace angle +{ +// If we are using guard blocks, we must track each individual allocation. If we aren't using guard +// blocks, these never get instantiated, so won't have any impact. + +class Allocation +{ + public: + Allocation(size_t size, unsigned char *mem, Allocation *prev = 0) + : mSize(size), mMem(mem), mPrevAlloc(prev) + { + // Allocations are bracketed: + // + // [allocationHeader][initialGuardBlock][userData][finalGuardBlock] + // + // This would be cleaner with if (kGuardBlockSize)..., but that makes the compiler print + // warnings about 0 length memsets, even with the if() protecting them. +#if defined(ANGLE_POOL_ALLOC_GUARD_BLOCKS) + memset(preGuard(), kGuardBlockBeginVal, kGuardBlockSize); + memset(data(), kUserDataFill, mSize); + memset(postGuard(), kGuardBlockEndVal, kGuardBlockSize); +#endif + } + + void checkAllocList() const; + + static size_t AlignedHeaderSize(uint8_t *allocationBasePtr, size_t alignment) + { + // Make sure that the data offset after the header is aligned to the given alignment. + size_t base = reinterpret_cast(allocationBasePtr); + return rx::roundUpPow2(base + kGuardBlockSize + HeaderSize(), alignment) - base; + } + + // Return total size needed to accommodate user buffer of 'size', + // plus our tracking data and any necessary alignments. + static size_t AllocationSize(uint8_t *allocationBasePtr, + size_t size, + size_t alignment, + size_t *preAllocationPaddingOut) + { + // The allocation will be laid out as such: + // + // Aligned to |alignment| + // ^ + // preAllocationPaddingOut | + // ___^___ | + // / \ | + // [header][guard][data][guard] + // \___________ __________/ + // V + // dataOffset + // + // Note that alignment is at least as much as a pointer alignment, so the pointers in the + // header are also necessarily aligned appropriately. + // + size_t dataOffset = AlignedHeaderSize(allocationBasePtr, alignment); + *preAllocationPaddingOut = dataOffset - HeaderSize() - kGuardBlockSize; + + return dataOffset + size + kGuardBlockSize; + } + + // Given memory pointing to |header|, returns |data|. + static uint8_t *GetDataPointer(uint8_t *memory, size_t alignment) + { + uint8_t *alignedPtr = memory + kGuardBlockSize + HeaderSize(); + + // |memory| must be aligned already such that user data is aligned to |alignment|. + ASSERT((reinterpret_cast(alignedPtr) & (alignment - 1)) == 0); + + return alignedPtr; + } + + private: + void checkGuardBlock(unsigned char *blockMem, unsigned char val, const char *locText) const; + + void checkAlloc() const + { + checkGuardBlock(preGuard(), kGuardBlockBeginVal, "before"); + checkGuardBlock(postGuard(), kGuardBlockEndVal, "after"); + } + + // Find offsets to pre and post guard blocks, and user data buffer + unsigned char *preGuard() const { return mMem + HeaderSize(); } + unsigned char *data() const { return preGuard() + kGuardBlockSize; } + unsigned char *postGuard() const { return data() + mSize; } + size_t mSize; // size of the user data area + unsigned char *mMem; // beginning of our allocation (points to header) + Allocation *mPrevAlloc; // prior allocation in the chain + + static constexpr unsigned char kGuardBlockBeginVal = 0xfb; + static constexpr unsigned char kGuardBlockEndVal = 0xfe; + static constexpr unsigned char kUserDataFill = 0xcd; +#if defined(ANGLE_POOL_ALLOC_GUARD_BLOCKS) + static constexpr size_t kGuardBlockSize = 16; + static constexpr size_t HeaderSize() { return sizeof(Allocation); } +#else + static constexpr size_t kGuardBlockSize = 0; + static constexpr size_t HeaderSize() { return 0; } +#endif +}; + +#if !defined(ANGLE_DISABLE_POOL_ALLOC) +class PageHeader +{ + public: + PageHeader(PageHeader *nextPage, size_t pageCount) + : nextPage(nextPage), + pageCount(pageCount) +# if defined(ANGLE_POOL_ALLOC_GUARD_BLOCKS) + , + lastAllocation(nullptr) +# endif + {} + + ~PageHeader() + { +# if defined(ANGLE_POOL_ALLOC_GUARD_BLOCKS) + if (lastAllocation) + { + lastAllocation->checkAllocList(); + } +# endif + } + + PageHeader *nextPage; + size_t pageCount; +# if defined(ANGLE_POOL_ALLOC_GUARD_BLOCKS) + Allocation *lastAllocation; +# endif +}; +#endif + +// +// Implement the functionality of the PoolAllocator class, which +// is documented in PoolAlloc.h. +// +PoolAllocator::PoolAllocator(int growthIncrement, int allocationAlignment) + : mAlignment(allocationAlignment), +#if !defined(ANGLE_DISABLE_POOL_ALLOC) + mPageSize(growthIncrement), + mFreeList(nullptr), + mInUseList(nullptr), + mNumCalls(0), + mTotalBytes(0), +#endif + mLocked(false) +{ + initialize(growthIncrement, allocationAlignment); +} + +void PoolAllocator::initialize(int pageSize, int alignment) +{ + mAlignment = alignment; +#if !defined(ANGLE_DISABLE_POOL_ALLOC) + mPageSize = pageSize; + mPageHeaderSkip = sizeof(PageHeader); + + // Alignment == 1 is a special fast-path where fastAllocate() is enabled + if (mAlignment != 1) + { +#endif + // Adjust mAlignment to be at least pointer aligned and + // power of 2. + // + size_t minAlign = sizeof(void *); + if (mAlignment < minAlign) + { + mAlignment = minAlign; + } + mAlignment = gl::ceilPow2(static_cast(mAlignment)); +#if !defined(ANGLE_DISABLE_POOL_ALLOC) + } + // + // Don't allow page sizes we know are smaller than all common + // OS page sizes. + // + if (mPageSize < 4 * 1024) + { + mPageSize = 4 * 1024; + } + + // + // A large mCurrentPageOffset indicates a new page needs to + // be obtained to allocate memory. + // + mCurrentPageOffset = mPageSize; + +#else // !defined(ANGLE_DISABLE_POOL_ALLOC) + mStack.push_back({}); +#endif +} + +PoolAllocator::~PoolAllocator() +{ +#if !defined(ANGLE_DISABLE_POOL_ALLOC) + while (mInUseList) + { + PageHeader *next = mInUseList->nextPage; + mInUseList->~PageHeader(); + delete[] reinterpret_cast(mInUseList); + mInUseList = next; + } + // We should not check the guard blocks + // here, because we did it already when the block was + // placed into the free list. + // + while (mFreeList) + { + PageHeader *next = mFreeList->nextPage; + delete[] reinterpret_cast(mFreeList); + mFreeList = next; + } +#else // !defined(ANGLE_DISABLE_POOL_ALLOC) + for (auto &allocs : mStack) + { + for (auto alloc : allocs) + { + free(alloc); + } + } + mStack.clear(); +#endif +} + +// +// Check a single guard block for damage +// +void Allocation::checkGuardBlock(unsigned char *blockMem, + unsigned char val, + const char *locText) const +{ +#if defined(ANGLE_POOL_ALLOC_GUARD_BLOCKS) + for (size_t x = 0; x < kGuardBlockSize; x++) + { + if (blockMem[x] != val) + { + char assertMsg[80]; + // We don't print the assert message. It's here just to be helpful. + snprintf(assertMsg, sizeof(assertMsg), + "PoolAlloc: Damage %s %zu byte allocation at 0x%p\n", locText, mSize, data()); + assert(0 && "PoolAlloc: Damage in guard block"); + } + } +#endif +} + +void PoolAllocator::push() +{ +#if !defined(ANGLE_DISABLE_POOL_ALLOC) + AllocState state = {mCurrentPageOffset, mInUseList}; + + mStack.push_back(state); + + // + // Indicate there is no current page to allocate from. + // + mCurrentPageOffset = mPageSize; +#else // !defined(ANGLE_DISABLE_POOL_ALLOC) + mStack.push_back({}); +#endif +} + +// Do a mass-deallocation of all the individual allocations that have occurred since the last +// push(), or since the last pop(), or since the object's creation. +// +// The deallocated pages are saved for future allocations. +void PoolAllocator::pop() +{ + if (mStack.size() < 1) + { + return; + } + +#if !defined(ANGLE_DISABLE_POOL_ALLOC) + PageHeader *page = mStack.back().page; + mCurrentPageOffset = mStack.back().offset; + + while (mInUseList != page) + { + // invoke destructor to free allocation list + mInUseList->~PageHeader(); + + PageHeader *nextInUse = mInUseList->nextPage; + if (mInUseList->pageCount > 1) + { + delete[] reinterpret_cast(mInUseList); + } + else + { + mInUseList->nextPage = mFreeList; + mFreeList = mInUseList; + } + mInUseList = nextInUse; + } + + mStack.pop_back(); +#else // !defined(ANGLE_DISABLE_POOL_ALLOC) + for (auto &alloc : mStack.back()) + { + free(alloc); + } + mStack.pop_back(); +#endif +} + +// +// Do a mass-deallocation of all the individual allocations +// that have occurred. +// +void PoolAllocator::popAll() +{ + while (mStack.size() > 0) + pop(); +} + +void *PoolAllocator::allocate(size_t numBytes) +{ + ASSERT(!mLocked); + +#if !defined(ANGLE_DISABLE_POOL_ALLOC) + // + // Just keep some interesting statistics. + // + ++mNumCalls; + mTotalBytes += numBytes; + + uint8_t *currentPagePtr = reinterpret_cast(mInUseList) + mCurrentPageOffset; + + size_t preAllocationPadding = 0; + size_t allocationSize = + Allocation::AllocationSize(currentPagePtr, numBytes, mAlignment, &preAllocationPadding); + + // Integer overflow is unexpected. + ASSERT(allocationSize >= numBytes); + + // Do the allocation, most likely case first, for efficiency. + if (allocationSize <= mPageSize - mCurrentPageOffset) + { + // There is enough room to allocate from the current page at mCurrentPageOffset. + uint8_t *memory = currentPagePtr + preAllocationPadding; + mCurrentPageOffset += allocationSize; + + return initializeAllocation(memory, numBytes); + } + + if (allocationSize > mPageSize - mPageHeaderSkip) + { + // If the allocation is larger than a whole page, do a multi-page allocation. These are not + // mixed with the others. The OS is efficient in allocating and freeing multiple pages. + + // We don't know what the alignment of the new allocated memory will be, so conservatively + // allocate enough memory for up to alignment extra bytes being needed. + allocationSize = Allocation::AllocationSize(reinterpret_cast(mPageHeaderSkip), + numBytes, mAlignment, &preAllocationPadding); + + size_t numBytesToAlloc = allocationSize + mPageHeaderSkip + mAlignment; + + // Integer overflow is unexpected. + ASSERT(numBytesToAlloc >= allocationSize); + + PageHeader *memory = reinterpret_cast(::new char[numBytesToAlloc]); + if (memory == nullptr) + { + return nullptr; + } + + // Use placement-new to initialize header + new (memory) PageHeader(mInUseList, (numBytesToAlloc + mPageSize - 1) / mPageSize); + mInUseList = memory; + + // Make next allocation come from a new page + mCurrentPageOffset = mPageSize; + + // Now that we actually have the pointer, make sure the data pointer will be aligned. + currentPagePtr = reinterpret_cast(memory) + mPageHeaderSkip; + Allocation::AllocationSize(currentPagePtr, numBytes, mAlignment, &preAllocationPadding); + + return initializeAllocation(currentPagePtr + preAllocationPadding, numBytes); + } + + uint8_t *newPageAddr = allocateNewPage(numBytes); + return initializeAllocation(newPageAddr, numBytes); + +#else // !defined(ANGLE_DISABLE_POOL_ALLOC) + + void *alloc = malloc(numBytes + mAlignment - 1); + mStack.back().push_back(alloc); + + intptr_t intAlloc = reinterpret_cast(alloc); + intAlloc = rx::roundUpPow2(intAlloc, mAlignment); + return reinterpret_cast(intAlloc); +#endif +} + +#if !defined(ANGLE_DISABLE_POOL_ALLOC) +uint8_t *PoolAllocator::allocateNewPage(size_t numBytes) +{ + // Need a simple page to allocate from. Pick a page from the free list, if any. Otherwise need + // to make the allocation. + PageHeader *memory; + if (mFreeList) + { + memory = mFreeList; + mFreeList = mFreeList->nextPage; + } + else + { + memory = reinterpret_cast(::new char[mPageSize]); + if (memory == nullptr) + { + return nullptr; + } + } + // Use placement-new to initialize header + new (memory) PageHeader(mInUseList, 1); + mInUseList = memory; + + // Leave room for the page header. + mCurrentPageOffset = mPageHeaderSkip; + uint8_t *currentPagePtr = reinterpret_cast(mInUseList) + mCurrentPageOffset; + + size_t preAllocationPadding = 0; + size_t allocationSize = + Allocation::AllocationSize(currentPagePtr, numBytes, mAlignment, &preAllocationPadding); + + mCurrentPageOffset += allocationSize; + + // The new allocation is made after the page header and any alignment required before it. + return reinterpret_cast(mInUseList) + mPageHeaderSkip + preAllocationPadding; +} + +void *PoolAllocator::initializeAllocation(uint8_t *memory, size_t numBytes) +{ +# if defined(ANGLE_POOL_ALLOC_GUARD_BLOCKS) + new (memory) Allocation(numBytes, memory, mInUseList->lastAllocation); + mInUseList->lastAllocation = reinterpret_cast(memory); +# endif + + return Allocation::GetDataPointer(memory, mAlignment); +} +#endif + +void PoolAllocator::lock() +{ + ASSERT(!mLocked); + mLocked = true; +} + +void PoolAllocator::unlock() +{ + ASSERT(mLocked); + mLocked = false; +} + +// +// Check all allocations in a list for damage by calling check on each. +// +void Allocation::checkAllocList() const +{ + for (const Allocation *alloc = this; alloc != nullptr; alloc = alloc->mPrevAlloc) + { + alloc->checkAlloc(); + } +} + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/PoolAlloc.h b/gfx/angle/checkout/src/common/PoolAlloc.h new file mode 100644 index 0000000000..536848f198 --- /dev/null +++ b/gfx/angle/checkout/src/common/PoolAlloc.h @@ -0,0 +1,181 @@ +// +// Copyright 2019 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// PoolAlloc.h: +// Defines the class interface for PoolAllocator. +// + +#ifndef COMMON_POOLALLOC_H_ +#define COMMON_POOLALLOC_H_ + +#if !defined(NDEBUG) +# define ANGLE_POOL_ALLOC_GUARD_BLOCKS // define to enable guard block checking +#endif + +// +// This header defines an allocator that can be used to efficiently +// allocate a large number of small requests for heap memory, with the +// intention that they are not individually deallocated, but rather +// collectively deallocated at one time. +// +// This simultaneously +// +// * Makes each individual allocation much more efficient; the +// typical allocation is trivial. +// * Completely avoids the cost of doing individual deallocation. +// * Saves the trouble of tracking down and plugging a large class of leaks. +// +// Individual classes can use this allocator by supplying their own +// new and delete methods. +// + +#include "angleutils.h" +#include "common/debug.h" + +namespace angle +{ +class Allocation; +class PageHeader; + +// +// There are several stacks. One is to track the pushing and popping +// of the user, and not yet implemented. The others are simply a +// repositories of free pages or used pages. +// +// Page stacks are linked together with a simple header at the beginning +// of each allocation obtained from the underlying OS. Multi-page allocations +// are returned to the OS. Individual page allocations are kept for future +// re-use. +// +// The "page size" used is not, nor must it match, the underlying OS +// page size. But, having it be about that size or equal to a set of +// pages is likely most optimal. +// +class PoolAllocator : angle::NonCopyable +{ + public: + static const int kDefaultAlignment = sizeof(void *); + // + // Create PoolAllocator. If alignment is set to 1 byte then fastAllocate() + // function can be used to make allocations with less overhead. + // + PoolAllocator(int growthIncrement = 8 * 1024, int allocationAlignment = kDefaultAlignment); + + // + // Don't call the destructor just to free up the memory, call pop() + // + ~PoolAllocator(); + + // + // Initialize page size and alignment after construction + // + void initialize(int pageSize, int alignment); + + // + // Call push() to establish a new place to pop memory to. Does not + // have to be called to get things started. + // + void push(); + + // + // Call pop() to free all memory allocated since the last call to push(), + // or if no last call to push, frees all memory since first allocation. + // + void pop(); + + // + // Call popAll() to free all memory allocated. + // + void popAll(); + + // + // Call allocate() to actually acquire memory. Returns 0 if no memory + // available, otherwise a properly aligned pointer to 'numBytes' of memory. + // + void *allocate(size_t numBytes); + + // + // Call fastAllocate() for a faster allocate function that does minimal bookkeeping + // preCondition: Allocator must have been created w/ alignment of 1 + ANGLE_INLINE uint8_t *fastAllocate(size_t numBytes) + { +#if defined(ANGLE_DISABLE_POOL_ALLOC) + return reinterpret_cast(allocate(numBytes)); +#else + ASSERT(mAlignment == 1); + // No multi-page allocations + ASSERT(numBytes <= (mPageSize - mPageHeaderSkip)); + // + // Do the allocation, most likely case inline first, for efficiency. + // + if (numBytes <= mPageSize - mCurrentPageOffset) + { + // + // Safe to allocate from mCurrentPageOffset. + // + uint8_t *memory = reinterpret_cast(mInUseList) + mCurrentPageOffset; + mCurrentPageOffset += numBytes; + return memory; + } + return allocateNewPage(numBytes); +#endif + } + + // There is no deallocate. The point of this class is that deallocation can be skipped by the + // user of it, as the model of use is to simultaneously deallocate everything at once by calling + // pop(), and to not have to solve memory leak problems. + + // Catch unwanted allocations. + // TODO(jmadill): Remove this when we remove the global allocator. + void lock(); + void unlock(); + + private: + size_t mAlignment; // all returned allocations will be aligned at + // this granularity, which will be a power of 2 +#if !defined(ANGLE_DISABLE_POOL_ALLOC) + struct AllocState + { + size_t offset; + PageHeader *page; + }; + using AllocStack = std::vector; + + // Slow path of allocation when we have to get a new page. + uint8_t *allocateNewPage(size_t numBytes); + // Track allocations if and only if we're using guard blocks + void *initializeAllocation(uint8_t *memory, size_t numBytes); + + // Granularity of allocation from the OS + size_t mPageSize; + // Amount of memory to skip to make room for the page header (which is the size of the page + // header, or PageHeader in PoolAlloc.cpp) + size_t mPageHeaderSkip; + // Next offset in top of inUseList to allocate from. This offset is not necessarily aligned to + // anything. When an allocation is made, the data is aligned to mAlignment, and the header (if + // any) will align to pointer size by extension (since mAlignment is made aligned to at least + // pointer size). + size_t mCurrentPageOffset; + // List of popped memory + PageHeader *mFreeList; + // List of all memory currently being used. The head of this list is where allocations are + // currently being made from. + PageHeader *mInUseList; + // Stack of where to allocate from, to partition pool + AllocStack mStack; + + int mNumCalls; // just an interesting statistic + size_t mTotalBytes; // just an interesting statistic + +#else // !defined(ANGLE_DISABLE_POOL_ALLOC) + std::vector> mStack; +#endif + + bool mLocked; +}; + +} // namespace angle + +#endif // COMMON_POOLALLOC_H_ diff --git a/gfx/angle/checkout/src/common/Spinlock.h b/gfx/angle/checkout/src/common/Spinlock.h new file mode 100644 index 0000000000..494da0943e --- /dev/null +++ b/gfx/angle/checkout/src/common/Spinlock.h @@ -0,0 +1,71 @@ +// +// Copyright 2021 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// Spinlock.h: +// Spinlock is a lock that loops actively until it gets the resource. +// Only use it when the lock will be granted in reasonably short time. + +#ifndef COMMON_SPINLOCK_H_ +#define COMMON_SPINLOCK_H_ + +#include + +// TODO(jplate) Add pause for ARM, http://anglebug.com:6067 +#if defined(_MSC_VER) && (defined(_M_IX86) || defined(_M_X64)) +extern "C" void _mm_pause(); +# pragma intrinsic(_mm_pause) +# define ANGLE_SMT_PAUSE() _mm_pause() +#elif defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) +# define ANGLE_SMT_PAUSE() __asm__ __volatile__("pause;") +#else +# define ANGLE_SMT_PAUSE() static_cast(0) +#endif + +namespace angle +{ + +class Spinlock +{ + public: + Spinlock() noexcept; + + bool try_lock() noexcept; + void lock() noexcept; + void unlock() noexcept; + + private: + std::atomic_bool mLock; +}; + +inline Spinlock::Spinlock() noexcept : mLock(false) {} + +inline bool Spinlock::try_lock() noexcept +{ + // Relaxed check first to prevent unnecessary cache misses. + return !mLock.load(std::memory_order_relaxed) && + !mLock.exchange(true, std::memory_order_acquire); +} + +inline void Spinlock::lock() noexcept +{ + while (mLock.exchange(true, std::memory_order_acquire)) + { + // Relaxed wait to prevent unnecessary cache misses. + while (mLock.load(std::memory_order_relaxed)) + { + // Optimization for simultaneous multithreading. + ANGLE_SMT_PAUSE(); + } + } +} + +inline void Spinlock::unlock() noexcept +{ + mLock.store(false, std::memory_order_release); +} + +} // namespace angle + +#endif // COMMON_SPINLOCK_H_ diff --git a/gfx/angle/checkout/src/common/SynchronizedValue.h b/gfx/angle/checkout/src/common/SynchronizedValue.h new file mode 100644 index 0000000000..95432cfbcd --- /dev/null +++ b/gfx/angle/checkout/src/common/SynchronizedValue.h @@ -0,0 +1,540 @@ +// +// Copyright 2021 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// SynchronizedValue.h: +// A class that ensures that the correct mutex is locked when the encapsulated data is accessed. +// Based on boost::synchronized_value, which probably becomes part of the next C++ standard. +// https://www.boost.org/doc/libs/1_76_0/doc/html/thread/sds.html#thread.sds.synchronized_valuesxxx + +#ifndef COMMON_SYNCHRONIZEDVALUE_H_ +#define COMMON_SYNCHRONIZEDVALUE_H_ + +#include "common/debug.h" + +#include +#include + +namespace angle +{ + +template +class ConstStrictLockPtr +{ + public: + using value_type = T; + using mutex_type = Lockable; + + ConstStrictLockPtr(const T &value, Lockable &mutex) : mLock(mutex), mValue(value) {} + ConstStrictLockPtr(const T &value, Lockable &mutex, std::adopt_lock_t) noexcept + : mLock(mutex, std::adopt_lock), mValue(value) + {} + + ConstStrictLockPtr(ConstStrictLockPtr &&other) noexcept + : mLock(std::move(other.mLock)), mValue(other.mValue) + {} + + ConstStrictLockPtr(const ConstStrictLockPtr &) = delete; + ConstStrictLockPtr &operator=(const ConstStrictLockPtr &) = delete; + + ~ConstStrictLockPtr() = default; + + const T *operator->() const { return &mValue; } + const T &operator*() const { return mValue; } + + protected: + std::unique_lock mLock; + T const &mValue; +}; + +template +class StrictLockPtr : public ConstStrictLockPtr +{ + private: + using BaseType = ConstStrictLockPtr; + + public: + StrictLockPtr(T &value, Lockable &mutex) : BaseType(value, mutex) {} + StrictLockPtr(T &value, Lockable &mutex, std::adopt_lock_t) noexcept + : BaseType(value, mutex, std::adopt_lock) + {} + + StrictLockPtr(StrictLockPtr &&other) noexcept + : BaseType(std::move(static_cast(other))) + {} + + StrictLockPtr(const StrictLockPtr &) = delete; + StrictLockPtr &operator=(const StrictLockPtr &) = delete; + + ~StrictLockPtr() = default; + + T *operator->() { return const_cast(&this->mValue); } + T &operator*() { return const_cast(this->mValue); } +}; + +template +struct SynchronizedValueStrictLockPtr +{ + using type = StrictLockPtr; +}; + +template +struct SynchronizedValueStrictLockPtr +{ + using type = ConstStrictLockPtr; +}; + +template +class ConstUniqueLockPtr : public std::unique_lock +{ + private: + using BaseType = std::unique_lock; + + public: + using value_type = T; + using mutex_type = Lockable; + + ConstUniqueLockPtr(const T &value, Lockable &mutex) : BaseType(mutex), mValue(value) {} + ConstUniqueLockPtr(const T &value, Lockable &mutex, std::adopt_lock_t) noexcept + : BaseType(mutex, std::adopt_lock), mValue(value) + {} + ConstUniqueLockPtr(const T &value, Lockable &mutex, std::defer_lock_t) noexcept + : BaseType(mutex, std::defer_lock), mValue(value) + {} + ConstUniqueLockPtr(const T &value, Lockable &mutex, std::try_to_lock_t) noexcept + : BaseType(mutex, std::try_to_lock), mValue(value) + {} + + ConstUniqueLockPtr(ConstUniqueLockPtr &&other) noexcept + : BaseType(std::move(static_cast(other))), mValue(other.mValue) + {} + + ConstUniqueLockPtr(const ConstUniqueLockPtr &) = delete; + ConstUniqueLockPtr &operator=(const ConstUniqueLockPtr &) = delete; + + ~ConstUniqueLockPtr() = default; + + const T *operator->() const + { + ASSERT(this->owns_lock()); + return &mValue; + } + const T &operator*() const + { + ASSERT(this->owns_lock()); + return mValue; + } + + protected: + T const &mValue; +}; + +template +class UniqueLockPtr : public ConstUniqueLockPtr +{ + private: + using BaseType = ConstUniqueLockPtr; + + public: + UniqueLockPtr(T &value, Lockable &mutex) : BaseType(value, mutex) {} + UniqueLockPtr(T &value, Lockable &mutex, std::adopt_lock_t) noexcept + : BaseType(value, mutex, std::adopt_lock) + {} + UniqueLockPtr(T &value, Lockable &mutex, std::defer_lock_t) noexcept + : BaseType(value, mutex, std::defer_lock) + {} + UniqueLockPtr(T &value, Lockable &mutex, std::try_to_lock_t) noexcept + : BaseType(value, mutex, std::try_to_lock) + {} + + UniqueLockPtr(UniqueLockPtr &&other) noexcept + : BaseType(std::move(static_cast(other))) + {} + + UniqueLockPtr(const UniqueLockPtr &) = delete; + UniqueLockPtr &operator=(const UniqueLockPtr &) = delete; + + ~UniqueLockPtr() = default; + + T *operator->() + { + ASSERT(this->owns_lock()); + return const_cast(&this->mValue); + } + T &operator*() + { + ASSERT(this->owns_lock()); + return const_cast(this->mValue); + } +}; + +template +struct SynchronizedValueUniqueLockPtr +{ + using type = UniqueLockPtr; +}; + +template +struct SynchronizedValueUniqueLockPtr +{ + using type = ConstUniqueLockPtr; +}; + +template +class SynchronizedValue +{ + public: + using value_type = T; + using mutex_type = Lockable; + + SynchronizedValue() noexcept(std::is_nothrow_default_constructible::value) : mValue() {} + + SynchronizedValue(const T &other) noexcept(std::is_nothrow_copy_constructible::value) + : mValue(other) + {} + + SynchronizedValue(T &&other) noexcept(std::is_nothrow_move_constructible::value) + : mValue(std::move(other)) + {} + + template + SynchronizedValue(Args &&... args) noexcept(noexcept(T(std::forward(args)...))) + : mValue(std::forward(args)...) + {} + + SynchronizedValue(const SynchronizedValue &other) + { + std::lock_guard lock(other.mMutex); + mValue = other.mValue; + } + + SynchronizedValue(SynchronizedValue &&other) + { + std::lock_guard lock(other.mMutex); + mValue = std::move(other.mValue); + } + + SynchronizedValue &operator=(const SynchronizedValue &other) + { + if (&other != this) + { + std::unique_lock lock1(mMutex, std::defer_lock); + std::unique_lock lock2(other.mMutex, std::defer_lock); + std::lock(lock1, lock2); + mValue = other.mValue; + } + return *this; + } + + SynchronizedValue &operator=(SynchronizedValue &&other) + { + if (&other != this) + { + std::unique_lock lock1(mMutex, std::defer_lock); + std::unique_lock lock2(other.mMutex, std::defer_lock); + std::lock(lock1, lock2); + mValue = std::move(other.mValue); + } + return *this; + } + + SynchronizedValue &operator=(const T &value) + { + { + std::lock_guard lock(mMutex); + mValue = value; + } + return *this; + } + + SynchronizedValue &operator=(T &&value) + { + { + std::lock_guard lock(mMutex); + mValue = std::move(value); + } + return *this; + } + + T get() const + { + std::lock_guard lock(mMutex); + return mValue; + } + + explicit operator T() const { return get(); } + + void swap(SynchronizedValue &other) + { + if (this == &other) + { + return; + } + std::unique_lock lock1(mMutex, std::defer_lock); + std::unique_lock lock2(other.mMutex, std::defer_lock); + std::lock(lock1, lock2); + std::swap(mValue, other.mValue); + } + + void swap(T &other) + { + std::lock_guard lock(mMutex); + std::swap(mValue, other); + } + + StrictLockPtr operator->() { return StrictLockPtr(mValue, mMutex); } + ConstStrictLockPtr operator->() const + { + return ConstStrictLockPtr(mValue, mMutex); + } + + StrictLockPtr synchronize() { return StrictLockPtr(mValue, mMutex); } + ConstStrictLockPtr synchronize() const + { + return ConstStrictLockPtr(mValue, mMutex); + } + + UniqueLockPtr unique_synchronize() + { + return UniqueLockPtr(mValue, mMutex); + } + ConstUniqueLockPtr unique_synchronize() const + { + return ConstUniqueLockPtr(mValue, mMutex); + } + + UniqueLockPtr defer_synchronize() noexcept + { + return UniqueLockPtr(mValue, mMutex, std::defer_lock); + } + ConstUniqueLockPtr defer_synchronize() const noexcept + { + return ConstUniqueLockPtr(mValue, mMutex, std::defer_lock); + } + + UniqueLockPtr try_to_synchronize() noexcept + { + return UniqueLockPtr(mValue, mMutex, std::try_to_lock); + } + ConstUniqueLockPtr try_to_synchronize() const noexcept + { + return ConstUniqueLockPtr(mValue, mMutex, std::try_to_lock); + } + + UniqueLockPtr adopt_synchronize() noexcept + { + return UniqueLockPtr(mValue, mMutex, std::adopt_lock); + } + ConstUniqueLockPtr adopt_synchronize() const noexcept + { + return ConstUniqueLockPtr(mValue, mMutex, std::adopt_lock); + } + + class DerefValue + { + public: + DerefValue(DerefValue &&other) : mLock(std::move(other.mLock)), mValue(other.mValue) {} + + DerefValue(const DerefValue &) = delete; + DerefValue &operator=(const DerefValue &) = delete; + + operator T &() { return mValue; } + + DerefValue &operator=(const T &other) + { + mValue = other; + return *this; + } + + private: + explicit DerefValue(SynchronizedValue &outer) : mLock(outer.mMutex), mValue(outer.mValue) {} + + std::unique_lock mLock; + T &mValue; + + friend class SynchronizedValue; + }; + + class ConstDerefValue + { + public: + ConstDerefValue(ConstDerefValue &&other) + : mLock(std::move(other.mLock)), mValue(other.mValue) + {} + + ConstDerefValue(const ConstDerefValue &) = delete; + ConstDerefValue &operator=(const ConstDerefValue &) = delete; + + operator const T &() { return mValue; } + + private: + explicit ConstDerefValue(const SynchronizedValue &outer) + : mLock(outer.mMutex), mValue(outer.mValue) + {} + + std::unique_lock mLock; + const T &mValue; + + friend class SynchronizedValue; + }; + + DerefValue operator*() { return DerefValue(*this); } + ConstDerefValue operator*() const { return ConstDerefValue(*this); } + + template + void save(OStream &os) const + { + std::lock_guard lock(mMutex); + os << mValue; + } + + template + void load(IStream &is) + { + std::lock_guard lock(mMutex); + is >> mValue; + } + + bool operator==(const SynchronizedValue &other) const + { + std::unique_lock lock1(mMutex, std::defer_lock); + std::unique_lock lock2(other.mMutex, std::defer_lock); + std::lock(lock1, lock2); + return mValue == other.mValue; + } + + bool operator!=(const SynchronizedValue &other) const + { + std::unique_lock lock1(mMutex, std::defer_lock); + std::unique_lock lock2(other.mMutex, std::defer_lock); + std::lock(lock1, lock2); + return mValue != other.mValue; + } + + bool operator<(const SynchronizedValue &other) const + { + std::unique_lock lock1(mMutex, std::defer_lock); + std::unique_lock lock2(other.mMutex, std::defer_lock); + std::lock(lock1, lock2); + return mValue < other.mValue; + } + + bool operator>(const SynchronizedValue &other) const + { + std::unique_lock lock1(mMutex, std::defer_lock); + std::unique_lock lock2(other.mMutex, std::defer_lock); + std::lock(lock1, lock2); + return mValue > other.mValue; + } + + bool operator<=(const SynchronizedValue &other) const + { + std::unique_lock lock1(mMutex, std::defer_lock); + std::unique_lock lock2(other.mMutex, std::defer_lock); + std::lock(lock1, lock2); + return mValue <= other.mValue; + } + + bool operator>=(const SynchronizedValue &other) const + { + std::unique_lock lock1(mMutex, std::defer_lock); + std::unique_lock lock2(other.mMutex, std::defer_lock); + std::lock(lock1, lock2); + return mValue >= other.mValue; + } + + bool operator==(const T &other) const + { + std::lock_guard lock(mMutex); + return mValue == other; + } + + bool operator!=(const T &other) const + { + std::lock_guard lock(mMutex); + return mValue != other; + } + + bool operator<(const T &other) const + { + std::lock_guard lock(mMutex); + return mValue < other; + } + + bool operator>(const T &other) const + { + std::lock_guard lock(mMutex); + return mValue > other; + } + + bool operator<=(const T &other) const + { + std::lock_guard lock(mMutex); + return mValue <= other; + } + + bool operator>=(const T &other) const + { + std::lock_guard lock(mMutex); + return mValue >= other; + } + + private: + T mValue; + mutable Lockable mMutex; +}; + +template +inline OStream &operator<<(OStream &os, SynchronizedValue const &sv) +{ + sv.save(os); + return os; +} + +template +inline IStream &operator>>(IStream &is, SynchronizedValue &sv) +{ + sv.load(is); + return is; +} + +template +bool operator==(const T &lhs, const SynchronizedValue &rhs) +{ + return rhs == lhs; +} + +template +bool operator!=(const T &lhs, const SynchronizedValue &rhs) +{ + return rhs != lhs; +} + +template +bool operator<(const T &lhs, const SynchronizedValue &rhs) +{ + return rhs < lhs; +} + +template +bool operator>(const T &lhs, const SynchronizedValue &rhs) +{ + return rhs > lhs; +} + +template +bool operator<=(const T &lhs, const SynchronizedValue &rhs) +{ + return rhs <= lhs; +} + +template +bool operator>=(const T &lhs, const SynchronizedValue &rhs) +{ + return rhs >= lhs; +} + +} // namespace angle + +#endif // COMMON_SYNCHRONIZEDVALUE_H_ diff --git a/gfx/angle/checkout/src/common/aligned_memory.cpp b/gfx/angle/checkout/src/common/aligned_memory.cpp new file mode 100644 index 0000000000..9798fc0f42 --- /dev/null +++ b/gfx/angle/checkout/src/common/aligned_memory.cpp @@ -0,0 +1,64 @@ +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// aligned_memory: An aligned memory allocator. Based on Chrome's base/memory/aligned_memory. +// + +#include "common/aligned_memory.h" + +#include "common/debug.h" +#include "common/platform.h" + +#if defined(COMPILER_MSVC) +# include +#else +# include +#endif + +namespace angle +{ + +void *AlignedAlloc(size_t size, size_t alignment) +{ + ASSERT(size > 0); + ASSERT((alignment & (alignment - 1)) == 0); + ASSERT((alignment % sizeof(void *)) == 0); + void *ptr = nullptr; +#if defined(ANGLE_PLATFORM_WINDOWS) + ptr = _aligned_malloc(size, alignment); +// Android technically supports posix_memalign(), but does not expose it in +// the current version of the library headers used by Chrome. Luckily, +// memalign() on Android returns pointers which can safely be used with +// free(), so we can use it instead. Issue filed to document this: +// http://code.google.com/p/android/issues/detail?id=35391 +#elif defined(ANGLE_PLATFORM_ANDROID) + ptr = memalign(alignment, size); +#else + if (posix_memalign(&ptr, alignment, size)) + ptr = nullptr; +#endif + // Since aligned allocations may fail for non-memory related reasons, force a + // crash if we encounter a failed allocation. + if (!ptr) + { + ERR() << "If you crashed here, your aligned allocation is incorrect: " + << "size=" << size << ", alignment=" << alignment; + ASSERT(false); + } + // Confidence check alignment just to be safe. + ASSERT((reinterpret_cast(ptr) & (alignment - 1)) == 0); + return ptr; +} + +void AlignedFree(void *ptr) +{ +#if defined(ANGLE_PLATFORM_WINDOWS) + _aligned_free(ptr); +#else + free(ptr); +#endif +} + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/aligned_memory.h b/gfx/angle/checkout/src/common/aligned_memory.h new file mode 100644 index 0000000000..dcbb60d1cb --- /dev/null +++ b/gfx/angle/checkout/src/common/aligned_memory.h @@ -0,0 +1,23 @@ +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// aligned_memory: An aligned memory allocator. Based on Chrome's base/memory/aligned_memory. +// + +#ifndef COMMON_ALIGNED_MEMORY_H_ +#define COMMON_ALIGNED_MEMORY_H_ + +#include + +namespace angle +{ + +// This can be replaced with std::aligned_malloc when we have C++17. +void *AlignedAlloc(size_t size, size_t alignment); +void AlignedFree(void *ptr); + +} // namespace angle + +#endif // COMMON_ALIGNED_MEMORY_H_ diff --git a/gfx/angle/checkout/src/common/android_util.cpp b/gfx/angle/checkout/src/common/android_util.cpp new file mode 100644 index 0000000000..8188da21ef --- /dev/null +++ b/gfx/angle/checkout/src/common/android_util.cpp @@ -0,0 +1,424 @@ +// +// Copyright 2018 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// android_util.cpp: Utilities for the using the Android platform + +#include "common/android_util.h" +#include "common/debug.h" + +#include + +#if defined(ANGLE_PLATFORM_ANDROID) && __ANDROID_API__ >= 26 +# define ANGLE_AHARDWARE_BUFFER_SUPPORT +// NDK header file for access to Android Hardware Buffers +# include +#endif + +// Taken from cutils/native_handle.h: +// https://android.googlesource.com/platform/system/core/+/master/libcutils/include/cutils/native_handle.h +typedef struct native_handle +{ + int version; /* sizeof(native_handle_t) */ + int numFds; /* number of file-descriptors at &data[0] */ + int numInts; /* number of ints at &data[numFds] */ +#if defined(__clang__) +# pragma clang diagnostic push +# pragma clang diagnostic ignored "-Wzero-length-array" +#elif defined(_MSC_VER) +# pragma warning(push) +# pragma warning(disable : 4200) +#endif + int data[0]; /* numFds + numInts ints */ +#if defined(__clang__) +# pragma clang diagnostic pop +#elif defined(_MSC_VER) +# pragma warning(pop) +#endif +} native_handle_t; + +// Taken from nativebase/nativebase.h +// https://android.googlesource.com/platform/frameworks/native/+/master/libs/nativebase/include/nativebase/nativebase.h +typedef const native_handle_t *buffer_handle_t; + +typedef struct android_native_base_t +{ + /* a magic value defined by the actual EGL native type */ + int magic; + /* the sizeof() of the actual EGL native type */ + int version; + void *reserved[4]; + /* reference-counting interface */ + void (*incRef)(struct android_native_base_t *base); + void (*decRef)(struct android_native_base_t *base); +} android_native_base_t; + +typedef struct ANativeWindowBuffer +{ + struct android_native_base_t common; + int width; + int height; + int stride; + int format; + int usage_deprecated; + uintptr_t layerCount; + void *reserved[1]; + const native_handle_t *handle; + uint64_t usage; + // we needed extra space for storing the 64-bits usage flags + // the number of slots to use from reserved_proc depends on the + // architecture. + void *reserved_proc[8 - (sizeof(uint64_t) / sizeof(void *))]; +} ANativeWindowBuffer_t; + +// Taken from android/hardware_buffer.h +// https://android.googlesource.com/platform/frameworks/native/+/master/libs/nativewindow/include/android/hardware_buffer.h + +// AHARDWAREBUFFER_FORMAT_B8G8R8A8_UNORM AHARDWAREBUFFER_FORMAT_B4G4R4A4_UNORM, +// AHARDWAREBUFFER_FORMAT_B5G5R5A1_UNORM formats were deprecated and re-added explicitly. + +// clang-format off +/** + * Buffer pixel formats. + */ +enum { + +#ifndef ANGLE_AHARDWARE_BUFFER_SUPPORT + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_R8G8B8A8_UNORM + * OpenGL ES: GL_RGBA8 + */ + AHARDWAREBUFFER_FORMAT_R8G8B8A8_UNORM = 1, + + /** + * 32 bits per pixel, 8 bits per channel format where alpha values are + * ignored (always opaque). + * Corresponding formats: + * Vulkan: VK_FORMAT_R8G8B8A8_UNORM + * OpenGL ES: GL_RGB8 + */ + AHARDWAREBUFFER_FORMAT_R8G8B8X8_UNORM = 2, + + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_R8G8B8_UNORM + * OpenGL ES: GL_RGB8 + */ + AHARDWAREBUFFER_FORMAT_R8G8B8_UNORM = 3, + + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_R5G6B5_UNORM_PACK16 + * OpenGL ES: GL_RGB565 + */ + AHARDWAREBUFFER_FORMAT_R5G6B5_UNORM = 4, +#endif // ANGLE_AHARDWARE_BUFFER_SUPPORT + + AHARDWAREBUFFER_FORMAT_B8G8R8A8_UNORM = 5, + AHARDWAREBUFFER_FORMAT_B5G5R5A1_UNORM = 6, + AHARDWAREBUFFER_FORMAT_B4G4R4A4_UNORM = 7, + +#ifndef ANGLE_AHARDWARE_BUFFER_SUPPORT + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_R16G16B16A16_SFLOAT + * OpenGL ES: GL_RGBA16F + */ + AHARDWAREBUFFER_FORMAT_R16G16B16A16_FLOAT = 0x16, + + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_A2B10G10R10_UNORM_PACK32 + * OpenGL ES: GL_RGB10_A2 + */ + AHARDWAREBUFFER_FORMAT_R10G10B10A2_UNORM = 0x2b, + + /** + * An opaque binary blob format that must have height 1, with width equal to + * the buffer size in bytes. + */ + AHARDWAREBUFFER_FORMAT_BLOB = 0x21, + + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_D16_UNORM + * OpenGL ES: GL_DEPTH_COMPONENT16 + */ + AHARDWAREBUFFER_FORMAT_D16_UNORM = 0x30, + + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_X8_D24_UNORM_PACK32 + * OpenGL ES: GL_DEPTH_COMPONENT24 + */ + AHARDWAREBUFFER_FORMAT_D24_UNORM = 0x31, + + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_D24_UNORM_S8_UINT + * OpenGL ES: GL_DEPTH24_STENCIL8 + */ + AHARDWAREBUFFER_FORMAT_D24_UNORM_S8_UINT = 0x32, + + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_D32_SFLOAT + * OpenGL ES: GL_DEPTH_COMPONENT32F + */ + AHARDWAREBUFFER_FORMAT_D32_FLOAT = 0x33, + + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_D32_SFLOAT_S8_UINT + * OpenGL ES: GL_DEPTH32F_STENCIL8 + */ + AHARDWAREBUFFER_FORMAT_D32_FLOAT_S8_UINT = 0x34, + + /** + * Corresponding formats: + * Vulkan: VK_FORMAT_S8_UINT + * OpenGL ES: GL_STENCIL_INDEX8 + */ + AHARDWAREBUFFER_FORMAT_S8_UINT = 0x35, + + /** + * YUV 420 888 format. + * Must have an even width and height. Can be accessed in OpenGL + * shaders through an external sampler. Does not support mip-maps + * cube-maps or multi-layered textures. + */ + AHARDWAREBUFFER_FORMAT_Y8Cb8Cr8_420 = 0x23, + +#endif // ANGLE_AHARDWARE_BUFFER_SUPPORT + + AHARDWAREBUFFER_FORMAT_YV12 = 0x32315659, + AHARDWAREBUFFER_FORMAT_IMPLEMENTATION_DEFINED = 0x22, +}; +// clang-format on + +namespace +{ + +// In the Android system: +// - AHardwareBuffer is essentially a typedef of GraphicBuffer. Conversion functions simply +// reinterpret_cast. +// - GraphicBuffer inherits from two base classes, ANativeWindowBuffer and RefBase. +// +// GraphicBuffer implements a getter for ANativeWindowBuffer (getNativeBuffer) by static_casting +// itself to its base class ANativeWindowBuffer. The offset of the ANativeWindowBuffer pointer +// from the GraphicBuffer pointer is 16 bytes. This is likely due to two pointers: The vtable of +// GraphicBuffer and the one pointer member of the RefBase class. +// +// This is not future proof at all. We need to look into getting utilities added to Android to +// perform this cast for us. +constexpr int kAHardwareBufferToANativeWindowBufferOffset = static_cast(sizeof(void *)) * 2; + +template +T1 *OffsetPointer(T2 *ptr, int bytes) +{ + return reinterpret_cast(reinterpret_cast(ptr) + bytes); +} + +GLenum GetPixelFormatInfo(int pixelFormat, bool *isYUV) +{ + *isYUV = false; + switch (pixelFormat) + { + case AHARDWAREBUFFER_FORMAT_R8G8B8A8_UNORM: + return GL_RGBA8; + case AHARDWAREBUFFER_FORMAT_R8G8B8X8_UNORM: + return GL_RGB8; + case AHARDWAREBUFFER_FORMAT_R8G8B8_UNORM: + return GL_RGB8; + case AHARDWAREBUFFER_FORMAT_R5G6B5_UNORM: + return GL_RGB565; + case AHARDWAREBUFFER_FORMAT_B8G8R8A8_UNORM: + return GL_BGRA8_EXT; + case AHARDWAREBUFFER_FORMAT_B5G5R5A1_UNORM: + return GL_RGB5_A1; + case AHARDWAREBUFFER_FORMAT_B4G4R4A4_UNORM: + return GL_RGBA4; + case AHARDWAREBUFFER_FORMAT_R16G16B16A16_FLOAT: + return GL_RGBA16F; + case AHARDWAREBUFFER_FORMAT_R10G10B10A2_UNORM: + return GL_RGB10_A2; + case AHARDWAREBUFFER_FORMAT_BLOB: + return GL_NONE; + case AHARDWAREBUFFER_FORMAT_D16_UNORM: + return GL_DEPTH_COMPONENT16; + case AHARDWAREBUFFER_FORMAT_D24_UNORM: + return GL_DEPTH_COMPONENT24; + case AHARDWAREBUFFER_FORMAT_D24_UNORM_S8_UINT: + return GL_DEPTH24_STENCIL8; + case AHARDWAREBUFFER_FORMAT_D32_FLOAT: + return GL_DEPTH_COMPONENT32F; + case AHARDWAREBUFFER_FORMAT_D32_FLOAT_S8_UINT: + return GL_DEPTH32F_STENCIL8; + case AHARDWAREBUFFER_FORMAT_S8_UINT: + return GL_STENCIL_INDEX8; + case AHARDWAREBUFFER_FORMAT_Y8Cb8Cr8_420: + case AHARDWAREBUFFER_FORMAT_YV12: + case AHARDWAREBUFFER_FORMAT_IMPLEMENTATION_DEFINED: + *isYUV = true; + return GL_RGB8; + default: + // Treat unknown formats as RGB. They are vendor-specific YUV formats that would sample + // as RGB. + *isYUV = true; + return GL_RGB8; + } +} + +} // anonymous namespace + +namespace angle +{ + +namespace android +{ + +ANativeWindowBuffer *ClientBufferToANativeWindowBuffer(EGLClientBuffer clientBuffer) +{ + return reinterpret_cast(clientBuffer); +} + +uint64_t GetAHBUsage(int eglNativeBufferUsage) +{ + uint64_t ahbUsage = 0; +#if defined(ANGLE_AHARDWARE_BUFFER_SUPPORT) + if (eglNativeBufferUsage & EGL_NATIVE_BUFFER_USAGE_PROTECTED_BIT_ANDROID) + { + ahbUsage |= AHARDWAREBUFFER_USAGE_PROTECTED_CONTENT; + } + if (eglNativeBufferUsage & EGL_NATIVE_BUFFER_USAGE_RENDERBUFFER_BIT_ANDROID) + { + ahbUsage |= AHARDWAREBUFFER_USAGE_GPU_FRAMEBUFFER; + } + if (eglNativeBufferUsage & EGL_NATIVE_BUFFER_USAGE_TEXTURE_BIT_ANDROID) + { + ahbUsage |= AHARDWAREBUFFER_USAGE_GPU_SAMPLED_IMAGE; + } +#endif // ANGLE_AHARDWARE_BUFFER_SUPPORT + return ahbUsage; +} + +EGLClientBuffer CreateEGLClientBufferFromAHardwareBuffer(int width, + int height, + int depth, + int androidFormat, + int usage) +{ +#if defined(ANGLE_AHARDWARE_BUFFER_SUPPORT) + + // The height and width are number of pixels of size format + AHardwareBuffer_Desc aHardwareBufferDescription = {}; + aHardwareBufferDescription.width = static_cast(width); + aHardwareBufferDescription.height = static_cast(height); + aHardwareBufferDescription.layers = static_cast(depth); + aHardwareBufferDescription.format = androidFormat; + aHardwareBufferDescription.usage = GetAHBUsage(usage); + + // Allocate memory from Android Hardware Buffer + AHardwareBuffer *aHardwareBuffer = nullptr; + int res = AHardwareBuffer_allocate(&aHardwareBufferDescription, &aHardwareBuffer); + if (res != 0) + { + return nullptr; + } + + return AHardwareBufferToClientBuffer(aHardwareBuffer); +#else + return nullptr; +#endif // ANGLE_AHARDWARE_BUFFER_SUPPORT +} + +void GetANativeWindowBufferProperties(const ANativeWindowBuffer *buffer, + int *width, + int *height, + int *depth, + int *pixelFormat, + uint64_t *usage) +{ + *width = buffer->width; + *height = buffer->height; + *depth = static_cast(buffer->layerCount); + *height = buffer->height; + *pixelFormat = buffer->format; + *usage = buffer->usage; +} + +GLenum NativePixelFormatToGLInternalFormat(int pixelFormat) +{ + bool isYuv = false; + return GetPixelFormatInfo(pixelFormat, &isYuv); +} + +int GLInternalFormatToNativePixelFormat(GLenum internalFormat) +{ + switch (internalFormat) + { + case GL_RGBA8: + return AHARDWAREBUFFER_FORMAT_R8G8B8A8_UNORM; + case GL_RGB8: + return AHARDWAREBUFFER_FORMAT_R8G8B8X8_UNORM; + case GL_RGB565: + return AHARDWAREBUFFER_FORMAT_R5G6B5_UNORM; + case GL_BGRA8_EXT: + return AHARDWAREBUFFER_FORMAT_B8G8R8A8_UNORM; + case GL_RGB5_A1: + return AHARDWAREBUFFER_FORMAT_B5G5R5A1_UNORM; + case GL_RGBA4: + return AHARDWAREBUFFER_FORMAT_B4G4R4A4_UNORM; + case GL_RGBA16F: + return AHARDWAREBUFFER_FORMAT_R16G16B16A16_FLOAT; + case GL_RGB10_A2: + return AHARDWAREBUFFER_FORMAT_R10G10B10A2_UNORM; + case GL_NONE: + return AHARDWAREBUFFER_FORMAT_BLOB; + case GL_DEPTH_COMPONENT16: + return AHARDWAREBUFFER_FORMAT_D16_UNORM; + case GL_DEPTH_COMPONENT24: + return AHARDWAREBUFFER_FORMAT_D24_UNORM; + case GL_DEPTH24_STENCIL8: + return AHARDWAREBUFFER_FORMAT_D24_UNORM_S8_UINT; + case GL_DEPTH_COMPONENT32F: + return AHARDWAREBUFFER_FORMAT_D32_FLOAT; + case GL_DEPTH32F_STENCIL8: + return AHARDWAREBUFFER_FORMAT_D32_FLOAT_S8_UINT; + case GL_STENCIL_INDEX8: + return AHARDWAREBUFFER_FORMAT_S8_UINT; + default: + WARN() << "Unknown internalFormat: " << internalFormat << ". Treating as 0"; + return 0; + } +} + +bool NativePixelFormatIsYUV(int pixelFormat) +{ + bool isYuv = false; + GetPixelFormatInfo(pixelFormat, &isYuv); + return isYuv; +} + +AHardwareBuffer *ANativeWindowBufferToAHardwareBuffer(ANativeWindowBuffer *windowBuffer) +{ + return OffsetPointer(windowBuffer, + -kAHardwareBufferToANativeWindowBufferOffset); +} + +EGLClientBuffer AHardwareBufferToClientBuffer(const AHardwareBuffer *hardwareBuffer) +{ + return OffsetPointer(hardwareBuffer, + kAHardwareBufferToANativeWindowBufferOffset); +} + +AHardwareBuffer *ClientBufferToAHardwareBuffer(EGLClientBuffer clientBuffer) +{ + return OffsetPointer(clientBuffer, + -kAHardwareBufferToANativeWindowBufferOffset); +} +} // namespace android +} // namespace angle diff --git a/gfx/angle/checkout/src/common/android_util.h b/gfx/angle/checkout/src/common/android_util.h new file mode 100644 index 0000000000..eee60ba244 --- /dev/null +++ b/gfx/angle/checkout/src/common/android_util.h @@ -0,0 +1,59 @@ +// +// Copyright 2018 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// android_util.h: Utilities for the using the Android platform + +#ifndef COMMON_ANDROIDUTIL_H_ +#define COMMON_ANDROIDUTIL_H_ + +#include +#include + +#include +#include + +#include "angle_gl.h" + +struct ANativeWindowBuffer; +struct AHardwareBuffer; + +namespace angle +{ + +namespace android +{ + +constexpr std::array kSupportedSizedInternalFormats = {GL_RGBA8, GL_RGB8, GL_RGB565}; + +ANativeWindowBuffer *ClientBufferToANativeWindowBuffer(EGLClientBuffer clientBuffer); +EGLClientBuffer AHardwareBufferToClientBuffer(const AHardwareBuffer *hardwareBuffer); +AHardwareBuffer *ClientBufferToAHardwareBuffer(EGLClientBuffer clientBuffer); + +EGLClientBuffer CreateEGLClientBufferFromAHardwareBuffer(int width, + int height, + int depth, + int androidFormat, + int usage); + +void GetANativeWindowBufferProperties(const ANativeWindowBuffer *buffer, + int *width, + int *height, + int *depth, + int *pixelFormat, + uint64_t *usage); +GLenum NativePixelFormatToGLInternalFormat(int pixelFormat); +int GLInternalFormatToNativePixelFormat(GLenum internalFormat); + +bool NativePixelFormatIsYUV(int pixelFormat); + +AHardwareBuffer *ANativeWindowBufferToAHardwareBuffer(ANativeWindowBuffer *windowBuffer); + +uint64_t GetAHBUsage(int eglNativeBufferUsage); + +} // namespace android +} // namespace angle + +#endif // COMMON_ANDROIDUTIL_H_ diff --git a/gfx/angle/checkout/src/common/angle_version.h b/gfx/angle/checkout/src/common/angle_version.h new file mode 100644 index 0000000000..d9d7e8929d --- /dev/null +++ b/gfx/angle/checkout/src/common/angle_version.h @@ -0,0 +1,28 @@ +// +// Copyright 2014 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// angle_version.h: ANGLE version constants. Generated from git commands. + +#ifndef COMMON_ANGLE_VERSION_H_ +#define COMMON_ANGLE_VERSION_H_ + +#include "angle_commit.h" + +#define ANGLE_MAJOR_VERSION 2 +#define ANGLE_MINOR_VERSION 1 + +#ifndef ANGLE_REVISION +# define ANGLE_REVISION ANGLE_COMMIT_POSITION +#endif + +#define ANGLE_STRINGIFY(x) #x +#define ANGLE_MACRO_STRINGIFY(x) ANGLE_STRINGIFY(x) + +#define ANGLE_VERSION_STRING \ + ANGLE_MACRO_STRINGIFY(ANGLE_MAJOR_VERSION) \ + "." ANGLE_MACRO_STRINGIFY(ANGLE_MINOR_VERSION) "." ANGLE_MACRO_STRINGIFY( \ + ANGLE_REVISION) " git hash: " ANGLE_COMMIT_HASH + +#endif // COMMON_ANGLE_VERSION_H_ diff --git a/gfx/angle/checkout/src/common/angle_version_info.cpp b/gfx/angle/checkout/src/common/angle_version_info.cpp new file mode 100644 index 0000000000..963741a456 --- /dev/null +++ b/gfx/angle/checkout/src/common/angle_version_info.cpp @@ -0,0 +1,40 @@ +// +// Copyright 2021 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// angle_version_info.cpp: ANGLE version queries. + +#include "common/angle_version.h" + +namespace angle +{ +int GetANGLERevision() +{ + return ANGLE_REVISION; +} + +const char *GetANGLEVersionString() +{ + return ANGLE_VERSION_STRING; +} + +const char *GetANGLECommitHash() +{ + return ANGLE_COMMIT_HASH; +} + +int GetANGLECommitHashSize() +{ + return ANGLE_COMMIT_HASH_SIZE; +} + +bool GetANGLEHasBinaryLoading() +{ +#ifdef ANGLE_HAS_BINARY_LOADING + return true; +#else + return false; +#endif // #ifndef ANGLE_HAS_BINARY_LOADING +} +} // namespace angle diff --git a/gfx/angle/checkout/src/common/angle_version_info.h b/gfx/angle/checkout/src/common/angle_version_info.h new file mode 100644 index 0000000000..1d5392068c --- /dev/null +++ b/gfx/angle/checkout/src/common/angle_version_info.h @@ -0,0 +1,20 @@ +// +// Copyright 2021 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// angle_version_info.h: ANGLE version queries. + +#ifndef COMMON_VERSION_INFO_H_ +#define COMMON_VERSION_INFO_H_ + +namespace angle +{ +int GetANGLERevision(); +const char *GetANGLEVersionString(); +const char *GetANGLECommitHash(); +int GetANGLECommitHashSize(); +bool GetANGLEHasBinaryLoading(); +} // namespace angle + +#endif // COMMON_VERSION_INFO_H_ diff --git a/gfx/angle/checkout/src/common/angleutils.cpp b/gfx/angle/checkout/src/common/angleutils.cpp new file mode 100644 index 0000000000..2b69f66d74 --- /dev/null +++ b/gfx/angle/checkout/src/common/angleutils.cpp @@ -0,0 +1,156 @@ +// +// Copyright 2014 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +#include "common/angleutils.h" +#include "common/debug.h" + +#include + +#include +#include + +namespace angle +{ +// dirtyPointer is a special value that will make the comparison with any valid pointer fail and +// force the renderer to re-apply the state. +const uintptr_t DirtyPointer = std::numeric_limits::max(); + +SaveFileHelper::SaveFileHelper(const std::string &filePathIn) + : mOfs(filePathIn, std::ios::binary | std::ios::out), mFilePath(filePathIn) +{ + if (!mOfs.is_open()) + { + FATAL() << "Could not open " << filePathIn; + } +} + +SaveFileHelper::~SaveFileHelper() +{ + printf("Saved '%s'.\n", mFilePath.c_str()); +} + +void SaveFileHelper::checkError() +{ + if (mOfs.bad()) + { + FATAL() << "Error writing to " << mFilePath; + } +} + +void SaveFileHelper::write(const uint8_t *data, size_t size) +{ + mOfs.write(reinterpret_cast(data), size); +} + +// AMD_performance_monitor helpers. + +PerfMonitorCounter::PerfMonitorCounter() = default; + +PerfMonitorCounter::~PerfMonitorCounter() = default; + +PerfMonitorCounterGroup::PerfMonitorCounterGroup() = default; + +PerfMonitorCounterGroup::~PerfMonitorCounterGroup() = default; + +uint32_t GetPerfMonitorCounterIndex(const PerfMonitorCounters &counters, const std::string &name) +{ + for (uint32_t counterIndex = 0; counterIndex < static_cast(counters.size()); + ++counterIndex) + { + if (counters[counterIndex].name == name) + { + return counterIndex; + } + } + + return std::numeric_limits::max(); +} + +uint32_t GetPerfMonitorCounterGroupIndex(const PerfMonitorCounterGroups &groups, + const std::string &name) +{ + for (uint32_t groupIndex = 0; groupIndex < static_cast(groups.size()); ++groupIndex) + { + if (groups[groupIndex].name == name) + { + return groupIndex; + } + } + + return std::numeric_limits::max(); +} + +const PerfMonitorCounter &GetPerfMonitorCounter(const PerfMonitorCounters &counters, + const std::string &name) +{ + return GetPerfMonitorCounter(const_cast(counters), name); +} + +PerfMonitorCounter &GetPerfMonitorCounter(PerfMonitorCounters &counters, const std::string &name) +{ + uint32_t counterIndex = GetPerfMonitorCounterIndex(counters, name); + ASSERT(counterIndex < static_cast(counters.size())); + return counters[counterIndex]; +} + +const PerfMonitorCounterGroup &GetPerfMonitorCounterGroup(const PerfMonitorCounterGroups &groups, + const std::string &name) +{ + return GetPerfMonitorCounterGroup(const_cast(groups), name); +} + +PerfMonitorCounterGroup &GetPerfMonitorCounterGroup(PerfMonitorCounterGroups &groups, + const std::string &name) +{ + uint32_t groupIndex = GetPerfMonitorCounterGroupIndex(groups, name); + ASSERT(groupIndex < static_cast(groups.size())); + return groups[groupIndex]; +} +} // namespace angle + +std::string ArrayString(unsigned int i) +{ + // We assume that UINT_MAX and GL_INVALID_INDEX are equal. + ASSERT(i != UINT_MAX); + + std::stringstream strstr; + strstr << "["; + strstr << i; + strstr << "]"; + return strstr.str(); +} + +std::string ArrayIndexString(const std::vector &indices) +{ + std::stringstream strstr; + + for (auto indicesIt = indices.rbegin(); indicesIt != indices.rend(); ++indicesIt) + { + // We assume that UINT_MAX and GL_INVALID_INDEX are equal. + ASSERT(*indicesIt != UINT_MAX); + strstr << "["; + strstr << (*indicesIt); + strstr << "]"; + } + + return strstr.str(); +} + +size_t FormatStringIntoVector(const char *fmt, va_list vararg, std::vector &outBuffer) +{ + va_list varargCopy; + va_copy(varargCopy, vararg); + + int len = vsnprintf(nullptr, 0, fmt, vararg); + ASSERT(len >= 0); + + outBuffer.resize(len + 1, 0); + + len = vsnprintf(outBuffer.data(), outBuffer.size(), fmt, varargCopy); + va_end(varargCopy); + ASSERT(len >= 0); + return static_cast(len); +} diff --git a/gfx/angle/checkout/src/common/angleutils.h b/gfx/angle/checkout/src/common/angleutils.h new file mode 100644 index 0000000000..bcbcabc782 --- /dev/null +++ b/gfx/angle/checkout/src/common/angleutils.h @@ -0,0 +1,601 @@ +// +// Copyright 2002 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// angleutils.h: Common ANGLE utilities. + +#ifndef COMMON_ANGLEUTILS_H_ +#define COMMON_ANGLEUTILS_H_ + +#include "common/platform.h" + +#if defined(ANGLE_USE_ABSEIL) +# include "absl/container/flat_hash_map.h" +# include "absl/container/flat_hash_set.h" +#endif // defined(ANGLE_USE_ABSEIL) + +#if defined(ANGLE_WITH_LSAN) +# include +#endif // defined(ANGLE_WITH_LSAN) + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +// A helper class to disallow copy and assignment operators +namespace angle +{ + +#if defined(ANGLE_ENABLE_D3D9) || defined(ANGLE_ENABLE_D3D11) +using Microsoft::WRL::ComPtr; +#endif // defined(ANGLE_ENABLE_D3D9) || defined(ANGLE_ENABLE_D3D11) + +#if defined(ANGLE_USE_ABSEIL) +template > +using HashMap = absl::flat_hash_map; +template > +using HashSet = absl::flat_hash_set; +#else +template > +using HashMap = std::unordered_map; +template > +using HashSet = std::unordered_set; +#endif // defined(ANGLE_USE_ABSEIL) + +class NonCopyable +{ + protected: + constexpr NonCopyable() = default; + ~NonCopyable() = default; + + private: + NonCopyable(const NonCopyable &) = delete; + void operator=(const NonCopyable &) = delete; +}; + +extern const uintptr_t DirtyPointer; + +struct SaveFileHelper +{ + public: + // We always use ios::binary to avoid inconsistent line endings when captured on Linux vs Win. + SaveFileHelper(const std::string &filePathIn); + ~SaveFileHelper(); + + template + SaveFileHelper &operator<<(const T &value) + { + mOfs << value; + checkError(); + return *this; + } + + void write(const uint8_t *data, size_t size); + + private: + void checkError(); + + std::ofstream mOfs; + std::string mFilePath; +}; + +// AMD_performance_monitor helpers. +constexpr char kPerfMonitorExtensionName[] = "GL_AMD_performance_monitor"; + +struct PerfMonitorCounter +{ + PerfMonitorCounter(); + ~PerfMonitorCounter(); + + std::string name; + uint64_t value; +}; +using PerfMonitorCounters = std::vector; + +struct PerfMonitorCounterGroup +{ + PerfMonitorCounterGroup(); + ~PerfMonitorCounterGroup(); + + std::string name; + PerfMonitorCounters counters; +}; +using PerfMonitorCounterGroups = std::vector; + +uint32_t GetPerfMonitorCounterIndex(const PerfMonitorCounters &counters, const std::string &name); +const PerfMonitorCounter &GetPerfMonitorCounter(const PerfMonitorCounters &counters, + const std::string &name); +PerfMonitorCounter &GetPerfMonitorCounter(PerfMonitorCounters &counters, const std::string &name); +uint32_t GetPerfMonitorCounterGroupIndex(const PerfMonitorCounterGroups &groups, + const std::string &name); +const PerfMonitorCounterGroup &GetPerfMonitorCounterGroup(const PerfMonitorCounterGroups &groups, + const std::string &name); +PerfMonitorCounterGroup &GetPerfMonitorCounterGroup(PerfMonitorCounterGroups &groups, + const std::string &name); + +struct PerfMonitorTriplet +{ + uint32_t group; + uint32_t counter; + uint64_t value; +}; + +#define ANGLE_VK_PERF_COUNTERS_X(FN) \ + FN(commandQueueSubmitCallsTotal) \ + FN(commandQueueSubmitCallsPerFrame) \ + FN(vkQueueSubmitCallsTotal) \ + FN(vkQueueSubmitCallsPerFrame) \ + FN(renderPasses) \ + FN(writeDescriptorSets) \ + FN(flushedOutsideRenderPassCommandBuffers) \ + FN(swapchainResolveInSubpass) \ + FN(swapchainResolveOutsideSubpass) \ + FN(resolveImageCommands) \ + FN(colorLoadOpClears) \ + FN(colorLoadOpLoads) \ + FN(colorLoadOpNones) \ + FN(colorStoreOpStores) \ + FN(colorStoreOpNones) \ + FN(colorClearAttachments) \ + FN(depthLoadOpClears) \ + FN(depthLoadOpLoads) \ + FN(depthLoadOpNones) \ + FN(depthStoreOpStores) \ + FN(depthStoreOpNones) \ + FN(depthClearAttachments) \ + FN(stencilLoadOpClears) \ + FN(stencilLoadOpLoads) \ + FN(stencilLoadOpNones) \ + FN(stencilStoreOpStores) \ + FN(stencilStoreOpNones) \ + FN(stencilClearAttachments) \ + FN(colorAttachmentUnresolves) \ + FN(depthAttachmentUnresolves) \ + FN(stencilAttachmentUnresolves) \ + FN(colorAttachmentResolves) \ + FN(depthAttachmentResolves) \ + FN(stencilAttachmentResolves) \ + FN(readOnlyDepthStencilRenderPasses) \ + FN(pipelineCreationCacheHits) \ + FN(pipelineCreationCacheMisses) \ + FN(pipelineCreationTotalCacheHitsDurationNs) \ + FN(pipelineCreationTotalCacheMissesDurationNs) \ + FN(descriptorSetAllocations) \ + FN(descriptorSetCacheTotalSize) \ + FN(descriptorSetCacheKeySizeBytes) \ + FN(uniformsAndXfbDescriptorSetCacheHits) \ + FN(uniformsAndXfbDescriptorSetCacheMisses) \ + FN(uniformsAndXfbDescriptorSetCacheTotalSize) \ + FN(textureDescriptorSetCacheHits) \ + FN(textureDescriptorSetCacheMisses) \ + FN(textureDescriptorSetCacheTotalSize) \ + FN(shaderResourcesDescriptorSetCacheHits) \ + FN(mutableTexturesUploaded) \ + FN(shaderResourcesDescriptorSetCacheMisses) \ + FN(shaderResourcesDescriptorSetCacheTotalSize) \ + FN(buffersGhosted) \ + FN(vertexArraySyncStateCalls) \ + FN(allocateNewBufferBlockCalls) \ + FN(dynamicBufferAllocations) \ + FN(framebufferCacheSize) + +#define ANGLE_DECLARE_PERF_COUNTER(COUNTER) uint64_t COUNTER; + +struct VulkanPerfCounters +{ + ANGLE_VK_PERF_COUNTERS_X(ANGLE_DECLARE_PERF_COUNTER) +}; + +#undef ANGLE_DECLARE_PERF_COUNTER + +} // namespace angle + +template +constexpr inline size_t ArraySize(T (&)[N]) +{ + return N; +} + +template +class WrappedArray final : angle::NonCopyable +{ + public: + template + constexpr WrappedArray(const T (&data)[N]) : mArray(&data[0]), mSize(N) + {} + + constexpr WrappedArray() : mArray(nullptr), mSize(0) {} + constexpr WrappedArray(const T *data, size_t size) : mArray(data), mSize(size) {} + + WrappedArray(WrappedArray &&other) : WrappedArray() + { + std::swap(mArray, other.mArray); + std::swap(mSize, other.mSize); + } + + ~WrappedArray() {} + + constexpr const T *get() const { return mArray; } + constexpr size_t size() const { return mSize; } + + private: + const T *mArray; + size_t mSize; +}; + +template +void SafeRelease(T (&resourceBlock)[N]) +{ + for (unsigned int i = 0; i < N; i++) + { + SafeRelease(resourceBlock[i]); + } +} + +template +void SafeRelease(T &resource) +{ + if (resource) + { + resource->Release(); + resource = nullptr; + } +} + +template +void SafeDelete(T *&resource) +{ + delete resource; + resource = nullptr; +} + +template +void SafeDeleteContainer(T &resource) +{ + for (auto &element : resource) + { + SafeDelete(element); + } + resource.clear(); +} + +template +void SafeDeleteArray(T *&resource) +{ + delete[] resource; + resource = nullptr; +} + +// Provide a less-than function for comparing structs +// Note: struct memory must be initialized to zero, because of packing gaps +template +inline bool StructLessThan(const T &a, const T &b) +{ + return (memcmp(&a, &b, sizeof(T)) < 0); +} + +// Provide a less-than function for comparing structs +// Note: struct memory must be initialized to zero, because of packing gaps +template +inline bool StructEquals(const T &a, const T &b) +{ + return (memcmp(&a, &b, sizeof(T)) == 0); +} + +template +inline void StructZero(T *obj) +{ + memset(obj, 0, sizeof(T)); +} + +template +inline bool IsMaskFlagSet(T mask, T flag) +{ + // Handles multibit flags as well + return (mask & flag) == flag; +} + +inline const char *MakeStaticString(const std::string &str) +{ + // On the heap so that no destructor runs on application exit. + static std::set *strings = new std::set; + std::set::iterator it = strings->find(str); + if (it != strings->end()) + { + return it->c_str(); + } + + return strings->insert(str).first->c_str(); +} + +std::string ArrayString(unsigned int i); + +// Indices are stored in vectors with the outermost index in the back. In the output of the function +// the indices are reversed. +std::string ArrayIndexString(const std::vector &indices); + +inline std::string Str(int i) +{ + std::stringstream strstr; + strstr << i; + return strstr.str(); +} + +template +std::string ToString(const T &value) +{ + std::ostringstream o; + o << value; + return o.str(); +} + +inline bool IsLittleEndian() +{ + constexpr uint32_t kEndiannessTest = 1; + const bool isLittleEndian = *reinterpret_cast(&kEndiannessTest) == 1; + return isLittleEndian; +} + +// Helper class to use a mutex with the control of boolean. +class ConditionalMutex final : angle::NonCopyable +{ + public: + ConditionalMutex() : mUseMutex(true) {} + void init(bool useMutex) { mUseMutex = useMutex; } + void lock() + { + if (mUseMutex) + { + mMutex.lock(); + } + } + void unlock() + { + if (mUseMutex) + { + mMutex.unlock(); + } + } + + private: + std::mutex mMutex; + bool mUseMutex; +}; + +// snprintf is not defined with MSVC prior to to msvc14 +#if defined(_MSC_VER) && _MSC_VER < 1900 +# define snprintf _snprintf +#endif + +#define GL_A1RGB5_ANGLEX 0x6AC5 +#define GL_BGRX8_ANGLEX 0x6ABA +#define GL_BGR565_ANGLEX 0x6ABB +#define GL_BGRA4_ANGLEX 0x6ABC +#define GL_BGR5_A1_ANGLEX 0x6ABD +#define GL_INT_64_ANGLEX 0x6ABE +#define GL_UINT_64_ANGLEX 0x6ABF +#define GL_BGRA8_SRGB_ANGLEX 0x6AC0 +#define GL_BGR10_A2_ANGLEX 0x6AF9 + +// These are fake formats used to fit typeless D3D textures that can be bound to EGL pbuffers into +// the format system (for extension EGL_ANGLE_d3d_texture_client_buffer): +#define GL_RGBA8_TYPELESS_ANGLEX 0x6AC1 +#define GL_RGBA8_TYPELESS_SRGB_ANGLEX 0x6AC2 +#define GL_BGRA8_TYPELESS_ANGLEX 0x6AC3 +#define GL_BGRA8_TYPELESS_SRGB_ANGLEX 0x6AC4 + +#define GL_R8_SSCALED_ANGLEX 0x6AC6 +#define GL_RG8_SSCALED_ANGLEX 0x6AC7 +#define GL_RGB8_SSCALED_ANGLEX 0x6AC8 +#define GL_RGBA8_SSCALED_ANGLEX 0x6AC9 +#define GL_R8_USCALED_ANGLEX 0x6ACA +#define GL_RG8_USCALED_ANGLEX 0x6ACB +#define GL_RGB8_USCALED_ANGLEX 0x6ACC +#define GL_RGBA8_USCALED_ANGLEX 0x6ACD + +#define GL_R16_SSCALED_ANGLEX 0x6ACE +#define GL_RG16_SSCALED_ANGLEX 0x6ACF +#define GL_RGB16_SSCALED_ANGLEX 0x6AD0 +#define GL_RGBA16_SSCALED_ANGLEX 0x6AD1 +#define GL_R16_USCALED_ANGLEX 0x6AD2 +#define GL_RG16_USCALED_ANGLEX 0x6AD3 +#define GL_RGB16_USCALED_ANGLEX 0x6AD4 +#define GL_RGBA16_USCALED_ANGLEX 0x6AD5 + +#define GL_R32_SSCALED_ANGLEX 0x6AD6 +#define GL_RG32_SSCALED_ANGLEX 0x6AD7 +#define GL_RGB32_SSCALED_ANGLEX 0x6AD8 +#define GL_RGBA32_SSCALED_ANGLEX 0x6AD9 +#define GL_R32_USCALED_ANGLEX 0x6ADA +#define GL_RG32_USCALED_ANGLEX 0x6ADB +#define GL_RGB32_USCALED_ANGLEX 0x6ADC +#define GL_RGBA32_USCALED_ANGLEX 0x6ADD + +#define GL_R32_SNORM_ANGLEX 0x6ADE +#define GL_RG32_SNORM_ANGLEX 0x6ADF +#define GL_RGB32_SNORM_ANGLEX 0x6AE0 +#define GL_RGBA32_SNORM_ANGLEX 0x6AE1 +#define GL_R32_UNORM_ANGLEX 0x6AE2 +#define GL_RG32_UNORM_ANGLEX 0x6AE3 +#define GL_RGB32_UNORM_ANGLEX 0x6AE4 +#define GL_RGBA32_UNORM_ANGLEX 0x6AE5 + +#define GL_R32_FIXED_ANGLEX 0x6AE6 +#define GL_RG32_FIXED_ANGLEX 0x6AE7 +#define GL_RGB32_FIXED_ANGLEX 0x6AE8 +#define GL_RGBA32_FIXED_ANGLEX 0x6AE9 + +#define GL_RGB10_A2_SINT_ANGLEX 0x6AEA +#define GL_RGB10_A2_SNORM_ANGLEX 0x6AEB +#define GL_RGB10_A2_SSCALED_ANGLEX 0x6AEC +#define GL_RGB10_A2_USCALED_ANGLEX 0x6AED + +// EXT_texture_type_2_10_10_10_REV +#define GL_RGB10_UNORM_ANGLEX 0x6AEE + +// These are fake formats for OES_vertex_type_10_10_10_2 +#define GL_A2_RGB10_UNORM_ANGLEX 0x6AEF +#define GL_A2_RGB10_SNORM_ANGLEX 0x6AF0 +#define GL_A2_RGB10_USCALED_ANGLEX 0x6AF1 +#define GL_A2_RGB10_SSCALED_ANGLEX 0x6AF2 +#define GL_X2_RGB10_UINT_ANGLEX 0x6AF3 +#define GL_X2_RGB10_SINT_ANGLEX 0x6AF4 +#define GL_X2_RGB10_USCALED_ANGLEX 0x6AF5 +#define GL_X2_RGB10_SSCALED_ANGLEX 0x6AF6 +#define GL_X2_RGB10_UNORM_ANGLEX 0x6AF7 +#define GL_X2_RGB10_SNORM_ANGLEX 0x6AF8 + +#define ANGLE_CHECK_GL_ALLOC(context, result) \ + ANGLE_CHECK(context, result, "Failed to allocate host memory", GL_OUT_OF_MEMORY) + +#define ANGLE_CHECK_GL_MATH(context, result) \ + ANGLE_CHECK(context, result, "Integer overflow.", GL_INVALID_OPERATION) + +#define ANGLE_GL_UNREACHABLE(context) \ + UNREACHABLE(); \ + ANGLE_CHECK(context, false, "Unreachable Code.", GL_INVALID_OPERATION) + +#if defined(ANGLE_WITH_LSAN) +# define ANGLE_SCOPED_DISABLE_LSAN() __lsan::ScopedDisabler lsanDisabler +#else +# define ANGLE_SCOPED_DISABLE_LSAN() +#endif + +#if defined(ANGLE_WITH_MSAN) +class MsanScopedDisableInterceptorChecks final : angle::NonCopyable +{ + public: + MsanScopedDisableInterceptorChecks() { __msan_scoped_disable_interceptor_checks(); } + ~MsanScopedDisableInterceptorChecks() { __msan_scoped_enable_interceptor_checks(); } +}; +# define ANGLE_SCOPED_DISABLE_MSAN() \ + MsanScopedDisableInterceptorChecks msanScopedDisableInterceptorChecks +#else +# define ANGLE_SCOPED_DISABLE_MSAN() +#endif + +// The ANGLE_NO_SANITIZE_MEMORY macro suppresses MemorySanitizer checks for +// use-of-uninitialized-data. It can be used to decorate functions with known +// false positives. +#ifdef __clang__ +# define ANGLE_NO_SANITIZE_MEMORY __attribute__((no_sanitize_memory)) +#else +# define ANGLE_NO_SANITIZE_MEMORY +#endif + +// Similar to the above, but for thread sanitization. +#ifdef __clang__ +# define ANGLE_NO_SANITIZE_THREAD __attribute__((no_sanitize_thread)) +#else +# define ANGLE_NO_SANITIZE_THREAD +#endif + +// The below inlining code lifted from V8. +#if defined(__clang__) || (defined(__GNUC__) && defined(__has_attribute)) +# define ANGLE_HAS_ATTRIBUTE_ALWAYS_INLINE (__has_attribute(always_inline)) +# define ANGLE_HAS___FORCEINLINE 0 +#elif defined(_MSC_VER) +# define ANGLE_HAS_ATTRIBUTE_ALWAYS_INLINE 0 +# define ANGLE_HAS___FORCEINLINE 1 +#else +# define ANGLE_HAS_ATTRIBUTE_ALWAYS_INLINE 0 +# define ANGLE_HAS___FORCEINLINE 0 +#endif + +#if defined(NDEBUG) && ANGLE_HAS_ATTRIBUTE_ALWAYS_INLINE +# define ANGLE_INLINE inline __attribute__((always_inline)) +#elif defined(NDEBUG) && ANGLE_HAS___FORCEINLINE +# define ANGLE_INLINE __forceinline +#else +# define ANGLE_INLINE inline +#endif + +#if defined(__clang__) || (defined(__GNUC__) && defined(__has_attribute)) +# if __has_attribute(noinline) +# define ANGLE_NOINLINE __attribute__((noinline)) +# else +# define ANGLE_NOINLINE +# endif +#elif defined(_MSC_VER) +# define ANGLE_NOINLINE __declspec(noinline) +#else +# define ANGLE_NOINLINE +#endif + +#if defined(__clang__) || (defined(__GNUC__) && defined(__has_attribute)) +# if __has_attribute(format) +# define ANGLE_FORMAT_PRINTF(fmt, args) __attribute__((format(__printf__, fmt, args))) +# else +# define ANGLE_FORMAT_PRINTF(fmt, args) +# endif +#else +# define ANGLE_FORMAT_PRINTF(fmt, args) +#endif + +ANGLE_FORMAT_PRINTF(1, 0) +size_t FormatStringIntoVector(const char *fmt, va_list vararg, std::vector &buffer); + +// Format messes up the # inside the macro. +// clang-format off +#ifndef ANGLE_STRINGIFY +# define ANGLE_STRINGIFY(x) #x +#endif +// clang-format on + +#ifndef ANGLE_MACRO_STRINGIFY +# define ANGLE_MACRO_STRINGIFY(x) ANGLE_STRINGIFY(x) +#endif + +#if __has_cpp_attribute(clang::require_constant_initialization) +# define ANGLE_REQUIRE_CONSTANT_INIT [[clang::require_constant_initialization]] +#else +# define ANGLE_REQUIRE_CONSTANT_INIT +#endif // __has_cpp_attribute(require_constant_initialization) + +// Compiler configs. +inline bool IsASan() +{ +#if defined(ANGLE_WITH_ASAN) + return true; +#else + return false; +#endif // defined(ANGLE_WITH_ASAN) +} + +inline bool IsMSan() +{ +#if defined(ANGLE_WITH_MSAN) + return true; +#else + return false; +#endif // defined(ANGLE_WITH_MSAN) +} + +inline bool IsTSan() +{ +#if defined(ANGLE_WITH_TSAN) + return true; +#else + return false; +#endif // defined(ANGLE_WITH_TSAN) +} + +inline bool IsUBSan() +{ +#if defined(ANGLE_WITH_UBSAN) + return true; +#else + return false; +#endif // defined(ANGLE_WITH_UBSAN) +} +#endif // COMMON_ANGLEUTILS_H_ diff --git a/gfx/angle/checkout/src/common/apple_platform_utils.h b/gfx/angle/checkout/src/common/apple_platform_utils.h new file mode 100644 index 0000000000..da932a9207 --- /dev/null +++ b/gfx/angle/checkout/src/common/apple_platform_utils.h @@ -0,0 +1,90 @@ +// +// Copyright 2019 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// apple_platform_utils.h: Common utilities for Apple platforms. + +#ifndef COMMON_APPLE_PLATFORM_UTILS_H_ +#define COMMON_APPLE_PLATFORM_UTILS_H_ + +#include "common/platform.h" + +// These are macros for substitution of Apple specific directive @available: + +// TARGET_OS_MACCATALYST only available in MacSDK 10.15 + +#if TARGET_OS_MACCATALYST +// ANGLE_APPLE_AVAILABLE_XCI: check if either of the 3 platforms (OSX/Catalyst/iOS) min verions is +// available: +# define ANGLE_APPLE_AVAILABLE_XCI(macVer, macCatalystVer, iOSVer) \ + @available(macOS macVer, macCatalyst macCatalystVer, iOS iOSVer, *) +// ANGLE_APPLE_AVAILABLE_XC: check if either of the 2 platforms (OSX/Catalyst) min verions is +// available: +# define ANGLE_APPLE_AVAILABLE_XC(macVer, macCatalystVer) \ + @available(macOS macVer, macCatalyst macCatalystVer, *) +// ANGLE_APPLE_AVAILABLE_CI: check if either of the 2 platforms (Catalyst/iOS) min verions is +// available: +# define ANGLE_APPLE_AVAILABLE_CI(macCatalystVer, iOSVer) \ + @available(macCatalyst macCatalystVer, iOS iOSVer, *) +#else +# define ANGLE_APPLE_AVAILABLE_XCI(macVer, macCatalystVer, iOSVer) \ + ANGLE_APPLE_AVAILABLE_XI(macVer, iOSVer) + +# define ANGLE_APPLE_AVAILABLE_XC(macVer, macCatalystVer) @available(macOS macVer, *) +# define ANGLE_APPLE_AVAILABLE_CI(macCatalystVer, iOSVer) @available(iOS iOSVer, tvOS iOSVer, *) +#endif + +// ANGLE_APPLE_AVAILABLE_XI: check if either of the 2 platforms (OSX/iOS) min verions is available: +#define ANGLE_APPLE_AVAILABLE_XI(macVer, iOSVer) \ + @available(macOS macVer, iOS iOSVer, tvOS iOSVer, *) + +// ANGLE_APPLE_AVAILABLE_I: check if a particular iOS version is available +#define ANGLE_APPLE_AVAILABLE_I(iOSVer) @available(iOS iOSVer, tvOS iOSVer, *) + +#if TARGET_OS_IPHONE +# if !defined(__IPHONE_11_0) +# define __IPHONE_11_0 110000 +# endif +# if !defined(ANGLE_IOS_DEPLOY_TARGET) +# define ANGLE_IOS_DEPLOY_TARGET __IPHONE_11_0 +# endif +# if !defined(__IPHONE_OS_VERSION_MAX_ALLOWED) +# define __IPHONE_OS_VERSION_MAX_ALLOWED __IPHONE_11_0 +# endif +# if !defined(__TV_OS_VERSION_MAX_ALLOWED) +# define __TV_OS_VERSION_MAX_ALLOWED __IPHONE_11_0 +# endif +#endif + +#if !defined(TARGET_OS_MACCATALYST) +# define TARGET_OS_MACCATALYST 0 +#endif + +#if defined(__ARM_ARCH) +# define ANGLE_APPLE_IS_ARM (__ARM_ARCH != 0) +#else +# define ANGLE_APPLE_IS_ARM 0 +#endif + +#define ANGLE_APPLE_OBJC_SCOPE @autoreleasepool + +#if !__has_feature(objc_arc) +# define ANGLE_APPLE_AUTORELEASE autorelease +# define ANGLE_APPLE_RETAIN retain +# define ANGLE_APPLE_RELEASE release +#else +# define ANGLE_APPLE_AUTORELEASE self +# define ANGLE_APPLE_RETAIN self +# define ANGLE_APPLE_RELEASE self +#endif + +#define ANGLE_APPLE_UNUSED __attribute__((unused)) + +namespace angle +{ +bool IsMetalRendererAvailable(); +} + +#endif diff --git a/gfx/angle/checkout/src/common/bitset_utils.h b/gfx/angle/checkout/src/common/bitset_utils.h new file mode 100644 index 0000000000..ee9a3f1b9b --- /dev/null +++ b/gfx/angle/checkout/src/common/bitset_utils.h @@ -0,0 +1,1106 @@ +// +// Copyright 2015 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// bitset_utils: +// Bitset-related helper classes, such as a fast iterator to scan for set bits. +// + +#ifndef COMMON_BITSETITERATOR_H_ +#define COMMON_BITSETITERATOR_H_ + +#include + +#include + +#include "common/angleutils.h" +#include "common/debug.h" +#include "common/mathutil.h" +#include "common/platform.h" + +namespace angle +{ +// Given x, create 1 << x. +template +constexpr BitsT Bit(ParamT x) +{ + // It's undefined behavior if the shift size is equal to or larger than the width of the type. + ASSERT(static_cast(x) < sizeof(BitsT) * 8); + + return (static_cast(1) << static_cast(x)); +} + +// Given x, create (1 << x) - 1, i.e. a mask with x bits set. +template +constexpr BitsT BitMask(ParamT x) +{ + if (static_cast(x) == 0) + { + return 0; + } + return ((Bit(static_cast(static_cast(x) - 1)) - 1) << 1) | 1; +} + +template +class BitSetT final +{ + public: + class Reference final + { + public: + ~Reference() {} + Reference &operator=(bool x) + { + mParent->set(mBit, x); + return *this; + } + explicit operator bool() const { return mParent->test(mBit); } + + private: + friend class BitSetT; + + Reference(BitSetT *parent, ParamT bit) : mParent(parent), mBit(bit) {} + + BitSetT *mParent; + ParamT mBit; + }; + + class Iterator final + { + public: + Iterator(const BitSetT &bits); + Iterator &operator++(); + + bool operator==(const Iterator &other) const; + bool operator!=(const Iterator &other) const; + ParamT operator*() const; + + // These helper functions allow mutating an iterator in-flight. + // They only operate on later bits to ensure we don't iterate the same bit twice. + void resetLaterBit(std::size_t index) + { + ASSERT(index > mCurrentBit); + mBitsCopy.reset(index); + } + + void setLaterBit(std::size_t index) + { + ASSERT(index > mCurrentBit); + mBitsCopy.set(index); + } + + void setLaterBits(const BitSetT &bits) + { + ASSERT((BitSetT(bits) &= Mask(mCurrentBit + 1)).none()); + mBitsCopy |= bits; + } + + private: + std::size_t getNextBit(); + + BitSetT mBitsCopy; + std::size_t mCurrentBit; + }; + + using value_type = BitsT; + using param_type = ParamT; + + constexpr BitSetT(); + constexpr explicit BitSetT(BitsT value); + constexpr explicit BitSetT(std::initializer_list init); + + constexpr BitSetT(const BitSetT &other); + constexpr BitSetT &operator=(const BitSetT &other); + + constexpr bool operator==(const BitSetT &other) const; + constexpr bool operator!=(const BitSetT &other) const; + + constexpr bool operator[](ParamT pos) const; + Reference operator[](ParamT pos) { return Reference(this, pos); } + + constexpr bool test(ParamT pos) const; + + constexpr bool all() const; + constexpr bool any() const; + constexpr bool none() const; + constexpr std::size_t count() const; + + constexpr static std::size_t size() { return N; } + + constexpr BitSetT &operator&=(const BitSetT &other); + constexpr BitSetT &operator|=(const BitSetT &other); + constexpr BitSetT &operator^=(const BitSetT &other); + constexpr BitSetT operator~() const; + + constexpr BitSetT &operator&=(BitsT value); + constexpr BitSetT &operator|=(BitsT value); + constexpr BitSetT &operator^=(BitsT value); + + constexpr BitSetT operator<<(std::size_t pos) const; + constexpr BitSetT &operator<<=(std::size_t pos); + constexpr BitSetT operator>>(std::size_t pos) const; + constexpr BitSetT &operator>>=(std::size_t pos); + + constexpr BitSetT &set(); + constexpr BitSetT &set(ParamT pos, bool value = true); + + constexpr BitSetT &reset(); + constexpr BitSetT &reset(ParamT pos); + + constexpr BitSetT &flip(); + constexpr BitSetT &flip(ParamT pos); + + constexpr unsigned long to_ulong() const { return static_cast(mBits); } + constexpr BitsT bits() const { return mBits; } + + Iterator begin() const { return Iterator(*this); } + Iterator end() const { return Iterator(BitSetT()); } + + constexpr static BitSetT Zero() { return BitSetT(); } + + constexpr ParamT first() const; + constexpr ParamT last() const; + + // Produces a mask of ones up to the "x"th bit. + constexpr static BitsT Mask(std::size_t x) { return BitMask(static_cast(x)); } + + private: + BitsT mBits; +}; + +template +constexpr BitSetT::BitSetT() : mBits(0) +{ + static_assert(N > 0, "Bitset type cannot support zero bits."); + static_assert(N <= sizeof(BitsT) * 8, "Bitset type cannot support a size this large."); +} + +template +constexpr BitSetT::BitSetT(BitsT value) : mBits(value & Mask(N)) +{} + +template +constexpr BitSetT::BitSetT(std::initializer_list init) : mBits(0) +{ + for (ParamT element : init) + { + mBits |= Bit(element); + } + ASSERT(mBits == (mBits & Mask(N))); +} + +template +constexpr BitSetT::BitSetT(const BitSetT &other) : mBits(other.mBits) +{} + +template +constexpr BitSetT &BitSetT::operator=(const BitSetT &other) +{ + mBits = other.mBits; + return *this; +} + +template +constexpr bool BitSetT::operator==(const BitSetT &other) const +{ + return mBits == other.mBits; +} + +template +constexpr bool BitSetT::operator!=(const BitSetT &other) const +{ + return mBits != other.mBits; +} + +template +constexpr bool BitSetT::operator[](ParamT pos) const +{ + return test(pos); +} + +template +constexpr bool BitSetT::test(ParamT pos) const +{ + return (mBits & Bit(pos)) != 0; +} + +template +constexpr bool BitSetT::all() const +{ + ASSERT(mBits == (mBits & Mask(N))); + return mBits == Mask(N); +} + +template +constexpr bool BitSetT::any() const +{ + ASSERT(mBits == (mBits & Mask(N))); + return (mBits != 0); +} + +template +constexpr bool BitSetT::none() const +{ + ASSERT(mBits == (mBits & Mask(N))); + return (mBits == 0); +} + +template +constexpr std::size_t BitSetT::count() const +{ + return gl::BitCount(mBits); +} + +template +constexpr BitSetT &BitSetT::operator&=(const BitSetT &other) +{ + mBits &= other.mBits; + return *this; +} + +template +constexpr BitSetT &BitSetT::operator|=(const BitSetT &other) +{ + mBits |= other.mBits; + return *this; +} + +template +constexpr BitSetT &BitSetT::operator^=(const BitSetT &other) +{ + mBits = mBits ^ other.mBits; + return *this; +} + +template +constexpr BitSetT BitSetT::operator~() const +{ + return BitSetT(~mBits & Mask(N)); +} + +template +constexpr BitSetT &BitSetT::operator&=(BitsT value) +{ + mBits &= value; + return *this; +} + +template +constexpr BitSetT &BitSetT::operator|=(BitsT value) +{ + mBits |= value; + ASSERT(mBits == (mBits & Mask(N))); + return *this; +} + +template +constexpr BitSetT &BitSetT::operator^=(BitsT value) +{ + mBits ^= value; + ASSERT(mBits == (mBits & Mask(N))); + return *this; +} + +template +constexpr BitSetT BitSetT::operator<<(std::size_t pos) const +{ + return BitSetT((mBits << pos) & Mask(N)); +} + +template +constexpr BitSetT &BitSetT::operator<<=(std::size_t pos) +{ + mBits = mBits << pos & Mask(N); + return *this; +} + +template +constexpr BitSetT BitSetT::operator>>(std::size_t pos) const +{ + return BitSetT(mBits >> pos); +} + +template +constexpr BitSetT &BitSetT::operator>>=(std::size_t pos) +{ + mBits = (mBits >> pos) & Mask(N); + return *this; +} + +template +constexpr BitSetT &BitSetT::set() +{ + ASSERT(mBits == (mBits & Mask(N))); + mBits = Mask(N); + return *this; +} + +template +constexpr BitSetT &BitSetT::set(ParamT pos, bool value) +{ + ASSERT(static_cast(pos) < N); + if (value) + { + mBits |= Bit(pos); + } + else + { + reset(pos); + } + ASSERT(mBits == (mBits & Mask(N))); + return *this; +} + +template +constexpr BitSetT &BitSetT::reset() +{ + ASSERT(mBits == (mBits & Mask(N))); + mBits = 0; + return *this; +} + +template +constexpr BitSetT &BitSetT::reset(ParamT pos) +{ + ASSERT(static_cast(pos) < N); + ASSERT(mBits == (mBits & Mask(N))); + mBits &= ~Bit(pos); + return *this; +} + +template +constexpr BitSetT &BitSetT::flip() +{ + ASSERT(mBits == (mBits & Mask(N))); + mBits ^= Mask(N); + return *this; +} + +template +constexpr BitSetT &BitSetT::flip(ParamT pos) +{ + ASSERT(static_cast(pos) < N); + mBits ^= Bit(pos); + ASSERT(mBits == (mBits & Mask(N))); + return *this; +} + +template +constexpr ParamT BitSetT::first() const +{ + ASSERT(!none()); + return static_cast(gl::ScanForward(mBits)); +} + +template +constexpr ParamT BitSetT::last() const +{ + ASSERT(!none()); + return static_cast(gl::ScanReverse(mBits)); +} + +template +BitSetT::Iterator::Iterator(const BitSetT &bits) : mBitsCopy(bits), mCurrentBit(0) +{ + if (bits.any()) + { + mCurrentBit = getNextBit(); + } +} + +template +ANGLE_INLINE typename BitSetT::Iterator & +BitSetT::Iterator::operator++() +{ + ASSERT(mBitsCopy.any()); + mBitsCopy.reset(static_cast(mCurrentBit)); + mCurrentBit = getNextBit(); + return *this; +} + +template +bool BitSetT::Iterator::operator==(const Iterator &other) const +{ + return mBitsCopy == other.mBitsCopy; +} + +template +bool BitSetT::Iterator::operator!=(const Iterator &other) const +{ + return !(*this == other); +} + +template +ParamT BitSetT::Iterator::operator*() const +{ + return static_cast(mCurrentBit); +} + +template +std::size_t BitSetT::Iterator::getNextBit() +{ + if (mBitsCopy.none()) + { + return 0; + } + + return gl::ScanForward(mBitsCopy.mBits); +} + +template +using BitSet8 = BitSetT; + +template +using BitSet16 = BitSetT; + +template +using BitSet32 = BitSetT; + +template +using BitSet64 = BitSetT; + +template +class BitSetArray; + +namespace priv +{ + +template +using EnableIfBitsFit = typename std::enable_if::type; + +template +struct GetBitSet +{ + using Type = BitSetArray; +}; + +// Prefer 64-bit bitsets on 64-bit CPUs. They seem faster than 32-bit. +#if defined(ANGLE_IS_64_BIT_CPU) +template +struct GetBitSet> +{ + using Type = BitSet64; +}; +constexpr std::size_t kDefaultBitSetSize = 64; +using BaseBitSetType = BitSet64; +#else +template +struct GetBitSet> +{ + using Type = BitSet32; +}; +constexpr std::size_t kDefaultBitSetSize = 32; +using BaseBitSetType = BitSet32; +#endif // defined(ANGLE_IS_64_BIT_CPU) + +} // namespace priv + +template +using BitSet = typename priv::GetBitSet::Type; + +template +class BitSetArray final +{ + public: + using BaseBitSet = priv::BaseBitSetType; + using value_type = BaseBitSet::value_type; + using param_type = BaseBitSet::param_type; + + constexpr BitSetArray(); + constexpr explicit BitSetArray(std::initializer_list init); + + BitSetArray(const BitSetArray &other); + + class Reference final + { + public: + ~Reference() {} + Reference &operator=(bool x) + { + mParent.set(mPosition, x); + return *this; + } + explicit operator bool() const { return mParent.test(mPosition); } + + private: + friend class BitSetArray; + + Reference(BitSetArray &parent, std::size_t pos) : mParent(parent), mPosition(pos) {} + + BitSetArray &mParent; + std::size_t mPosition; + }; + class Iterator final + { + public: + Iterator(const BitSetArray &bitSetArray, std::size_t index); + Iterator &operator++(); + bool operator==(const Iterator &other) const; + bool operator!=(const Iterator &other) const; + size_t operator*() const; + + // These helper functions allow mutating an iterator in-flight. + // They only operate on later bits to ensure we don't iterate the same bit twice. + void resetLaterBit(std::size_t pos) + { + ASSERT(pos > (mIndex * priv::kDefaultBitSetSize) + *mCurrentIterator); + prepareCopy(); + mParentCopy.reset(pos); + updateIteratorBit(pos, false); + } + + void setLaterBit(std::size_t pos) + { + ASSERT(pos > (mIndex * priv::kDefaultBitSetSize) + *mCurrentIterator); + prepareCopy(); + mParentCopy.set(pos); + updateIteratorBit(pos, true); + } + + void setLaterBits(const BitSetArray &bits) + { + prepareCopy(); + mParentCopy |= bits; + updateIteratorBits(bits); + } + + private: + ANGLE_INLINE void prepareCopy() + { + ASSERT(mParent.mBaseBitSetArray[mIndex].end() == + mParentCopy.mBaseBitSetArray[mIndex].end()); + if (mParentCopy.none()) + { + mParentCopy = mParent; + mCurrentParent = &mParentCopy; + } + } + + ANGLE_INLINE void updateIteratorBit(std::size_t pos, bool setBit) + { + // Get the index and offset, update current interator if within range + size_t index = pos >> kShiftForDivision; + size_t offset = pos & kDefaultBitSetSizeMinusOne; + if (index == mIndex) + { + if (setBit) + { + mCurrentIterator.setLaterBit(offset); + } + else + { + mCurrentIterator.resetLaterBit(offset); + } + } + } + + ANGLE_INLINE void updateIteratorBits(const BitSetArray &bits) + { + mCurrentIterator.setLaterBits(bits.mBaseBitSetArray[mIndex]); + } + + // Problem - + // We want to provide the fastest path possible for usecases that iterate though the bitset. + // + // Options - + // 1) For non-mutating iterations the const ref is set as mCurrentParent and only + // for usecases that need to mutate the bitset while iterating we perform a copy of + // into and modify its bits accordingly. + // 2) The alternate approach was to perform a copy all the time in the constructor + // irrespective of whether it was a mutating usecase or not. + // + // Experiment - + // BitSetIteratorPerfTest was run on a Windows machine with Intel CPU and these were the + // results - + // 1) Copy only when necessary - + // RESULT BitSetIteratorPerf.wall_time: run = 116.1067374961 ns + // RESULT BitSetIteratorPerf.trial_steps : run = 8416124 count + // RESULT BitSetIteratorPerf.total_steps : run = 16832251 count + // 2) Copy always - + // RESULT BitSetIteratorPerf.wall_time: run = 242.7446459439 ns + // RESULT BitSetIteratorPerf.trial_steps : run = 4171416 count + // RESULT BitSetIteratorPerf.total_steps : run = 8342834 count + // + // Resolution - + // We settled on the copy only when necessary path. + size_t mIndex; + const BitSetArray &mParent; + BitSetArray mParentCopy; + const BitSetArray *mCurrentParent; + typename BaseBitSet::Iterator mCurrentIterator; + }; + + constexpr static std::size_t size() { return N; } + Iterator begin() const { return Iterator(*this, 0); } + Iterator end() const { return Iterator(*this, kArraySize); } + constexpr unsigned long to_ulong() const + { + // TODO(anglebug.com/5628): Handle serializing more than kDefaultBitSetSize + for (std::size_t index = 1; index < kArraySize; index++) + { + ASSERT(mBaseBitSetArray[index].none()); + } + return static_cast(mBaseBitSetArray[0].to_ulong()); + } + + // Assignment operators + constexpr BitSetArray &operator=(const BitSetArray &other); + constexpr BitSetArray &operator&=(const BitSetArray &other); + constexpr BitSetArray &operator|=(const BitSetArray &other); + constexpr BitSetArray &operator^=(const BitSetArray &other); + + // Bitwise operators + constexpr BitSetArray operator&(const angle::BitSetArray &other) const; + constexpr BitSetArray operator|(const angle::BitSetArray &other) const; + constexpr BitSetArray operator^(const angle::BitSetArray &other) const; + + // Relational Operators + constexpr bool operator==(const angle::BitSetArray &other) const; + constexpr bool operator!=(const angle::BitSetArray &other) const; + + // Unary operators + constexpr BitSetArray operator~() const; + constexpr bool operator[](std::size_t pos) const; + constexpr Reference operator[](std::size_t pos) + { + ASSERT(pos < size()); + return Reference(*this, pos); + } + + // Setter, getters and other helper methods + constexpr BitSetArray &set(); + constexpr BitSetArray &set(std::size_t pos, bool value = true); + constexpr BitSetArray &reset(); + constexpr BitSetArray &reset(std::size_t pos); + constexpr bool test(std::size_t pos) const; + constexpr bool all() const; + constexpr bool any() const; + constexpr bool none() const; + constexpr std::size_t count() const; + constexpr bool intersects(const BitSetArray &other) const; + constexpr BitSetArray &flip(); + constexpr param_type first() const; + constexpr param_type last() const; + + constexpr value_type bits(size_t index) const; + + private: + static constexpr std::size_t kDefaultBitSetSizeMinusOne = priv::kDefaultBitSetSize - 1; + static constexpr std::size_t kShiftForDivision = + static_cast(rx::Log2(static_cast(priv::kDefaultBitSetSize))); + static constexpr std::size_t kArraySize = + ((N + kDefaultBitSetSizeMinusOne) >> kShiftForDivision); + constexpr static std::size_t kLastElementCount = (N & kDefaultBitSetSizeMinusOne); + constexpr static std::size_t kLastElementMask = priv::BaseBitSetType::Mask( + kLastElementCount == 0 ? priv::kDefaultBitSetSize : kLastElementCount); + + std::array mBaseBitSetArray; +}; + +template +constexpr BitSetArray::BitSetArray() +{ + static_assert(N > priv::kDefaultBitSetSize, "BitSetArray type can't support requested size."); + reset(); +} + +template +constexpr BitSetArray::BitSetArray(std::initializer_list init) +{ + reset(); + + for (param_type element : init) + { + size_t index = element >> kShiftForDivision; + size_t offset = element & kDefaultBitSetSizeMinusOne; + mBaseBitSetArray[index].set(offset, true); + } +} + +template +BitSetArray::BitSetArray(const BitSetArray &other) +{ + for (std::size_t index = 0; index < kArraySize; index++) + { + mBaseBitSetArray[index] = other.mBaseBitSetArray[index]; + } +} + +template +BitSetArray::Iterator::Iterator(const BitSetArray &bitSetArray, std::size_t index) + : mIndex(index), + mParent(bitSetArray), + mCurrentParent(&mParent), + mCurrentIterator(mParent.mBaseBitSetArray[0].begin()) +{ + while (mIndex < mCurrentParent->kArraySize) + { + if (mCurrentParent->mBaseBitSetArray[mIndex].any()) + { + break; + } + mIndex++; + } + + if (mIndex < mCurrentParent->kArraySize) + { + mCurrentIterator = mCurrentParent->mBaseBitSetArray[mIndex].begin(); + } + else + { + mCurrentIterator = mCurrentParent->mBaseBitSetArray[mCurrentParent->kArraySize - 1].end(); + } +} + +template +typename BitSetArray::Iterator &BitSetArray::Iterator::operator++() +{ + ++mCurrentIterator; + while (mCurrentIterator == mCurrentParent->mBaseBitSetArray[mIndex].end()) + { + mIndex++; + if (mIndex >= mCurrentParent->kArraySize) + { + break; + } + mCurrentIterator = mCurrentParent->mBaseBitSetArray[mIndex].begin(); + } + return *this; +} + +template +bool BitSetArray::Iterator::operator==(const BitSetArray::Iterator &other) const +{ + return mCurrentIterator == other.mCurrentIterator; +} + +template +bool BitSetArray::Iterator::operator!=(const BitSetArray::Iterator &other) const +{ + return mCurrentIterator != other.mCurrentIterator; +} + +template +std::size_t BitSetArray::Iterator::operator*() const +{ + return (mIndex * priv::kDefaultBitSetSize) + *mCurrentIterator; +} + +template +constexpr BitSetArray &BitSetArray::operator=(const BitSetArray &other) +{ + for (std::size_t index = 0; index < kArraySize; index++) + { + mBaseBitSetArray[index] = other.mBaseBitSetArray[index]; + } + return *this; +} + +template +constexpr BitSetArray &BitSetArray::operator&=(const BitSetArray &other) +{ + for (std::size_t index = 0; index < kArraySize; index++) + { + mBaseBitSetArray[index] &= other.mBaseBitSetArray[index]; + } + return *this; +} + +template +constexpr BitSetArray &BitSetArray::operator|=(const BitSetArray &other) +{ + for (std::size_t index = 0; index < kArraySize; index++) + { + mBaseBitSetArray[index] |= other.mBaseBitSetArray[index]; + } + return *this; +} + +template +constexpr BitSetArray &BitSetArray::operator^=(const BitSetArray &other) +{ + for (std::size_t index = 0; index < kArraySize; index++) + { + mBaseBitSetArray[index] ^= other.mBaseBitSetArray[index]; + } + return *this; +} + +template +constexpr BitSetArray BitSetArray::operator&(const angle::BitSetArray &other) const +{ + angle::BitSetArray result(other); + result &= *this; + return result; +} + +template +constexpr BitSetArray BitSetArray::operator|(const angle::BitSetArray &other) const +{ + angle::BitSetArray result(other); + result |= *this; + return result; +} + +template +constexpr BitSetArray BitSetArray::operator^(const angle::BitSetArray &other) const +{ + angle::BitSetArray result(other); + result ^= *this; + return result; +} + +template +constexpr bool BitSetArray::operator==(const angle::BitSetArray &other) const +{ + for (std::size_t index = 0; index < kArraySize; index++) + { + if (mBaseBitSetArray[index] != other.mBaseBitSetArray[index]) + { + return false; + } + } + return true; +} + +template +constexpr bool BitSetArray::operator!=(const angle::BitSetArray &other) const +{ + return !(*this == other); +} + +template +constexpr BitSetArray BitSetArray::operator~() const +{ + angle::BitSetArray result; + for (std::size_t index = 0; index < kArraySize; index++) + { + result.mBaseBitSetArray[index] |= ~mBaseBitSetArray[index]; + } + // The last element in result may need special handling + result.mBaseBitSetArray[kArraySize - 1] &= kLastElementMask; + + return result; +} + +template +constexpr bool BitSetArray::operator[](std::size_t pos) const +{ + ASSERT(pos < size()); + return test(pos); +} + +template +constexpr BitSetArray &BitSetArray::set() +{ + for (BaseBitSet &baseBitSet : mBaseBitSetArray) + { + baseBitSet.set(); + } + // The last element in mBaseBitSetArray may need special handling + mBaseBitSetArray[kArraySize - 1] &= kLastElementMask; + + return *this; +} + +template +constexpr BitSetArray &BitSetArray::set(std::size_t pos, bool value) +{ + ASSERT(pos < size()); + // Get the index and offset, then set the bit + size_t index = pos >> kShiftForDivision; + size_t offset = pos & kDefaultBitSetSizeMinusOne; + mBaseBitSetArray[index].set(offset, value); + return *this; +} + +template +constexpr BitSetArray &BitSetArray::reset() +{ + for (BaseBitSet &baseBitSet : mBaseBitSetArray) + { + baseBitSet.reset(); + } + return *this; +} + +template +constexpr BitSetArray &BitSetArray::reset(std::size_t pos) +{ + ASSERT(pos < size()); + return set(pos, false); +} + +template +constexpr bool BitSetArray::test(std::size_t pos) const +{ + ASSERT(pos < size()); + // Get the index and offset, then test the bit + size_t index = pos >> kShiftForDivision; + size_t offset = pos & kDefaultBitSetSizeMinusOne; + return mBaseBitSetArray[index].test(offset); +} + +template +constexpr bool BitSetArray::all() const +{ + constexpr priv::BaseBitSetType kLastElementBitSet = priv::BaseBitSetType(kLastElementMask); + + for (std::size_t index = 0; index < kArraySize - 1; index++) + { + if (!mBaseBitSetArray[index].all()) + { + return false; + } + } + + // The last element in mBaseBitSetArray may need special handling + return mBaseBitSetArray[kArraySize - 1] == kLastElementBitSet; +} + +template +constexpr bool BitSetArray::any() const +{ + for (const BaseBitSet &baseBitSet : mBaseBitSetArray) + { + if (baseBitSet.any()) + { + return true; + } + } + return false; +} + +template +constexpr bool BitSetArray::none() const +{ + for (const BaseBitSet &baseBitSet : mBaseBitSetArray) + { + if (!baseBitSet.none()) + { + return false; + } + } + return true; +} + +template +constexpr std::size_t BitSetArray::count() const +{ + size_t count = 0; + for (const BaseBitSet &baseBitSet : mBaseBitSetArray) + { + count += baseBitSet.count(); + } + return count; +} + +template +constexpr bool BitSetArray::intersects(const BitSetArray &other) const +{ + for (std::size_t index = 0; index < kArraySize; index++) + { + if ((mBaseBitSetArray[index].bits() & other.mBaseBitSetArray[index].bits()) != 0) + { + return true; + } + } + return false; +} + +template +constexpr BitSetArray &BitSetArray::flip() +{ + for (BaseBitSet &baseBitSet : mBaseBitSetArray) + { + baseBitSet.flip(); + } + + // The last element in mBaseBitSetArray may need special handling + mBaseBitSetArray[kArraySize - 1] &= kLastElementMask; + return *this; +} + +template +constexpr typename BitSetArray::param_type BitSetArray::first() const +{ + ASSERT(any()); + for (size_t arrayIndex = 0; arrayIndex < kArraySize; ++arrayIndex) + { + const BaseBitSet &baseBitSet = mBaseBitSetArray[arrayIndex]; + if (baseBitSet.any()) + { + return baseBitSet.first() + arrayIndex * priv::kDefaultBitSetSize; + } + } + UNREACHABLE(); + return 0; +} + +template +constexpr typename BitSetArray::param_type BitSetArray::last() const +{ + ASSERT(any()); + for (size_t arrayIndex = kArraySize; arrayIndex > 0; --arrayIndex) + { + const BaseBitSet &baseBitSet = mBaseBitSetArray[arrayIndex - 1]; + if (baseBitSet.any()) + { + return baseBitSet.last() + (arrayIndex - 1) * priv::kDefaultBitSetSize; + } + } + UNREACHABLE(); + return 0; +} + +template +constexpr typename BitSetArray::value_type BitSetArray::bits(size_t index) const +{ + return mBaseBitSetArray[index].bits(); +} +} // namespace angle + +template +inline constexpr angle::BitSetT operator&( + const angle::BitSetT &lhs, + const angle::BitSetT &rhs) +{ + angle::BitSetT result(lhs); + result &= rhs.bits(); + return result; +} + +template +inline constexpr angle::BitSetT operator|( + const angle::BitSetT &lhs, + const angle::BitSetT &rhs) +{ + angle::BitSetT result(lhs); + result |= rhs.bits(); + return result; +} + +template +inline constexpr angle::BitSetT operator^( + const angle::BitSetT &lhs, + const angle::BitSetT &rhs) +{ + angle::BitSetT result(lhs); + result ^= rhs.bits(); + return result; +} + +template +inline bool operator==(angle::BitSetT &lhs, angle::BitSetT &rhs) +{ + return lhs.bits() == rhs.bits(); +} + +template +inline bool operator!=(angle::BitSetT &lhs, angle::BitSetT &rhs) +{ + return !(lhs == rhs); +} + +#endif // COMMON_BITSETITERATOR_H_ diff --git a/gfx/angle/checkout/src/common/debug.cpp b/gfx/angle/checkout/src/common/debug.cpp new file mode 100644 index 0000000000..23424d443a --- /dev/null +++ b/gfx/angle/checkout/src/common/debug.cpp @@ -0,0 +1,349 @@ +// +// Copyright 2002 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// debug.cpp: Debugging utilities. + +#include "common/debug.h" + +#include + +#include +#include +#include +#include +#include +#include + +#if defined(ANGLE_PLATFORM_ANDROID) +# include +#endif + +#if defined(ANGLE_PLATFORM_APPLE) +# include +#endif + +#if defined(ANGLE_PLATFORM_WINDOWS) +# include +#endif + +#include "anglebase/no_destructor.h" +#include "common/Optional.h" +#include "common/angleutils.h" +#include "common/entry_points_enum_autogen.h" +#include "common/system_utils.h" + +namespace gl +{ + +namespace +{ + +DebugAnnotator *g_debugAnnotator = nullptr; + +std::mutex *g_debugMutex = nullptr; + +constexpr std::array g_logSeverityNames = { + {"EVENT", "INFO", "WARN", "ERR", "FATAL"}}; + +constexpr const char *LogSeverityName(int severity) +{ + return (severity >= 0 && severity < LOG_NUM_SEVERITIES) ? g_logSeverityNames[severity] + : "UNKNOWN"; +} + +bool ShouldCreateLogMessage(LogSeverity severity) +{ +#if defined(ANGLE_TRACE_ENABLED) + return true; +#elif defined(ANGLE_ENABLE_ASSERTS) + return severity == LOG_FATAL || severity == LOG_ERR || severity == LOG_WARN; +#else + return severity == LOG_FATAL || severity == LOG_ERR; +#endif +} + +} // namespace + +namespace priv +{ + +bool ShouldCreatePlatformLogMessage(LogSeverity severity) +{ +#if defined(ANGLE_TRACE_ENABLED) + return true; +#else + return severity != LOG_EVENT; +#endif +} + +// This is never instantiated, it's just used for EAT_STREAM_PARAMETERS to an object of the correct +// type on the LHS of the unused part of the ternary operator. +std::ostream *gSwallowStream; +} // namespace priv + +bool DebugAnnotationsActive(const gl::Context *context) +{ +#if defined(ANGLE_ENABLE_DEBUG_ANNOTATIONS) || defined(ANGLE_ENABLE_DEBUG_TRACE) + return g_debugAnnotator != nullptr && g_debugAnnotator->getStatus(context); +#else + return false; +#endif +} + +bool ShouldBeginScopedEvent(const gl::Context *context) +{ +#if defined(ANGLE_ENABLE_ANNOTATOR_RUN_TIME_CHECKS) + return DebugAnnotationsActive(context); +#else + return true; +#endif // defined(ANGLE_ENABLE_ANNOTATOR_RUN_TIME_CHECKS) +} + +bool DebugAnnotationsInitialized() +{ + return g_debugAnnotator != nullptr; +} + +void InitializeDebugAnnotations(DebugAnnotator *debugAnnotator) +{ + UninitializeDebugAnnotations(); + g_debugAnnotator = debugAnnotator; +} + +void UninitializeDebugAnnotations() +{ + // Pointer is not managed. + g_debugAnnotator = nullptr; +} + +void InitializeDebugMutexIfNeeded() +{ + if (g_debugMutex == nullptr) + { + g_debugMutex = new std::mutex(); + } +} + +std::mutex &GetDebugMutex() +{ + ASSERT(g_debugMutex); + return *g_debugMutex; +} + +ScopedPerfEventHelper::ScopedPerfEventHelper(gl::Context *context, angle::EntryPoint entryPoint) + : mContext(context), mEntryPoint(entryPoint), mFunctionName(nullptr), mCalledBeginEvent(false) +{} + +ScopedPerfEventHelper::~ScopedPerfEventHelper() +{ + // EGL_Initialize() and EGL_Terminate() can change g_debugAnnotator. Must check the value of + // g_debugAnnotator and whether ScopedPerfEventHelper::begin() initiated a begine that must be + // ended now. + if (DebugAnnotationsInitialized() && mCalledBeginEvent) + { + g_debugAnnotator->endEvent(mContext, mFunctionName, mEntryPoint); + } +} + +void ScopedPerfEventHelper::begin(const char *format, ...) +{ + mFunctionName = GetEntryPointName(mEntryPoint); + + va_list vararg; + va_start(vararg, format); + + std::vector buffer; + size_t len = FormatStringIntoVector(format, vararg, buffer); + va_end(vararg); + + ANGLE_LOG(EVENT) << std::string(&buffer[0], len); + if (DebugAnnotationsInitialized()) + { + mCalledBeginEvent = true; + g_debugAnnotator->beginEvent(mContext, mEntryPoint, mFunctionName, buffer.data()); + } +} + +LogMessage::LogMessage(const char *file, const char *function, int line, LogSeverity severity) + : mFile(file), mFunction(function), mLine(line), mSeverity(severity) +{ + // INFO() and EVENT() do not require additional function(line) info. + if (mSeverity > LOG_INFO) + { + const char *slash = std::max(strrchr(mFile, '/'), strrchr(mFile, '\\')); + mStream << (slash ? (slash + 1) : mFile) << ":" << mLine << " (" << mFunction << "): "; + } +} + +LogMessage::~LogMessage() +{ + { + std::unique_lock lock; + if (g_debugMutex != nullptr) + { + lock = std::unique_lock(*g_debugMutex); + } + + if (DebugAnnotationsInitialized() && (mSeverity > LOG_INFO)) + { + g_debugAnnotator->logMessage(*this); + } + else + { + Trace(getSeverity(), getMessage().c_str()); + } + } + + if (mSeverity == LOG_FATAL) + { + if (angle::IsDebuggerAttached()) + { + angle::BreakDebugger(); + } + else + { + ANGLE_CRASH(); + } + } +} + +void Trace(LogSeverity severity, const char *message) +{ + if (!ShouldCreateLogMessage(severity)) + { + return; + } + + std::string str(message); + + if (DebugAnnotationsActive(/*context=*/nullptr)) + { + + switch (severity) + { + case LOG_EVENT: + // Debugging logging done in ScopedPerfEventHelper + break; + default: + g_debugAnnotator->setMarker(/*context=*/nullptr, message); + break; + } + } + + if (severity == LOG_FATAL || severity == LOG_ERR || severity == LOG_WARN || +#if defined(ANGLE_ENABLE_TRACE_ANDROID_LOGCAT) || defined(ANGLE_ENABLE_TRACE_EVENTS) + severity == LOG_EVENT || +#endif + severity == LOG_INFO) + { +#if defined(ANGLE_PLATFORM_ANDROID) + android_LogPriority android_priority = ANDROID_LOG_ERROR; + switch (severity) + { + case LOG_INFO: + case LOG_EVENT: + android_priority = ANDROID_LOG_INFO; + break; + case LOG_WARN: + android_priority = ANDROID_LOG_WARN; + break; + case LOG_ERR: + android_priority = ANDROID_LOG_ERROR; + break; + case LOG_FATAL: + android_priority = ANDROID_LOG_FATAL; + break; + default: + UNREACHABLE(); + } + __android_log_print(android_priority, "ANGLE", "%s: %s\n", LogSeverityName(severity), + str.c_str()); +#elif defined(ANGLE_PLATFORM_APPLE) + if (__builtin_available(macOS 10.12, iOS 10.0, *)) + { + os_log_type_t apple_log_type = OS_LOG_TYPE_DEFAULT; + switch (severity) + { + case LOG_INFO: + apple_log_type = OS_LOG_TYPE_INFO; + break; + case LOG_WARN: + apple_log_type = OS_LOG_TYPE_DEFAULT; + break; + case LOG_ERR: + apple_log_type = OS_LOG_TYPE_ERROR; + break; + case LOG_FATAL: + // OS_LOG_TYPE_FAULT is too severe - grabs the entire process tree. + apple_log_type = OS_LOG_TYPE_ERROR; + break; + default: + UNREACHABLE(); + } + os_log_with_type(OS_LOG_DEFAULT, apple_log_type, "ANGLE: %s: %s\n", + LogSeverityName(severity), str.c_str()); + } +#else + // Note: we use fprintf because includes static initializers. + fprintf((severity >= LOG_WARN) ? stderr : stdout, "%s: %s\n", LogSeverityName(severity), + str.c_str()); +#endif + } + +#if defined(ANGLE_PLATFORM_WINDOWS) && \ + (defined(ANGLE_ENABLE_DEBUG_TRACE_TO_DEBUGGER) || !defined(NDEBUG)) +# if !defined(ANGLE_ENABLE_DEBUG_TRACE_TO_DEBUGGER) + if (severity >= LOG_ERR) +# endif // !defined(ANGLE_ENABLE_DEBUG_TRACE_TO_DEBUGGER) + { + OutputDebugStringA(str.c_str()); + OutputDebugStringA("\n"); + } +#endif + +#if defined(ANGLE_ENABLE_DEBUG_TRACE) +# if defined(NDEBUG) + if (severity == LOG_EVENT || severity == LOG_WARN || severity == LOG_INFO) + { + return; + } +# endif // defined(NDEBUG) + static angle::base::NoDestructor file(TRACE_OUTPUT_FILE, std::ofstream::app); + if (file->good()) + { + if (severity > LOG_EVENT) + { + *file << LogSeverityName(severity) << ": "; + } + *file << str << "\n"; + file->flush(); + } +#endif // defined(ANGLE_ENABLE_DEBUG_TRACE) +} + +LogSeverity LogMessage::getSeverity() const +{ + return mSeverity; +} + +std::string LogMessage::getMessage() const +{ + return mStream.str(); +} + +#if defined(ANGLE_PLATFORM_WINDOWS) +priv::FmtHexHelper FmtHR(HRESULT value) +{ + return priv::FmtHexHelper("HRESULT: ", value); +} + +priv::FmtHexHelper FmtErr(DWORD value) +{ + return priv::FmtHexHelper("error: ", value); +} +#endif // defined(ANGLE_PLATFORM_WINDOWS) + +} // namespace gl diff --git a/gfx/angle/checkout/src/common/debug.h b/gfx/angle/checkout/src/common/debug.h new file mode 100644 index 0000000000..a9ee795103 --- /dev/null +++ b/gfx/angle/checkout/src/common/debug.h @@ -0,0 +1,468 @@ +// +// Copyright 2002 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// debug.h: Debugging utilities. A lot of the logging code is adapted from Chromium's +// base/logging.h. + +#ifndef COMMON_DEBUG_H_ +#define COMMON_DEBUG_H_ + +#include +#include + +#include +#include +#include +#include +#include + +#include "common/angleutils.h" +#include "common/entry_points_enum_autogen.h" +#include "common/platform.h" + +#if defined(ANGLE_PLATFORM_WINDOWS) +# include +typedef unsigned long DWORD; +typedef _Return_type_success_(return >= 0) long HRESULT; +#endif + +#if !defined(TRACE_OUTPUT_FILE) +# define TRACE_OUTPUT_FILE "angle_debug.txt" +#endif + +namespace gl +{ +class Context; + +// Pairs a begin event with an end event. +class [[nodiscard]] ScopedPerfEventHelper : angle::NonCopyable +{ + public: + ScopedPerfEventHelper(Context *context, angle::EntryPoint entryPoint); + ~ScopedPerfEventHelper(); + ANGLE_FORMAT_PRINTF(2, 3) + void begin(const char *format, ...); + + private: + gl::Context *mContext; + const angle::EntryPoint mEntryPoint; + const char *mFunctionName; + bool mCalledBeginEvent; +}; + +using LogSeverity = int; +// Note: the log severities are used to index into the array of names, +// see g_logSeverityNames. +constexpr LogSeverity LOG_EVENT = 0; +constexpr LogSeverity LOG_INFO = 1; +constexpr LogSeverity LOG_WARN = 2; +constexpr LogSeverity LOG_ERR = 3; +constexpr LogSeverity LOG_FATAL = 4; +constexpr LogSeverity LOG_NUM_SEVERITIES = 5; + +void Trace(LogSeverity severity, const char *message); + +// This class more or less represents a particular log message. You +// create an instance of LogMessage and then stream stuff to it. +// When you finish streaming to it, ~LogMessage is called and the +// full message gets streamed to the appropriate destination. +// +// You shouldn't actually use LogMessage's constructor to log things, +// though. You should use the ERR() and WARN() macros. +class LogMessage : angle::NonCopyable +{ + public: + // Used for ANGLE_LOG(severity). + LogMessage(const char *file, const char *function, int line, LogSeverity severity); + ~LogMessage(); + std::ostream &stream() { return mStream; } + + LogSeverity getSeverity() const; + std::string getMessage() const; + + private: + const char *mFile; + const char *mFunction; + const int mLine; + const LogSeverity mSeverity; + + std::ostringstream mStream; +}; + +// Wraps the API/Platform-specific debug annotation functions. +// Also handles redirecting logging destination. +class DebugAnnotator : angle::NonCopyable +{ + public: + DebugAnnotator() {} + virtual ~DebugAnnotator() {} + virtual void beginEvent(gl::Context *context, + angle::EntryPoint entryPoint, + const char *eventName, + const char *eventMessage) = 0; + virtual void endEvent(gl::Context *context, + const char *eventName, + angle::EntryPoint entryPoint) = 0; + virtual void setMarker(gl::Context *context, const char *markerName) = 0; + virtual bool getStatus(const gl::Context *context) = 0; + // Log Message Handler that gets passed every log message, + // when debug annotations are initialized, + // replacing default handling by LogMessage. + virtual void logMessage(const LogMessage &msg) const = 0; +}; + +bool ShouldBeginScopedEvent(const gl::Context *context); +void InitializeDebugAnnotations(DebugAnnotator *debugAnnotator); +void UninitializeDebugAnnotations(); +bool DebugAnnotationsActive(const gl::Context *context); +bool DebugAnnotationsInitialized(); + +void InitializeDebugMutexIfNeeded(); + +std::mutex &GetDebugMutex(); + +namespace priv +{ +// This class is used to explicitly ignore values in the conditional logging macros. This avoids +// compiler warnings like "value computed is not used" and "statement has no effect". +class LogMessageVoidify +{ + public: + LogMessageVoidify() {} + // This has to be an operator with a precedence lower than << but higher than ?: + void operator&(std::ostream &) {} +}; + +extern std::ostream *gSwallowStream; + +// Used by ANGLE_LOG_IS_ON to lazy-evaluate stream arguments. +bool ShouldCreatePlatformLogMessage(LogSeverity severity); + +// N is the width of the output to the stream. The output is padded with zeros +// if value is less than N characters. +// S is the stream type, either ostream for ANSI or wostream for wide character. +// T is the type of the value to output to the stream. +// C is the type of characters - either char for ANSI or wchar_t for wide char. +template +S &FmtHex(S &stream, T value, const C *zeroX, C zero) +{ + stream << zeroX; + + std::ios_base::fmtflags oldFlags = stream.flags(); + std::streamsize oldWidth = stream.width(); + typename S::char_type oldFill = stream.fill(); + + stream << std::hex << std::uppercase << std::setw(N) << std::setfill(zero) << value; + + stream.flags(oldFlags); + stream.width(oldWidth); + stream.fill(oldFill); + + return stream; +} + +template +S &FmtHexAutoSized(S &stream, T value, const C *prefix, const C *zeroX, C zero) +{ + if (prefix) + { + stream << prefix; + } + + constexpr int N = sizeof(T) * 2; + return priv::FmtHex(stream, value, zeroX, zero); +} + +template +class FmtHexHelper +{ + public: + FmtHexHelper(const C *prefix, T value) : mPrefix(prefix), mValue(value) {} + explicit FmtHexHelper(T value) : mPrefix(nullptr), mValue(value) {} + + private: + const C *mPrefix; + T mValue; + + friend std::ostream &operator<<(std::ostream &os, const FmtHexHelper &fmt) + { + return FmtHexAutoSized(os, fmt.mValue, fmt.mPrefix, "0x", '0'); + } + + friend std::wostream &operator<<(std::wostream &wos, const FmtHexHelper &fmt) + { + return FmtHexAutoSized(wos, fmt.mValue, fmt.mPrefix, L"0x", L'0'); + } +}; + +} // namespace priv + +template +priv::FmtHexHelper FmtHex(T value) +{ + return priv::FmtHexHelper(value); +} + +#if defined(ANGLE_PLATFORM_WINDOWS) +priv::FmtHexHelper FmtHR(HRESULT value); +priv::FmtHexHelper FmtErr(DWORD value); +#endif // defined(ANGLE_PLATFORM_WINDOWS) + +template +std::ostream &FmtHex(std::ostream &os, T value) +{ + return priv::FmtHexAutoSized(os, value, "", "0x", '0'); +} + +// A few definitions of macros that don't generate much code. These are used +// by ANGLE_LOG(). Since these are used all over our code, it's +// better to have compact code for these operations. +#define COMPACT_ANGLE_LOG_EX_EVENT(ClassName, ...) \ + ::gl::ClassName(__FILE__, __FUNCTION__, __LINE__, ::gl::LOG_EVENT, ##__VA_ARGS__) +#define COMPACT_ANGLE_LOG_EX_INFO(ClassName, ...) \ + ::gl::ClassName(__FILE__, __FUNCTION__, __LINE__, ::gl::LOG_INFO, ##__VA_ARGS__) +#define COMPACT_ANGLE_LOG_EX_WARN(ClassName, ...) \ + ::gl::ClassName(__FILE__, __FUNCTION__, __LINE__, ::gl::LOG_WARN, ##__VA_ARGS__) +#define COMPACT_ANGLE_LOG_EX_ERR(ClassName, ...) \ + ::gl::ClassName(__FILE__, __FUNCTION__, __LINE__, ::gl::LOG_ERR, ##__VA_ARGS__) +#define COMPACT_ANGLE_LOG_EX_FATAL(ClassName, ...) \ + ::gl::ClassName(__FILE__, __FUNCTION__, __LINE__, ::gl::LOG_FATAL, ##__VA_ARGS__) + +#define COMPACT_ANGLE_LOG_EVENT COMPACT_ANGLE_LOG_EX_EVENT(LogMessage) +#define COMPACT_ANGLE_LOG_INFO COMPACT_ANGLE_LOG_EX_INFO(LogMessage) +#define COMPACT_ANGLE_LOG_WARN COMPACT_ANGLE_LOG_EX_WARN(LogMessage) +#define COMPACT_ANGLE_LOG_ERR COMPACT_ANGLE_LOG_EX_ERR(LogMessage) +#define COMPACT_ANGLE_LOG_FATAL COMPACT_ANGLE_LOG_EX_FATAL(LogMessage) + +#define ANGLE_LOG_IS_ON(severity) (::gl::priv::ShouldCreatePlatformLogMessage(::gl::LOG_##severity)) + +// Helper macro which avoids evaluating the arguments to a stream if the condition doesn't hold. +// Condition is evaluated once and only once. +#define ANGLE_LAZY_STREAM(stream, condition) \ + !(condition) ? static_cast(0) : ::gl::priv::LogMessageVoidify() & (stream) + +// We use the preprocessor's merging operator, "##", so that, e.g., +// ANGLE_LOG(EVENT) becomes the token COMPACT_ANGLE_LOG_EVENT. There's some funny +// subtle difference between ostream member streaming functions (e.g., +// ostream::operator<<(int) and ostream non-member streaming functions +// (e.g., ::operator<<(ostream&, string&): it turns out that it's +// impossible to stream something like a string directly to an unnamed +// ostream. We employ a neat hack by calling the stream() member +// function of LogMessage which seems to avoid the problem. +#define ANGLE_LOG_STREAM(severity) COMPACT_ANGLE_LOG_##severity.stream() + +#define ANGLE_LOG(severity) ANGLE_LAZY_STREAM(ANGLE_LOG_STREAM(severity), ANGLE_LOG_IS_ON(severity)) + +} // namespace gl + +#if defined(ANGLE_ENABLE_DEBUG_TRACE) || defined(ANGLE_ENABLE_DEBUG_ANNOTATIONS) +# define ANGLE_TRACE_ENABLED +#endif + +#if !defined(NDEBUG) || defined(ANGLE_ASSERT_ALWAYS_ON) +# define ANGLE_ENABLE_ASSERTS +#endif + +#define INFO() ANGLE_LOG(INFO) +#define WARN() ANGLE_LOG(WARN) +#define ERR() ANGLE_LOG(ERR) +#define FATAL() ANGLE_LOG(FATAL) + +// A macro to log a performance event around a scope. +#if defined(ANGLE_TRACE_ENABLED) +# if defined(_MSC_VER) +# define EVENT(context, entryPoint, message, ...) \ + gl::ScopedPerfEventHelper scopedPerfEventHelper##__LINE__( \ + context, angle::EntryPoint::entryPoint); \ + do \ + { \ + if (gl::ShouldBeginScopedEvent(context)) \ + { \ + scopedPerfEventHelper##__LINE__.begin( \ + "%s(" message ")", GetEntryPointName(angle::EntryPoint::entryPoint), \ + __VA_ARGS__); \ + } \ + } while (0) +# else +# define EVENT(context, entryPoint, message, ...) \ + gl::ScopedPerfEventHelper scopedPerfEventHelper(context, \ + angle::EntryPoint::entryPoint); \ + do \ + { \ + if (gl::ShouldBeginScopedEvent(context)) \ + { \ + scopedPerfEventHelper.begin("%s(" message ")", \ + GetEntryPointName(angle::EntryPoint::entryPoint), \ + ##__VA_ARGS__); \ + } \ + } while (0) +# endif // _MSC_VER +#else +# define EVENT(message, ...) (void(0)) +#endif + +// The state tracked by ANGLE will be validated with the driver state before each call +#if defined(ANGLE_ENABLE_DEBUG_TRACE) +# define ANGLE_STATE_VALIDATION_ENABLED +#endif + +#if defined(__GNUC__) +# define ANGLE_CRASH() __builtin_trap() +#else +# define ANGLE_CRASH() ((void)(*(volatile char *)0 = 0)), __assume(0) +#endif + +#if !defined(NDEBUG) +# define ANGLE_ASSERT_IMPL(expression) assert(expression) +#else +// TODO(jmadill): Detect if debugger is attached and break. +# define ANGLE_ASSERT_IMPL(expression) ANGLE_CRASH() +#endif // !defined(NDEBUG) + +// Note that gSwallowStream is used instead of an arbitrary LOG() stream to avoid the creation of an +// object with a non-trivial destructor (LogMessage). On MSVC x86 (checked on 2015 Update 3), this +// causes a few additional pointless instructions to be emitted even at full optimization level, +// even though the : arm of the ternary operator is clearly never executed. Using a simpler object +// to be &'d with Voidify() avoids these extra instructions. Using a simpler POD object with a +// templated operator<< also works to avoid these instructions. However, this causes warnings on +// statically defined implementations of operator<<(std::ostream, ...) in some .cpp files, because +// they become defined-but-unreferenced functions. A reinterpret_cast of 0 to an ostream* also is +// not suitable, because some compilers warn of undefined behavior. +#define ANGLE_EAT_STREAM_PARAMETERS \ + true ? static_cast(0) : ::gl::priv::LogMessageVoidify() & (*::gl::priv::gSwallowStream) + +// A macro asserting a condition and outputting failures to the debug log +#if defined(ANGLE_ENABLE_ASSERTS) +# define ASSERT(expression) \ + (expression ? static_cast(0) \ + : (FATAL() << "\t! Assert failed in " << __FUNCTION__ << " (" << __FILE__ \ + << ":" << __LINE__ << "): " << #expression)) +#else +# define ASSERT(condition) ANGLE_EAT_STREAM_PARAMETERS << !(condition) +#endif // defined(ANGLE_ENABLE_ASSERTS) + +#define ANGLE_UNUSED_VARIABLE(variable) (static_cast(variable)) + +// A macro to indicate unimplemented functionality +#ifndef NOASSERT_UNIMPLEMENTED +# define NOASSERT_UNIMPLEMENTED 1 +#endif + +#if defined(ANGLE_TRACE_ENABLED) || defined(ANGLE_ENABLE_ASSERTS) +# define UNIMPLEMENTED() \ + do \ + { \ + WARN() << "\t! Unimplemented: " << __FUNCTION__ << "(" << __FILE__ << ":" << __LINE__ \ + << ")"; \ + ASSERT(NOASSERT_UNIMPLEMENTED); \ + } while (0) + +// A macro for code which is not expected to be reached under valid assumptions +# define UNREACHABLE() \ + do \ + { \ + FATAL() << "\t! Unreachable reached: " << __FUNCTION__ << "(" << __FILE__ << ":" \ + << __LINE__ << ")"; \ + } while (0) +#else +# define UNIMPLEMENTED() \ + do \ + { \ + ASSERT(NOASSERT_UNIMPLEMENTED); \ + } while (0) + +// A macro for code which is not expected to be reached under valid assumptions +# define UNREACHABLE() \ + do \ + { \ + ASSERT(false); \ + } while (0) +#endif // defined(ANGLE_TRACE_ENABLED) || defined(ANGLE_ENABLE_ASSERTS) + +#if defined(ANGLE_PLATFORM_WINDOWS) +# define ANGLE_FUNCTION __FUNCTION__ +#else +# define ANGLE_FUNCTION __func__ +#endif + +// Defining ANGLE_ENABLE_STRUCT_PADDING_WARNINGS will enable warnings when members are added to +// structs to enforce packing. This is helpful for diagnosing unexpected struct sizes when making +// fast cache variables. +#if defined(__clang__) +# define ANGLE_ENABLE_STRUCT_PADDING_WARNINGS \ + _Pragma("clang diagnostic push") _Pragma("clang diagnostic error \"-Wpadded\"") +# define ANGLE_DISABLE_STRUCT_PADDING_WARNINGS _Pragma("clang diagnostic pop") +#elif defined(__GNUC__) +# define ANGLE_ENABLE_STRUCT_PADDING_WARNINGS \ + _Pragma("GCC diagnostic push") _Pragma("GCC diagnostic error \"-Wpadded\"") +# define ANGLE_DISABLE_STRUCT_PADDING_WARNINGS _Pragma("GCC diagnostic pop") +#elif defined(_MSC_VER) +# define ANGLE_ENABLE_STRUCT_PADDING_WARNINGS \ + __pragma(warning(push)) __pragma(warning(error : 4820)) +# define ANGLE_DISABLE_STRUCT_PADDING_WARNINGS __pragma(warning(pop)) +#else +# define ANGLE_ENABLE_STRUCT_PADDING_WARNINGS +# define ANGLE_DISABLE_STRUCT_PADDING_WARNINGS +#endif + +#if defined(__clang__) +# define ANGLE_DISABLE_SUGGEST_OVERRIDE_WARNINGS \ + _Pragma("clang diagnostic push") \ + _Pragma("clang diagnostic ignored \"-Wsuggest-destructor-override\"") \ + _Pragma("clang diagnostic ignored \"-Wsuggest-override\"") +# define ANGLE_REENABLE_SUGGEST_OVERRIDE_WARNINGS _Pragma("clang diagnostic pop") +#else +# define ANGLE_DISABLE_SUGGEST_OVERRIDE_WARNINGS +# define ANGLE_REENABLE_SUGGEST_OVERRIDE_WARNINGS +#endif + +#if defined(__clang__) +# define ANGLE_DISABLE_EXTRA_SEMI_WARNING \ + _Pragma("clang diagnostic push") _Pragma("clang diagnostic ignored \"-Wextra-semi\"") +# define ANGLE_REENABLE_EXTRA_SEMI_WARNING _Pragma("clang diagnostic pop") +#else +# define ANGLE_DISABLE_EXTRA_SEMI_WARNING +# define ANGLE_REENABLE_EXTRA_SEMI_WARNING +#endif + +#if defined(__clang__) +# define ANGLE_DISABLE_EXTRA_SEMI_STMT_WARNING \ + _Pragma("clang diagnostic push") _Pragma("clang diagnostic ignored \"-Wextra-semi-stmt\"") +# define ANGLE_REENABLE_EXTRA_SEMI_STMT_WARNING _Pragma("clang diagnostic pop") +#else +# define ANGLE_DISABLE_EXTRA_SEMI_STMT_WARNING +# define ANGLE_REENABLE_EXTRA_SEMI_STMT_WARNING +#endif + +#if defined(__clang__) +# define ANGLE_DISABLE_SHADOWING_WARNING \ + _Pragma("clang diagnostic push") _Pragma("clang diagnostic ignored \"-Wshadow-field\"") +# define ANGLE_REENABLE_SHADOWING_WARNING _Pragma("clang diagnostic pop") +#else +# define ANGLE_DISABLE_SHADOWING_WARNING +# define ANGLE_REENABLE_SHADOWING_WARNING +#endif + +#if defined(__clang__) +# define ANGLE_DISABLE_DESTRUCTOR_OVERRIDE_WARNING \ + _Pragma("clang diagnostic push") \ + _Pragma("clang diagnostic ignored \"-Winconsistent-missing-destructor-override\"") +# define ANGLE_REENABLE_DESTRUCTOR_OVERRIDE_WARNING _Pragma("clang diagnostic pop") +#else +# define ANGLE_DISABLE_DESTRUCTOR_OVERRIDE_WARNING +# define ANGLE_REENABLE_DESTRUCTOR_OVERRIDE_WARNING +#endif + +#if defined(__clang__) +# define ANGLE_DISABLE_UNUSED_FUNCTION_WARNING \ + _Pragma("clang diagnostic push") _Pragma("clang diagnostic ignored \"-Wunused-function\"") +# define ANGLE_REENABLE_UNUSED_FUNCTION_WARNING _Pragma("clang diagnostic pop") +#else +# define ANGLE_DISABLE_UNUSED_FUNCTION_WARNING +# define ANGLE_REENABLE_UNUSED_FUNCTION_WARNING +#endif + +#endif // COMMON_DEBUG_H_ diff --git a/gfx/angle/checkout/src/common/entry_points_enum_autogen.cpp b/gfx/angle/checkout/src/common/entry_points_enum_autogen.cpp new file mode 100644 index 0000000000..993eecc8da --- /dev/null +++ b/gfx/angle/checkout/src/common/entry_points_enum_autogen.cpp @@ -0,0 +1,3454 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by generate_entry_points.py using data from gl.xml and gl_angle_ext.xml. +// +// Copyright 2020 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// entry_points_enum_autogen.cpp: +// Helper methods for the GL/GLES entry points enumeration. + +#include "common/entry_points_enum_autogen.h" + +#include "common/debug.h" + +namespace angle +{ +const char *GetEntryPointName(EntryPoint ep) +{ + switch (ep) + { + case EntryPoint::CLBuildProgram: + return "clBuildProgram"; + case EntryPoint::CLCloneKernel: + return "clCloneKernel"; + case EntryPoint::CLCompileProgram: + return "clCompileProgram"; + case EntryPoint::CLCreateBuffer: + return "clCreateBuffer"; + case EntryPoint::CLCreateBufferWithProperties: + return "clCreateBufferWithProperties"; + case EntryPoint::CLCreateCommandQueue: + return "clCreateCommandQueue"; + case EntryPoint::CLCreateCommandQueueWithProperties: + return "clCreateCommandQueueWithProperties"; + case EntryPoint::CLCreateContext: + return "clCreateContext"; + case EntryPoint::CLCreateContextFromType: + return "clCreateContextFromType"; + case EntryPoint::CLCreateImage: + return "clCreateImage"; + case EntryPoint::CLCreateImage2D: + return "clCreateImage2D"; + case EntryPoint::CLCreateImage3D: + return "clCreateImage3D"; + case EntryPoint::CLCreateImageWithProperties: + return "clCreateImageWithProperties"; + case EntryPoint::CLCreateKernel: + return "clCreateKernel"; + case EntryPoint::CLCreateKernelsInProgram: + return "clCreateKernelsInProgram"; + case EntryPoint::CLCreatePipe: + return "clCreatePipe"; + case EntryPoint::CLCreateProgramWithBinary: + return "clCreateProgramWithBinary"; + case EntryPoint::CLCreateProgramWithBuiltInKernels: + return "clCreateProgramWithBuiltInKernels"; + case EntryPoint::CLCreateProgramWithIL: + return "clCreateProgramWithIL"; + case EntryPoint::CLCreateProgramWithSource: + return "clCreateProgramWithSource"; + case EntryPoint::CLCreateSampler: + return "clCreateSampler"; + case EntryPoint::CLCreateSamplerWithProperties: + return "clCreateSamplerWithProperties"; + case EntryPoint::CLCreateSubBuffer: + return "clCreateSubBuffer"; + case EntryPoint::CLCreateSubDevices: + return "clCreateSubDevices"; + case EntryPoint::CLCreateUserEvent: + return "clCreateUserEvent"; + case EntryPoint::CLEnqueueBarrier: + return "clEnqueueBarrier"; + case EntryPoint::CLEnqueueBarrierWithWaitList: + return "clEnqueueBarrierWithWaitList"; + case EntryPoint::CLEnqueueCopyBuffer: + return "clEnqueueCopyBuffer"; + case EntryPoint::CLEnqueueCopyBufferRect: + return "clEnqueueCopyBufferRect"; + case EntryPoint::CLEnqueueCopyBufferToImage: + return "clEnqueueCopyBufferToImage"; + case EntryPoint::CLEnqueueCopyImage: + return "clEnqueueCopyImage"; + case EntryPoint::CLEnqueueCopyImageToBuffer: + return "clEnqueueCopyImageToBuffer"; + case EntryPoint::CLEnqueueFillBuffer: + return "clEnqueueFillBuffer"; + case EntryPoint::CLEnqueueFillImage: + return "clEnqueueFillImage"; + case EntryPoint::CLEnqueueMapBuffer: + return "clEnqueueMapBuffer"; + case EntryPoint::CLEnqueueMapImage: + return "clEnqueueMapImage"; + case EntryPoint::CLEnqueueMarker: + return "clEnqueueMarker"; + case EntryPoint::CLEnqueueMarkerWithWaitList: + return "clEnqueueMarkerWithWaitList"; + case EntryPoint::CLEnqueueMigrateMemObjects: + return "clEnqueueMigrateMemObjects"; + case EntryPoint::CLEnqueueNDRangeKernel: + return "clEnqueueNDRangeKernel"; + case EntryPoint::CLEnqueueNativeKernel: + return "clEnqueueNativeKernel"; + case EntryPoint::CLEnqueueReadBuffer: + return "clEnqueueReadBuffer"; + case EntryPoint::CLEnqueueReadBufferRect: + return "clEnqueueReadBufferRect"; + case EntryPoint::CLEnqueueReadImage: + return "clEnqueueReadImage"; + case EntryPoint::CLEnqueueSVMFree: + return "clEnqueueSVMFree"; + case EntryPoint::CLEnqueueSVMMap: + return "clEnqueueSVMMap"; + case EntryPoint::CLEnqueueSVMMemFill: + return "clEnqueueSVMMemFill"; + case EntryPoint::CLEnqueueSVMMemcpy: + return "clEnqueueSVMMemcpy"; + case EntryPoint::CLEnqueueSVMMigrateMem: + return "clEnqueueSVMMigrateMem"; + case EntryPoint::CLEnqueueSVMUnmap: + return "clEnqueueSVMUnmap"; + case EntryPoint::CLEnqueueTask: + return "clEnqueueTask"; + case EntryPoint::CLEnqueueUnmapMemObject: + return "clEnqueueUnmapMemObject"; + case EntryPoint::CLEnqueueWaitForEvents: + return "clEnqueueWaitForEvents"; + case EntryPoint::CLEnqueueWriteBuffer: + return "clEnqueueWriteBuffer"; + case EntryPoint::CLEnqueueWriteBufferRect: + return "clEnqueueWriteBufferRect"; + case EntryPoint::CLEnqueueWriteImage: + return "clEnqueueWriteImage"; + case EntryPoint::CLFinish: + return "clFinish"; + case EntryPoint::CLFlush: + return "clFlush"; + case EntryPoint::CLGetCommandQueueInfo: + return "clGetCommandQueueInfo"; + case EntryPoint::CLGetContextInfo: + return "clGetContextInfo"; + case EntryPoint::CLGetDeviceAndHostTimer: + return "clGetDeviceAndHostTimer"; + case EntryPoint::CLGetDeviceIDs: + return "clGetDeviceIDs"; + case EntryPoint::CLGetDeviceInfo: + return "clGetDeviceInfo"; + case EntryPoint::CLGetEventInfo: + return "clGetEventInfo"; + case EntryPoint::CLGetEventProfilingInfo: + return "clGetEventProfilingInfo"; + case EntryPoint::CLGetExtensionFunctionAddress: + return "clGetExtensionFunctionAddress"; + case EntryPoint::CLGetExtensionFunctionAddressForPlatform: + return "clGetExtensionFunctionAddressForPlatform"; + case EntryPoint::CLGetHostTimer: + return "clGetHostTimer"; + case EntryPoint::CLGetImageInfo: + return "clGetImageInfo"; + case EntryPoint::CLGetKernelArgInfo: + return "clGetKernelArgInfo"; + case EntryPoint::CLGetKernelInfo: + return "clGetKernelInfo"; + case EntryPoint::CLGetKernelSubGroupInfo: + return "clGetKernelSubGroupInfo"; + case EntryPoint::CLGetKernelWorkGroupInfo: + return "clGetKernelWorkGroupInfo"; + case EntryPoint::CLGetMemObjectInfo: + return "clGetMemObjectInfo"; + case EntryPoint::CLGetPipeInfo: + return "clGetPipeInfo"; + case EntryPoint::CLGetPlatformIDs: + return "clGetPlatformIDs"; + case EntryPoint::CLGetPlatformInfo: + return "clGetPlatformInfo"; + case EntryPoint::CLGetProgramBuildInfo: + return "clGetProgramBuildInfo"; + case EntryPoint::CLGetProgramInfo: + return "clGetProgramInfo"; + case EntryPoint::CLGetSamplerInfo: + return "clGetSamplerInfo"; + case EntryPoint::CLGetSupportedImageFormats: + return "clGetSupportedImageFormats"; + case EntryPoint::CLIcdGetPlatformIDsKHR: + return "clIcdGetPlatformIDsKHR"; + case EntryPoint::CLLinkProgram: + return "clLinkProgram"; + case EntryPoint::CLReleaseCommandQueue: + return "clReleaseCommandQueue"; + case EntryPoint::CLReleaseContext: + return "clReleaseContext"; + case EntryPoint::CLReleaseDevice: + return "clReleaseDevice"; + case EntryPoint::CLReleaseEvent: + return "clReleaseEvent"; + case EntryPoint::CLReleaseKernel: + return "clReleaseKernel"; + case EntryPoint::CLReleaseMemObject: + return "clReleaseMemObject"; + case EntryPoint::CLReleaseProgram: + return "clReleaseProgram"; + case EntryPoint::CLReleaseSampler: + return "clReleaseSampler"; + case EntryPoint::CLRetainCommandQueue: + return "clRetainCommandQueue"; + case EntryPoint::CLRetainContext: + return "clRetainContext"; + case EntryPoint::CLRetainDevice: + return "clRetainDevice"; + case EntryPoint::CLRetainEvent: + return "clRetainEvent"; + case EntryPoint::CLRetainKernel: + return "clRetainKernel"; + case EntryPoint::CLRetainMemObject: + return "clRetainMemObject"; + case EntryPoint::CLRetainProgram: + return "clRetainProgram"; + case EntryPoint::CLRetainSampler: + return "clRetainSampler"; + case EntryPoint::CLSVMAlloc: + return "clSVMAlloc"; + case EntryPoint::CLSVMFree: + return "clSVMFree"; + case EntryPoint::CLSetCommandQueueProperty: + return "clSetCommandQueueProperty"; + case EntryPoint::CLSetContextDestructorCallback: + return "clSetContextDestructorCallback"; + case EntryPoint::CLSetDefaultDeviceCommandQueue: + return "clSetDefaultDeviceCommandQueue"; + case EntryPoint::CLSetEventCallback: + return "clSetEventCallback"; + case EntryPoint::CLSetKernelArg: + return "clSetKernelArg"; + case EntryPoint::CLSetKernelArgSVMPointer: + return "clSetKernelArgSVMPointer"; + case EntryPoint::CLSetKernelExecInfo: + return "clSetKernelExecInfo"; + case EntryPoint::CLSetMemObjectDestructorCallback: + return "clSetMemObjectDestructorCallback"; + case EntryPoint::CLSetProgramReleaseCallback: + return "clSetProgramReleaseCallback"; + case EntryPoint::CLSetProgramSpecializationConstant: + return "clSetProgramSpecializationConstant"; + case EntryPoint::CLSetUserEventStatus: + return "clSetUserEventStatus"; + case EntryPoint::CLUnloadCompiler: + return "clUnloadCompiler"; + case EntryPoint::CLUnloadPlatformCompiler: + return "clUnloadPlatformCompiler"; + case EntryPoint::CLWaitForEvents: + return "clWaitForEvents"; + case EntryPoint::EGLBindAPI: + return "eglBindAPI"; + case EntryPoint::EGLBindTexImage: + return "eglBindTexImage"; + case EntryPoint::EGLChooseConfig: + return "eglChooseConfig"; + case EntryPoint::EGLClientWaitSync: + return "eglClientWaitSync"; + case EntryPoint::EGLClientWaitSyncKHR: + return "eglClientWaitSyncKHR"; + case EntryPoint::EGLCopyBuffers: + return "eglCopyBuffers"; + case EntryPoint::EGLCopyMetalSharedEventANGLE: + return "eglCopyMetalSharedEventANGLE"; + case EntryPoint::EGLCreateContext: + return "eglCreateContext"; + case EntryPoint::EGLCreateDeviceANGLE: + return "eglCreateDeviceANGLE"; + case EntryPoint::EGLCreateImage: + return "eglCreateImage"; + case EntryPoint::EGLCreateImageKHR: + return "eglCreateImageKHR"; + case EntryPoint::EGLCreateNativeClientBufferANDROID: + return "eglCreateNativeClientBufferANDROID"; + case EntryPoint::EGLCreatePbufferFromClientBuffer: + return "eglCreatePbufferFromClientBuffer"; + case EntryPoint::EGLCreatePbufferSurface: + return "eglCreatePbufferSurface"; + case EntryPoint::EGLCreatePixmapSurface: + return "eglCreatePixmapSurface"; + case EntryPoint::EGLCreatePlatformPixmapSurface: + return "eglCreatePlatformPixmapSurface"; + case EntryPoint::EGLCreatePlatformPixmapSurfaceEXT: + return "eglCreatePlatformPixmapSurfaceEXT"; + case EntryPoint::EGLCreatePlatformWindowSurface: + return "eglCreatePlatformWindowSurface"; + case EntryPoint::EGLCreatePlatformWindowSurfaceEXT: + return "eglCreatePlatformWindowSurfaceEXT"; + case EntryPoint::EGLCreateStreamKHR: + return "eglCreateStreamKHR"; + case EntryPoint::EGLCreateStreamProducerD3DTextureANGLE: + return "eglCreateStreamProducerD3DTextureANGLE"; + case EntryPoint::EGLCreateSync: + return "eglCreateSync"; + case EntryPoint::EGLCreateSyncKHR: + return "eglCreateSyncKHR"; + case EntryPoint::EGLCreateWindowSurface: + return "eglCreateWindowSurface"; + case EntryPoint::EGLDebugMessageControlKHR: + return "eglDebugMessageControlKHR"; + case EntryPoint::EGLDestroyContext: + return "eglDestroyContext"; + case EntryPoint::EGLDestroyImage: + return "eglDestroyImage"; + case EntryPoint::EGLDestroyImageKHR: + return "eglDestroyImageKHR"; + case EntryPoint::EGLDestroyStreamKHR: + return "eglDestroyStreamKHR"; + case EntryPoint::EGLDestroySurface: + return "eglDestroySurface"; + case EntryPoint::EGLDestroySync: + return "eglDestroySync"; + case EntryPoint::EGLDestroySyncKHR: + return "eglDestroySyncKHR"; + case EntryPoint::EGLDupNativeFenceFDANDROID: + return "eglDupNativeFenceFDANDROID"; + case EntryPoint::EGLExportVkImageANGLE: + return "eglExportVkImageANGLE"; + case EntryPoint::EGLForceGPUSwitchANGLE: + return "eglForceGPUSwitchANGLE"; + case EntryPoint::EGLGetCompositorTimingANDROID: + return "eglGetCompositorTimingANDROID"; + case EntryPoint::EGLGetCompositorTimingSupportedANDROID: + return "eglGetCompositorTimingSupportedANDROID"; + case EntryPoint::EGLGetConfigAttrib: + return "eglGetConfigAttrib"; + case EntryPoint::EGLGetConfigs: + return "eglGetConfigs"; + case EntryPoint::EGLGetCurrentContext: + return "eglGetCurrentContext"; + case EntryPoint::EGLGetCurrentDisplay: + return "eglGetCurrentDisplay"; + case EntryPoint::EGLGetCurrentSurface: + return "eglGetCurrentSurface"; + case EntryPoint::EGLGetDisplay: + return "eglGetDisplay"; + case EntryPoint::EGLGetError: + return "eglGetError"; + case EntryPoint::EGLGetFrameTimestampSupportedANDROID: + return "eglGetFrameTimestampSupportedANDROID"; + case EntryPoint::EGLGetFrameTimestampsANDROID: + return "eglGetFrameTimestampsANDROID"; + case EntryPoint::EGLGetMscRateANGLE: + return "eglGetMscRateANGLE"; + case EntryPoint::EGLGetNativeClientBufferANDROID: + return "eglGetNativeClientBufferANDROID"; + case EntryPoint::EGLGetNextFrameIdANDROID: + return "eglGetNextFrameIdANDROID"; + case EntryPoint::EGLGetPlatformDisplay: + return "eglGetPlatformDisplay"; + case EntryPoint::EGLGetPlatformDisplayEXT: + return "eglGetPlatformDisplayEXT"; + case EntryPoint::EGLGetProcAddress: + return "eglGetProcAddress"; + case EntryPoint::EGLGetSyncAttrib: + return "eglGetSyncAttrib"; + case EntryPoint::EGLGetSyncAttribKHR: + return "eglGetSyncAttribKHR"; + case EntryPoint::EGLGetSyncValuesCHROMIUM: + return "eglGetSyncValuesCHROMIUM"; + case EntryPoint::EGLHandleGPUSwitchANGLE: + return "eglHandleGPUSwitchANGLE"; + case EntryPoint::EGLInitialize: + return "eglInitialize"; + case EntryPoint::EGLLabelObjectKHR: + return "eglLabelObjectKHR"; + case EntryPoint::EGLLockSurfaceKHR: + return "eglLockSurfaceKHR"; + case EntryPoint::EGLMakeCurrent: + return "eglMakeCurrent"; + case EntryPoint::EGLPostSubBufferNV: + return "eglPostSubBufferNV"; + case EntryPoint::EGLPrepareSwapBuffersANGLE: + return "eglPrepareSwapBuffersANGLE"; + case EntryPoint::EGLPresentationTimeANDROID: + return "eglPresentationTimeANDROID"; + case EntryPoint::EGLProgramCacheGetAttribANGLE: + return "eglProgramCacheGetAttribANGLE"; + case EntryPoint::EGLProgramCachePopulateANGLE: + return "eglProgramCachePopulateANGLE"; + case EntryPoint::EGLProgramCacheQueryANGLE: + return "eglProgramCacheQueryANGLE"; + case EntryPoint::EGLProgramCacheResizeANGLE: + return "eglProgramCacheResizeANGLE"; + case EntryPoint::EGLQueryAPI: + return "eglQueryAPI"; + case EntryPoint::EGLQueryContext: + return "eglQueryContext"; + case EntryPoint::EGLQueryDebugKHR: + return "eglQueryDebugKHR"; + case EntryPoint::EGLQueryDeviceAttribEXT: + return "eglQueryDeviceAttribEXT"; + case EntryPoint::EGLQueryDeviceStringEXT: + return "eglQueryDeviceStringEXT"; + case EntryPoint::EGLQueryDisplayAttribANGLE: + return "eglQueryDisplayAttribANGLE"; + case EntryPoint::EGLQueryDisplayAttribEXT: + return "eglQueryDisplayAttribEXT"; + case EntryPoint::EGLQueryDmaBufFormatsEXT: + return "eglQueryDmaBufFormatsEXT"; + case EntryPoint::EGLQueryDmaBufModifiersEXT: + return "eglQueryDmaBufModifiersEXT"; + case EntryPoint::EGLQueryStreamKHR: + return "eglQueryStreamKHR"; + case EntryPoint::EGLQueryStreamu64KHR: + return "eglQueryStreamu64KHR"; + case EntryPoint::EGLQueryString: + return "eglQueryString"; + case EntryPoint::EGLQueryStringiANGLE: + return "eglQueryStringiANGLE"; + case EntryPoint::EGLQuerySurface: + return "eglQuerySurface"; + case EntryPoint::EGLQuerySurface64KHR: + return "eglQuerySurface64KHR"; + case EntryPoint::EGLQuerySurfacePointerANGLE: + return "eglQuerySurfacePointerANGLE"; + case EntryPoint::EGLReacquireHighPowerGPUANGLE: + return "eglReacquireHighPowerGPUANGLE"; + case EntryPoint::EGLReleaseDeviceANGLE: + return "eglReleaseDeviceANGLE"; + case EntryPoint::EGLReleaseHighPowerGPUANGLE: + return "eglReleaseHighPowerGPUANGLE"; + case EntryPoint::EGLReleaseTexImage: + return "eglReleaseTexImage"; + case EntryPoint::EGLReleaseThread: + return "eglReleaseThread"; + case EntryPoint::EGLSetBlobCacheFuncsANDROID: + return "eglSetBlobCacheFuncsANDROID"; + case EntryPoint::EGLSetDamageRegionKHR: + return "eglSetDamageRegionKHR"; + case EntryPoint::EGLSignalSyncKHR: + return "eglSignalSyncKHR"; + case EntryPoint::EGLStreamAttribKHR: + return "eglStreamAttribKHR"; + case EntryPoint::EGLStreamConsumerAcquireKHR: + return "eglStreamConsumerAcquireKHR"; + case EntryPoint::EGLStreamConsumerGLTextureExternalAttribsNV: + return "eglStreamConsumerGLTextureExternalAttribsNV"; + case EntryPoint::EGLStreamConsumerGLTextureExternalKHR: + return "eglStreamConsumerGLTextureExternalKHR"; + case EntryPoint::EGLStreamConsumerReleaseKHR: + return "eglStreamConsumerReleaseKHR"; + case EntryPoint::EGLStreamPostD3DTextureANGLE: + return "eglStreamPostD3DTextureANGLE"; + case EntryPoint::EGLSurfaceAttrib: + return "eglSurfaceAttrib"; + case EntryPoint::EGLSwapBuffers: + return "eglSwapBuffers"; + case EntryPoint::EGLSwapBuffersWithDamageKHR: + return "eglSwapBuffersWithDamageKHR"; + case EntryPoint::EGLSwapBuffersWithFrameTokenANGLE: + return "eglSwapBuffersWithFrameTokenANGLE"; + case EntryPoint::EGLSwapInterval: + return "eglSwapInterval"; + case EntryPoint::EGLTerminate: + return "eglTerminate"; + case EntryPoint::EGLUnlockSurfaceKHR: + return "eglUnlockSurfaceKHR"; + case EntryPoint::EGLWaitClient: + return "eglWaitClient"; + case EntryPoint::EGLWaitGL: + return "eglWaitGL"; + case EntryPoint::EGLWaitNative: + return "eglWaitNative"; + case EntryPoint::EGLWaitSync: + return "eglWaitSync"; + case EntryPoint::EGLWaitSyncKHR: + return "eglWaitSyncKHR"; + case EntryPoint::GLAccum: + return "glAccum"; + case EntryPoint::GLAcquireTexturesANGLE: + return "glAcquireTexturesANGLE"; + case EntryPoint::GLActiveShaderProgram: + return "glActiveShaderProgram"; + case EntryPoint::GLActiveShaderProgramEXT: + return "glActiveShaderProgramEXT"; + case EntryPoint::GLActiveTexture: + return "glActiveTexture"; + case EntryPoint::GLAlphaFunc: + return "glAlphaFunc"; + case EntryPoint::GLAlphaFuncx: + return "glAlphaFuncx"; + case EntryPoint::GLAreTexturesResident: + return "glAreTexturesResident"; + case EntryPoint::GLArrayElement: + return "glArrayElement"; + case EntryPoint::GLAttachShader: + return "glAttachShader"; + case EntryPoint::GLBegin: + return "glBegin"; + case EntryPoint::GLBeginConditionalRender: + return "glBeginConditionalRender"; + case EntryPoint::GLBeginPerfMonitorAMD: + return "glBeginPerfMonitorAMD"; + case EntryPoint::GLBeginPixelLocalStorageANGLE: + return "glBeginPixelLocalStorageANGLE"; + case EntryPoint::GLBeginQuery: + return "glBeginQuery"; + case EntryPoint::GLBeginQueryEXT: + return "glBeginQueryEXT"; + case EntryPoint::GLBeginQueryIndexed: + return "glBeginQueryIndexed"; + case EntryPoint::GLBeginTransformFeedback: + return "glBeginTransformFeedback"; + case EntryPoint::GLBindAttribLocation: + return "glBindAttribLocation"; + case EntryPoint::GLBindBuffer: + return "glBindBuffer"; + case EntryPoint::GLBindBufferBase: + return "glBindBufferBase"; + case EntryPoint::GLBindBufferRange: + return "glBindBufferRange"; + case EntryPoint::GLBindBuffersBase: + return "glBindBuffersBase"; + case EntryPoint::GLBindBuffersRange: + return "glBindBuffersRange"; + case EntryPoint::GLBindFragDataLocation: + return "glBindFragDataLocation"; + case EntryPoint::GLBindFragDataLocationEXT: + return "glBindFragDataLocationEXT"; + case EntryPoint::GLBindFragDataLocationIndexed: + return "glBindFragDataLocationIndexed"; + case EntryPoint::GLBindFragDataLocationIndexedEXT: + return "glBindFragDataLocationIndexedEXT"; + case EntryPoint::GLBindFramebuffer: + return "glBindFramebuffer"; + case EntryPoint::GLBindFramebufferOES: + return "glBindFramebufferOES"; + case EntryPoint::GLBindImageTexture: + return "glBindImageTexture"; + case EntryPoint::GLBindImageTextures: + return "glBindImageTextures"; + case EntryPoint::GLBindProgramPipeline: + return "glBindProgramPipeline"; + case EntryPoint::GLBindProgramPipelineEXT: + return "glBindProgramPipelineEXT"; + case EntryPoint::GLBindRenderbuffer: + return "glBindRenderbuffer"; + case EntryPoint::GLBindRenderbufferOES: + return "glBindRenderbufferOES"; + case EntryPoint::GLBindSampler: + return "glBindSampler"; + case EntryPoint::GLBindSamplers: + return "glBindSamplers"; + case EntryPoint::GLBindTexture: + return "glBindTexture"; + case EntryPoint::GLBindTextureUnit: + return "glBindTextureUnit"; + case EntryPoint::GLBindTextures: + return "glBindTextures"; + case EntryPoint::GLBindTransformFeedback: + return "glBindTransformFeedback"; + case EntryPoint::GLBindUniformLocationCHROMIUM: + return "glBindUniformLocationCHROMIUM"; + case EntryPoint::GLBindVertexArray: + return "glBindVertexArray"; + case EntryPoint::GLBindVertexArrayOES: + return "glBindVertexArrayOES"; + case EntryPoint::GLBindVertexBuffer: + return "glBindVertexBuffer"; + case EntryPoint::GLBindVertexBuffers: + return "glBindVertexBuffers"; + case EntryPoint::GLBitmap: + return "glBitmap"; + case EntryPoint::GLBlendBarrier: + return "glBlendBarrier"; + case EntryPoint::GLBlendBarrierKHR: + return "glBlendBarrierKHR"; + case EntryPoint::GLBlendColor: + return "glBlendColor"; + case EntryPoint::GLBlendEquation: + return "glBlendEquation"; + case EntryPoint::GLBlendEquationSeparate: + return "glBlendEquationSeparate"; + case EntryPoint::GLBlendEquationSeparatei: + return "glBlendEquationSeparatei"; + case EntryPoint::GLBlendEquationSeparateiEXT: + return "glBlendEquationSeparateiEXT"; + case EntryPoint::GLBlendEquationSeparateiOES: + return "glBlendEquationSeparateiOES"; + case EntryPoint::GLBlendEquationi: + return "glBlendEquationi"; + case EntryPoint::GLBlendEquationiEXT: + return "glBlendEquationiEXT"; + case EntryPoint::GLBlendEquationiOES: + return "glBlendEquationiOES"; + case EntryPoint::GLBlendFunc: + return "glBlendFunc"; + case EntryPoint::GLBlendFuncSeparate: + return "glBlendFuncSeparate"; + case EntryPoint::GLBlendFuncSeparatei: + return "glBlendFuncSeparatei"; + case EntryPoint::GLBlendFuncSeparateiEXT: + return "glBlendFuncSeparateiEXT"; + case EntryPoint::GLBlendFuncSeparateiOES: + return "glBlendFuncSeparateiOES"; + case EntryPoint::GLBlendFunci: + return "glBlendFunci"; + case EntryPoint::GLBlendFunciEXT: + return "glBlendFunciEXT"; + case EntryPoint::GLBlendFunciOES: + return "glBlendFunciOES"; + case EntryPoint::GLBlitFramebuffer: + return "glBlitFramebuffer"; + case EntryPoint::GLBlitFramebufferANGLE: + return "glBlitFramebufferANGLE"; + case EntryPoint::GLBlitFramebufferNV: + return "glBlitFramebufferNV"; + case EntryPoint::GLBlitNamedFramebuffer: + return "glBlitNamedFramebuffer"; + case EntryPoint::GLBufferData: + return "glBufferData"; + case EntryPoint::GLBufferStorage: + return "glBufferStorage"; + case EntryPoint::GLBufferStorageEXT: + return "glBufferStorageEXT"; + case EntryPoint::GLBufferStorageExternalEXT: + return "glBufferStorageExternalEXT"; + case EntryPoint::GLBufferStorageMemEXT: + return "glBufferStorageMemEXT"; + case EntryPoint::GLBufferSubData: + return "glBufferSubData"; + case EntryPoint::GLCallList: + return "glCallList"; + case EntryPoint::GLCallLists: + return "glCallLists"; + case EntryPoint::GLCheckFramebufferStatus: + return "glCheckFramebufferStatus"; + case EntryPoint::GLCheckFramebufferStatusOES: + return "glCheckFramebufferStatusOES"; + case EntryPoint::GLCheckNamedFramebufferStatus: + return "glCheckNamedFramebufferStatus"; + case EntryPoint::GLClampColor: + return "glClampColor"; + case EntryPoint::GLClear: + return "glClear"; + case EntryPoint::GLClearAccum: + return "glClearAccum"; + case EntryPoint::GLClearBufferData: + return "glClearBufferData"; + case EntryPoint::GLClearBufferSubData: + return "glClearBufferSubData"; + case EntryPoint::GLClearBufferfi: + return "glClearBufferfi"; + case EntryPoint::GLClearBufferfv: + return "glClearBufferfv"; + case EntryPoint::GLClearBufferiv: + return "glClearBufferiv"; + case EntryPoint::GLClearBufferuiv: + return "glClearBufferuiv"; + case EntryPoint::GLClearColor: + return "glClearColor"; + case EntryPoint::GLClearColorx: + return "glClearColorx"; + case EntryPoint::GLClearDepth: + return "glClearDepth"; + case EntryPoint::GLClearDepthf: + return "glClearDepthf"; + case EntryPoint::GLClearDepthx: + return "glClearDepthx"; + case EntryPoint::GLClearIndex: + return "glClearIndex"; + case EntryPoint::GLClearNamedBufferData: + return "glClearNamedBufferData"; + case EntryPoint::GLClearNamedBufferSubData: + return "glClearNamedBufferSubData"; + case EntryPoint::GLClearNamedFramebufferfi: + return "glClearNamedFramebufferfi"; + case EntryPoint::GLClearNamedFramebufferfv: + return "glClearNamedFramebufferfv"; + case EntryPoint::GLClearNamedFramebufferiv: + return "glClearNamedFramebufferiv"; + case EntryPoint::GLClearNamedFramebufferuiv: + return "glClearNamedFramebufferuiv"; + case EntryPoint::GLClearStencil: + return "glClearStencil"; + case EntryPoint::GLClearTexImage: + return "glClearTexImage"; + case EntryPoint::GLClearTexSubImage: + return "glClearTexSubImage"; + case EntryPoint::GLClientActiveTexture: + return "glClientActiveTexture"; + case EntryPoint::GLClientWaitSync: + return "glClientWaitSync"; + case EntryPoint::GLClipControl: + return "glClipControl"; + case EntryPoint::GLClipControlEXT: + return "glClipControlEXT"; + case EntryPoint::GLClipPlane: + return "glClipPlane"; + case EntryPoint::GLClipPlanef: + return "glClipPlanef"; + case EntryPoint::GLClipPlanex: + return "glClipPlanex"; + case EntryPoint::GLColor3b: + return "glColor3b"; + case EntryPoint::GLColor3bv: + return "glColor3bv"; + case EntryPoint::GLColor3d: + return "glColor3d"; + case EntryPoint::GLColor3dv: + return "glColor3dv"; + case EntryPoint::GLColor3f: + return "glColor3f"; + case EntryPoint::GLColor3fv: + return "glColor3fv"; + case EntryPoint::GLColor3i: + return "glColor3i"; + case EntryPoint::GLColor3iv: + return "glColor3iv"; + case EntryPoint::GLColor3s: + return "glColor3s"; + case EntryPoint::GLColor3sv: + return "glColor3sv"; + case EntryPoint::GLColor3ub: + return "glColor3ub"; + case EntryPoint::GLColor3ubv: + return "glColor3ubv"; + case EntryPoint::GLColor3ui: + return "glColor3ui"; + case EntryPoint::GLColor3uiv: + return "glColor3uiv"; + case EntryPoint::GLColor3us: + return "glColor3us"; + case EntryPoint::GLColor3usv: + return "glColor3usv"; + case EntryPoint::GLColor4b: + return "glColor4b"; + case EntryPoint::GLColor4bv: + return "glColor4bv"; + case EntryPoint::GLColor4d: + return "glColor4d"; + case EntryPoint::GLColor4dv: + return "glColor4dv"; + case EntryPoint::GLColor4f: + return "glColor4f"; + case EntryPoint::GLColor4fv: + return "glColor4fv"; + case EntryPoint::GLColor4i: + return "glColor4i"; + case EntryPoint::GLColor4iv: + return "glColor4iv"; + case EntryPoint::GLColor4s: + return "glColor4s"; + case EntryPoint::GLColor4sv: + return "glColor4sv"; + case EntryPoint::GLColor4ub: + return "glColor4ub"; + case EntryPoint::GLColor4ubv: + return "glColor4ubv"; + case EntryPoint::GLColor4ui: + return "glColor4ui"; + case EntryPoint::GLColor4uiv: + return "glColor4uiv"; + case EntryPoint::GLColor4us: + return "glColor4us"; + case EntryPoint::GLColor4usv: + return "glColor4usv"; + case EntryPoint::GLColor4x: + return "glColor4x"; + case EntryPoint::GLColorMask: + return "glColorMask"; + case EntryPoint::GLColorMaski: + return "glColorMaski"; + case EntryPoint::GLColorMaskiEXT: + return "glColorMaskiEXT"; + case EntryPoint::GLColorMaskiOES: + return "glColorMaskiOES"; + case EntryPoint::GLColorMaterial: + return "glColorMaterial"; + case EntryPoint::GLColorP3ui: + return "glColorP3ui"; + case EntryPoint::GLColorP3uiv: + return "glColorP3uiv"; + case EntryPoint::GLColorP4ui: + return "glColorP4ui"; + case EntryPoint::GLColorP4uiv: + return "glColorP4uiv"; + case EntryPoint::GLColorPointer: + return "glColorPointer"; + case EntryPoint::GLCompileShader: + return "glCompileShader"; + case EntryPoint::GLCompressedCopyTextureCHROMIUM: + return "glCompressedCopyTextureCHROMIUM"; + case EntryPoint::GLCompressedTexImage1D: + return "glCompressedTexImage1D"; + case EntryPoint::GLCompressedTexImage2D: + return "glCompressedTexImage2D"; + case EntryPoint::GLCompressedTexImage2DRobustANGLE: + return "glCompressedTexImage2DRobustANGLE"; + case EntryPoint::GLCompressedTexImage3D: + return "glCompressedTexImage3D"; + case EntryPoint::GLCompressedTexImage3DOES: + return "glCompressedTexImage3DOES"; + case EntryPoint::GLCompressedTexImage3DRobustANGLE: + return "glCompressedTexImage3DRobustANGLE"; + case EntryPoint::GLCompressedTexSubImage1D: + return "glCompressedTexSubImage1D"; + case EntryPoint::GLCompressedTexSubImage2D: + return "glCompressedTexSubImage2D"; + case EntryPoint::GLCompressedTexSubImage2DRobustANGLE: + return "glCompressedTexSubImage2DRobustANGLE"; + case EntryPoint::GLCompressedTexSubImage3D: + return "glCompressedTexSubImage3D"; + case EntryPoint::GLCompressedTexSubImage3DOES: + return "glCompressedTexSubImage3DOES"; + case EntryPoint::GLCompressedTexSubImage3DRobustANGLE: + return "glCompressedTexSubImage3DRobustANGLE"; + case EntryPoint::GLCompressedTextureSubImage1D: + return "glCompressedTextureSubImage1D"; + case EntryPoint::GLCompressedTextureSubImage2D: + return "glCompressedTextureSubImage2D"; + case EntryPoint::GLCompressedTextureSubImage3D: + return "glCompressedTextureSubImage3D"; + case EntryPoint::GLCopyBufferSubData: + return "glCopyBufferSubData"; + case EntryPoint::GLCopyImageSubData: + return "glCopyImageSubData"; + case EntryPoint::GLCopyImageSubDataEXT: + return "glCopyImageSubDataEXT"; + case EntryPoint::GLCopyImageSubDataOES: + return "glCopyImageSubDataOES"; + case EntryPoint::GLCopyNamedBufferSubData: + return "glCopyNamedBufferSubData"; + case EntryPoint::GLCopyPixels: + return "glCopyPixels"; + case EntryPoint::GLCopySubTexture3DANGLE: + return "glCopySubTexture3DANGLE"; + case EntryPoint::GLCopySubTextureCHROMIUM: + return "glCopySubTextureCHROMIUM"; + case EntryPoint::GLCopyTexImage1D: + return "glCopyTexImage1D"; + case EntryPoint::GLCopyTexImage2D: + return "glCopyTexImage2D"; + case EntryPoint::GLCopyTexSubImage1D: + return "glCopyTexSubImage1D"; + case EntryPoint::GLCopyTexSubImage2D: + return "glCopyTexSubImage2D"; + case EntryPoint::GLCopyTexSubImage3D: + return "glCopyTexSubImage3D"; + case EntryPoint::GLCopyTexSubImage3DOES: + return "glCopyTexSubImage3DOES"; + case EntryPoint::GLCopyTexture3DANGLE: + return "glCopyTexture3DANGLE"; + case EntryPoint::GLCopyTextureCHROMIUM: + return "glCopyTextureCHROMIUM"; + case EntryPoint::GLCopyTextureSubImage1D: + return "glCopyTextureSubImage1D"; + case EntryPoint::GLCopyTextureSubImage2D: + return "glCopyTextureSubImage2D"; + case EntryPoint::GLCopyTextureSubImage3D: + return "glCopyTextureSubImage3D"; + case EntryPoint::GLCoverageModulationCHROMIUM: + return "glCoverageModulationCHROMIUM"; + case EntryPoint::GLCreateBuffers: + return "glCreateBuffers"; + case EntryPoint::GLCreateFramebuffers: + return "glCreateFramebuffers"; + case EntryPoint::GLCreateMemoryObjectsEXT: + return "glCreateMemoryObjectsEXT"; + case EntryPoint::GLCreateProgram: + return "glCreateProgram"; + case EntryPoint::GLCreateProgramPipelines: + return "glCreateProgramPipelines"; + case EntryPoint::GLCreateQueries: + return "glCreateQueries"; + case EntryPoint::GLCreateRenderbuffers: + return "glCreateRenderbuffers"; + case EntryPoint::GLCreateSamplers: + return "glCreateSamplers"; + case EntryPoint::GLCreateShader: + return "glCreateShader"; + case EntryPoint::GLCreateShaderProgramv: + return "glCreateShaderProgramv"; + case EntryPoint::GLCreateShaderProgramvEXT: + return "glCreateShaderProgramvEXT"; + case EntryPoint::GLCreateTextures: + return "glCreateTextures"; + case EntryPoint::GLCreateTransformFeedbacks: + return "glCreateTransformFeedbacks"; + case EntryPoint::GLCreateVertexArrays: + return "glCreateVertexArrays"; + case EntryPoint::GLCullFace: + return "glCullFace"; + case EntryPoint::GLCurrentPaletteMatrixOES: + return "glCurrentPaletteMatrixOES"; + case EntryPoint::GLDebugMessageCallback: + return "glDebugMessageCallback"; + case EntryPoint::GLDebugMessageCallbackKHR: + return "glDebugMessageCallbackKHR"; + case EntryPoint::GLDebugMessageControl: + return "glDebugMessageControl"; + case EntryPoint::GLDebugMessageControlKHR: + return "glDebugMessageControlKHR"; + case EntryPoint::GLDebugMessageInsert: + return "glDebugMessageInsert"; + case EntryPoint::GLDebugMessageInsertKHR: + return "glDebugMessageInsertKHR"; + case EntryPoint::GLDeleteBuffers: + return "glDeleteBuffers"; + case EntryPoint::GLDeleteFencesNV: + return "glDeleteFencesNV"; + case EntryPoint::GLDeleteFramebuffers: + return "glDeleteFramebuffers"; + case EntryPoint::GLDeleteFramebuffersOES: + return "glDeleteFramebuffersOES"; + case EntryPoint::GLDeleteLists: + return "glDeleteLists"; + case EntryPoint::GLDeleteMemoryObjectsEXT: + return "glDeleteMemoryObjectsEXT"; + case EntryPoint::GLDeletePerfMonitorsAMD: + return "glDeletePerfMonitorsAMD"; + case EntryPoint::GLDeleteProgram: + return "glDeleteProgram"; + case EntryPoint::GLDeleteProgramPipelines: + return "glDeleteProgramPipelines"; + case EntryPoint::GLDeleteProgramPipelinesEXT: + return "glDeleteProgramPipelinesEXT"; + case EntryPoint::GLDeleteQueries: + return "glDeleteQueries"; + case EntryPoint::GLDeleteQueriesEXT: + return "glDeleteQueriesEXT"; + case EntryPoint::GLDeleteRenderbuffers: + return "glDeleteRenderbuffers"; + case EntryPoint::GLDeleteRenderbuffersOES: + return "glDeleteRenderbuffersOES"; + case EntryPoint::GLDeleteSamplers: + return "glDeleteSamplers"; + case EntryPoint::GLDeleteSemaphoresEXT: + return "glDeleteSemaphoresEXT"; + case EntryPoint::GLDeleteShader: + return "glDeleteShader"; + case EntryPoint::GLDeleteSync: + return "glDeleteSync"; + case EntryPoint::GLDeleteTextures: + return "glDeleteTextures"; + case EntryPoint::GLDeleteTransformFeedbacks: + return "glDeleteTransformFeedbacks"; + case EntryPoint::GLDeleteVertexArrays: + return "glDeleteVertexArrays"; + case EntryPoint::GLDeleteVertexArraysOES: + return "glDeleteVertexArraysOES"; + case EntryPoint::GLDepthFunc: + return "glDepthFunc"; + case EntryPoint::GLDepthMask: + return "glDepthMask"; + case EntryPoint::GLDepthRange: + return "glDepthRange"; + case EntryPoint::GLDepthRangeArrayv: + return "glDepthRangeArrayv"; + case EntryPoint::GLDepthRangeIndexed: + return "glDepthRangeIndexed"; + case EntryPoint::GLDepthRangef: + return "glDepthRangef"; + case EntryPoint::GLDepthRangex: + return "glDepthRangex"; + case EntryPoint::GLDetachShader: + return "glDetachShader"; + case EntryPoint::GLDisable: + return "glDisable"; + case EntryPoint::GLDisableClientState: + return "glDisableClientState"; + case EntryPoint::GLDisableExtensionANGLE: + return "glDisableExtensionANGLE"; + case EntryPoint::GLDisableVertexArrayAttrib: + return "glDisableVertexArrayAttrib"; + case EntryPoint::GLDisableVertexAttribArray: + return "glDisableVertexAttribArray"; + case EntryPoint::GLDisablei: + return "glDisablei"; + case EntryPoint::GLDisableiEXT: + return "glDisableiEXT"; + case EntryPoint::GLDisableiOES: + return "glDisableiOES"; + case EntryPoint::GLDiscardFramebufferEXT: + return "glDiscardFramebufferEXT"; + case EntryPoint::GLDispatchCompute: + return "glDispatchCompute"; + case EntryPoint::GLDispatchComputeIndirect: + return "glDispatchComputeIndirect"; + case EntryPoint::GLDrawArrays: + return "glDrawArrays"; + case EntryPoint::GLDrawArraysIndirect: + return "glDrawArraysIndirect"; + case EntryPoint::GLDrawArraysInstanced: + return "glDrawArraysInstanced"; + case EntryPoint::GLDrawArraysInstancedANGLE: + return "glDrawArraysInstancedANGLE"; + case EntryPoint::GLDrawArraysInstancedBaseInstance: + return "glDrawArraysInstancedBaseInstance"; + case EntryPoint::GLDrawArraysInstancedBaseInstanceANGLE: + return "glDrawArraysInstancedBaseInstanceANGLE"; + case EntryPoint::GLDrawArraysInstancedBaseInstanceEXT: + return "glDrawArraysInstancedBaseInstanceEXT"; + case EntryPoint::GLDrawArraysInstancedEXT: + return "glDrawArraysInstancedEXT"; + case EntryPoint::GLDrawBuffer: + return "glDrawBuffer"; + case EntryPoint::GLDrawBuffers: + return "glDrawBuffers"; + case EntryPoint::GLDrawBuffersEXT: + return "glDrawBuffersEXT"; + case EntryPoint::GLDrawElements: + return "glDrawElements"; + case EntryPoint::GLDrawElementsBaseVertex: + return "glDrawElementsBaseVertex"; + case EntryPoint::GLDrawElementsBaseVertexEXT: + return "glDrawElementsBaseVertexEXT"; + case EntryPoint::GLDrawElementsBaseVertexOES: + return "glDrawElementsBaseVertexOES"; + case EntryPoint::GLDrawElementsIndirect: + return "glDrawElementsIndirect"; + case EntryPoint::GLDrawElementsInstanced: + return "glDrawElementsInstanced"; + case EntryPoint::GLDrawElementsInstancedANGLE: + return "glDrawElementsInstancedANGLE"; + case EntryPoint::GLDrawElementsInstancedBaseInstance: + return "glDrawElementsInstancedBaseInstance"; + case EntryPoint::GLDrawElementsInstancedBaseInstanceEXT: + return "glDrawElementsInstancedBaseInstanceEXT"; + case EntryPoint::GLDrawElementsInstancedBaseVertex: + return "glDrawElementsInstancedBaseVertex"; + case EntryPoint::GLDrawElementsInstancedBaseVertexBaseInstance: + return "glDrawElementsInstancedBaseVertexBaseInstance"; + case EntryPoint::GLDrawElementsInstancedBaseVertexBaseInstanceANGLE: + return "glDrawElementsInstancedBaseVertexBaseInstanceANGLE"; + case EntryPoint::GLDrawElementsInstancedBaseVertexBaseInstanceEXT: + return "glDrawElementsInstancedBaseVertexBaseInstanceEXT"; + case EntryPoint::GLDrawElementsInstancedBaseVertexEXT: + return "glDrawElementsInstancedBaseVertexEXT"; + case EntryPoint::GLDrawElementsInstancedBaseVertexOES: + return "glDrawElementsInstancedBaseVertexOES"; + case EntryPoint::GLDrawElementsInstancedEXT: + return "glDrawElementsInstancedEXT"; + case EntryPoint::GLDrawPixels: + return "glDrawPixels"; + case EntryPoint::GLDrawRangeElements: + return "glDrawRangeElements"; + case EntryPoint::GLDrawRangeElementsBaseVertex: + return "glDrawRangeElementsBaseVertex"; + case EntryPoint::GLDrawRangeElementsBaseVertexEXT: + return "glDrawRangeElementsBaseVertexEXT"; + case EntryPoint::GLDrawRangeElementsBaseVertexOES: + return "glDrawRangeElementsBaseVertexOES"; + case EntryPoint::GLDrawTexfOES: + return "glDrawTexfOES"; + case EntryPoint::GLDrawTexfvOES: + return "glDrawTexfvOES"; + case EntryPoint::GLDrawTexiOES: + return "glDrawTexiOES"; + case EntryPoint::GLDrawTexivOES: + return "glDrawTexivOES"; + case EntryPoint::GLDrawTexsOES: + return "glDrawTexsOES"; + case EntryPoint::GLDrawTexsvOES: + return "glDrawTexsvOES"; + case EntryPoint::GLDrawTexxOES: + return "glDrawTexxOES"; + case EntryPoint::GLDrawTexxvOES: + return "glDrawTexxvOES"; + case EntryPoint::GLDrawTransformFeedback: + return "glDrawTransformFeedback"; + case EntryPoint::GLDrawTransformFeedbackInstanced: + return "glDrawTransformFeedbackInstanced"; + case EntryPoint::GLDrawTransformFeedbackStream: + return "glDrawTransformFeedbackStream"; + case EntryPoint::GLDrawTransformFeedbackStreamInstanced: + return "glDrawTransformFeedbackStreamInstanced"; + case EntryPoint::GLEGLImageTargetRenderbufferStorageOES: + return "glEGLImageTargetRenderbufferStorageOES"; + case EntryPoint::GLEGLImageTargetTexStorageEXT: + return "glEGLImageTargetTexStorageEXT"; + case EntryPoint::GLEGLImageTargetTexture2DOES: + return "glEGLImageTargetTexture2DOES"; + case EntryPoint::GLEGLImageTargetTextureStorageEXT: + return "glEGLImageTargetTextureStorageEXT"; + case EntryPoint::GLEdgeFlag: + return "glEdgeFlag"; + case EntryPoint::GLEdgeFlagPointer: + return "glEdgeFlagPointer"; + case EntryPoint::GLEdgeFlagv: + return "glEdgeFlagv"; + case EntryPoint::GLEnable: + return "glEnable"; + case EntryPoint::GLEnableClientState: + return "glEnableClientState"; + case EntryPoint::GLEnableVertexArrayAttrib: + return "glEnableVertexArrayAttrib"; + case EntryPoint::GLEnableVertexAttribArray: + return "glEnableVertexAttribArray"; + case EntryPoint::GLEnablei: + return "glEnablei"; + case EntryPoint::GLEnableiEXT: + return "glEnableiEXT"; + case EntryPoint::GLEnableiOES: + return "glEnableiOES"; + case EntryPoint::GLEnd: + return "glEnd"; + case EntryPoint::GLEndConditionalRender: + return "glEndConditionalRender"; + case EntryPoint::GLEndList: + return "glEndList"; + case EntryPoint::GLEndPerfMonitorAMD: + return "glEndPerfMonitorAMD"; + case EntryPoint::GLEndPixelLocalStorageANGLE: + return "glEndPixelLocalStorageANGLE"; + case EntryPoint::GLEndQuery: + return "glEndQuery"; + case EntryPoint::GLEndQueryEXT: + return "glEndQueryEXT"; + case EntryPoint::GLEndQueryIndexed: + return "glEndQueryIndexed"; + case EntryPoint::GLEndTransformFeedback: + return "glEndTransformFeedback"; + case EntryPoint::GLEvalCoord1d: + return "glEvalCoord1d"; + case EntryPoint::GLEvalCoord1dv: + return "glEvalCoord1dv"; + case EntryPoint::GLEvalCoord1f: + return "glEvalCoord1f"; + case EntryPoint::GLEvalCoord1fv: + return "glEvalCoord1fv"; + case EntryPoint::GLEvalCoord2d: + return "glEvalCoord2d"; + case EntryPoint::GLEvalCoord2dv: + return "glEvalCoord2dv"; + case EntryPoint::GLEvalCoord2f: + return "glEvalCoord2f"; + case EntryPoint::GLEvalCoord2fv: + return "glEvalCoord2fv"; + case EntryPoint::GLEvalMesh1: + return "glEvalMesh1"; + case EntryPoint::GLEvalMesh2: + return "glEvalMesh2"; + case EntryPoint::GLEvalPoint1: + return "glEvalPoint1"; + case EntryPoint::GLEvalPoint2: + return "glEvalPoint2"; + case EntryPoint::GLFeedbackBuffer: + return "glFeedbackBuffer"; + case EntryPoint::GLFenceSync: + return "glFenceSync"; + case EntryPoint::GLFinish: + return "glFinish"; + case EntryPoint::GLFinishFenceNV: + return "glFinishFenceNV"; + case EntryPoint::GLFlush: + return "glFlush"; + case EntryPoint::GLFlushMappedBufferRange: + return "glFlushMappedBufferRange"; + case EntryPoint::GLFlushMappedBufferRangeEXT: + return "glFlushMappedBufferRangeEXT"; + case EntryPoint::GLFlushMappedNamedBufferRange: + return "glFlushMappedNamedBufferRange"; + case EntryPoint::GLFogCoordPointer: + return "glFogCoordPointer"; + case EntryPoint::GLFogCoordd: + return "glFogCoordd"; + case EntryPoint::GLFogCoorddv: + return "glFogCoorddv"; + case EntryPoint::GLFogCoordf: + return "glFogCoordf"; + case EntryPoint::GLFogCoordfv: + return "glFogCoordfv"; + case EntryPoint::GLFogf: + return "glFogf"; + case EntryPoint::GLFogfv: + return "glFogfv"; + case EntryPoint::GLFogi: + return "glFogi"; + case EntryPoint::GLFogiv: + return "glFogiv"; + case EntryPoint::GLFogx: + return "glFogx"; + case EntryPoint::GLFogxv: + return "glFogxv"; + case EntryPoint::GLFramebufferFetchBarrierEXT: + return "glFramebufferFetchBarrierEXT"; + case EntryPoint::GLFramebufferMemorylessPixelLocalStorageANGLE: + return "glFramebufferMemorylessPixelLocalStorageANGLE"; + case EntryPoint::GLFramebufferParameteri: + return "glFramebufferParameteri"; + case EntryPoint::GLFramebufferParameteriMESA: + return "glFramebufferParameteriMESA"; + case EntryPoint::GLFramebufferRenderbuffer: + return "glFramebufferRenderbuffer"; + case EntryPoint::GLFramebufferRenderbufferOES: + return "glFramebufferRenderbufferOES"; + case EntryPoint::GLFramebufferTexture: + return "glFramebufferTexture"; + case EntryPoint::GLFramebufferTexture1D: + return "glFramebufferTexture1D"; + case EntryPoint::GLFramebufferTexture2D: + return "glFramebufferTexture2D"; + case EntryPoint::GLFramebufferTexture2DMultisampleEXT: + return "glFramebufferTexture2DMultisampleEXT"; + case EntryPoint::GLFramebufferTexture2DOES: + return "glFramebufferTexture2DOES"; + case EntryPoint::GLFramebufferTexture3D: + return "glFramebufferTexture3D"; + case EntryPoint::GLFramebufferTexture3DOES: + return "glFramebufferTexture3DOES"; + case EntryPoint::GLFramebufferTextureEXT: + return "glFramebufferTextureEXT"; + case EntryPoint::GLFramebufferTextureLayer: + return "glFramebufferTextureLayer"; + case EntryPoint::GLFramebufferTextureMultiviewOVR: + return "glFramebufferTextureMultiviewOVR"; + case EntryPoint::GLFramebufferTextureOES: + return "glFramebufferTextureOES"; + case EntryPoint::GLFramebufferTexturePixelLocalStorageANGLE: + return "glFramebufferTexturePixelLocalStorageANGLE"; + case EntryPoint::GLFrontFace: + return "glFrontFace"; + case EntryPoint::GLFrustum: + return "glFrustum"; + case EntryPoint::GLFrustumf: + return "glFrustumf"; + case EntryPoint::GLFrustumx: + return "glFrustumx"; + case EntryPoint::GLGenBuffers: + return "glGenBuffers"; + case EntryPoint::GLGenFencesNV: + return "glGenFencesNV"; + case EntryPoint::GLGenFramebuffers: + return "glGenFramebuffers"; + case EntryPoint::GLGenFramebuffersOES: + return "glGenFramebuffersOES"; + case EntryPoint::GLGenLists: + return "glGenLists"; + case EntryPoint::GLGenPerfMonitorsAMD: + return "glGenPerfMonitorsAMD"; + case EntryPoint::GLGenProgramPipelines: + return "glGenProgramPipelines"; + case EntryPoint::GLGenProgramPipelinesEXT: + return "glGenProgramPipelinesEXT"; + case EntryPoint::GLGenQueries: + return "glGenQueries"; + case EntryPoint::GLGenQueriesEXT: + return "glGenQueriesEXT"; + case EntryPoint::GLGenRenderbuffers: + return "glGenRenderbuffers"; + case EntryPoint::GLGenRenderbuffersOES: + return "glGenRenderbuffersOES"; + case EntryPoint::GLGenSamplers: + return "glGenSamplers"; + case EntryPoint::GLGenSemaphoresEXT: + return "glGenSemaphoresEXT"; + case EntryPoint::GLGenTextures: + return "glGenTextures"; + case EntryPoint::GLGenTransformFeedbacks: + return "glGenTransformFeedbacks"; + case EntryPoint::GLGenVertexArrays: + return "glGenVertexArrays"; + case EntryPoint::GLGenVertexArraysOES: + return "glGenVertexArraysOES"; + case EntryPoint::GLGenerateMipmap: + return "glGenerateMipmap"; + case EntryPoint::GLGenerateMipmapOES: + return "glGenerateMipmapOES"; + case EntryPoint::GLGenerateTextureMipmap: + return "glGenerateTextureMipmap"; + case EntryPoint::GLGetActiveAtomicCounterBufferiv: + return "glGetActiveAtomicCounterBufferiv"; + case EntryPoint::GLGetActiveAttrib: + return "glGetActiveAttrib"; + case EntryPoint::GLGetActiveSubroutineName: + return "glGetActiveSubroutineName"; + case EntryPoint::GLGetActiveSubroutineUniformName: + return "glGetActiveSubroutineUniformName"; + case EntryPoint::GLGetActiveSubroutineUniformiv: + return "glGetActiveSubroutineUniformiv"; + case EntryPoint::GLGetActiveUniform: + return "glGetActiveUniform"; + case EntryPoint::GLGetActiveUniformBlockName: + return "glGetActiveUniformBlockName"; + case EntryPoint::GLGetActiveUniformBlockiv: + return "glGetActiveUniformBlockiv"; + case EntryPoint::GLGetActiveUniformBlockivRobustANGLE: + return "glGetActiveUniformBlockivRobustANGLE"; + case EntryPoint::GLGetActiveUniformName: + return "glGetActiveUniformName"; + case EntryPoint::GLGetActiveUniformsiv: + return "glGetActiveUniformsiv"; + case EntryPoint::GLGetAttachedShaders: + return "glGetAttachedShaders"; + case EntryPoint::GLGetAttribLocation: + return "glGetAttribLocation"; + case EntryPoint::GLGetBooleani_v: + return "glGetBooleani_v"; + case EntryPoint::GLGetBooleani_vRobustANGLE: + return "glGetBooleani_vRobustANGLE"; + case EntryPoint::GLGetBooleanv: + return "glGetBooleanv"; + case EntryPoint::GLGetBooleanvRobustANGLE: + return "glGetBooleanvRobustANGLE"; + case EntryPoint::GLGetBufferParameteri64v: + return "glGetBufferParameteri64v"; + case EntryPoint::GLGetBufferParameteri64vRobustANGLE: + return "glGetBufferParameteri64vRobustANGLE"; + case EntryPoint::GLGetBufferParameteriv: + return "glGetBufferParameteriv"; + case EntryPoint::GLGetBufferParameterivRobustANGLE: + return "glGetBufferParameterivRobustANGLE"; + case EntryPoint::GLGetBufferPointerv: + return "glGetBufferPointerv"; + case EntryPoint::GLGetBufferPointervOES: + return "glGetBufferPointervOES"; + case EntryPoint::GLGetBufferPointervRobustANGLE: + return "glGetBufferPointervRobustANGLE"; + case EntryPoint::GLGetBufferSubData: + return "glGetBufferSubData"; + case EntryPoint::GLGetClipPlane: + return "glGetClipPlane"; + case EntryPoint::GLGetClipPlanef: + return "glGetClipPlanef"; + case EntryPoint::GLGetClipPlanex: + return "glGetClipPlanex"; + case EntryPoint::GLGetCompressedTexImage: + return "glGetCompressedTexImage"; + case EntryPoint::GLGetCompressedTexImageANGLE: + return "glGetCompressedTexImageANGLE"; + case EntryPoint::GLGetCompressedTextureImage: + return "glGetCompressedTextureImage"; + case EntryPoint::GLGetCompressedTextureSubImage: + return "glGetCompressedTextureSubImage"; + case EntryPoint::GLGetDebugMessageLog: + return "glGetDebugMessageLog"; + case EntryPoint::GLGetDebugMessageLogKHR: + return "glGetDebugMessageLogKHR"; + case EntryPoint::GLGetDoublei_v: + return "glGetDoublei_v"; + case EntryPoint::GLGetDoublev: + return "glGetDoublev"; + case EntryPoint::GLGetError: + return "glGetError"; + case EntryPoint::GLGetFenceivNV: + return "glGetFenceivNV"; + case EntryPoint::GLGetFixedv: + return "glGetFixedv"; + case EntryPoint::GLGetFloati_v: + return "glGetFloati_v"; + case EntryPoint::GLGetFloatv: + return "glGetFloatv"; + case EntryPoint::GLGetFloatvRobustANGLE: + return "glGetFloatvRobustANGLE"; + case EntryPoint::GLGetFragDataIndex: + return "glGetFragDataIndex"; + case EntryPoint::GLGetFragDataIndexEXT: + return "glGetFragDataIndexEXT"; + case EntryPoint::GLGetFragDataLocation: + return "glGetFragDataLocation"; + case EntryPoint::GLGetFramebufferAttachmentParameteriv: + return "glGetFramebufferAttachmentParameteriv"; + case EntryPoint::GLGetFramebufferAttachmentParameterivOES: + return "glGetFramebufferAttachmentParameterivOES"; + case EntryPoint::GLGetFramebufferAttachmentParameterivRobustANGLE: + return "glGetFramebufferAttachmentParameterivRobustANGLE"; + case EntryPoint::GLGetFramebufferParameteriv: + return "glGetFramebufferParameteriv"; + case EntryPoint::GLGetFramebufferParameterivMESA: + return "glGetFramebufferParameterivMESA"; + case EntryPoint::GLGetFramebufferParameterivRobustANGLE: + return "glGetFramebufferParameterivRobustANGLE"; + case EntryPoint::GLGetGraphicsResetStatus: + return "glGetGraphicsResetStatus"; + case EntryPoint::GLGetGraphicsResetStatusEXT: + return "glGetGraphicsResetStatusEXT"; + case EntryPoint::GLGetInteger64i_v: + return "glGetInteger64i_v"; + case EntryPoint::GLGetInteger64i_vRobustANGLE: + return "glGetInteger64i_vRobustANGLE"; + case EntryPoint::GLGetInteger64v: + return "glGetInteger64v"; + case EntryPoint::GLGetInteger64vEXT: + return "glGetInteger64vEXT"; + case EntryPoint::GLGetInteger64vRobustANGLE: + return "glGetInteger64vRobustANGLE"; + case EntryPoint::GLGetIntegeri_v: + return "glGetIntegeri_v"; + case EntryPoint::GLGetIntegeri_vRobustANGLE: + return "glGetIntegeri_vRobustANGLE"; + case EntryPoint::GLGetIntegerv: + return "glGetIntegerv"; + case EntryPoint::GLGetIntegervRobustANGLE: + return "glGetIntegervRobustANGLE"; + case EntryPoint::GLGetInternalformati64v: + return "glGetInternalformati64v"; + case EntryPoint::GLGetInternalformativ: + return "glGetInternalformativ"; + case EntryPoint::GLGetInternalformativRobustANGLE: + return "glGetInternalformativRobustANGLE"; + case EntryPoint::GLGetLightfv: + return "glGetLightfv"; + case EntryPoint::GLGetLightiv: + return "glGetLightiv"; + case EntryPoint::GLGetLightxv: + return "glGetLightxv"; + case EntryPoint::GLGetMapdv: + return "glGetMapdv"; + case EntryPoint::GLGetMapfv: + return "glGetMapfv"; + case EntryPoint::GLGetMapiv: + return "glGetMapiv"; + case EntryPoint::GLGetMaterialfv: + return "glGetMaterialfv"; + case EntryPoint::GLGetMaterialiv: + return "glGetMaterialiv"; + case EntryPoint::GLGetMaterialxv: + return "glGetMaterialxv"; + case EntryPoint::GLGetMemoryObjectParameterivEXT: + return "glGetMemoryObjectParameterivEXT"; + case EntryPoint::GLGetMultisamplefv: + return "glGetMultisamplefv"; + case EntryPoint::GLGetMultisamplefvANGLE: + return "glGetMultisamplefvANGLE"; + case EntryPoint::GLGetMultisamplefvRobustANGLE: + return "glGetMultisamplefvRobustANGLE"; + case EntryPoint::GLGetNamedBufferParameteri64v: + return "glGetNamedBufferParameteri64v"; + case EntryPoint::GLGetNamedBufferParameteriv: + return "glGetNamedBufferParameteriv"; + case EntryPoint::GLGetNamedBufferPointerv: + return "glGetNamedBufferPointerv"; + case EntryPoint::GLGetNamedBufferSubData: + return "glGetNamedBufferSubData"; + case EntryPoint::GLGetNamedFramebufferAttachmentParameteriv: + return "glGetNamedFramebufferAttachmentParameteriv"; + case EntryPoint::GLGetNamedFramebufferParameteriv: + return "glGetNamedFramebufferParameteriv"; + case EntryPoint::GLGetNamedRenderbufferParameteriv: + return "glGetNamedRenderbufferParameteriv"; + case EntryPoint::GLGetObjectLabel: + return "glGetObjectLabel"; + case EntryPoint::GLGetObjectLabelEXT: + return "glGetObjectLabelEXT"; + case EntryPoint::GLGetObjectLabelKHR: + return "glGetObjectLabelKHR"; + case EntryPoint::GLGetObjectPtrLabel: + return "glGetObjectPtrLabel"; + case EntryPoint::GLGetObjectPtrLabelKHR: + return "glGetObjectPtrLabelKHR"; + case EntryPoint::GLGetPerfMonitorCounterDataAMD: + return "glGetPerfMonitorCounterDataAMD"; + case EntryPoint::GLGetPerfMonitorCounterInfoAMD: + return "glGetPerfMonitorCounterInfoAMD"; + case EntryPoint::GLGetPerfMonitorCounterStringAMD: + return "glGetPerfMonitorCounterStringAMD"; + case EntryPoint::GLGetPerfMonitorCountersAMD: + return "glGetPerfMonitorCountersAMD"; + case EntryPoint::GLGetPerfMonitorGroupStringAMD: + return "glGetPerfMonitorGroupStringAMD"; + case EntryPoint::GLGetPerfMonitorGroupsAMD: + return "glGetPerfMonitorGroupsAMD"; + case EntryPoint::GLGetPixelMapfv: + return "glGetPixelMapfv"; + case EntryPoint::GLGetPixelMapuiv: + return "glGetPixelMapuiv"; + case EntryPoint::GLGetPixelMapusv: + return "glGetPixelMapusv"; + case EntryPoint::GLGetPointerv: + return "glGetPointerv"; + case EntryPoint::GLGetPointervKHR: + return "glGetPointervKHR"; + case EntryPoint::GLGetPointervRobustANGLERobustANGLE: + return "glGetPointervRobustANGLERobustANGLE"; + case EntryPoint::GLGetPolygonStipple: + return "glGetPolygonStipple"; + case EntryPoint::GLGetProgramBinary: + return "glGetProgramBinary"; + case EntryPoint::GLGetProgramBinaryOES: + return "glGetProgramBinaryOES"; + case EntryPoint::GLGetProgramInfoLog: + return "glGetProgramInfoLog"; + case EntryPoint::GLGetProgramInterfaceiv: + return "glGetProgramInterfaceiv"; + case EntryPoint::GLGetProgramInterfaceivRobustANGLE: + return "glGetProgramInterfaceivRobustANGLE"; + case EntryPoint::GLGetProgramPipelineInfoLog: + return "glGetProgramPipelineInfoLog"; + case EntryPoint::GLGetProgramPipelineInfoLogEXT: + return "glGetProgramPipelineInfoLogEXT"; + case EntryPoint::GLGetProgramPipelineiv: + return "glGetProgramPipelineiv"; + case EntryPoint::GLGetProgramPipelineivEXT: + return "glGetProgramPipelineivEXT"; + case EntryPoint::GLGetProgramResourceIndex: + return "glGetProgramResourceIndex"; + case EntryPoint::GLGetProgramResourceLocation: + return "glGetProgramResourceLocation"; + case EntryPoint::GLGetProgramResourceLocationIndex: + return "glGetProgramResourceLocationIndex"; + case EntryPoint::GLGetProgramResourceLocationIndexEXT: + return "glGetProgramResourceLocationIndexEXT"; + case EntryPoint::GLGetProgramResourceName: + return "glGetProgramResourceName"; + case EntryPoint::GLGetProgramResourceiv: + return "glGetProgramResourceiv"; + case EntryPoint::GLGetProgramStageiv: + return "glGetProgramStageiv"; + case EntryPoint::GLGetProgramiv: + return "glGetProgramiv"; + case EntryPoint::GLGetProgramivRobustANGLE: + return "glGetProgramivRobustANGLE"; + case EntryPoint::GLGetQueryBufferObjecti64v: + return "glGetQueryBufferObjecti64v"; + case EntryPoint::GLGetQueryBufferObjectiv: + return "glGetQueryBufferObjectiv"; + case EntryPoint::GLGetQueryBufferObjectui64v: + return "glGetQueryBufferObjectui64v"; + case EntryPoint::GLGetQueryBufferObjectuiv: + return "glGetQueryBufferObjectuiv"; + case EntryPoint::GLGetQueryIndexediv: + return "glGetQueryIndexediv"; + case EntryPoint::GLGetQueryObjecti64v: + return "glGetQueryObjecti64v"; + case EntryPoint::GLGetQueryObjecti64vEXT: + return "glGetQueryObjecti64vEXT"; + case EntryPoint::GLGetQueryObjecti64vRobustANGLE: + return "glGetQueryObjecti64vRobustANGLE"; + case EntryPoint::GLGetQueryObjectiv: + return "glGetQueryObjectiv"; + case EntryPoint::GLGetQueryObjectivEXT: + return "glGetQueryObjectivEXT"; + case EntryPoint::GLGetQueryObjectivRobustANGLE: + return "glGetQueryObjectivRobustANGLE"; + case EntryPoint::GLGetQueryObjectui64v: + return "glGetQueryObjectui64v"; + case EntryPoint::GLGetQueryObjectui64vEXT: + return "glGetQueryObjectui64vEXT"; + case EntryPoint::GLGetQueryObjectui64vRobustANGLE: + return "glGetQueryObjectui64vRobustANGLE"; + case EntryPoint::GLGetQueryObjectuiv: + return "glGetQueryObjectuiv"; + case EntryPoint::GLGetQueryObjectuivEXT: + return "glGetQueryObjectuivEXT"; + case EntryPoint::GLGetQueryObjectuivRobustANGLE: + return "glGetQueryObjectuivRobustANGLE"; + case EntryPoint::GLGetQueryiv: + return "glGetQueryiv"; + case EntryPoint::GLGetQueryivEXT: + return "glGetQueryivEXT"; + case EntryPoint::GLGetQueryivRobustANGLE: + return "glGetQueryivRobustANGLE"; + case EntryPoint::GLGetRenderbufferImageANGLE: + return "glGetRenderbufferImageANGLE"; + case EntryPoint::GLGetRenderbufferParameteriv: + return "glGetRenderbufferParameteriv"; + case EntryPoint::GLGetRenderbufferParameterivOES: + return "glGetRenderbufferParameterivOES"; + case EntryPoint::GLGetRenderbufferParameterivRobustANGLE: + return "glGetRenderbufferParameterivRobustANGLE"; + case EntryPoint::GLGetSamplerParameterIiv: + return "glGetSamplerParameterIiv"; + case EntryPoint::GLGetSamplerParameterIivEXT: + return "glGetSamplerParameterIivEXT"; + case EntryPoint::GLGetSamplerParameterIivOES: + return "glGetSamplerParameterIivOES"; + case EntryPoint::GLGetSamplerParameterIivRobustANGLE: + return "glGetSamplerParameterIivRobustANGLE"; + case EntryPoint::GLGetSamplerParameterIuiv: + return "glGetSamplerParameterIuiv"; + case EntryPoint::GLGetSamplerParameterIuivEXT: + return "glGetSamplerParameterIuivEXT"; + case EntryPoint::GLGetSamplerParameterIuivOES: + return "glGetSamplerParameterIuivOES"; + case EntryPoint::GLGetSamplerParameterIuivRobustANGLE: + return "glGetSamplerParameterIuivRobustANGLE"; + case EntryPoint::GLGetSamplerParameterfv: + return "glGetSamplerParameterfv"; + case EntryPoint::GLGetSamplerParameterfvRobustANGLE: + return "glGetSamplerParameterfvRobustANGLE"; + case EntryPoint::GLGetSamplerParameteriv: + return "glGetSamplerParameteriv"; + case EntryPoint::GLGetSamplerParameterivRobustANGLE: + return "glGetSamplerParameterivRobustANGLE"; + case EntryPoint::GLGetSemaphoreParameterui64vEXT: + return "glGetSemaphoreParameterui64vEXT"; + case EntryPoint::GLGetShaderInfoLog: + return "glGetShaderInfoLog"; + case EntryPoint::GLGetShaderPrecisionFormat: + return "glGetShaderPrecisionFormat"; + case EntryPoint::GLGetShaderSource: + return "glGetShaderSource"; + case EntryPoint::GLGetShaderiv: + return "glGetShaderiv"; + case EntryPoint::GLGetShaderivRobustANGLE: + return "glGetShaderivRobustANGLE"; + case EntryPoint::GLGetString: + return "glGetString"; + case EntryPoint::GLGetStringi: + return "glGetStringi"; + case EntryPoint::GLGetSubroutineIndex: + return "glGetSubroutineIndex"; + case EntryPoint::GLGetSubroutineUniformLocation: + return "glGetSubroutineUniformLocation"; + case EntryPoint::GLGetSynciv: + return "glGetSynciv"; + case EntryPoint::GLGetTexEnvfv: + return "glGetTexEnvfv"; + case EntryPoint::GLGetTexEnviv: + return "glGetTexEnviv"; + case EntryPoint::GLGetTexEnvxv: + return "glGetTexEnvxv"; + case EntryPoint::GLGetTexGendv: + return "glGetTexGendv"; + case EntryPoint::GLGetTexGenfv: + return "glGetTexGenfv"; + case EntryPoint::GLGetTexGenfvOES: + return "glGetTexGenfvOES"; + case EntryPoint::GLGetTexGeniv: + return "glGetTexGeniv"; + case EntryPoint::GLGetTexGenivOES: + return "glGetTexGenivOES"; + case EntryPoint::GLGetTexGenxvOES: + return "glGetTexGenxvOES"; + case EntryPoint::GLGetTexImage: + return "glGetTexImage"; + case EntryPoint::GLGetTexImageANGLE: + return "glGetTexImageANGLE"; + case EntryPoint::GLGetTexLevelParameterfv: + return "glGetTexLevelParameterfv"; + case EntryPoint::GLGetTexLevelParameterfvANGLE: + return "glGetTexLevelParameterfvANGLE"; + case EntryPoint::GLGetTexLevelParameterfvRobustANGLE: + return "glGetTexLevelParameterfvRobustANGLE"; + case EntryPoint::GLGetTexLevelParameteriv: + return "glGetTexLevelParameteriv"; + case EntryPoint::GLGetTexLevelParameterivANGLE: + return "glGetTexLevelParameterivANGLE"; + case EntryPoint::GLGetTexLevelParameterivRobustANGLE: + return "glGetTexLevelParameterivRobustANGLE"; + case EntryPoint::GLGetTexParameterIiv: + return "glGetTexParameterIiv"; + case EntryPoint::GLGetTexParameterIivEXT: + return "glGetTexParameterIivEXT"; + case EntryPoint::GLGetTexParameterIivOES: + return "glGetTexParameterIivOES"; + case EntryPoint::GLGetTexParameterIivRobustANGLE: + return "glGetTexParameterIivRobustANGLE"; + case EntryPoint::GLGetTexParameterIuiv: + return "glGetTexParameterIuiv"; + case EntryPoint::GLGetTexParameterIuivEXT: + return "glGetTexParameterIuivEXT"; + case EntryPoint::GLGetTexParameterIuivOES: + return "glGetTexParameterIuivOES"; + case EntryPoint::GLGetTexParameterIuivRobustANGLE: + return "glGetTexParameterIuivRobustANGLE"; + case EntryPoint::GLGetTexParameterfv: + return "glGetTexParameterfv"; + case EntryPoint::GLGetTexParameterfvRobustANGLE: + return "glGetTexParameterfvRobustANGLE"; + case EntryPoint::GLGetTexParameteriv: + return "glGetTexParameteriv"; + case EntryPoint::GLGetTexParameterivRobustANGLE: + return "glGetTexParameterivRobustANGLE"; + case EntryPoint::GLGetTexParameterxv: + return "glGetTexParameterxv"; + case EntryPoint::GLGetTextureImage: + return "glGetTextureImage"; + case EntryPoint::GLGetTextureLevelParameterfv: + return "glGetTextureLevelParameterfv"; + case EntryPoint::GLGetTextureLevelParameteriv: + return "glGetTextureLevelParameteriv"; + case EntryPoint::GLGetTextureParameterIiv: + return "glGetTextureParameterIiv"; + case EntryPoint::GLGetTextureParameterIuiv: + return "glGetTextureParameterIuiv"; + case EntryPoint::GLGetTextureParameterfv: + return "glGetTextureParameterfv"; + case EntryPoint::GLGetTextureParameteriv: + return "glGetTextureParameteriv"; + case EntryPoint::GLGetTextureSubImage: + return "glGetTextureSubImage"; + case EntryPoint::GLGetTransformFeedbackVarying: + return "glGetTransformFeedbackVarying"; + case EntryPoint::GLGetTransformFeedbacki64_v: + return "glGetTransformFeedbacki64_v"; + case EntryPoint::GLGetTransformFeedbacki_v: + return "glGetTransformFeedbacki_v"; + case EntryPoint::GLGetTransformFeedbackiv: + return "glGetTransformFeedbackiv"; + case EntryPoint::GLGetTranslatedShaderSourceANGLE: + return "glGetTranslatedShaderSourceANGLE"; + case EntryPoint::GLGetUniformBlockIndex: + return "glGetUniformBlockIndex"; + case EntryPoint::GLGetUniformIndices: + return "glGetUniformIndices"; + case EntryPoint::GLGetUniformLocation: + return "glGetUniformLocation"; + case EntryPoint::GLGetUniformSubroutineuiv: + return "glGetUniformSubroutineuiv"; + case EntryPoint::GLGetUniformdv: + return "glGetUniformdv"; + case EntryPoint::GLGetUniformfv: + return "glGetUniformfv"; + case EntryPoint::GLGetUniformfvRobustANGLE: + return "glGetUniformfvRobustANGLE"; + case EntryPoint::GLGetUniformiv: + return "glGetUniformiv"; + case EntryPoint::GLGetUniformivRobustANGLE: + return "glGetUniformivRobustANGLE"; + case EntryPoint::GLGetUniformuiv: + return "glGetUniformuiv"; + case EntryPoint::GLGetUniformuivRobustANGLE: + return "glGetUniformuivRobustANGLE"; + case EntryPoint::GLGetUnsignedBytei_vEXT: + return "glGetUnsignedBytei_vEXT"; + case EntryPoint::GLGetUnsignedBytevEXT: + return "glGetUnsignedBytevEXT"; + case EntryPoint::GLGetVertexArrayIndexed64iv: + return "glGetVertexArrayIndexed64iv"; + case EntryPoint::GLGetVertexArrayIndexediv: + return "glGetVertexArrayIndexediv"; + case EntryPoint::GLGetVertexArrayiv: + return "glGetVertexArrayiv"; + case EntryPoint::GLGetVertexAttribIiv: + return "glGetVertexAttribIiv"; + case EntryPoint::GLGetVertexAttribIivRobustANGLE: + return "glGetVertexAttribIivRobustANGLE"; + case EntryPoint::GLGetVertexAttribIuiv: + return "glGetVertexAttribIuiv"; + case EntryPoint::GLGetVertexAttribIuivRobustANGLE: + return "glGetVertexAttribIuivRobustANGLE"; + case EntryPoint::GLGetVertexAttribLdv: + return "glGetVertexAttribLdv"; + case EntryPoint::GLGetVertexAttribPointerv: + return "glGetVertexAttribPointerv"; + case EntryPoint::GLGetVertexAttribPointervRobustANGLE: + return "glGetVertexAttribPointervRobustANGLE"; + case EntryPoint::GLGetVertexAttribdv: + return "glGetVertexAttribdv"; + case EntryPoint::GLGetVertexAttribfv: + return "glGetVertexAttribfv"; + case EntryPoint::GLGetVertexAttribfvRobustANGLE: + return "glGetVertexAttribfvRobustANGLE"; + case EntryPoint::GLGetVertexAttribiv: + return "glGetVertexAttribiv"; + case EntryPoint::GLGetVertexAttribivRobustANGLE: + return "glGetVertexAttribivRobustANGLE"; + case EntryPoint::GLGetnColorTable: + return "glGetnColorTable"; + case EntryPoint::GLGetnCompressedTexImage: + return "glGetnCompressedTexImage"; + case EntryPoint::GLGetnConvolutionFilter: + return "glGetnConvolutionFilter"; + case EntryPoint::GLGetnHistogram: + return "glGetnHistogram"; + case EntryPoint::GLGetnMapdv: + return "glGetnMapdv"; + case EntryPoint::GLGetnMapfv: + return "glGetnMapfv"; + case EntryPoint::GLGetnMapiv: + return "glGetnMapiv"; + case EntryPoint::GLGetnMinmax: + return "glGetnMinmax"; + case EntryPoint::GLGetnPixelMapfv: + return "glGetnPixelMapfv"; + case EntryPoint::GLGetnPixelMapuiv: + return "glGetnPixelMapuiv"; + case EntryPoint::GLGetnPixelMapusv: + return "glGetnPixelMapusv"; + case EntryPoint::GLGetnPolygonStipple: + return "glGetnPolygonStipple"; + case EntryPoint::GLGetnSeparableFilter: + return "glGetnSeparableFilter"; + case EntryPoint::GLGetnTexImage: + return "glGetnTexImage"; + case EntryPoint::GLGetnUniformdv: + return "glGetnUniformdv"; + case EntryPoint::GLGetnUniformfv: + return "glGetnUniformfv"; + case EntryPoint::GLGetnUniformfvEXT: + return "glGetnUniformfvEXT"; + case EntryPoint::GLGetnUniformfvRobustANGLE: + return "glGetnUniformfvRobustANGLE"; + case EntryPoint::GLGetnUniformiv: + return "glGetnUniformiv"; + case EntryPoint::GLGetnUniformivEXT: + return "glGetnUniformivEXT"; + case EntryPoint::GLGetnUniformivRobustANGLE: + return "glGetnUniformivRobustANGLE"; + case EntryPoint::GLGetnUniformuiv: + return "glGetnUniformuiv"; + case EntryPoint::GLGetnUniformuivRobustANGLE: + return "glGetnUniformuivRobustANGLE"; + case EntryPoint::GLHint: + return "glHint"; + case EntryPoint::GLImportMemoryFdEXT: + return "glImportMemoryFdEXT"; + case EntryPoint::GLImportMemoryZirconHandleANGLE: + return "glImportMemoryZirconHandleANGLE"; + case EntryPoint::GLImportSemaphoreFdEXT: + return "glImportSemaphoreFdEXT"; + case EntryPoint::GLImportSemaphoreZirconHandleANGLE: + return "glImportSemaphoreZirconHandleANGLE"; + case EntryPoint::GLIndexMask: + return "glIndexMask"; + case EntryPoint::GLIndexPointer: + return "glIndexPointer"; + case EntryPoint::GLIndexd: + return "glIndexd"; + case EntryPoint::GLIndexdv: + return "glIndexdv"; + case EntryPoint::GLIndexf: + return "glIndexf"; + case EntryPoint::GLIndexfv: + return "glIndexfv"; + case EntryPoint::GLIndexi: + return "glIndexi"; + case EntryPoint::GLIndexiv: + return "glIndexiv"; + case EntryPoint::GLIndexs: + return "glIndexs"; + case EntryPoint::GLIndexsv: + return "glIndexsv"; + case EntryPoint::GLIndexub: + return "glIndexub"; + case EntryPoint::GLIndexubv: + return "glIndexubv"; + case EntryPoint::GLInitNames: + return "glInitNames"; + case EntryPoint::GLInsertEventMarkerEXT: + return "glInsertEventMarkerEXT"; + case EntryPoint::GLInterleavedArrays: + return "glInterleavedArrays"; + case EntryPoint::GLInvalid: + return "glInvalid"; + case EntryPoint::GLInvalidateBufferData: + return "glInvalidateBufferData"; + case EntryPoint::GLInvalidateBufferSubData: + return "glInvalidateBufferSubData"; + case EntryPoint::GLInvalidateFramebuffer: + return "glInvalidateFramebuffer"; + case EntryPoint::GLInvalidateNamedFramebufferData: + return "glInvalidateNamedFramebufferData"; + case EntryPoint::GLInvalidateNamedFramebufferSubData: + return "glInvalidateNamedFramebufferSubData"; + case EntryPoint::GLInvalidateSubFramebuffer: + return "glInvalidateSubFramebuffer"; + case EntryPoint::GLInvalidateTexImage: + return "glInvalidateTexImage"; + case EntryPoint::GLInvalidateTexSubImage: + return "glInvalidateTexSubImage"; + case EntryPoint::GLInvalidateTextureANGLE: + return "glInvalidateTextureANGLE"; + case EntryPoint::GLIsBuffer: + return "glIsBuffer"; + case EntryPoint::GLIsEnabled: + return "glIsEnabled"; + case EntryPoint::GLIsEnabledi: + return "glIsEnabledi"; + case EntryPoint::GLIsEnablediEXT: + return "glIsEnablediEXT"; + case EntryPoint::GLIsEnablediOES: + return "glIsEnablediOES"; + case EntryPoint::GLIsFenceNV: + return "glIsFenceNV"; + case EntryPoint::GLIsFramebuffer: + return "glIsFramebuffer"; + case EntryPoint::GLIsFramebufferOES: + return "glIsFramebufferOES"; + case EntryPoint::GLIsList: + return "glIsList"; + case EntryPoint::GLIsMemoryObjectEXT: + return "glIsMemoryObjectEXT"; + case EntryPoint::GLIsProgram: + return "glIsProgram"; + case EntryPoint::GLIsProgramPipeline: + return "glIsProgramPipeline"; + case EntryPoint::GLIsProgramPipelineEXT: + return "glIsProgramPipelineEXT"; + case EntryPoint::GLIsQuery: + return "glIsQuery"; + case EntryPoint::GLIsQueryEXT: + return "glIsQueryEXT"; + case EntryPoint::GLIsRenderbuffer: + return "glIsRenderbuffer"; + case EntryPoint::GLIsRenderbufferOES: + return "glIsRenderbufferOES"; + case EntryPoint::GLIsSampler: + return "glIsSampler"; + case EntryPoint::GLIsSemaphoreEXT: + return "glIsSemaphoreEXT"; + case EntryPoint::GLIsShader: + return "glIsShader"; + case EntryPoint::GLIsSync: + return "glIsSync"; + case EntryPoint::GLIsTexture: + return "glIsTexture"; + case EntryPoint::GLIsTransformFeedback: + return "glIsTransformFeedback"; + case EntryPoint::GLIsVertexArray: + return "glIsVertexArray"; + case EntryPoint::GLIsVertexArrayOES: + return "glIsVertexArrayOES"; + case EntryPoint::GLLabelObjectEXT: + return "glLabelObjectEXT"; + case EntryPoint::GLLightModelf: + return "glLightModelf"; + case EntryPoint::GLLightModelfv: + return "glLightModelfv"; + case EntryPoint::GLLightModeli: + return "glLightModeli"; + case EntryPoint::GLLightModeliv: + return "glLightModeliv"; + case EntryPoint::GLLightModelx: + return "glLightModelx"; + case EntryPoint::GLLightModelxv: + return "glLightModelxv"; + case EntryPoint::GLLightf: + return "glLightf"; + case EntryPoint::GLLightfv: + return "glLightfv"; + case EntryPoint::GLLighti: + return "glLighti"; + case EntryPoint::GLLightiv: + return "glLightiv"; + case EntryPoint::GLLightx: + return "glLightx"; + case EntryPoint::GLLightxv: + return "glLightxv"; + case EntryPoint::GLLineStipple: + return "glLineStipple"; + case EntryPoint::GLLineWidth: + return "glLineWidth"; + case EntryPoint::GLLineWidthx: + return "glLineWidthx"; + case EntryPoint::GLLinkProgram: + return "glLinkProgram"; + case EntryPoint::GLListBase: + return "glListBase"; + case EntryPoint::GLLoadIdentity: + return "glLoadIdentity"; + case EntryPoint::GLLoadMatrixd: + return "glLoadMatrixd"; + case EntryPoint::GLLoadMatrixf: + return "glLoadMatrixf"; + case EntryPoint::GLLoadMatrixx: + return "glLoadMatrixx"; + case EntryPoint::GLLoadName: + return "glLoadName"; + case EntryPoint::GLLoadPaletteFromModelViewMatrixOES: + return "glLoadPaletteFromModelViewMatrixOES"; + case EntryPoint::GLLoadTransposeMatrixd: + return "glLoadTransposeMatrixd"; + case EntryPoint::GLLoadTransposeMatrixf: + return "glLoadTransposeMatrixf"; + case EntryPoint::GLLogicOp: + return "glLogicOp"; + case EntryPoint::GLLogicOpANGLE: + return "glLogicOpANGLE"; + case EntryPoint::GLLoseContextCHROMIUM: + return "glLoseContextCHROMIUM"; + case EntryPoint::GLMap1d: + return "glMap1d"; + case EntryPoint::GLMap1f: + return "glMap1f"; + case EntryPoint::GLMap2d: + return "glMap2d"; + case EntryPoint::GLMap2f: + return "glMap2f"; + case EntryPoint::GLMapBuffer: + return "glMapBuffer"; + case EntryPoint::GLMapBufferOES: + return "glMapBufferOES"; + case EntryPoint::GLMapBufferRange: + return "glMapBufferRange"; + case EntryPoint::GLMapBufferRangeEXT: + return "glMapBufferRangeEXT"; + case EntryPoint::GLMapGrid1d: + return "glMapGrid1d"; + case EntryPoint::GLMapGrid1f: + return "glMapGrid1f"; + case EntryPoint::GLMapGrid2d: + return "glMapGrid2d"; + case EntryPoint::GLMapGrid2f: + return "glMapGrid2f"; + case EntryPoint::GLMapNamedBuffer: + return "glMapNamedBuffer"; + case EntryPoint::GLMapNamedBufferRange: + return "glMapNamedBufferRange"; + case EntryPoint::GLMaterialf: + return "glMaterialf"; + case EntryPoint::GLMaterialfv: + return "glMaterialfv"; + case EntryPoint::GLMateriali: + return "glMateriali"; + case EntryPoint::GLMaterialiv: + return "glMaterialiv"; + case EntryPoint::GLMaterialx: + return "glMaterialx"; + case EntryPoint::GLMaterialxv: + return "glMaterialxv"; + case EntryPoint::GLMatrixIndexPointerOES: + return "glMatrixIndexPointerOES"; + case EntryPoint::GLMatrixMode: + return "glMatrixMode"; + case EntryPoint::GLMaxShaderCompilerThreadsKHR: + return "glMaxShaderCompilerThreadsKHR"; + case EntryPoint::GLMemoryBarrier: + return "glMemoryBarrier"; + case EntryPoint::GLMemoryBarrierByRegion: + return "glMemoryBarrierByRegion"; + case EntryPoint::GLMemoryObjectParameterivEXT: + return "glMemoryObjectParameterivEXT"; + case EntryPoint::GLMinSampleShading: + return "glMinSampleShading"; + case EntryPoint::GLMinSampleShadingOES: + return "glMinSampleShadingOES"; + case EntryPoint::GLMultMatrixd: + return "glMultMatrixd"; + case EntryPoint::GLMultMatrixf: + return "glMultMatrixf"; + case EntryPoint::GLMultMatrixx: + return "glMultMatrixx"; + case EntryPoint::GLMultTransposeMatrixd: + return "glMultTransposeMatrixd"; + case EntryPoint::GLMultTransposeMatrixf: + return "glMultTransposeMatrixf"; + case EntryPoint::GLMultiDrawArrays: + return "glMultiDrawArrays"; + case EntryPoint::GLMultiDrawArraysANGLE: + return "glMultiDrawArraysANGLE"; + case EntryPoint::GLMultiDrawArraysIndirect: + return "glMultiDrawArraysIndirect"; + case EntryPoint::GLMultiDrawArraysIndirectCount: + return "glMultiDrawArraysIndirectCount"; + case EntryPoint::GLMultiDrawArraysIndirectEXT: + return "glMultiDrawArraysIndirectEXT"; + case EntryPoint::GLMultiDrawArraysInstancedANGLE: + return "glMultiDrawArraysInstancedANGLE"; + case EntryPoint::GLMultiDrawArraysInstancedBaseInstanceANGLE: + return "glMultiDrawArraysInstancedBaseInstanceANGLE"; + case EntryPoint::GLMultiDrawElements: + return "glMultiDrawElements"; + case EntryPoint::GLMultiDrawElementsANGLE: + return "glMultiDrawElementsANGLE"; + case EntryPoint::GLMultiDrawElementsBaseVertex: + return "glMultiDrawElementsBaseVertex"; + case EntryPoint::GLMultiDrawElementsBaseVertexEXT: + return "glMultiDrawElementsBaseVertexEXT"; + case EntryPoint::GLMultiDrawElementsIndirect: + return "glMultiDrawElementsIndirect"; + case EntryPoint::GLMultiDrawElementsIndirectCount: + return "glMultiDrawElementsIndirectCount"; + case EntryPoint::GLMultiDrawElementsIndirectEXT: + return "glMultiDrawElementsIndirectEXT"; + case EntryPoint::GLMultiDrawElementsInstancedANGLE: + return "glMultiDrawElementsInstancedANGLE"; + case EntryPoint::GLMultiDrawElementsInstancedBaseVertexBaseInstanceANGLE: + return "glMultiDrawElementsInstancedBaseVertexBaseInstanceANGLE"; + case EntryPoint::GLMultiTexCoord1d: + return "glMultiTexCoord1d"; + case EntryPoint::GLMultiTexCoord1dv: + return "glMultiTexCoord1dv"; + case EntryPoint::GLMultiTexCoord1f: + return "glMultiTexCoord1f"; + case EntryPoint::GLMultiTexCoord1fv: + return "glMultiTexCoord1fv"; + case EntryPoint::GLMultiTexCoord1i: + return "glMultiTexCoord1i"; + case EntryPoint::GLMultiTexCoord1iv: + return "glMultiTexCoord1iv"; + case EntryPoint::GLMultiTexCoord1s: + return "glMultiTexCoord1s"; + case EntryPoint::GLMultiTexCoord1sv: + return "glMultiTexCoord1sv"; + case EntryPoint::GLMultiTexCoord2d: + return "glMultiTexCoord2d"; + case EntryPoint::GLMultiTexCoord2dv: + return "glMultiTexCoord2dv"; + case EntryPoint::GLMultiTexCoord2f: + return "glMultiTexCoord2f"; + case EntryPoint::GLMultiTexCoord2fv: + return "glMultiTexCoord2fv"; + case EntryPoint::GLMultiTexCoord2i: + return "glMultiTexCoord2i"; + case EntryPoint::GLMultiTexCoord2iv: + return "glMultiTexCoord2iv"; + case EntryPoint::GLMultiTexCoord2s: + return "glMultiTexCoord2s"; + case EntryPoint::GLMultiTexCoord2sv: + return "glMultiTexCoord2sv"; + case EntryPoint::GLMultiTexCoord3d: + return "glMultiTexCoord3d"; + case EntryPoint::GLMultiTexCoord3dv: + return "glMultiTexCoord3dv"; + case EntryPoint::GLMultiTexCoord3f: + return "glMultiTexCoord3f"; + case EntryPoint::GLMultiTexCoord3fv: + return "glMultiTexCoord3fv"; + case EntryPoint::GLMultiTexCoord3i: + return "glMultiTexCoord3i"; + case EntryPoint::GLMultiTexCoord3iv: + return "glMultiTexCoord3iv"; + case EntryPoint::GLMultiTexCoord3s: + return "glMultiTexCoord3s"; + case EntryPoint::GLMultiTexCoord3sv: + return "glMultiTexCoord3sv"; + case EntryPoint::GLMultiTexCoord4d: + return "glMultiTexCoord4d"; + case EntryPoint::GLMultiTexCoord4dv: + return "glMultiTexCoord4dv"; + case EntryPoint::GLMultiTexCoord4f: + return "glMultiTexCoord4f"; + case EntryPoint::GLMultiTexCoord4fv: + return "glMultiTexCoord4fv"; + case EntryPoint::GLMultiTexCoord4i: + return "glMultiTexCoord4i"; + case EntryPoint::GLMultiTexCoord4iv: + return "glMultiTexCoord4iv"; + case EntryPoint::GLMultiTexCoord4s: + return "glMultiTexCoord4s"; + case EntryPoint::GLMultiTexCoord4sv: + return "glMultiTexCoord4sv"; + case EntryPoint::GLMultiTexCoord4x: + return "glMultiTexCoord4x"; + case EntryPoint::GLMultiTexCoordP1ui: + return "glMultiTexCoordP1ui"; + case EntryPoint::GLMultiTexCoordP1uiv: + return "glMultiTexCoordP1uiv"; + case EntryPoint::GLMultiTexCoordP2ui: + return "glMultiTexCoordP2ui"; + case EntryPoint::GLMultiTexCoordP2uiv: + return "glMultiTexCoordP2uiv"; + case EntryPoint::GLMultiTexCoordP3ui: + return "glMultiTexCoordP3ui"; + case EntryPoint::GLMultiTexCoordP3uiv: + return "glMultiTexCoordP3uiv"; + case EntryPoint::GLMultiTexCoordP4ui: + return "glMultiTexCoordP4ui"; + case EntryPoint::GLMultiTexCoordP4uiv: + return "glMultiTexCoordP4uiv"; + case EntryPoint::GLNamedBufferData: + return "glNamedBufferData"; + case EntryPoint::GLNamedBufferStorage: + return "glNamedBufferStorage"; + case EntryPoint::GLNamedBufferStorageExternalEXT: + return "glNamedBufferStorageExternalEXT"; + case EntryPoint::GLNamedBufferSubData: + return "glNamedBufferSubData"; + case EntryPoint::GLNamedFramebufferDrawBuffer: + return "glNamedFramebufferDrawBuffer"; + case EntryPoint::GLNamedFramebufferDrawBuffers: + return "glNamedFramebufferDrawBuffers"; + case EntryPoint::GLNamedFramebufferParameteri: + return "glNamedFramebufferParameteri"; + case EntryPoint::GLNamedFramebufferReadBuffer: + return "glNamedFramebufferReadBuffer"; + case EntryPoint::GLNamedFramebufferRenderbuffer: + return "glNamedFramebufferRenderbuffer"; + case EntryPoint::GLNamedFramebufferTexture: + return "glNamedFramebufferTexture"; + case EntryPoint::GLNamedFramebufferTextureLayer: + return "glNamedFramebufferTextureLayer"; + case EntryPoint::GLNamedRenderbufferStorage: + return "glNamedRenderbufferStorage"; + case EntryPoint::GLNamedRenderbufferStorageMultisample: + return "glNamedRenderbufferStorageMultisample"; + case EntryPoint::GLNewList: + return "glNewList"; + case EntryPoint::GLNormal3b: + return "glNormal3b"; + case EntryPoint::GLNormal3bv: + return "glNormal3bv"; + case EntryPoint::GLNormal3d: + return "glNormal3d"; + case EntryPoint::GLNormal3dv: + return "glNormal3dv"; + case EntryPoint::GLNormal3f: + return "glNormal3f"; + case EntryPoint::GLNormal3fv: + return "glNormal3fv"; + case EntryPoint::GLNormal3i: + return "glNormal3i"; + case EntryPoint::GLNormal3iv: + return "glNormal3iv"; + case EntryPoint::GLNormal3s: + return "glNormal3s"; + case EntryPoint::GLNormal3sv: + return "glNormal3sv"; + case EntryPoint::GLNormal3x: + return "glNormal3x"; + case EntryPoint::GLNormalP3ui: + return "glNormalP3ui"; + case EntryPoint::GLNormalP3uiv: + return "glNormalP3uiv"; + case EntryPoint::GLNormalPointer: + return "glNormalPointer"; + case EntryPoint::GLObjectLabel: + return "glObjectLabel"; + case EntryPoint::GLObjectLabelKHR: + return "glObjectLabelKHR"; + case EntryPoint::GLObjectPtrLabel: + return "glObjectPtrLabel"; + case EntryPoint::GLObjectPtrLabelKHR: + return "glObjectPtrLabelKHR"; + case EntryPoint::GLOrtho: + return "glOrtho"; + case EntryPoint::GLOrthof: + return "glOrthof"; + case EntryPoint::GLOrthox: + return "glOrthox"; + case EntryPoint::GLPassThrough: + return "glPassThrough"; + case EntryPoint::GLPatchParameterfv: + return "glPatchParameterfv"; + case EntryPoint::GLPatchParameteri: + return "glPatchParameteri"; + case EntryPoint::GLPatchParameteriEXT: + return "glPatchParameteriEXT"; + case EntryPoint::GLPauseTransformFeedback: + return "glPauseTransformFeedback"; + case EntryPoint::GLPixelLocalStorageBarrierANGLE: + return "glPixelLocalStorageBarrierANGLE"; + case EntryPoint::GLPixelMapfv: + return "glPixelMapfv"; + case EntryPoint::GLPixelMapuiv: + return "glPixelMapuiv"; + case EntryPoint::GLPixelMapusv: + return "glPixelMapusv"; + case EntryPoint::GLPixelStoref: + return "glPixelStoref"; + case EntryPoint::GLPixelStorei: + return "glPixelStorei"; + case EntryPoint::GLPixelTransferf: + return "glPixelTransferf"; + case EntryPoint::GLPixelTransferi: + return "glPixelTransferi"; + case EntryPoint::GLPixelZoom: + return "glPixelZoom"; + case EntryPoint::GLPointParameterf: + return "glPointParameterf"; + case EntryPoint::GLPointParameterfv: + return "glPointParameterfv"; + case EntryPoint::GLPointParameteri: + return "glPointParameteri"; + case EntryPoint::GLPointParameteriv: + return "glPointParameteriv"; + case EntryPoint::GLPointParameterx: + return "glPointParameterx"; + case EntryPoint::GLPointParameterxv: + return "glPointParameterxv"; + case EntryPoint::GLPointSize: + return "glPointSize"; + case EntryPoint::GLPointSizePointerOES: + return "glPointSizePointerOES"; + case EntryPoint::GLPointSizex: + return "glPointSizex"; + case EntryPoint::GLPolygonMode: + return "glPolygonMode"; + case EntryPoint::GLPolygonOffset: + return "glPolygonOffset"; + case EntryPoint::GLPolygonOffsetClamp: + return "glPolygonOffsetClamp"; + case EntryPoint::GLPolygonOffsetx: + return "glPolygonOffsetx"; + case EntryPoint::GLPolygonStipple: + return "glPolygonStipple"; + case EntryPoint::GLPopAttrib: + return "glPopAttrib"; + case EntryPoint::GLPopClientAttrib: + return "glPopClientAttrib"; + case EntryPoint::GLPopDebugGroup: + return "glPopDebugGroup"; + case EntryPoint::GLPopDebugGroupKHR: + return "glPopDebugGroupKHR"; + case EntryPoint::GLPopGroupMarkerEXT: + return "glPopGroupMarkerEXT"; + case EntryPoint::GLPopMatrix: + return "glPopMatrix"; + case EntryPoint::GLPopName: + return "glPopName"; + case EntryPoint::GLPrimitiveBoundingBox: + return "glPrimitiveBoundingBox"; + case EntryPoint::GLPrimitiveBoundingBoxEXT: + return "glPrimitiveBoundingBoxEXT"; + case EntryPoint::GLPrimitiveBoundingBoxOES: + return "glPrimitiveBoundingBoxOES"; + case EntryPoint::GLPrimitiveRestartIndex: + return "glPrimitiveRestartIndex"; + case EntryPoint::GLPrioritizeTextures: + return "glPrioritizeTextures"; + case EntryPoint::GLProgramBinary: + return "glProgramBinary"; + case EntryPoint::GLProgramBinaryOES: + return "glProgramBinaryOES"; + case EntryPoint::GLProgramParameteri: + return "glProgramParameteri"; + case EntryPoint::GLProgramParameteriEXT: + return "glProgramParameteriEXT"; + case EntryPoint::GLProgramUniform1d: + return "glProgramUniform1d"; + case EntryPoint::GLProgramUniform1dv: + return "glProgramUniform1dv"; + case EntryPoint::GLProgramUniform1f: + return "glProgramUniform1f"; + case EntryPoint::GLProgramUniform1fEXT: + return "glProgramUniform1fEXT"; + case EntryPoint::GLProgramUniform1fv: + return "glProgramUniform1fv"; + case EntryPoint::GLProgramUniform1fvEXT: + return "glProgramUniform1fvEXT"; + case EntryPoint::GLProgramUniform1i: + return "glProgramUniform1i"; + case EntryPoint::GLProgramUniform1iEXT: + return "glProgramUniform1iEXT"; + case EntryPoint::GLProgramUniform1iv: + return "glProgramUniform1iv"; + case EntryPoint::GLProgramUniform1ivEXT: + return "glProgramUniform1ivEXT"; + case EntryPoint::GLProgramUniform1ui: + return "glProgramUniform1ui"; + case EntryPoint::GLProgramUniform1uiEXT: + return "glProgramUniform1uiEXT"; + case EntryPoint::GLProgramUniform1uiv: + return "glProgramUniform1uiv"; + case EntryPoint::GLProgramUniform1uivEXT: + return "glProgramUniform1uivEXT"; + case EntryPoint::GLProgramUniform2d: + return "glProgramUniform2d"; + case EntryPoint::GLProgramUniform2dv: + return "glProgramUniform2dv"; + case EntryPoint::GLProgramUniform2f: + return "glProgramUniform2f"; + case EntryPoint::GLProgramUniform2fEXT: + return "glProgramUniform2fEXT"; + case EntryPoint::GLProgramUniform2fv: + return "glProgramUniform2fv"; + case EntryPoint::GLProgramUniform2fvEXT: + return "glProgramUniform2fvEXT"; + case EntryPoint::GLProgramUniform2i: + return "glProgramUniform2i"; + case EntryPoint::GLProgramUniform2iEXT: + return "glProgramUniform2iEXT"; + case EntryPoint::GLProgramUniform2iv: + return "glProgramUniform2iv"; + case EntryPoint::GLProgramUniform2ivEXT: + return "glProgramUniform2ivEXT"; + case EntryPoint::GLProgramUniform2ui: + return "glProgramUniform2ui"; + case EntryPoint::GLProgramUniform2uiEXT: + return "glProgramUniform2uiEXT"; + case EntryPoint::GLProgramUniform2uiv: + return "glProgramUniform2uiv"; + case EntryPoint::GLProgramUniform2uivEXT: + return "glProgramUniform2uivEXT"; + case EntryPoint::GLProgramUniform3d: + return "glProgramUniform3d"; + case EntryPoint::GLProgramUniform3dv: + return "glProgramUniform3dv"; + case EntryPoint::GLProgramUniform3f: + return "glProgramUniform3f"; + case EntryPoint::GLProgramUniform3fEXT: + return "glProgramUniform3fEXT"; + case EntryPoint::GLProgramUniform3fv: + return "glProgramUniform3fv"; + case EntryPoint::GLProgramUniform3fvEXT: + return "glProgramUniform3fvEXT"; + case EntryPoint::GLProgramUniform3i: + return "glProgramUniform3i"; + case EntryPoint::GLProgramUniform3iEXT: + return "glProgramUniform3iEXT"; + case EntryPoint::GLProgramUniform3iv: + return "glProgramUniform3iv"; + case EntryPoint::GLProgramUniform3ivEXT: + return "glProgramUniform3ivEXT"; + case EntryPoint::GLProgramUniform3ui: + return "glProgramUniform3ui"; + case EntryPoint::GLProgramUniform3uiEXT: + return "glProgramUniform3uiEXT"; + case EntryPoint::GLProgramUniform3uiv: + return "glProgramUniform3uiv"; + case EntryPoint::GLProgramUniform3uivEXT: + return "glProgramUniform3uivEXT"; + case EntryPoint::GLProgramUniform4d: + return "glProgramUniform4d"; + case EntryPoint::GLProgramUniform4dv: + return "glProgramUniform4dv"; + case EntryPoint::GLProgramUniform4f: + return "glProgramUniform4f"; + case EntryPoint::GLProgramUniform4fEXT: + return "glProgramUniform4fEXT"; + case EntryPoint::GLProgramUniform4fv: + return "glProgramUniform4fv"; + case EntryPoint::GLProgramUniform4fvEXT: + return "glProgramUniform4fvEXT"; + case EntryPoint::GLProgramUniform4i: + return "glProgramUniform4i"; + case EntryPoint::GLProgramUniform4iEXT: + return "glProgramUniform4iEXT"; + case EntryPoint::GLProgramUniform4iv: + return "glProgramUniform4iv"; + case EntryPoint::GLProgramUniform4ivEXT: + return "glProgramUniform4ivEXT"; + case EntryPoint::GLProgramUniform4ui: + return "glProgramUniform4ui"; + case EntryPoint::GLProgramUniform4uiEXT: + return "glProgramUniform4uiEXT"; + case EntryPoint::GLProgramUniform4uiv: + return "glProgramUniform4uiv"; + case EntryPoint::GLProgramUniform4uivEXT: + return "glProgramUniform4uivEXT"; + case EntryPoint::GLProgramUniformMatrix2dv: + return "glProgramUniformMatrix2dv"; + case EntryPoint::GLProgramUniformMatrix2fv: + return "glProgramUniformMatrix2fv"; + case EntryPoint::GLProgramUniformMatrix2fvEXT: + return "glProgramUniformMatrix2fvEXT"; + case EntryPoint::GLProgramUniformMatrix2x3dv: + return "glProgramUniformMatrix2x3dv"; + case EntryPoint::GLProgramUniformMatrix2x3fv: + return "glProgramUniformMatrix2x3fv"; + case EntryPoint::GLProgramUniformMatrix2x3fvEXT: + return "glProgramUniformMatrix2x3fvEXT"; + case EntryPoint::GLProgramUniformMatrix2x4dv: + return "glProgramUniformMatrix2x4dv"; + case EntryPoint::GLProgramUniformMatrix2x4fv: + return "glProgramUniformMatrix2x4fv"; + case EntryPoint::GLProgramUniformMatrix2x4fvEXT: + return "glProgramUniformMatrix2x4fvEXT"; + case EntryPoint::GLProgramUniformMatrix3dv: + return "glProgramUniformMatrix3dv"; + case EntryPoint::GLProgramUniformMatrix3fv: + return "glProgramUniformMatrix3fv"; + case EntryPoint::GLProgramUniformMatrix3fvEXT: + return "glProgramUniformMatrix3fvEXT"; + case EntryPoint::GLProgramUniformMatrix3x2dv: + return "glProgramUniformMatrix3x2dv"; + case EntryPoint::GLProgramUniformMatrix3x2fv: + return "glProgramUniformMatrix3x2fv"; + case EntryPoint::GLProgramUniformMatrix3x2fvEXT: + return "glProgramUniformMatrix3x2fvEXT"; + case EntryPoint::GLProgramUniformMatrix3x4dv: + return "glProgramUniformMatrix3x4dv"; + case EntryPoint::GLProgramUniformMatrix3x4fv: + return "glProgramUniformMatrix3x4fv"; + case EntryPoint::GLProgramUniformMatrix3x4fvEXT: + return "glProgramUniformMatrix3x4fvEXT"; + case EntryPoint::GLProgramUniformMatrix4dv: + return "glProgramUniformMatrix4dv"; + case EntryPoint::GLProgramUniformMatrix4fv: + return "glProgramUniformMatrix4fv"; + case EntryPoint::GLProgramUniformMatrix4fvEXT: + return "glProgramUniformMatrix4fvEXT"; + case EntryPoint::GLProgramUniformMatrix4x2dv: + return "glProgramUniformMatrix4x2dv"; + case EntryPoint::GLProgramUniformMatrix4x2fv: + return "glProgramUniformMatrix4x2fv"; + case EntryPoint::GLProgramUniformMatrix4x2fvEXT: + return "glProgramUniformMatrix4x2fvEXT"; + case EntryPoint::GLProgramUniformMatrix4x3dv: + return "glProgramUniformMatrix4x3dv"; + case EntryPoint::GLProgramUniformMatrix4x3fv: + return "glProgramUniformMatrix4x3fv"; + case EntryPoint::GLProgramUniformMatrix4x3fvEXT: + return "glProgramUniformMatrix4x3fvEXT"; + case EntryPoint::GLProvokingVertex: + return "glProvokingVertex"; + case EntryPoint::GLProvokingVertexANGLE: + return "glProvokingVertexANGLE"; + case EntryPoint::GLPushAttrib: + return "glPushAttrib"; + case EntryPoint::GLPushClientAttrib: + return "glPushClientAttrib"; + case EntryPoint::GLPushDebugGroup: + return "glPushDebugGroup"; + case EntryPoint::GLPushDebugGroupKHR: + return "glPushDebugGroupKHR"; + case EntryPoint::GLPushGroupMarkerEXT: + return "glPushGroupMarkerEXT"; + case EntryPoint::GLPushMatrix: + return "glPushMatrix"; + case EntryPoint::GLPushName: + return "glPushName"; + case EntryPoint::GLQueryCounter: + return "glQueryCounter"; + case EntryPoint::GLQueryCounterEXT: + return "glQueryCounterEXT"; + case EntryPoint::GLQueryMatrixxOES: + return "glQueryMatrixxOES"; + case EntryPoint::GLRasterPos2d: + return "glRasterPos2d"; + case EntryPoint::GLRasterPos2dv: + return "glRasterPos2dv"; + case EntryPoint::GLRasterPos2f: + return "glRasterPos2f"; + case EntryPoint::GLRasterPos2fv: + return "glRasterPos2fv"; + case EntryPoint::GLRasterPos2i: + return "glRasterPos2i"; + case EntryPoint::GLRasterPos2iv: + return "glRasterPos2iv"; + case EntryPoint::GLRasterPos2s: + return "glRasterPos2s"; + case EntryPoint::GLRasterPos2sv: + return "glRasterPos2sv"; + case EntryPoint::GLRasterPos3d: + return "glRasterPos3d"; + case EntryPoint::GLRasterPos3dv: + return "glRasterPos3dv"; + case EntryPoint::GLRasterPos3f: + return "glRasterPos3f"; + case EntryPoint::GLRasterPos3fv: + return "glRasterPos3fv"; + case EntryPoint::GLRasterPos3i: + return "glRasterPos3i"; + case EntryPoint::GLRasterPos3iv: + return "glRasterPos3iv"; + case EntryPoint::GLRasterPos3s: + return "glRasterPos3s"; + case EntryPoint::GLRasterPos3sv: + return "glRasterPos3sv"; + case EntryPoint::GLRasterPos4d: + return "glRasterPos4d"; + case EntryPoint::GLRasterPos4dv: + return "glRasterPos4dv"; + case EntryPoint::GLRasterPos4f: + return "glRasterPos4f"; + case EntryPoint::GLRasterPos4fv: + return "glRasterPos4fv"; + case EntryPoint::GLRasterPos4i: + return "glRasterPos4i"; + case EntryPoint::GLRasterPos4iv: + return "glRasterPos4iv"; + case EntryPoint::GLRasterPos4s: + return "glRasterPos4s"; + case EntryPoint::GLRasterPos4sv: + return "glRasterPos4sv"; + case EntryPoint::GLReadBuffer: + return "glReadBuffer"; + case EntryPoint::GLReadPixels: + return "glReadPixels"; + case EntryPoint::GLReadPixelsRobustANGLE: + return "glReadPixelsRobustANGLE"; + case EntryPoint::GLReadnPixels: + return "glReadnPixels"; + case EntryPoint::GLReadnPixelsEXT: + return "glReadnPixelsEXT"; + case EntryPoint::GLReadnPixelsRobustANGLE: + return "glReadnPixelsRobustANGLE"; + case EntryPoint::GLRectd: + return "glRectd"; + case EntryPoint::GLRectdv: + return "glRectdv"; + case EntryPoint::GLRectf: + return "glRectf"; + case EntryPoint::GLRectfv: + return "glRectfv"; + case EntryPoint::GLRecti: + return "glRecti"; + case EntryPoint::GLRectiv: + return "glRectiv"; + case EntryPoint::GLRects: + return "glRects"; + case EntryPoint::GLRectsv: + return "glRectsv"; + case EntryPoint::GLReleaseShaderCompiler: + return "glReleaseShaderCompiler"; + case EntryPoint::GLReleaseTexturesANGLE: + return "glReleaseTexturesANGLE"; + case EntryPoint::GLRenderMode: + return "glRenderMode"; + case EntryPoint::GLRenderbufferStorage: + return "glRenderbufferStorage"; + case EntryPoint::GLRenderbufferStorageMultisample: + return "glRenderbufferStorageMultisample"; + case EntryPoint::GLRenderbufferStorageMultisampleANGLE: + return "glRenderbufferStorageMultisampleANGLE"; + case EntryPoint::GLRenderbufferStorageMultisampleEXT: + return "glRenderbufferStorageMultisampleEXT"; + case EntryPoint::GLRenderbufferStorageOES: + return "glRenderbufferStorageOES"; + case EntryPoint::GLRequestExtensionANGLE: + return "glRequestExtensionANGLE"; + case EntryPoint::GLResumeTransformFeedback: + return "glResumeTransformFeedback"; + case EntryPoint::GLRotated: + return "glRotated"; + case EntryPoint::GLRotatef: + return "glRotatef"; + case EntryPoint::GLRotatex: + return "glRotatex"; + case EntryPoint::GLSampleCoverage: + return "glSampleCoverage"; + case EntryPoint::GLSampleCoveragex: + return "glSampleCoveragex"; + case EntryPoint::GLSampleMaski: + return "glSampleMaski"; + case EntryPoint::GLSampleMaskiANGLE: + return "glSampleMaskiANGLE"; + case EntryPoint::GLSamplerParameterIiv: + return "glSamplerParameterIiv"; + case EntryPoint::GLSamplerParameterIivEXT: + return "glSamplerParameterIivEXT"; + case EntryPoint::GLSamplerParameterIivOES: + return "glSamplerParameterIivOES"; + case EntryPoint::GLSamplerParameterIivRobustANGLE: + return "glSamplerParameterIivRobustANGLE"; + case EntryPoint::GLSamplerParameterIuiv: + return "glSamplerParameterIuiv"; + case EntryPoint::GLSamplerParameterIuivEXT: + return "glSamplerParameterIuivEXT"; + case EntryPoint::GLSamplerParameterIuivOES: + return "glSamplerParameterIuivOES"; + case EntryPoint::GLSamplerParameterIuivRobustANGLE: + return "glSamplerParameterIuivRobustANGLE"; + case EntryPoint::GLSamplerParameterf: + return "glSamplerParameterf"; + case EntryPoint::GLSamplerParameterfv: + return "glSamplerParameterfv"; + case EntryPoint::GLSamplerParameterfvRobustANGLE: + return "glSamplerParameterfvRobustANGLE"; + case EntryPoint::GLSamplerParameteri: + return "glSamplerParameteri"; + case EntryPoint::GLSamplerParameteriv: + return "glSamplerParameteriv"; + case EntryPoint::GLSamplerParameterivRobustANGLE: + return "glSamplerParameterivRobustANGLE"; + case EntryPoint::GLScaled: + return "glScaled"; + case EntryPoint::GLScalef: + return "glScalef"; + case EntryPoint::GLScalex: + return "glScalex"; + case EntryPoint::GLScissor: + return "glScissor"; + case EntryPoint::GLScissorArrayv: + return "glScissorArrayv"; + case EntryPoint::GLScissorIndexed: + return "glScissorIndexed"; + case EntryPoint::GLScissorIndexedv: + return "glScissorIndexedv"; + case EntryPoint::GLSecondaryColor3b: + return "glSecondaryColor3b"; + case EntryPoint::GLSecondaryColor3bv: + return "glSecondaryColor3bv"; + case EntryPoint::GLSecondaryColor3d: + return "glSecondaryColor3d"; + case EntryPoint::GLSecondaryColor3dv: + return "glSecondaryColor3dv"; + case EntryPoint::GLSecondaryColor3f: + return "glSecondaryColor3f"; + case EntryPoint::GLSecondaryColor3fv: + return "glSecondaryColor3fv"; + case EntryPoint::GLSecondaryColor3i: + return "glSecondaryColor3i"; + case EntryPoint::GLSecondaryColor3iv: + return "glSecondaryColor3iv"; + case EntryPoint::GLSecondaryColor3s: + return "glSecondaryColor3s"; + case EntryPoint::GLSecondaryColor3sv: + return "glSecondaryColor3sv"; + case EntryPoint::GLSecondaryColor3ub: + return "glSecondaryColor3ub"; + case EntryPoint::GLSecondaryColor3ubv: + return "glSecondaryColor3ubv"; + case EntryPoint::GLSecondaryColor3ui: + return "glSecondaryColor3ui"; + case EntryPoint::GLSecondaryColor3uiv: + return "glSecondaryColor3uiv"; + case EntryPoint::GLSecondaryColor3us: + return "glSecondaryColor3us"; + case EntryPoint::GLSecondaryColor3usv: + return "glSecondaryColor3usv"; + case EntryPoint::GLSecondaryColorP3ui: + return "glSecondaryColorP3ui"; + case EntryPoint::GLSecondaryColorP3uiv: + return "glSecondaryColorP3uiv"; + case EntryPoint::GLSecondaryColorPointer: + return "glSecondaryColorPointer"; + case EntryPoint::GLSelectBuffer: + return "glSelectBuffer"; + case EntryPoint::GLSelectPerfMonitorCountersAMD: + return "glSelectPerfMonitorCountersAMD"; + case EntryPoint::GLSemaphoreParameterui64vEXT: + return "glSemaphoreParameterui64vEXT"; + case EntryPoint::GLSetFenceNV: + return "glSetFenceNV"; + case EntryPoint::GLShadeModel: + return "glShadeModel"; + case EntryPoint::GLShaderBinary: + return "glShaderBinary"; + case EntryPoint::GLShaderSource: + return "glShaderSource"; + case EntryPoint::GLShaderStorageBlockBinding: + return "glShaderStorageBlockBinding"; + case EntryPoint::GLShadingRateQCOM: + return "glShadingRateQCOM"; + case EntryPoint::GLSignalSemaphoreEXT: + return "glSignalSemaphoreEXT"; + case EntryPoint::GLSpecializeShader: + return "glSpecializeShader"; + case EntryPoint::GLStencilFunc: + return "glStencilFunc"; + case EntryPoint::GLStencilFuncSeparate: + return "glStencilFuncSeparate"; + case EntryPoint::GLStencilMask: + return "glStencilMask"; + case EntryPoint::GLStencilMaskSeparate: + return "glStencilMaskSeparate"; + case EntryPoint::GLStencilOp: + return "glStencilOp"; + case EntryPoint::GLStencilOpSeparate: + return "glStencilOpSeparate"; + case EntryPoint::GLTestFenceNV: + return "glTestFenceNV"; + case EntryPoint::GLTexBuffer: + return "glTexBuffer"; + case EntryPoint::GLTexBufferEXT: + return "glTexBufferEXT"; + case EntryPoint::GLTexBufferOES: + return "glTexBufferOES"; + case EntryPoint::GLTexBufferRange: + return "glTexBufferRange"; + case EntryPoint::GLTexBufferRangeEXT: + return "glTexBufferRangeEXT"; + case EntryPoint::GLTexBufferRangeOES: + return "glTexBufferRangeOES"; + case EntryPoint::GLTexCoord1d: + return "glTexCoord1d"; + case EntryPoint::GLTexCoord1dv: + return "glTexCoord1dv"; + case EntryPoint::GLTexCoord1f: + return "glTexCoord1f"; + case EntryPoint::GLTexCoord1fv: + return "glTexCoord1fv"; + case EntryPoint::GLTexCoord1i: + return "glTexCoord1i"; + case EntryPoint::GLTexCoord1iv: + return "glTexCoord1iv"; + case EntryPoint::GLTexCoord1s: + return "glTexCoord1s"; + case EntryPoint::GLTexCoord1sv: + return "glTexCoord1sv"; + case EntryPoint::GLTexCoord2d: + return "glTexCoord2d"; + case EntryPoint::GLTexCoord2dv: + return "glTexCoord2dv"; + case EntryPoint::GLTexCoord2f: + return "glTexCoord2f"; + case EntryPoint::GLTexCoord2fv: + return "glTexCoord2fv"; + case EntryPoint::GLTexCoord2i: + return "glTexCoord2i"; + case EntryPoint::GLTexCoord2iv: + return "glTexCoord2iv"; + case EntryPoint::GLTexCoord2s: + return "glTexCoord2s"; + case EntryPoint::GLTexCoord2sv: + return "glTexCoord2sv"; + case EntryPoint::GLTexCoord3d: + return "glTexCoord3d"; + case EntryPoint::GLTexCoord3dv: + return "glTexCoord3dv"; + case EntryPoint::GLTexCoord3f: + return "glTexCoord3f"; + case EntryPoint::GLTexCoord3fv: + return "glTexCoord3fv"; + case EntryPoint::GLTexCoord3i: + return "glTexCoord3i"; + case EntryPoint::GLTexCoord3iv: + return "glTexCoord3iv"; + case EntryPoint::GLTexCoord3s: + return "glTexCoord3s"; + case EntryPoint::GLTexCoord3sv: + return "glTexCoord3sv"; + case EntryPoint::GLTexCoord4d: + return "glTexCoord4d"; + case EntryPoint::GLTexCoord4dv: + return "glTexCoord4dv"; + case EntryPoint::GLTexCoord4f: + return "glTexCoord4f"; + case EntryPoint::GLTexCoord4fv: + return "glTexCoord4fv"; + case EntryPoint::GLTexCoord4i: + return "glTexCoord4i"; + case EntryPoint::GLTexCoord4iv: + return "glTexCoord4iv"; + case EntryPoint::GLTexCoord4s: + return "glTexCoord4s"; + case EntryPoint::GLTexCoord4sv: + return "glTexCoord4sv"; + case EntryPoint::GLTexCoordP1ui: + return "glTexCoordP1ui"; + case EntryPoint::GLTexCoordP1uiv: + return "glTexCoordP1uiv"; + case EntryPoint::GLTexCoordP2ui: + return "glTexCoordP2ui"; + case EntryPoint::GLTexCoordP2uiv: + return "glTexCoordP2uiv"; + case EntryPoint::GLTexCoordP3ui: + return "glTexCoordP3ui"; + case EntryPoint::GLTexCoordP3uiv: + return "glTexCoordP3uiv"; + case EntryPoint::GLTexCoordP4ui: + return "glTexCoordP4ui"; + case EntryPoint::GLTexCoordP4uiv: + return "glTexCoordP4uiv"; + case EntryPoint::GLTexCoordPointer: + return "glTexCoordPointer"; + case EntryPoint::GLTexEnvf: + return "glTexEnvf"; + case EntryPoint::GLTexEnvfv: + return "glTexEnvfv"; + case EntryPoint::GLTexEnvi: + return "glTexEnvi"; + case EntryPoint::GLTexEnviv: + return "glTexEnviv"; + case EntryPoint::GLTexEnvx: + return "glTexEnvx"; + case EntryPoint::GLTexEnvxv: + return "glTexEnvxv"; + case EntryPoint::GLTexGend: + return "glTexGend"; + case EntryPoint::GLTexGendv: + return "glTexGendv"; + case EntryPoint::GLTexGenf: + return "glTexGenf"; + case EntryPoint::GLTexGenfOES: + return "glTexGenfOES"; + case EntryPoint::GLTexGenfv: + return "glTexGenfv"; + case EntryPoint::GLTexGenfvOES: + return "glTexGenfvOES"; + case EntryPoint::GLTexGeni: + return "glTexGeni"; + case EntryPoint::GLTexGeniOES: + return "glTexGeniOES"; + case EntryPoint::GLTexGeniv: + return "glTexGeniv"; + case EntryPoint::GLTexGenivOES: + return "glTexGenivOES"; + case EntryPoint::GLTexGenxOES: + return "glTexGenxOES"; + case EntryPoint::GLTexGenxvOES: + return "glTexGenxvOES"; + case EntryPoint::GLTexImage1D: + return "glTexImage1D"; + case EntryPoint::GLTexImage2D: + return "glTexImage2D"; + case EntryPoint::GLTexImage2DExternalANGLE: + return "glTexImage2DExternalANGLE"; + case EntryPoint::GLTexImage2DMultisample: + return "glTexImage2DMultisample"; + case EntryPoint::GLTexImage2DRobustANGLE: + return "glTexImage2DRobustANGLE"; + case EntryPoint::GLTexImage3D: + return "glTexImage3D"; + case EntryPoint::GLTexImage3DMultisample: + return "glTexImage3DMultisample"; + case EntryPoint::GLTexImage3DOES: + return "glTexImage3DOES"; + case EntryPoint::GLTexImage3DRobustANGLE: + return "glTexImage3DRobustANGLE"; + case EntryPoint::GLTexParameterIiv: + return "glTexParameterIiv"; + case EntryPoint::GLTexParameterIivEXT: + return "glTexParameterIivEXT"; + case EntryPoint::GLTexParameterIivOES: + return "glTexParameterIivOES"; + case EntryPoint::GLTexParameterIivRobustANGLE: + return "glTexParameterIivRobustANGLE"; + case EntryPoint::GLTexParameterIuiv: + return "glTexParameterIuiv"; + case EntryPoint::GLTexParameterIuivEXT: + return "glTexParameterIuivEXT"; + case EntryPoint::GLTexParameterIuivOES: + return "glTexParameterIuivOES"; + case EntryPoint::GLTexParameterIuivRobustANGLE: + return "glTexParameterIuivRobustANGLE"; + case EntryPoint::GLTexParameterf: + return "glTexParameterf"; + case EntryPoint::GLTexParameterfv: + return "glTexParameterfv"; + case EntryPoint::GLTexParameterfvRobustANGLE: + return "glTexParameterfvRobustANGLE"; + case EntryPoint::GLTexParameteri: + return "glTexParameteri"; + case EntryPoint::GLTexParameteriv: + return "glTexParameteriv"; + case EntryPoint::GLTexParameterivRobustANGLE: + return "glTexParameterivRobustANGLE"; + case EntryPoint::GLTexParameterx: + return "glTexParameterx"; + case EntryPoint::GLTexParameterxv: + return "glTexParameterxv"; + case EntryPoint::GLTexStorage1D: + return "glTexStorage1D"; + case EntryPoint::GLTexStorage1DEXT: + return "glTexStorage1DEXT"; + case EntryPoint::GLTexStorage2D: + return "glTexStorage2D"; + case EntryPoint::GLTexStorage2DEXT: + return "glTexStorage2DEXT"; + case EntryPoint::GLTexStorage2DMultisample: + return "glTexStorage2DMultisample"; + case EntryPoint::GLTexStorage2DMultisampleANGLE: + return "glTexStorage2DMultisampleANGLE"; + case EntryPoint::GLTexStorage3D: + return "glTexStorage3D"; + case EntryPoint::GLTexStorage3DEXT: + return "glTexStorage3DEXT"; + case EntryPoint::GLTexStorage3DMultisample: + return "glTexStorage3DMultisample"; + case EntryPoint::GLTexStorage3DMultisampleOES: + return "glTexStorage3DMultisampleOES"; + case EntryPoint::GLTexStorageMem2DEXT: + return "glTexStorageMem2DEXT"; + case EntryPoint::GLTexStorageMem2DMultisampleEXT: + return "glTexStorageMem2DMultisampleEXT"; + case EntryPoint::GLTexStorageMem3DEXT: + return "glTexStorageMem3DEXT"; + case EntryPoint::GLTexStorageMem3DMultisampleEXT: + return "glTexStorageMem3DMultisampleEXT"; + case EntryPoint::GLTexStorageMemFlags2DANGLE: + return "glTexStorageMemFlags2DANGLE"; + case EntryPoint::GLTexStorageMemFlags2DMultisampleANGLE: + return "glTexStorageMemFlags2DMultisampleANGLE"; + case EntryPoint::GLTexStorageMemFlags3DANGLE: + return "glTexStorageMemFlags3DANGLE"; + case EntryPoint::GLTexStorageMemFlags3DMultisampleANGLE: + return "glTexStorageMemFlags3DMultisampleANGLE"; + case EntryPoint::GLTexSubImage1D: + return "glTexSubImage1D"; + case EntryPoint::GLTexSubImage2D: + return "glTexSubImage2D"; + case EntryPoint::GLTexSubImage2DRobustANGLE: + return "glTexSubImage2DRobustANGLE"; + case EntryPoint::GLTexSubImage3D: + return "glTexSubImage3D"; + case EntryPoint::GLTexSubImage3DOES: + return "glTexSubImage3DOES"; + case EntryPoint::GLTexSubImage3DRobustANGLE: + return "glTexSubImage3DRobustANGLE"; + case EntryPoint::GLTextureBarrier: + return "glTextureBarrier"; + case EntryPoint::GLTextureBuffer: + return "glTextureBuffer"; + case EntryPoint::GLTextureBufferRange: + return "glTextureBufferRange"; + case EntryPoint::GLTextureParameterIiv: + return "glTextureParameterIiv"; + case EntryPoint::GLTextureParameterIuiv: + return "glTextureParameterIuiv"; + case EntryPoint::GLTextureParameterf: + return "glTextureParameterf"; + case EntryPoint::GLTextureParameterfv: + return "glTextureParameterfv"; + case EntryPoint::GLTextureParameteri: + return "glTextureParameteri"; + case EntryPoint::GLTextureParameteriv: + return "glTextureParameteriv"; + case EntryPoint::GLTextureStorage1D: + return "glTextureStorage1D"; + case EntryPoint::GLTextureStorage2D: + return "glTextureStorage2D"; + case EntryPoint::GLTextureStorage2DMultisample: + return "glTextureStorage2DMultisample"; + case EntryPoint::GLTextureStorage3D: + return "glTextureStorage3D"; + case EntryPoint::GLTextureStorage3DMultisample: + return "glTextureStorage3DMultisample"; + case EntryPoint::GLTextureSubImage1D: + return "glTextureSubImage1D"; + case EntryPoint::GLTextureSubImage2D: + return "glTextureSubImage2D"; + case EntryPoint::GLTextureSubImage3D: + return "glTextureSubImage3D"; + case EntryPoint::GLTextureView: + return "glTextureView"; + case EntryPoint::GLTransformFeedbackBufferBase: + return "glTransformFeedbackBufferBase"; + case EntryPoint::GLTransformFeedbackBufferRange: + return "glTransformFeedbackBufferRange"; + case EntryPoint::GLTransformFeedbackVaryings: + return "glTransformFeedbackVaryings"; + case EntryPoint::GLTranslated: + return "glTranslated"; + case EntryPoint::GLTranslatef: + return "glTranslatef"; + case EntryPoint::GLTranslatex: + return "glTranslatex"; + case EntryPoint::GLUniform1d: + return "glUniform1d"; + case EntryPoint::GLUniform1dv: + return "glUniform1dv"; + case EntryPoint::GLUniform1f: + return "glUniform1f"; + case EntryPoint::GLUniform1fv: + return "glUniform1fv"; + case EntryPoint::GLUniform1i: + return "glUniform1i"; + case EntryPoint::GLUniform1iv: + return "glUniform1iv"; + case EntryPoint::GLUniform1ui: + return "glUniform1ui"; + case EntryPoint::GLUniform1uiv: + return "glUniform1uiv"; + case EntryPoint::GLUniform2d: + return "glUniform2d"; + case EntryPoint::GLUniform2dv: + return "glUniform2dv"; + case EntryPoint::GLUniform2f: + return "glUniform2f"; + case EntryPoint::GLUniform2fv: + return "glUniform2fv"; + case EntryPoint::GLUniform2i: + return "glUniform2i"; + case EntryPoint::GLUniform2iv: + return "glUniform2iv"; + case EntryPoint::GLUniform2ui: + return "glUniform2ui"; + case EntryPoint::GLUniform2uiv: + return "glUniform2uiv"; + case EntryPoint::GLUniform3d: + return "glUniform3d"; + case EntryPoint::GLUniform3dv: + return "glUniform3dv"; + case EntryPoint::GLUniform3f: + return "glUniform3f"; + case EntryPoint::GLUniform3fv: + return "glUniform3fv"; + case EntryPoint::GLUniform3i: + return "glUniform3i"; + case EntryPoint::GLUniform3iv: + return "glUniform3iv"; + case EntryPoint::GLUniform3ui: + return "glUniform3ui"; + case EntryPoint::GLUniform3uiv: + return "glUniform3uiv"; + case EntryPoint::GLUniform4d: + return "glUniform4d"; + case EntryPoint::GLUniform4dv: + return "glUniform4dv"; + case EntryPoint::GLUniform4f: + return "glUniform4f"; + case EntryPoint::GLUniform4fv: + return "glUniform4fv"; + case EntryPoint::GLUniform4i: + return "glUniform4i"; + case EntryPoint::GLUniform4iv: + return "glUniform4iv"; + case EntryPoint::GLUniform4ui: + return "glUniform4ui"; + case EntryPoint::GLUniform4uiv: + return "glUniform4uiv"; + case EntryPoint::GLUniformBlockBinding: + return "glUniformBlockBinding"; + case EntryPoint::GLUniformMatrix2dv: + return "glUniformMatrix2dv"; + case EntryPoint::GLUniformMatrix2fv: + return "glUniformMatrix2fv"; + case EntryPoint::GLUniformMatrix2x3dv: + return "glUniformMatrix2x3dv"; + case EntryPoint::GLUniformMatrix2x3fv: + return "glUniformMatrix2x3fv"; + case EntryPoint::GLUniformMatrix2x4dv: + return "glUniformMatrix2x4dv"; + case EntryPoint::GLUniformMatrix2x4fv: + return "glUniformMatrix2x4fv"; + case EntryPoint::GLUniformMatrix3dv: + return "glUniformMatrix3dv"; + case EntryPoint::GLUniformMatrix3fv: + return "glUniformMatrix3fv"; + case EntryPoint::GLUniformMatrix3x2dv: + return "glUniformMatrix3x2dv"; + case EntryPoint::GLUniformMatrix3x2fv: + return "glUniformMatrix3x2fv"; + case EntryPoint::GLUniformMatrix3x4dv: + return "glUniformMatrix3x4dv"; + case EntryPoint::GLUniformMatrix3x4fv: + return "glUniformMatrix3x4fv"; + case EntryPoint::GLUniformMatrix4dv: + return "glUniformMatrix4dv"; + case EntryPoint::GLUniformMatrix4fv: + return "glUniformMatrix4fv"; + case EntryPoint::GLUniformMatrix4x2dv: + return "glUniformMatrix4x2dv"; + case EntryPoint::GLUniformMatrix4x2fv: + return "glUniformMatrix4x2fv"; + case EntryPoint::GLUniformMatrix4x3dv: + return "glUniformMatrix4x3dv"; + case EntryPoint::GLUniformMatrix4x3fv: + return "glUniformMatrix4x3fv"; + case EntryPoint::GLUniformSubroutinesuiv: + return "glUniformSubroutinesuiv"; + case EntryPoint::GLUnmapBuffer: + return "glUnmapBuffer"; + case EntryPoint::GLUnmapBufferOES: + return "glUnmapBufferOES"; + case EntryPoint::GLUnmapNamedBuffer: + return "glUnmapNamedBuffer"; + case EntryPoint::GLUseProgram: + return "glUseProgram"; + case EntryPoint::GLUseProgramStages: + return "glUseProgramStages"; + case EntryPoint::GLUseProgramStagesEXT: + return "glUseProgramStagesEXT"; + case EntryPoint::GLValidateProgram: + return "glValidateProgram"; + case EntryPoint::GLValidateProgramPipeline: + return "glValidateProgramPipeline"; + case EntryPoint::GLValidateProgramPipelineEXT: + return "glValidateProgramPipelineEXT"; + case EntryPoint::GLVertex2d: + return "glVertex2d"; + case EntryPoint::GLVertex2dv: + return "glVertex2dv"; + case EntryPoint::GLVertex2f: + return "glVertex2f"; + case EntryPoint::GLVertex2fv: + return "glVertex2fv"; + case EntryPoint::GLVertex2i: + return "glVertex2i"; + case EntryPoint::GLVertex2iv: + return "glVertex2iv"; + case EntryPoint::GLVertex2s: + return "glVertex2s"; + case EntryPoint::GLVertex2sv: + return "glVertex2sv"; + case EntryPoint::GLVertex3d: + return "glVertex3d"; + case EntryPoint::GLVertex3dv: + return "glVertex3dv"; + case EntryPoint::GLVertex3f: + return "glVertex3f"; + case EntryPoint::GLVertex3fv: + return "glVertex3fv"; + case EntryPoint::GLVertex3i: + return "glVertex3i"; + case EntryPoint::GLVertex3iv: + return "glVertex3iv"; + case EntryPoint::GLVertex3s: + return "glVertex3s"; + case EntryPoint::GLVertex3sv: + return "glVertex3sv"; + case EntryPoint::GLVertex4d: + return "glVertex4d"; + case EntryPoint::GLVertex4dv: + return "glVertex4dv"; + case EntryPoint::GLVertex4f: + return "glVertex4f"; + case EntryPoint::GLVertex4fv: + return "glVertex4fv"; + case EntryPoint::GLVertex4i: + return "glVertex4i"; + case EntryPoint::GLVertex4iv: + return "glVertex4iv"; + case EntryPoint::GLVertex4s: + return "glVertex4s"; + case EntryPoint::GLVertex4sv: + return "glVertex4sv"; + case EntryPoint::GLVertexArrayAttribBinding: + return "glVertexArrayAttribBinding"; + case EntryPoint::GLVertexArrayAttribFormat: + return "glVertexArrayAttribFormat"; + case EntryPoint::GLVertexArrayAttribIFormat: + return "glVertexArrayAttribIFormat"; + case EntryPoint::GLVertexArrayAttribLFormat: + return "glVertexArrayAttribLFormat"; + case EntryPoint::GLVertexArrayBindingDivisor: + return "glVertexArrayBindingDivisor"; + case EntryPoint::GLVertexArrayElementBuffer: + return "glVertexArrayElementBuffer"; + case EntryPoint::GLVertexArrayVertexBuffer: + return "glVertexArrayVertexBuffer"; + case EntryPoint::GLVertexArrayVertexBuffers: + return "glVertexArrayVertexBuffers"; + case EntryPoint::GLVertexAttrib1d: + return "glVertexAttrib1d"; + case EntryPoint::GLVertexAttrib1dv: + return "glVertexAttrib1dv"; + case EntryPoint::GLVertexAttrib1f: + return "glVertexAttrib1f"; + case EntryPoint::GLVertexAttrib1fv: + return "glVertexAttrib1fv"; + case EntryPoint::GLVertexAttrib1s: + return "glVertexAttrib1s"; + case EntryPoint::GLVertexAttrib1sv: + return "glVertexAttrib1sv"; + case EntryPoint::GLVertexAttrib2d: + return "glVertexAttrib2d"; + case EntryPoint::GLVertexAttrib2dv: + return "glVertexAttrib2dv"; + case EntryPoint::GLVertexAttrib2f: + return "glVertexAttrib2f"; + case EntryPoint::GLVertexAttrib2fv: + return "glVertexAttrib2fv"; + case EntryPoint::GLVertexAttrib2s: + return "glVertexAttrib2s"; + case EntryPoint::GLVertexAttrib2sv: + return "glVertexAttrib2sv"; + case EntryPoint::GLVertexAttrib3d: + return "glVertexAttrib3d"; + case EntryPoint::GLVertexAttrib3dv: + return "glVertexAttrib3dv"; + case EntryPoint::GLVertexAttrib3f: + return "glVertexAttrib3f"; + case EntryPoint::GLVertexAttrib3fv: + return "glVertexAttrib3fv"; + case EntryPoint::GLVertexAttrib3s: + return "glVertexAttrib3s"; + case EntryPoint::GLVertexAttrib3sv: + return "glVertexAttrib3sv"; + case EntryPoint::GLVertexAttrib4Nbv: + return "glVertexAttrib4Nbv"; + case EntryPoint::GLVertexAttrib4Niv: + return "glVertexAttrib4Niv"; + case EntryPoint::GLVertexAttrib4Nsv: + return "glVertexAttrib4Nsv"; + case EntryPoint::GLVertexAttrib4Nub: + return "glVertexAttrib4Nub"; + case EntryPoint::GLVertexAttrib4Nubv: + return "glVertexAttrib4Nubv"; + case EntryPoint::GLVertexAttrib4Nuiv: + return "glVertexAttrib4Nuiv"; + case EntryPoint::GLVertexAttrib4Nusv: + return "glVertexAttrib4Nusv"; + case EntryPoint::GLVertexAttrib4bv: + return "glVertexAttrib4bv"; + case EntryPoint::GLVertexAttrib4d: + return "glVertexAttrib4d"; + case EntryPoint::GLVertexAttrib4dv: + return "glVertexAttrib4dv"; + case EntryPoint::GLVertexAttrib4f: + return "glVertexAttrib4f"; + case EntryPoint::GLVertexAttrib4fv: + return "glVertexAttrib4fv"; + case EntryPoint::GLVertexAttrib4iv: + return "glVertexAttrib4iv"; + case EntryPoint::GLVertexAttrib4s: + return "glVertexAttrib4s"; + case EntryPoint::GLVertexAttrib4sv: + return "glVertexAttrib4sv"; + case EntryPoint::GLVertexAttrib4ubv: + return "glVertexAttrib4ubv"; + case EntryPoint::GLVertexAttrib4uiv: + return "glVertexAttrib4uiv"; + case EntryPoint::GLVertexAttrib4usv: + return "glVertexAttrib4usv"; + case EntryPoint::GLVertexAttribBinding: + return "glVertexAttribBinding"; + case EntryPoint::GLVertexAttribDivisor: + return "glVertexAttribDivisor"; + case EntryPoint::GLVertexAttribDivisorANGLE: + return "glVertexAttribDivisorANGLE"; + case EntryPoint::GLVertexAttribDivisorEXT: + return "glVertexAttribDivisorEXT"; + case EntryPoint::GLVertexAttribFormat: + return "glVertexAttribFormat"; + case EntryPoint::GLVertexAttribI1i: + return "glVertexAttribI1i"; + case EntryPoint::GLVertexAttribI1iv: + return "glVertexAttribI1iv"; + case EntryPoint::GLVertexAttribI1ui: + return "glVertexAttribI1ui"; + case EntryPoint::GLVertexAttribI1uiv: + return "glVertexAttribI1uiv"; + case EntryPoint::GLVertexAttribI2i: + return "glVertexAttribI2i"; + case EntryPoint::GLVertexAttribI2iv: + return "glVertexAttribI2iv"; + case EntryPoint::GLVertexAttribI2ui: + return "glVertexAttribI2ui"; + case EntryPoint::GLVertexAttribI2uiv: + return "glVertexAttribI2uiv"; + case EntryPoint::GLVertexAttribI3i: + return "glVertexAttribI3i"; + case EntryPoint::GLVertexAttribI3iv: + return "glVertexAttribI3iv"; + case EntryPoint::GLVertexAttribI3ui: + return "glVertexAttribI3ui"; + case EntryPoint::GLVertexAttribI3uiv: + return "glVertexAttribI3uiv"; + case EntryPoint::GLVertexAttribI4bv: + return "glVertexAttribI4bv"; + case EntryPoint::GLVertexAttribI4i: + return "glVertexAttribI4i"; + case EntryPoint::GLVertexAttribI4iv: + return "glVertexAttribI4iv"; + case EntryPoint::GLVertexAttribI4sv: + return "glVertexAttribI4sv"; + case EntryPoint::GLVertexAttribI4ubv: + return "glVertexAttribI4ubv"; + case EntryPoint::GLVertexAttribI4ui: + return "glVertexAttribI4ui"; + case EntryPoint::GLVertexAttribI4uiv: + return "glVertexAttribI4uiv"; + case EntryPoint::GLVertexAttribI4usv: + return "glVertexAttribI4usv"; + case EntryPoint::GLVertexAttribIFormat: + return "glVertexAttribIFormat"; + case EntryPoint::GLVertexAttribIPointer: + return "glVertexAttribIPointer"; + case EntryPoint::GLVertexAttribL1d: + return "glVertexAttribL1d"; + case EntryPoint::GLVertexAttribL1dv: + return "glVertexAttribL1dv"; + case EntryPoint::GLVertexAttribL2d: + return "glVertexAttribL2d"; + case EntryPoint::GLVertexAttribL2dv: + return "glVertexAttribL2dv"; + case EntryPoint::GLVertexAttribL3d: + return "glVertexAttribL3d"; + case EntryPoint::GLVertexAttribL3dv: + return "glVertexAttribL3dv"; + case EntryPoint::GLVertexAttribL4d: + return "glVertexAttribL4d"; + case EntryPoint::GLVertexAttribL4dv: + return "glVertexAttribL4dv"; + case EntryPoint::GLVertexAttribLFormat: + return "glVertexAttribLFormat"; + case EntryPoint::GLVertexAttribLPointer: + return "glVertexAttribLPointer"; + case EntryPoint::GLVertexAttribP1ui: + return "glVertexAttribP1ui"; + case EntryPoint::GLVertexAttribP1uiv: + return "glVertexAttribP1uiv"; + case EntryPoint::GLVertexAttribP2ui: + return "glVertexAttribP2ui"; + case EntryPoint::GLVertexAttribP2uiv: + return "glVertexAttribP2uiv"; + case EntryPoint::GLVertexAttribP3ui: + return "glVertexAttribP3ui"; + case EntryPoint::GLVertexAttribP3uiv: + return "glVertexAttribP3uiv"; + case EntryPoint::GLVertexAttribP4ui: + return "glVertexAttribP4ui"; + case EntryPoint::GLVertexAttribP4uiv: + return "glVertexAttribP4uiv"; + case EntryPoint::GLVertexAttribPointer: + return "glVertexAttribPointer"; + case EntryPoint::GLVertexBindingDivisor: + return "glVertexBindingDivisor"; + case EntryPoint::GLVertexP2ui: + return "glVertexP2ui"; + case EntryPoint::GLVertexP2uiv: + return "glVertexP2uiv"; + case EntryPoint::GLVertexP3ui: + return "glVertexP3ui"; + case EntryPoint::GLVertexP3uiv: + return "glVertexP3uiv"; + case EntryPoint::GLVertexP4ui: + return "glVertexP4ui"; + case EntryPoint::GLVertexP4uiv: + return "glVertexP4uiv"; + case EntryPoint::GLVertexPointer: + return "glVertexPointer"; + case EntryPoint::GLViewport: + return "glViewport"; + case EntryPoint::GLViewportArrayv: + return "glViewportArrayv"; + case EntryPoint::GLViewportIndexedf: + return "glViewportIndexedf"; + case EntryPoint::GLViewportIndexedfv: + return "glViewportIndexedfv"; + case EntryPoint::GLWaitSemaphoreEXT: + return "glWaitSemaphoreEXT"; + case EntryPoint::GLWaitSync: + return "glWaitSync"; + case EntryPoint::GLWeightPointerOES: + return "glWeightPointerOES"; + case EntryPoint::GLWindowPos2d: + return "glWindowPos2d"; + case EntryPoint::GLWindowPos2dv: + return "glWindowPos2dv"; + case EntryPoint::GLWindowPos2f: + return "glWindowPos2f"; + case EntryPoint::GLWindowPos2fv: + return "glWindowPos2fv"; + case EntryPoint::GLWindowPos2i: + return "glWindowPos2i"; + case EntryPoint::GLWindowPos2iv: + return "glWindowPos2iv"; + case EntryPoint::GLWindowPos2s: + return "glWindowPos2s"; + case EntryPoint::GLWindowPos2sv: + return "glWindowPos2sv"; + case EntryPoint::GLWindowPos3d: + return "glWindowPos3d"; + case EntryPoint::GLWindowPos3dv: + return "glWindowPos3dv"; + case EntryPoint::GLWindowPos3f: + return "glWindowPos3f"; + case EntryPoint::GLWindowPos3fv: + return "glWindowPos3fv"; + case EntryPoint::GLWindowPos3i: + return "glWindowPos3i"; + case EntryPoint::GLWindowPos3iv: + return "glWindowPos3iv"; + case EntryPoint::GLWindowPos3s: + return "glWindowPos3s"; + case EntryPoint::GLWindowPos3sv: + return "glWindowPos3sv"; + case EntryPoint::WGLChoosePixelFormat: + return "wglChoosePixelFormat"; + case EntryPoint::WGLCopyContext: + return "wglCopyContext"; + case EntryPoint::WGLCreateContext: + return "wglCreateContext"; + case EntryPoint::WGLCreateLayerContext: + return "wglCreateLayerContext"; + case EntryPoint::WGLDeleteContext: + return "wglDeleteContext"; + case EntryPoint::WGLDescribeLayerPlane: + return "wglDescribeLayerPlane"; + case EntryPoint::WGLDescribePixelFormat: + return "wglDescribePixelFormat"; + case EntryPoint::WGLGetCurrentContext: + return "wglGetCurrentContext"; + case EntryPoint::WGLGetCurrentDC: + return "wglGetCurrentDC"; + case EntryPoint::WGLGetEnhMetaFilePixelFormat: + return "wglGetEnhMetaFilePixelFormat"; + case EntryPoint::WGLGetLayerPaletteEntries: + return "wglGetLayerPaletteEntries"; + case EntryPoint::WGLGetPixelFormat: + return "wglGetPixelFormat"; + case EntryPoint::WGLGetProcAddress: + return "wglGetProcAddress"; + case EntryPoint::WGLMakeCurrent: + return "wglMakeCurrent"; + case EntryPoint::WGLRealizeLayerPalette: + return "wglRealizeLayerPalette"; + case EntryPoint::WGLSetLayerPaletteEntries: + return "wglSetLayerPaletteEntries"; + case EntryPoint::WGLSetPixelFormat: + return "wglSetPixelFormat"; + case EntryPoint::WGLShareLists: + return "wglShareLists"; + case EntryPoint::WGLSwapBuffers: + return "wglSwapBuffers"; + case EntryPoint::WGLSwapLayerBuffers: + return "wglSwapLayerBuffers"; + case EntryPoint::WGLUseFontBitmaps: + return "wglUseFontBitmaps"; + case EntryPoint::WGLUseFontBitmapsA: + return "wglUseFontBitmapsA"; + case EntryPoint::WGLUseFontBitmapsW: + return "wglUseFontBitmapsW"; + case EntryPoint::WGLUseFontOutlines: + return "wglUseFontOutlines"; + case EntryPoint::WGLUseFontOutlinesA: + return "wglUseFontOutlinesA"; + case EntryPoint::WGLUseFontOutlinesW: + return "wglUseFontOutlinesW"; + default: + UNREACHABLE(); + return "error"; + } +} +} // namespace angle diff --git a/gfx/angle/checkout/src/common/entry_points_enum_autogen.h b/gfx/angle/checkout/src/common/entry_points_enum_autogen.h new file mode 100644 index 0000000000..61c5c76f58 --- /dev/null +++ b/gfx/angle/checkout/src/common/entry_points_enum_autogen.h @@ -0,0 +1,1736 @@ +// GENERATED FILE - DO NOT EDIT. +// Generated by generate_entry_points.py using data from gl.xml and gl_angle_ext.xml. +// +// Copyright 2020 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// entry_points_enum_autogen.h: +// Defines the GL/GLES entry points enumeration. + +#ifndef COMMON_ENTRYPOINTSENUM_AUTOGEN_H_ +#define COMMON_ENTRYPOINTSENUM_AUTOGEN_H_ + +namespace angle +{ +enum class EntryPoint +{ + CLBuildProgram, + CLCloneKernel, + CLCompileProgram, + CLCreateBuffer, + CLCreateBufferWithProperties, + CLCreateCommandQueue, + CLCreateCommandQueueWithProperties, + CLCreateContext, + CLCreateContextFromType, + CLCreateImage, + CLCreateImage2D, + CLCreateImage3D, + CLCreateImageWithProperties, + CLCreateKernel, + CLCreateKernelsInProgram, + CLCreatePipe, + CLCreateProgramWithBinary, + CLCreateProgramWithBuiltInKernels, + CLCreateProgramWithIL, + CLCreateProgramWithSource, + CLCreateSampler, + CLCreateSamplerWithProperties, + CLCreateSubBuffer, + CLCreateSubDevices, + CLCreateUserEvent, + CLEnqueueBarrier, + CLEnqueueBarrierWithWaitList, + CLEnqueueCopyBuffer, + CLEnqueueCopyBufferRect, + CLEnqueueCopyBufferToImage, + CLEnqueueCopyImage, + CLEnqueueCopyImageToBuffer, + CLEnqueueFillBuffer, + CLEnqueueFillImage, + CLEnqueueMapBuffer, + CLEnqueueMapImage, + CLEnqueueMarker, + CLEnqueueMarkerWithWaitList, + CLEnqueueMigrateMemObjects, + CLEnqueueNDRangeKernel, + CLEnqueueNativeKernel, + CLEnqueueReadBuffer, + CLEnqueueReadBufferRect, + CLEnqueueReadImage, + CLEnqueueSVMFree, + CLEnqueueSVMMap, + CLEnqueueSVMMemFill, + CLEnqueueSVMMemcpy, + CLEnqueueSVMMigrateMem, + CLEnqueueSVMUnmap, + CLEnqueueTask, + CLEnqueueUnmapMemObject, + CLEnqueueWaitForEvents, + CLEnqueueWriteBuffer, + CLEnqueueWriteBufferRect, + CLEnqueueWriteImage, + CLFinish, + CLFlush, + CLGetCommandQueueInfo, + CLGetContextInfo, + CLGetDeviceAndHostTimer, + CLGetDeviceIDs, + CLGetDeviceInfo, + CLGetEventInfo, + CLGetEventProfilingInfo, + CLGetExtensionFunctionAddress, + CLGetExtensionFunctionAddressForPlatform, + CLGetHostTimer, + CLGetImageInfo, + CLGetKernelArgInfo, + CLGetKernelInfo, + CLGetKernelSubGroupInfo, + CLGetKernelWorkGroupInfo, + CLGetMemObjectInfo, + CLGetPipeInfo, + CLGetPlatformIDs, + CLGetPlatformInfo, + CLGetProgramBuildInfo, + CLGetProgramInfo, + CLGetSamplerInfo, + CLGetSupportedImageFormats, + CLIcdGetPlatformIDsKHR, + CLLinkProgram, + CLReleaseCommandQueue, + CLReleaseContext, + CLReleaseDevice, + CLReleaseEvent, + CLReleaseKernel, + CLReleaseMemObject, + CLReleaseProgram, + CLReleaseSampler, + CLRetainCommandQueue, + CLRetainContext, + CLRetainDevice, + CLRetainEvent, + CLRetainKernel, + CLRetainMemObject, + CLRetainProgram, + CLRetainSampler, + CLSVMAlloc, + CLSVMFree, + CLSetCommandQueueProperty, + CLSetContextDestructorCallback, + CLSetDefaultDeviceCommandQueue, + CLSetEventCallback, + CLSetKernelArg, + CLSetKernelArgSVMPointer, + CLSetKernelExecInfo, + CLSetMemObjectDestructorCallback, + CLSetProgramReleaseCallback, + CLSetProgramSpecializationConstant, + CLSetUserEventStatus, + CLUnloadCompiler, + CLUnloadPlatformCompiler, + CLWaitForEvents, + EGLBindAPI, + EGLBindTexImage, + EGLChooseConfig, + EGLClientWaitSync, + EGLClientWaitSyncKHR, + EGLCopyBuffers, + EGLCopyMetalSharedEventANGLE, + EGLCreateContext, + EGLCreateDeviceANGLE, + EGLCreateImage, + EGLCreateImageKHR, + EGLCreateNativeClientBufferANDROID, + EGLCreatePbufferFromClientBuffer, + EGLCreatePbufferSurface, + EGLCreatePixmapSurface, + EGLCreatePlatformPixmapSurface, + EGLCreatePlatformPixmapSurfaceEXT, + EGLCreatePlatformWindowSurface, + EGLCreatePlatformWindowSurfaceEXT, + EGLCreateStreamKHR, + EGLCreateStreamProducerD3DTextureANGLE, + EGLCreateSync, + EGLCreateSyncKHR, + EGLCreateWindowSurface, + EGLDebugMessageControlKHR, + EGLDestroyContext, + EGLDestroyImage, + EGLDestroyImageKHR, + EGLDestroyStreamKHR, + EGLDestroySurface, + EGLDestroySync, + EGLDestroySyncKHR, + EGLDupNativeFenceFDANDROID, + EGLExportVkImageANGLE, + EGLForceGPUSwitchANGLE, + EGLGetCompositorTimingANDROID, + EGLGetCompositorTimingSupportedANDROID, + EGLGetConfigAttrib, + EGLGetConfigs, + EGLGetCurrentContext, + EGLGetCurrentDisplay, + EGLGetCurrentSurface, + EGLGetDisplay, + EGLGetError, + EGLGetFrameTimestampSupportedANDROID, + EGLGetFrameTimestampsANDROID, + EGLGetMscRateANGLE, + EGLGetNativeClientBufferANDROID, + EGLGetNextFrameIdANDROID, + EGLGetPlatformDisplay, + EGLGetPlatformDisplayEXT, + EGLGetProcAddress, + EGLGetSyncAttrib, + EGLGetSyncAttribKHR, + EGLGetSyncValuesCHROMIUM, + EGLHandleGPUSwitchANGLE, + EGLInitialize, + EGLLabelObjectKHR, + EGLLockSurfaceKHR, + EGLMakeCurrent, + EGLPostSubBufferNV, + EGLPrepareSwapBuffersANGLE, + EGLPresentationTimeANDROID, + EGLProgramCacheGetAttribANGLE, + EGLProgramCachePopulateANGLE, + EGLProgramCacheQueryANGLE, + EGLProgramCacheResizeANGLE, + EGLQueryAPI, + EGLQueryContext, + EGLQueryDebugKHR, + EGLQueryDeviceAttribEXT, + EGLQueryDeviceStringEXT, + EGLQueryDisplayAttribANGLE, + EGLQueryDisplayAttribEXT, + EGLQueryDmaBufFormatsEXT, + EGLQueryDmaBufModifiersEXT, + EGLQueryStreamKHR, + EGLQueryStreamu64KHR, + EGLQueryString, + EGLQueryStringiANGLE, + EGLQuerySurface, + EGLQuerySurface64KHR, + EGLQuerySurfacePointerANGLE, + EGLReacquireHighPowerGPUANGLE, + EGLReleaseDeviceANGLE, + EGLReleaseHighPowerGPUANGLE, + EGLReleaseTexImage, + EGLReleaseThread, + EGLSetBlobCacheFuncsANDROID, + EGLSetDamageRegionKHR, + EGLSignalSyncKHR, + EGLStreamAttribKHR, + EGLStreamConsumerAcquireKHR, + EGLStreamConsumerGLTextureExternalAttribsNV, + EGLStreamConsumerGLTextureExternalKHR, + EGLStreamConsumerReleaseKHR, + EGLStreamPostD3DTextureANGLE, + EGLSurfaceAttrib, + EGLSwapBuffers, + EGLSwapBuffersWithDamageKHR, + EGLSwapBuffersWithFrameTokenANGLE, + EGLSwapInterval, + EGLTerminate, + EGLUnlockSurfaceKHR, + EGLWaitClient, + EGLWaitGL, + EGLWaitNative, + EGLWaitSync, + EGLWaitSyncKHR, + GLAccum, + GLAcquireTexturesANGLE, + GLActiveShaderProgram, + GLActiveShaderProgramEXT, + GLActiveTexture, + GLAlphaFunc, + GLAlphaFuncx, + GLAreTexturesResident, + GLArrayElement, + GLAttachShader, + GLBegin, + GLBeginConditionalRender, + GLBeginPerfMonitorAMD, + GLBeginPixelLocalStorageANGLE, + GLBeginQuery, + GLBeginQueryEXT, + GLBeginQueryIndexed, + GLBeginTransformFeedback, + GLBindAttribLocation, + GLBindBuffer, + GLBindBufferBase, + GLBindBufferRange, + GLBindBuffersBase, + GLBindBuffersRange, + GLBindFragDataLocation, + GLBindFragDataLocationEXT, + GLBindFragDataLocationIndexed, + GLBindFragDataLocationIndexedEXT, + GLBindFramebuffer, + GLBindFramebufferOES, + GLBindImageTexture, + GLBindImageTextures, + GLBindProgramPipeline, + GLBindProgramPipelineEXT, + GLBindRenderbuffer, + GLBindRenderbufferOES, + GLBindSampler, + GLBindSamplers, + GLBindTexture, + GLBindTextureUnit, + GLBindTextures, + GLBindTransformFeedback, + GLBindUniformLocationCHROMIUM, + GLBindVertexArray, + GLBindVertexArrayOES, + GLBindVertexBuffer, + GLBindVertexBuffers, + GLBitmap, + GLBlendBarrier, + GLBlendBarrierKHR, + GLBlendColor, + GLBlendEquation, + GLBlendEquationSeparate, + GLBlendEquationSeparatei, + GLBlendEquationSeparateiEXT, + GLBlendEquationSeparateiOES, + GLBlendEquationi, + GLBlendEquationiEXT, + GLBlendEquationiOES, + GLBlendFunc, + GLBlendFuncSeparate, + GLBlendFuncSeparatei, + GLBlendFuncSeparateiEXT, + GLBlendFuncSeparateiOES, + GLBlendFunci, + GLBlendFunciEXT, + GLBlendFunciOES, + GLBlitFramebuffer, + GLBlitFramebufferANGLE, + GLBlitFramebufferNV, + GLBlitNamedFramebuffer, + GLBufferData, + GLBufferStorage, + GLBufferStorageEXT, + GLBufferStorageExternalEXT, + GLBufferStorageMemEXT, + GLBufferSubData, + GLCallList, + GLCallLists, + GLCheckFramebufferStatus, + GLCheckFramebufferStatusOES, + GLCheckNamedFramebufferStatus, + GLClampColor, + GLClear, + GLClearAccum, + GLClearBufferData, + GLClearBufferSubData, + GLClearBufferfi, + GLClearBufferfv, + GLClearBufferiv, + GLClearBufferuiv, + GLClearColor, + GLClearColorx, + GLClearDepth, + GLClearDepthf, + GLClearDepthx, + GLClearIndex, + GLClearNamedBufferData, + GLClearNamedBufferSubData, + GLClearNamedFramebufferfi, + GLClearNamedFramebufferfv, + GLClearNamedFramebufferiv, + GLClearNamedFramebufferuiv, + GLClearStencil, + GLClearTexImage, + GLClearTexSubImage, + GLClientActiveTexture, + GLClientWaitSync, + GLClipControl, + GLClipControlEXT, + GLClipPlane, + GLClipPlanef, + GLClipPlanex, + GLColor3b, + GLColor3bv, + GLColor3d, + GLColor3dv, + GLColor3f, + GLColor3fv, + GLColor3i, + GLColor3iv, + GLColor3s, + GLColor3sv, + GLColor3ub, + GLColor3ubv, + GLColor3ui, + GLColor3uiv, + GLColor3us, + GLColor3usv, + GLColor4b, + GLColor4bv, + GLColor4d, + GLColor4dv, + GLColor4f, + GLColor4fv, + GLColor4i, + GLColor4iv, + GLColor4s, + GLColor4sv, + GLColor4ub, + GLColor4ubv, + GLColor4ui, + GLColor4uiv, + GLColor4us, + GLColor4usv, + GLColor4x, + GLColorMask, + GLColorMaski, + GLColorMaskiEXT, + GLColorMaskiOES, + GLColorMaterial, + GLColorP3ui, + GLColorP3uiv, + GLColorP4ui, + GLColorP4uiv, + GLColorPointer, + GLCompileShader, + GLCompressedCopyTextureCHROMIUM, + GLCompressedTexImage1D, + GLCompressedTexImage2D, + GLCompressedTexImage2DRobustANGLE, + GLCompressedTexImage3D, + GLCompressedTexImage3DOES, + GLCompressedTexImage3DRobustANGLE, + GLCompressedTexSubImage1D, + GLCompressedTexSubImage2D, + GLCompressedTexSubImage2DRobustANGLE, + GLCompressedTexSubImage3D, + GLCompressedTexSubImage3DOES, + GLCompressedTexSubImage3DRobustANGLE, + GLCompressedTextureSubImage1D, + GLCompressedTextureSubImage2D, + GLCompressedTextureSubImage3D, + GLCopyBufferSubData, + GLCopyImageSubData, + GLCopyImageSubDataEXT, + GLCopyImageSubDataOES, + GLCopyNamedBufferSubData, + GLCopyPixels, + GLCopySubTexture3DANGLE, + GLCopySubTextureCHROMIUM, + GLCopyTexImage1D, + GLCopyTexImage2D, + GLCopyTexSubImage1D, + GLCopyTexSubImage2D, + GLCopyTexSubImage3D, + GLCopyTexSubImage3DOES, + GLCopyTexture3DANGLE, + GLCopyTextureCHROMIUM, + GLCopyTextureSubImage1D, + GLCopyTextureSubImage2D, + GLCopyTextureSubImage3D, + GLCoverageModulationCHROMIUM, + GLCreateBuffers, + GLCreateFramebuffers, + GLCreateMemoryObjectsEXT, + GLCreateProgram, + GLCreateProgramPipelines, + GLCreateQueries, + GLCreateRenderbuffers, + GLCreateSamplers, + GLCreateShader, + GLCreateShaderProgramv, + GLCreateShaderProgramvEXT, + GLCreateTextures, + GLCreateTransformFeedbacks, + GLCreateVertexArrays, + GLCullFace, + GLCurrentPaletteMatrixOES, + GLDebugMessageCallback, + GLDebugMessageCallbackKHR, + GLDebugMessageControl, + GLDebugMessageControlKHR, + GLDebugMessageInsert, + GLDebugMessageInsertKHR, + GLDeleteBuffers, + GLDeleteFencesNV, + GLDeleteFramebuffers, + GLDeleteFramebuffersOES, + GLDeleteLists, + GLDeleteMemoryObjectsEXT, + GLDeletePerfMonitorsAMD, + GLDeleteProgram, + GLDeleteProgramPipelines, + GLDeleteProgramPipelinesEXT, + GLDeleteQueries, + GLDeleteQueriesEXT, + GLDeleteRenderbuffers, + GLDeleteRenderbuffersOES, + GLDeleteSamplers, + GLDeleteSemaphoresEXT, + GLDeleteShader, + GLDeleteSync, + GLDeleteTextures, + GLDeleteTransformFeedbacks, + GLDeleteVertexArrays, + GLDeleteVertexArraysOES, + GLDepthFunc, + GLDepthMask, + GLDepthRange, + GLDepthRangeArrayv, + GLDepthRangeIndexed, + GLDepthRangef, + GLDepthRangex, + GLDetachShader, + GLDisable, + GLDisableClientState, + GLDisableExtensionANGLE, + GLDisableVertexArrayAttrib, + GLDisableVertexAttribArray, + GLDisablei, + GLDisableiEXT, + GLDisableiOES, + GLDiscardFramebufferEXT, + GLDispatchCompute, + GLDispatchComputeIndirect, + GLDrawArrays, + GLDrawArraysIndirect, + GLDrawArraysInstanced, + GLDrawArraysInstancedANGLE, + GLDrawArraysInstancedBaseInstance, + GLDrawArraysInstancedBaseInstanceANGLE, + GLDrawArraysInstancedBaseInstanceEXT, + GLDrawArraysInstancedEXT, + GLDrawBuffer, + GLDrawBuffers, + GLDrawBuffersEXT, + GLDrawElements, + GLDrawElementsBaseVertex, + GLDrawElementsBaseVertexEXT, + GLDrawElementsBaseVertexOES, + GLDrawElementsIndirect, + GLDrawElementsInstanced, + GLDrawElementsInstancedANGLE, + GLDrawElementsInstancedBaseInstance, + GLDrawElementsInstancedBaseInstanceEXT, + GLDrawElementsInstancedBaseVertex, + GLDrawElementsInstancedBaseVertexBaseInstance, + GLDrawElementsInstancedBaseVertexBaseInstanceANGLE, + GLDrawElementsInstancedBaseVertexBaseInstanceEXT, + GLDrawElementsInstancedBaseVertexEXT, + GLDrawElementsInstancedBaseVertexOES, + GLDrawElementsInstancedEXT, + GLDrawPixels, + GLDrawRangeElements, + GLDrawRangeElementsBaseVertex, + GLDrawRangeElementsBaseVertexEXT, + GLDrawRangeElementsBaseVertexOES, + GLDrawTexfOES, + GLDrawTexfvOES, + GLDrawTexiOES, + GLDrawTexivOES, + GLDrawTexsOES, + GLDrawTexsvOES, + GLDrawTexxOES, + GLDrawTexxvOES, + GLDrawTransformFeedback, + GLDrawTransformFeedbackInstanced, + GLDrawTransformFeedbackStream, + GLDrawTransformFeedbackStreamInstanced, + GLEGLImageTargetRenderbufferStorageOES, + GLEGLImageTargetTexStorageEXT, + GLEGLImageTargetTexture2DOES, + GLEGLImageTargetTextureStorageEXT, + GLEdgeFlag, + GLEdgeFlagPointer, + GLEdgeFlagv, + GLEnable, + GLEnableClientState, + GLEnableVertexArrayAttrib, + GLEnableVertexAttribArray, + GLEnablei, + GLEnableiEXT, + GLEnableiOES, + GLEnd, + GLEndConditionalRender, + GLEndList, + GLEndPerfMonitorAMD, + GLEndPixelLocalStorageANGLE, + GLEndQuery, + GLEndQueryEXT, + GLEndQueryIndexed, + GLEndTransformFeedback, + GLEvalCoord1d, + GLEvalCoord1dv, + GLEvalCoord1f, + GLEvalCoord1fv, + GLEvalCoord2d, + GLEvalCoord2dv, + GLEvalCoord2f, + GLEvalCoord2fv, + GLEvalMesh1, + GLEvalMesh2, + GLEvalPoint1, + GLEvalPoint2, + GLFeedbackBuffer, + GLFenceSync, + GLFinish, + GLFinishFenceNV, + GLFlush, + GLFlushMappedBufferRange, + GLFlushMappedBufferRangeEXT, + GLFlushMappedNamedBufferRange, + GLFogCoordPointer, + GLFogCoordd, + GLFogCoorddv, + GLFogCoordf, + GLFogCoordfv, + GLFogf, + GLFogfv, + GLFogi, + GLFogiv, + GLFogx, + GLFogxv, + GLFramebufferFetchBarrierEXT, + GLFramebufferMemorylessPixelLocalStorageANGLE, + GLFramebufferParameteri, + GLFramebufferParameteriMESA, + GLFramebufferRenderbuffer, + GLFramebufferRenderbufferOES, + GLFramebufferTexture, + GLFramebufferTexture1D, + GLFramebufferTexture2D, + GLFramebufferTexture2DMultisampleEXT, + GLFramebufferTexture2DOES, + GLFramebufferTexture3D, + GLFramebufferTexture3DOES, + GLFramebufferTextureEXT, + GLFramebufferTextureLayer, + GLFramebufferTextureMultiviewOVR, + GLFramebufferTextureOES, + GLFramebufferTexturePixelLocalStorageANGLE, + GLFrontFace, + GLFrustum, + GLFrustumf, + GLFrustumx, + GLGenBuffers, + GLGenFencesNV, + GLGenFramebuffers, + GLGenFramebuffersOES, + GLGenLists, + GLGenPerfMonitorsAMD, + GLGenProgramPipelines, + GLGenProgramPipelinesEXT, + GLGenQueries, + GLGenQueriesEXT, + GLGenRenderbuffers, + GLGenRenderbuffersOES, + GLGenSamplers, + GLGenSemaphoresEXT, + GLGenTextures, + GLGenTransformFeedbacks, + GLGenVertexArrays, + GLGenVertexArraysOES, + GLGenerateMipmap, + GLGenerateMipmapOES, + GLGenerateTextureMipmap, + GLGetActiveAtomicCounterBufferiv, + GLGetActiveAttrib, + GLGetActiveSubroutineName, + GLGetActiveSubroutineUniformName, + GLGetActiveSubroutineUniformiv, + GLGetActiveUniform, + GLGetActiveUniformBlockName, + GLGetActiveUniformBlockiv, + GLGetActiveUniformBlockivRobustANGLE, + GLGetActiveUniformName, + GLGetActiveUniformsiv, + GLGetAttachedShaders, + GLGetAttribLocation, + GLGetBooleani_v, + GLGetBooleani_vRobustANGLE, + GLGetBooleanv, + GLGetBooleanvRobustANGLE, + GLGetBufferParameteri64v, + GLGetBufferParameteri64vRobustANGLE, + GLGetBufferParameteriv, + GLGetBufferParameterivRobustANGLE, + GLGetBufferPointerv, + GLGetBufferPointervOES, + GLGetBufferPointervRobustANGLE, + GLGetBufferSubData, + GLGetClipPlane, + GLGetClipPlanef, + GLGetClipPlanex, + GLGetCompressedTexImage, + GLGetCompressedTexImageANGLE, + GLGetCompressedTextureImage, + GLGetCompressedTextureSubImage, + GLGetDebugMessageLog, + GLGetDebugMessageLogKHR, + GLGetDoublei_v, + GLGetDoublev, + GLGetError, + GLGetFenceivNV, + GLGetFixedv, + GLGetFloati_v, + GLGetFloatv, + GLGetFloatvRobustANGLE, + GLGetFragDataIndex, + GLGetFragDataIndexEXT, + GLGetFragDataLocation, + GLGetFramebufferAttachmentParameteriv, + GLGetFramebufferAttachmentParameterivOES, + GLGetFramebufferAttachmentParameterivRobustANGLE, + GLGetFramebufferParameteriv, + GLGetFramebufferParameterivMESA, + GLGetFramebufferParameterivRobustANGLE, + GLGetGraphicsResetStatus, + GLGetGraphicsResetStatusEXT, + GLGetInteger64i_v, + GLGetInteger64i_vRobustANGLE, + GLGetInteger64v, + GLGetInteger64vEXT, + GLGetInteger64vRobustANGLE, + GLGetIntegeri_v, + GLGetIntegeri_vRobustANGLE, + GLGetIntegerv, + GLGetIntegervRobustANGLE, + GLGetInternalformati64v, + GLGetInternalformativ, + GLGetInternalformativRobustANGLE, + GLGetLightfv, + GLGetLightiv, + GLGetLightxv, + GLGetMapdv, + GLGetMapfv, + GLGetMapiv, + GLGetMaterialfv, + GLGetMaterialiv, + GLGetMaterialxv, + GLGetMemoryObjectParameterivEXT, + GLGetMultisamplefv, + GLGetMultisamplefvANGLE, + GLGetMultisamplefvRobustANGLE, + GLGetNamedBufferParameteri64v, + GLGetNamedBufferParameteriv, + GLGetNamedBufferPointerv, + GLGetNamedBufferSubData, + GLGetNamedFramebufferAttachmentParameteriv, + GLGetNamedFramebufferParameteriv, + GLGetNamedRenderbufferParameteriv, + GLGetObjectLabel, + GLGetObjectLabelEXT, + GLGetObjectLabelKHR, + GLGetObjectPtrLabel, + GLGetObjectPtrLabelKHR, + GLGetPerfMonitorCounterDataAMD, + GLGetPerfMonitorCounterInfoAMD, + GLGetPerfMonitorCounterStringAMD, + GLGetPerfMonitorCountersAMD, + GLGetPerfMonitorGroupStringAMD, + GLGetPerfMonitorGroupsAMD, + GLGetPixelMapfv, + GLGetPixelMapuiv, + GLGetPixelMapusv, + GLGetPointerv, + GLGetPointervKHR, + GLGetPointervRobustANGLERobustANGLE, + GLGetPolygonStipple, + GLGetProgramBinary, + GLGetProgramBinaryOES, + GLGetProgramInfoLog, + GLGetProgramInterfaceiv, + GLGetProgramInterfaceivRobustANGLE, + GLGetProgramPipelineInfoLog, + GLGetProgramPipelineInfoLogEXT, + GLGetProgramPipelineiv, + GLGetProgramPipelineivEXT, + GLGetProgramResourceIndex, + GLGetProgramResourceLocation, + GLGetProgramResourceLocationIndex, + GLGetProgramResourceLocationIndexEXT, + GLGetProgramResourceName, + GLGetProgramResourceiv, + GLGetProgramStageiv, + GLGetProgramiv, + GLGetProgramivRobustANGLE, + GLGetQueryBufferObjecti64v, + GLGetQueryBufferObjectiv, + GLGetQueryBufferObjectui64v, + GLGetQueryBufferObjectuiv, + GLGetQueryIndexediv, + GLGetQueryObjecti64v, + GLGetQueryObjecti64vEXT, + GLGetQueryObjecti64vRobustANGLE, + GLGetQueryObjectiv, + GLGetQueryObjectivEXT, + GLGetQueryObjectivRobustANGLE, + GLGetQueryObjectui64v, + GLGetQueryObjectui64vEXT, + GLGetQueryObjectui64vRobustANGLE, + GLGetQueryObjectuiv, + GLGetQueryObjectuivEXT, + GLGetQueryObjectuivRobustANGLE, + GLGetQueryiv, + GLGetQueryivEXT, + GLGetQueryivRobustANGLE, + GLGetRenderbufferImageANGLE, + GLGetRenderbufferParameteriv, + GLGetRenderbufferParameterivOES, + GLGetRenderbufferParameterivRobustANGLE, + GLGetSamplerParameterIiv, + GLGetSamplerParameterIivEXT, + GLGetSamplerParameterIivOES, + GLGetSamplerParameterIivRobustANGLE, + GLGetSamplerParameterIuiv, + GLGetSamplerParameterIuivEXT, + GLGetSamplerParameterIuivOES, + GLGetSamplerParameterIuivRobustANGLE, + GLGetSamplerParameterfv, + GLGetSamplerParameterfvRobustANGLE, + GLGetSamplerParameteriv, + GLGetSamplerParameterivRobustANGLE, + GLGetSemaphoreParameterui64vEXT, + GLGetShaderInfoLog, + GLGetShaderPrecisionFormat, + GLGetShaderSource, + GLGetShaderiv, + GLGetShaderivRobustANGLE, + GLGetString, + GLGetStringi, + GLGetSubroutineIndex, + GLGetSubroutineUniformLocation, + GLGetSynciv, + GLGetTexEnvfv, + GLGetTexEnviv, + GLGetTexEnvxv, + GLGetTexGendv, + GLGetTexGenfv, + GLGetTexGenfvOES, + GLGetTexGeniv, + GLGetTexGenivOES, + GLGetTexGenxvOES, + GLGetTexImage, + GLGetTexImageANGLE, + GLGetTexLevelParameterfv, + GLGetTexLevelParameterfvANGLE, + GLGetTexLevelParameterfvRobustANGLE, + GLGetTexLevelParameteriv, + GLGetTexLevelParameterivANGLE, + GLGetTexLevelParameterivRobustANGLE, + GLGetTexParameterIiv, + GLGetTexParameterIivEXT, + GLGetTexParameterIivOES, + GLGetTexParameterIivRobustANGLE, + GLGetTexParameterIuiv, + GLGetTexParameterIuivEXT, + GLGetTexParameterIuivOES, + GLGetTexParameterIuivRobustANGLE, + GLGetTexParameterfv, + GLGetTexParameterfvRobustANGLE, + GLGetTexParameteriv, + GLGetTexParameterivRobustANGLE, + GLGetTexParameterxv, + GLGetTextureImage, + GLGetTextureLevelParameterfv, + GLGetTextureLevelParameteriv, + GLGetTextureParameterIiv, + GLGetTextureParameterIuiv, + GLGetTextureParameterfv, + GLGetTextureParameteriv, + GLGetTextureSubImage, + GLGetTransformFeedbackVarying, + GLGetTransformFeedbacki64_v, + GLGetTransformFeedbacki_v, + GLGetTransformFeedbackiv, + GLGetTranslatedShaderSourceANGLE, + GLGetUniformBlockIndex, + GLGetUniformIndices, + GLGetUniformLocation, + GLGetUniformSubroutineuiv, + GLGetUniformdv, + GLGetUniformfv, + GLGetUniformfvRobustANGLE, + GLGetUniformiv, + GLGetUniformivRobustANGLE, + GLGetUniformuiv, + GLGetUniformuivRobustANGLE, + GLGetUnsignedBytei_vEXT, + GLGetUnsignedBytevEXT, + GLGetVertexArrayIndexed64iv, + GLGetVertexArrayIndexediv, + GLGetVertexArrayiv, + GLGetVertexAttribIiv, + GLGetVertexAttribIivRobustANGLE, + GLGetVertexAttribIuiv, + GLGetVertexAttribIuivRobustANGLE, + GLGetVertexAttribLdv, + GLGetVertexAttribPointerv, + GLGetVertexAttribPointervRobustANGLE, + GLGetVertexAttribdv, + GLGetVertexAttribfv, + GLGetVertexAttribfvRobustANGLE, + GLGetVertexAttribiv, + GLGetVertexAttribivRobustANGLE, + GLGetnColorTable, + GLGetnCompressedTexImage, + GLGetnConvolutionFilter, + GLGetnHistogram, + GLGetnMapdv, + GLGetnMapfv, + GLGetnMapiv, + GLGetnMinmax, + GLGetnPixelMapfv, + GLGetnPixelMapuiv, + GLGetnPixelMapusv, + GLGetnPolygonStipple, + GLGetnSeparableFilter, + GLGetnTexImage, + GLGetnUniformdv, + GLGetnUniformfv, + GLGetnUniformfvEXT, + GLGetnUniformfvRobustANGLE, + GLGetnUniformiv, + GLGetnUniformivEXT, + GLGetnUniformivRobustANGLE, + GLGetnUniformuiv, + GLGetnUniformuivRobustANGLE, + GLHint, + GLImportMemoryFdEXT, + GLImportMemoryZirconHandleANGLE, + GLImportSemaphoreFdEXT, + GLImportSemaphoreZirconHandleANGLE, + GLIndexMask, + GLIndexPointer, + GLIndexd, + GLIndexdv, + GLIndexf, + GLIndexfv, + GLIndexi, + GLIndexiv, + GLIndexs, + GLIndexsv, + GLIndexub, + GLIndexubv, + GLInitNames, + GLInsertEventMarkerEXT, + GLInterleavedArrays, + GLInvalid, + GLInvalidateBufferData, + GLInvalidateBufferSubData, + GLInvalidateFramebuffer, + GLInvalidateNamedFramebufferData, + GLInvalidateNamedFramebufferSubData, + GLInvalidateSubFramebuffer, + GLInvalidateTexImage, + GLInvalidateTexSubImage, + GLInvalidateTextureANGLE, + GLIsBuffer, + GLIsEnabled, + GLIsEnabledi, + GLIsEnablediEXT, + GLIsEnablediOES, + GLIsFenceNV, + GLIsFramebuffer, + GLIsFramebufferOES, + GLIsList, + GLIsMemoryObjectEXT, + GLIsProgram, + GLIsProgramPipeline, + GLIsProgramPipelineEXT, + GLIsQuery, + GLIsQueryEXT, + GLIsRenderbuffer, + GLIsRenderbufferOES, + GLIsSampler, + GLIsSemaphoreEXT, + GLIsShader, + GLIsSync, + GLIsTexture, + GLIsTransformFeedback, + GLIsVertexArray, + GLIsVertexArrayOES, + GLLabelObjectEXT, + GLLightModelf, + GLLightModelfv, + GLLightModeli, + GLLightModeliv, + GLLightModelx, + GLLightModelxv, + GLLightf, + GLLightfv, + GLLighti, + GLLightiv, + GLLightx, + GLLightxv, + GLLineStipple, + GLLineWidth, + GLLineWidthx, + GLLinkProgram, + GLListBase, + GLLoadIdentity, + GLLoadMatrixd, + GLLoadMatrixf, + GLLoadMatrixx, + GLLoadName, + GLLoadPaletteFromModelViewMatrixOES, + GLLoadTransposeMatrixd, + GLLoadTransposeMatrixf, + GLLogicOp, + GLLogicOpANGLE, + GLLoseContextCHROMIUM, + GLMap1d, + GLMap1f, + GLMap2d, + GLMap2f, + GLMapBuffer, + GLMapBufferOES, + GLMapBufferRange, + GLMapBufferRangeEXT, + GLMapGrid1d, + GLMapGrid1f, + GLMapGrid2d, + GLMapGrid2f, + GLMapNamedBuffer, + GLMapNamedBufferRange, + GLMaterialf, + GLMaterialfv, + GLMateriali, + GLMaterialiv, + GLMaterialx, + GLMaterialxv, + GLMatrixIndexPointerOES, + GLMatrixMode, + GLMaxShaderCompilerThreadsKHR, + GLMemoryBarrier, + GLMemoryBarrierByRegion, + GLMemoryObjectParameterivEXT, + GLMinSampleShading, + GLMinSampleShadingOES, + GLMultMatrixd, + GLMultMatrixf, + GLMultMatrixx, + GLMultTransposeMatrixd, + GLMultTransposeMatrixf, + GLMultiDrawArrays, + GLMultiDrawArraysANGLE, + GLMultiDrawArraysIndirect, + GLMultiDrawArraysIndirectCount, + GLMultiDrawArraysIndirectEXT, + GLMultiDrawArraysInstancedANGLE, + GLMultiDrawArraysInstancedBaseInstanceANGLE, + GLMultiDrawElements, + GLMultiDrawElementsANGLE, + GLMultiDrawElementsBaseVertex, + GLMultiDrawElementsBaseVertexEXT, + GLMultiDrawElementsIndirect, + GLMultiDrawElementsIndirectCount, + GLMultiDrawElementsIndirectEXT, + GLMultiDrawElementsInstancedANGLE, + GLMultiDrawElementsInstancedBaseVertexBaseInstanceANGLE, + GLMultiTexCoord1d, + GLMultiTexCoord1dv, + GLMultiTexCoord1f, + GLMultiTexCoord1fv, + GLMultiTexCoord1i, + GLMultiTexCoord1iv, + GLMultiTexCoord1s, + GLMultiTexCoord1sv, + GLMultiTexCoord2d, + GLMultiTexCoord2dv, + GLMultiTexCoord2f, + GLMultiTexCoord2fv, + GLMultiTexCoord2i, + GLMultiTexCoord2iv, + GLMultiTexCoord2s, + GLMultiTexCoord2sv, + GLMultiTexCoord3d, + GLMultiTexCoord3dv, + GLMultiTexCoord3f, + GLMultiTexCoord3fv, + GLMultiTexCoord3i, + GLMultiTexCoord3iv, + GLMultiTexCoord3s, + GLMultiTexCoord3sv, + GLMultiTexCoord4d, + GLMultiTexCoord4dv, + GLMultiTexCoord4f, + GLMultiTexCoord4fv, + GLMultiTexCoord4i, + GLMultiTexCoord4iv, + GLMultiTexCoord4s, + GLMultiTexCoord4sv, + GLMultiTexCoord4x, + GLMultiTexCoordP1ui, + GLMultiTexCoordP1uiv, + GLMultiTexCoordP2ui, + GLMultiTexCoordP2uiv, + GLMultiTexCoordP3ui, + GLMultiTexCoordP3uiv, + GLMultiTexCoordP4ui, + GLMultiTexCoordP4uiv, + GLNamedBufferData, + GLNamedBufferStorage, + GLNamedBufferStorageExternalEXT, + GLNamedBufferSubData, + GLNamedFramebufferDrawBuffer, + GLNamedFramebufferDrawBuffers, + GLNamedFramebufferParameteri, + GLNamedFramebufferReadBuffer, + GLNamedFramebufferRenderbuffer, + GLNamedFramebufferTexture, + GLNamedFramebufferTextureLayer, + GLNamedRenderbufferStorage, + GLNamedRenderbufferStorageMultisample, + GLNewList, + GLNormal3b, + GLNormal3bv, + GLNormal3d, + GLNormal3dv, + GLNormal3f, + GLNormal3fv, + GLNormal3i, + GLNormal3iv, + GLNormal3s, + GLNormal3sv, + GLNormal3x, + GLNormalP3ui, + GLNormalP3uiv, + GLNormalPointer, + GLObjectLabel, + GLObjectLabelKHR, + GLObjectPtrLabel, + GLObjectPtrLabelKHR, + GLOrtho, + GLOrthof, + GLOrthox, + GLPassThrough, + GLPatchParameterfv, + GLPatchParameteri, + GLPatchParameteriEXT, + GLPauseTransformFeedback, + GLPixelLocalStorageBarrierANGLE, + GLPixelMapfv, + GLPixelMapuiv, + GLPixelMapusv, + GLPixelStoref, + GLPixelStorei, + GLPixelTransferf, + GLPixelTransferi, + GLPixelZoom, + GLPointParameterf, + GLPointParameterfv, + GLPointParameteri, + GLPointParameteriv, + GLPointParameterx, + GLPointParameterxv, + GLPointSize, + GLPointSizePointerOES, + GLPointSizex, + GLPolygonMode, + GLPolygonOffset, + GLPolygonOffsetClamp, + GLPolygonOffsetx, + GLPolygonStipple, + GLPopAttrib, + GLPopClientAttrib, + GLPopDebugGroup, + GLPopDebugGroupKHR, + GLPopGroupMarkerEXT, + GLPopMatrix, + GLPopName, + GLPrimitiveBoundingBox, + GLPrimitiveBoundingBoxEXT, + GLPrimitiveBoundingBoxOES, + GLPrimitiveRestartIndex, + GLPrioritizeTextures, + GLProgramBinary, + GLProgramBinaryOES, + GLProgramParameteri, + GLProgramParameteriEXT, + GLProgramUniform1d, + GLProgramUniform1dv, + GLProgramUniform1f, + GLProgramUniform1fEXT, + GLProgramUniform1fv, + GLProgramUniform1fvEXT, + GLProgramUniform1i, + GLProgramUniform1iEXT, + GLProgramUniform1iv, + GLProgramUniform1ivEXT, + GLProgramUniform1ui, + GLProgramUniform1uiEXT, + GLProgramUniform1uiv, + GLProgramUniform1uivEXT, + GLProgramUniform2d, + GLProgramUniform2dv, + GLProgramUniform2f, + GLProgramUniform2fEXT, + GLProgramUniform2fv, + GLProgramUniform2fvEXT, + GLProgramUniform2i, + GLProgramUniform2iEXT, + GLProgramUniform2iv, + GLProgramUniform2ivEXT, + GLProgramUniform2ui, + GLProgramUniform2uiEXT, + GLProgramUniform2uiv, + GLProgramUniform2uivEXT, + GLProgramUniform3d, + GLProgramUniform3dv, + GLProgramUniform3f, + GLProgramUniform3fEXT, + GLProgramUniform3fv, + GLProgramUniform3fvEXT, + GLProgramUniform3i, + GLProgramUniform3iEXT, + GLProgramUniform3iv, + GLProgramUniform3ivEXT, + GLProgramUniform3ui, + GLProgramUniform3uiEXT, + GLProgramUniform3uiv, + GLProgramUniform3uivEXT, + GLProgramUniform4d, + GLProgramUniform4dv, + GLProgramUniform4f, + GLProgramUniform4fEXT, + GLProgramUniform4fv, + GLProgramUniform4fvEXT, + GLProgramUniform4i, + GLProgramUniform4iEXT, + GLProgramUniform4iv, + GLProgramUniform4ivEXT, + GLProgramUniform4ui, + GLProgramUniform4uiEXT, + GLProgramUniform4uiv, + GLProgramUniform4uivEXT, + GLProgramUniformMatrix2dv, + GLProgramUniformMatrix2fv, + GLProgramUniformMatrix2fvEXT, + GLProgramUniformMatrix2x3dv, + GLProgramUniformMatrix2x3fv, + GLProgramUniformMatrix2x3fvEXT, + GLProgramUniformMatrix2x4dv, + GLProgramUniformMatrix2x4fv, + GLProgramUniformMatrix2x4fvEXT, + GLProgramUniformMatrix3dv, + GLProgramUniformMatrix3fv, + GLProgramUniformMatrix3fvEXT, + GLProgramUniformMatrix3x2dv, + GLProgramUniformMatrix3x2fv, + GLProgramUniformMatrix3x2fvEXT, + GLProgramUniformMatrix3x4dv, + GLProgramUniformMatrix3x4fv, + GLProgramUniformMatrix3x4fvEXT, + GLProgramUniformMatrix4dv, + GLProgramUniformMatrix4fv, + GLProgramUniformMatrix4fvEXT, + GLProgramUniformMatrix4x2dv, + GLProgramUniformMatrix4x2fv, + GLProgramUniformMatrix4x2fvEXT, + GLProgramUniformMatrix4x3dv, + GLProgramUniformMatrix4x3fv, + GLProgramUniformMatrix4x3fvEXT, + GLProvokingVertex, + GLProvokingVertexANGLE, + GLPushAttrib, + GLPushClientAttrib, + GLPushDebugGroup, + GLPushDebugGroupKHR, + GLPushGroupMarkerEXT, + GLPushMatrix, + GLPushName, + GLQueryCounter, + GLQueryCounterEXT, + GLQueryMatrixxOES, + GLRasterPos2d, + GLRasterPos2dv, + GLRasterPos2f, + GLRasterPos2fv, + GLRasterPos2i, + GLRasterPos2iv, + GLRasterPos2s, + GLRasterPos2sv, + GLRasterPos3d, + GLRasterPos3dv, + GLRasterPos3f, + GLRasterPos3fv, + GLRasterPos3i, + GLRasterPos3iv, + GLRasterPos3s, + GLRasterPos3sv, + GLRasterPos4d, + GLRasterPos4dv, + GLRasterPos4f, + GLRasterPos4fv, + GLRasterPos4i, + GLRasterPos4iv, + GLRasterPos4s, + GLRasterPos4sv, + GLReadBuffer, + GLReadPixels, + GLReadPixelsRobustANGLE, + GLReadnPixels, + GLReadnPixelsEXT, + GLReadnPixelsRobustANGLE, + GLRectd, + GLRectdv, + GLRectf, + GLRectfv, + GLRecti, + GLRectiv, + GLRects, + GLRectsv, + GLReleaseShaderCompiler, + GLReleaseTexturesANGLE, + GLRenderMode, + GLRenderbufferStorage, + GLRenderbufferStorageMultisample, + GLRenderbufferStorageMultisampleANGLE, + GLRenderbufferStorageMultisampleEXT, + GLRenderbufferStorageOES, + GLRequestExtensionANGLE, + GLResumeTransformFeedback, + GLRotated, + GLRotatef, + GLRotatex, + GLSampleCoverage, + GLSampleCoveragex, + GLSampleMaski, + GLSampleMaskiANGLE, + GLSamplerParameterIiv, + GLSamplerParameterIivEXT, + GLSamplerParameterIivOES, + GLSamplerParameterIivRobustANGLE, + GLSamplerParameterIuiv, + GLSamplerParameterIuivEXT, + GLSamplerParameterIuivOES, + GLSamplerParameterIuivRobustANGLE, + GLSamplerParameterf, + GLSamplerParameterfv, + GLSamplerParameterfvRobustANGLE, + GLSamplerParameteri, + GLSamplerParameteriv, + GLSamplerParameterivRobustANGLE, + GLScaled, + GLScalef, + GLScalex, + GLScissor, + GLScissorArrayv, + GLScissorIndexed, + GLScissorIndexedv, + GLSecondaryColor3b, + GLSecondaryColor3bv, + GLSecondaryColor3d, + GLSecondaryColor3dv, + GLSecondaryColor3f, + GLSecondaryColor3fv, + GLSecondaryColor3i, + GLSecondaryColor3iv, + GLSecondaryColor3s, + GLSecondaryColor3sv, + GLSecondaryColor3ub, + GLSecondaryColor3ubv, + GLSecondaryColor3ui, + GLSecondaryColor3uiv, + GLSecondaryColor3us, + GLSecondaryColor3usv, + GLSecondaryColorP3ui, + GLSecondaryColorP3uiv, + GLSecondaryColorPointer, + GLSelectBuffer, + GLSelectPerfMonitorCountersAMD, + GLSemaphoreParameterui64vEXT, + GLSetFenceNV, + GLShadeModel, + GLShaderBinary, + GLShaderSource, + GLShaderStorageBlockBinding, + GLShadingRateQCOM, + GLSignalSemaphoreEXT, + GLSpecializeShader, + GLStencilFunc, + GLStencilFuncSeparate, + GLStencilMask, + GLStencilMaskSeparate, + GLStencilOp, + GLStencilOpSeparate, + GLTestFenceNV, + GLTexBuffer, + GLTexBufferEXT, + GLTexBufferOES, + GLTexBufferRange, + GLTexBufferRangeEXT, + GLTexBufferRangeOES, + GLTexCoord1d, + GLTexCoord1dv, + GLTexCoord1f, + GLTexCoord1fv, + GLTexCoord1i, + GLTexCoord1iv, + GLTexCoord1s, + GLTexCoord1sv, + GLTexCoord2d, + GLTexCoord2dv, + GLTexCoord2f, + GLTexCoord2fv, + GLTexCoord2i, + GLTexCoord2iv, + GLTexCoord2s, + GLTexCoord2sv, + GLTexCoord3d, + GLTexCoord3dv, + GLTexCoord3f, + GLTexCoord3fv, + GLTexCoord3i, + GLTexCoord3iv, + GLTexCoord3s, + GLTexCoord3sv, + GLTexCoord4d, + GLTexCoord4dv, + GLTexCoord4f, + GLTexCoord4fv, + GLTexCoord4i, + GLTexCoord4iv, + GLTexCoord4s, + GLTexCoord4sv, + GLTexCoordP1ui, + GLTexCoordP1uiv, + GLTexCoordP2ui, + GLTexCoordP2uiv, + GLTexCoordP3ui, + GLTexCoordP3uiv, + GLTexCoordP4ui, + GLTexCoordP4uiv, + GLTexCoordPointer, + GLTexEnvf, + GLTexEnvfv, + GLTexEnvi, + GLTexEnviv, + GLTexEnvx, + GLTexEnvxv, + GLTexGend, + GLTexGendv, + GLTexGenf, + GLTexGenfOES, + GLTexGenfv, + GLTexGenfvOES, + GLTexGeni, + GLTexGeniOES, + GLTexGeniv, + GLTexGenivOES, + GLTexGenxOES, + GLTexGenxvOES, + GLTexImage1D, + GLTexImage2D, + GLTexImage2DExternalANGLE, + GLTexImage2DMultisample, + GLTexImage2DRobustANGLE, + GLTexImage3D, + GLTexImage3DMultisample, + GLTexImage3DOES, + GLTexImage3DRobustANGLE, + GLTexParameterIiv, + GLTexParameterIivEXT, + GLTexParameterIivOES, + GLTexParameterIivRobustANGLE, + GLTexParameterIuiv, + GLTexParameterIuivEXT, + GLTexParameterIuivOES, + GLTexParameterIuivRobustANGLE, + GLTexParameterf, + GLTexParameterfv, + GLTexParameterfvRobustANGLE, + GLTexParameteri, + GLTexParameteriv, + GLTexParameterivRobustANGLE, + GLTexParameterx, + GLTexParameterxv, + GLTexStorage1D, + GLTexStorage1DEXT, + GLTexStorage2D, + GLTexStorage2DEXT, + GLTexStorage2DMultisample, + GLTexStorage2DMultisampleANGLE, + GLTexStorage3D, + GLTexStorage3DEXT, + GLTexStorage3DMultisample, + GLTexStorage3DMultisampleOES, + GLTexStorageMem2DEXT, + GLTexStorageMem2DMultisampleEXT, + GLTexStorageMem3DEXT, + GLTexStorageMem3DMultisampleEXT, + GLTexStorageMemFlags2DANGLE, + GLTexStorageMemFlags2DMultisampleANGLE, + GLTexStorageMemFlags3DANGLE, + GLTexStorageMemFlags3DMultisampleANGLE, + GLTexSubImage1D, + GLTexSubImage2D, + GLTexSubImage2DRobustANGLE, + GLTexSubImage3D, + GLTexSubImage3DOES, + GLTexSubImage3DRobustANGLE, + GLTextureBarrier, + GLTextureBuffer, + GLTextureBufferRange, + GLTextureParameterIiv, + GLTextureParameterIuiv, + GLTextureParameterf, + GLTextureParameterfv, + GLTextureParameteri, + GLTextureParameteriv, + GLTextureStorage1D, + GLTextureStorage2D, + GLTextureStorage2DMultisample, + GLTextureStorage3D, + GLTextureStorage3DMultisample, + GLTextureSubImage1D, + GLTextureSubImage2D, + GLTextureSubImage3D, + GLTextureView, + GLTransformFeedbackBufferBase, + GLTransformFeedbackBufferRange, + GLTransformFeedbackVaryings, + GLTranslated, + GLTranslatef, + GLTranslatex, + GLUniform1d, + GLUniform1dv, + GLUniform1f, + GLUniform1fv, + GLUniform1i, + GLUniform1iv, + GLUniform1ui, + GLUniform1uiv, + GLUniform2d, + GLUniform2dv, + GLUniform2f, + GLUniform2fv, + GLUniform2i, + GLUniform2iv, + GLUniform2ui, + GLUniform2uiv, + GLUniform3d, + GLUniform3dv, + GLUniform3f, + GLUniform3fv, + GLUniform3i, + GLUniform3iv, + GLUniform3ui, + GLUniform3uiv, + GLUniform4d, + GLUniform4dv, + GLUniform4f, + GLUniform4fv, + GLUniform4i, + GLUniform4iv, + GLUniform4ui, + GLUniform4uiv, + GLUniformBlockBinding, + GLUniformMatrix2dv, + GLUniformMatrix2fv, + GLUniformMatrix2x3dv, + GLUniformMatrix2x3fv, + GLUniformMatrix2x4dv, + GLUniformMatrix2x4fv, + GLUniformMatrix3dv, + GLUniformMatrix3fv, + GLUniformMatrix3x2dv, + GLUniformMatrix3x2fv, + GLUniformMatrix3x4dv, + GLUniformMatrix3x4fv, + GLUniformMatrix4dv, + GLUniformMatrix4fv, + GLUniformMatrix4x2dv, + GLUniformMatrix4x2fv, + GLUniformMatrix4x3dv, + GLUniformMatrix4x3fv, + GLUniformSubroutinesuiv, + GLUnmapBuffer, + GLUnmapBufferOES, + GLUnmapNamedBuffer, + GLUseProgram, + GLUseProgramStages, + GLUseProgramStagesEXT, + GLValidateProgram, + GLValidateProgramPipeline, + GLValidateProgramPipelineEXT, + GLVertex2d, + GLVertex2dv, + GLVertex2f, + GLVertex2fv, + GLVertex2i, + GLVertex2iv, + GLVertex2s, + GLVertex2sv, + GLVertex3d, + GLVertex3dv, + GLVertex3f, + GLVertex3fv, + GLVertex3i, + GLVertex3iv, + GLVertex3s, + GLVertex3sv, + GLVertex4d, + GLVertex4dv, + GLVertex4f, + GLVertex4fv, + GLVertex4i, + GLVertex4iv, + GLVertex4s, + GLVertex4sv, + GLVertexArrayAttribBinding, + GLVertexArrayAttribFormat, + GLVertexArrayAttribIFormat, + GLVertexArrayAttribLFormat, + GLVertexArrayBindingDivisor, + GLVertexArrayElementBuffer, + GLVertexArrayVertexBuffer, + GLVertexArrayVertexBuffers, + GLVertexAttrib1d, + GLVertexAttrib1dv, + GLVertexAttrib1f, + GLVertexAttrib1fv, + GLVertexAttrib1s, + GLVertexAttrib1sv, + GLVertexAttrib2d, + GLVertexAttrib2dv, + GLVertexAttrib2f, + GLVertexAttrib2fv, + GLVertexAttrib2s, + GLVertexAttrib2sv, + GLVertexAttrib3d, + GLVertexAttrib3dv, + GLVertexAttrib3f, + GLVertexAttrib3fv, + GLVertexAttrib3s, + GLVertexAttrib3sv, + GLVertexAttrib4Nbv, + GLVertexAttrib4Niv, + GLVertexAttrib4Nsv, + GLVertexAttrib4Nub, + GLVertexAttrib4Nubv, + GLVertexAttrib4Nuiv, + GLVertexAttrib4Nusv, + GLVertexAttrib4bv, + GLVertexAttrib4d, + GLVertexAttrib4dv, + GLVertexAttrib4f, + GLVertexAttrib4fv, + GLVertexAttrib4iv, + GLVertexAttrib4s, + GLVertexAttrib4sv, + GLVertexAttrib4ubv, + GLVertexAttrib4uiv, + GLVertexAttrib4usv, + GLVertexAttribBinding, + GLVertexAttribDivisor, + GLVertexAttribDivisorANGLE, + GLVertexAttribDivisorEXT, + GLVertexAttribFormat, + GLVertexAttribI1i, + GLVertexAttribI1iv, + GLVertexAttribI1ui, + GLVertexAttribI1uiv, + GLVertexAttribI2i, + GLVertexAttribI2iv, + GLVertexAttribI2ui, + GLVertexAttribI2uiv, + GLVertexAttribI3i, + GLVertexAttribI3iv, + GLVertexAttribI3ui, + GLVertexAttribI3uiv, + GLVertexAttribI4bv, + GLVertexAttribI4i, + GLVertexAttribI4iv, + GLVertexAttribI4sv, + GLVertexAttribI4ubv, + GLVertexAttribI4ui, + GLVertexAttribI4uiv, + GLVertexAttribI4usv, + GLVertexAttribIFormat, + GLVertexAttribIPointer, + GLVertexAttribL1d, + GLVertexAttribL1dv, + GLVertexAttribL2d, + GLVertexAttribL2dv, + GLVertexAttribL3d, + GLVertexAttribL3dv, + GLVertexAttribL4d, + GLVertexAttribL4dv, + GLVertexAttribLFormat, + GLVertexAttribLPointer, + GLVertexAttribP1ui, + GLVertexAttribP1uiv, + GLVertexAttribP2ui, + GLVertexAttribP2uiv, + GLVertexAttribP3ui, + GLVertexAttribP3uiv, + GLVertexAttribP4ui, + GLVertexAttribP4uiv, + GLVertexAttribPointer, + GLVertexBindingDivisor, + GLVertexP2ui, + GLVertexP2uiv, + GLVertexP3ui, + GLVertexP3uiv, + GLVertexP4ui, + GLVertexP4uiv, + GLVertexPointer, + GLViewport, + GLViewportArrayv, + GLViewportIndexedf, + GLViewportIndexedfv, + GLWaitSemaphoreEXT, + GLWaitSync, + GLWeightPointerOES, + GLWindowPos2d, + GLWindowPos2dv, + GLWindowPos2f, + GLWindowPos2fv, + GLWindowPos2i, + GLWindowPos2iv, + GLWindowPos2s, + GLWindowPos2sv, + GLWindowPos3d, + GLWindowPos3dv, + GLWindowPos3f, + GLWindowPos3fv, + GLWindowPos3i, + GLWindowPos3iv, + GLWindowPos3s, + GLWindowPos3sv, + WGLChoosePixelFormat, + WGLCopyContext, + WGLCreateContext, + WGLCreateLayerContext, + WGLDeleteContext, + WGLDescribeLayerPlane, + WGLDescribePixelFormat, + WGLGetCurrentContext, + WGLGetCurrentDC, + WGLGetEnhMetaFilePixelFormat, + WGLGetLayerPaletteEntries, + WGLGetPixelFormat, + WGLGetProcAddress, + WGLMakeCurrent, + WGLRealizeLayerPalette, + WGLSetLayerPaletteEntries, + WGLSetPixelFormat, + WGLShareLists, + WGLSwapBuffers, + WGLSwapLayerBuffers, + WGLUseFontBitmaps, + WGLUseFontBitmapsA, + WGLUseFontBitmapsW, + WGLUseFontOutlines, + WGLUseFontOutlinesA, + WGLUseFontOutlinesW +}; + +const char *GetEntryPointName(EntryPoint ep); +} // namespace angle +#endif // COMMON_ENTRY_POINTS_ENUM_AUTOGEN_H_ diff --git a/gfx/angle/checkout/src/common/event_tracer.cpp b/gfx/angle/checkout/src/common/event_tracer.cpp new file mode 100644 index 0000000000..151cb2cd70 --- /dev/null +++ b/gfx/angle/checkout/src/common/event_tracer.cpp @@ -0,0 +1,53 @@ +// Copyright 2012 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#include "common/event_tracer.h" + +#include "common/debug.h" + +namespace angle +{ + +const unsigned char *GetTraceCategoryEnabledFlag(PlatformMethods *platform, const char *name) +{ + ASSERT(platform); + + const unsigned char *categoryEnabledFlag = + platform->getTraceCategoryEnabledFlag(platform, name); + if (categoryEnabledFlag != nullptr) + { + return categoryEnabledFlag; + } + + static unsigned char disabled = 0; + return &disabled; +} + +angle::TraceEventHandle AddTraceEvent(PlatformMethods *platform, + char phase, + const unsigned char *categoryGroupEnabled, + const char *name, + unsigned long long id, + int numArgs, + const char **argNames, + const unsigned char *argTypes, + const unsigned long long *argValues, + unsigned char flags) +{ + ASSERT(platform); + + double timestamp = platform->monotonicallyIncreasingTime(platform); + + if (timestamp != 0) + { + angle::TraceEventHandle handle = + platform->addTraceEvent(platform, phase, categoryGroupEnabled, name, id, timestamp, + numArgs, argNames, argTypes, argValues, flags); + return handle; + } + + return static_cast(0); +} + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/event_tracer.h b/gfx/angle/checkout/src/common/event_tracer.h new file mode 100644 index 0000000000..128d88b9e0 --- /dev/null +++ b/gfx/angle/checkout/src/common/event_tracer.h @@ -0,0 +1,26 @@ +// Copyright 2012 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef COMMON_EVENT_TRACER_H_ +#define COMMON_EVENT_TRACER_H_ + +#include "common/platform.h" +#include "platform/PlatformMethods.h" + +namespace angle +{ +const unsigned char *GetTraceCategoryEnabledFlag(PlatformMethods *platform, const char *name); +angle::TraceEventHandle AddTraceEvent(PlatformMethods *platform, + char phase, + const unsigned char *categoryGroupEnabled, + const char *name, + unsigned long long id, + int numArgs, + const char **argNames, + const unsigned char *argTypes, + const unsigned long long *argValues, + unsigned char flags); +} // namespace angle + +#endif // COMMON_EVENT_TRACER_H_ diff --git a/gfx/angle/checkout/src/common/hash_utils.h b/gfx/angle/checkout/src/common/hash_utils.h new file mode 100644 index 0000000000..aec4e7f77c --- /dev/null +++ b/gfx/angle/checkout/src/common/hash_utils.h @@ -0,0 +1,39 @@ +// +// Copyright 2018 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// hash_utils.h: Hashing based helper functions. + +#ifndef COMMON_HASHUTILS_H_ +#define COMMON_HASHUTILS_H_ + +#include "common/debug.h" +#include "common/third_party/xxhash/xxhash.h" + +namespace angle +{ +// Computes a hash of "key". Any data passed to this function must be multiples of +// 4 bytes, since the PMurHash32 method can only operate increments of 4-byte words. +inline std::size_t ComputeGenericHash(const void *key, size_t keySize) +{ + static constexpr unsigned int kSeed = 0xABCDEF98; + + // We can't support "odd" alignments. ComputeGenericHash requires aligned types + ASSERT(keySize % 4 == 0); +#if defined(ANGLE_IS_64_BIT_CPU) + return XXH64(key, keySize, kSeed); +#else + return XXH32(key, keySize, kSeed); +#endif // defined(ANGLE_IS_64_BIT_CPU) +} + +template +std::size_t ComputeGenericHash(const T &key) +{ + static_assert(sizeof(key) % 4 == 0, "ComputeGenericHash requires aligned types"); + return ComputeGenericHash(&key, sizeof(key)); +} +} // namespace angle + +#endif // COMMON_HASHUTILS_H_ diff --git a/gfx/angle/checkout/src/common/mathutil.cpp b/gfx/angle/checkout/src/common/mathutil.cpp new file mode 100644 index 0000000000..5cbc6a920a --- /dev/null +++ b/gfx/angle/checkout/src/common/mathutil.cpp @@ -0,0 +1,83 @@ +// +// Copyright 2013 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// mathutil.cpp: Math and bit manipulation functions. + +#include "common/mathutil.h" + +#include +#include + +namespace gl +{ + +namespace +{ + +struct RGB9E5Data +{ + unsigned int R : 9; + unsigned int G : 9; + unsigned int B : 9; + unsigned int E : 5; +}; + +// B is the exponent bias (15) +constexpr int g_sharedexp_bias = 15; + +// N is the number of mantissa bits per component (9) +constexpr int g_sharedexp_mantissabits = 9; + +// number of mantissa bits per component pre-biased +constexpr int g_sharedexp_biased_mantissabits = g_sharedexp_bias + g_sharedexp_mantissabits; + +// Emax is the maximum allowed biased exponent value (31) +constexpr int g_sharedexp_maxexponent = 31; + +constexpr float g_sharedexp_max = + ((static_cast(1 << g_sharedexp_mantissabits) - 1) / + static_cast(1 << g_sharedexp_mantissabits)) * + static_cast(1 << (g_sharedexp_maxexponent - g_sharedexp_bias)); + +} // anonymous namespace + +unsigned int convertRGBFloatsTo999E5(float red, float green, float blue) +{ + const float red_c = std::max(0, std::min(g_sharedexp_max, red)); + const float green_c = std::max(0, std::min(g_sharedexp_max, green)); + const float blue_c = std::max(0, std::min(g_sharedexp_max, blue)); + + const float max_c = std::max(std::max(red_c, green_c), blue_c); + const float exp_p = + std::max(-g_sharedexp_bias - 1, floor(log(max_c))) + 1 + g_sharedexp_bias; + const int max_s = static_cast( + floor((max_c / (pow(2.0f, exp_p - g_sharedexp_biased_mantissabits))) + 0.5f)); + const int exp_s = + static_cast((max_s < pow(2.0f, g_sharedexp_mantissabits)) ? exp_p : exp_p + 1); + const float pow2_exp = pow(2.0f, static_cast(exp_s) - g_sharedexp_biased_mantissabits); + + RGB9E5Data output; + output.R = static_cast(floor((red_c / pow2_exp) + 0.5f)); + output.G = static_cast(floor((green_c / pow2_exp) + 0.5f)); + output.B = static_cast(floor((blue_c / pow2_exp) + 0.5f)); + output.E = exp_s; + + return bitCast(output); +} + +void convert999E5toRGBFloats(unsigned int input, float *red, float *green, float *blue) +{ + const RGB9E5Data *inputData = reinterpret_cast(&input); + + const float pow2_exp = + pow(2.0f, static_cast(inputData->E) - g_sharedexp_biased_mantissabits); + + *red = inputData->R * pow2_exp; + *green = inputData->G * pow2_exp; + *blue = inputData->B * pow2_exp; +} + +} // namespace gl diff --git a/gfx/angle/checkout/src/common/mathutil.h b/gfx/angle/checkout/src/common/mathutil.h new file mode 100644 index 0000000000..560929239f --- /dev/null +++ b/gfx/angle/checkout/src/common/mathutil.h @@ -0,0 +1,1482 @@ +// +// Copyright 2002 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// mathutil.h: Math and bit manipulation functions. + +#ifndef COMMON_MATHUTIL_H_ +#define COMMON_MATHUTIL_H_ + +#include +#include +#include +#include +#include +#include + +#include + +#include "common/debug.h" +#include "common/platform.h" + +namespace angle +{ +using base::CheckedNumeric; +using base::IsValueInRangeForNumericType; +} // namespace angle + +namespace gl +{ + +const unsigned int Float32One = 0x3F800000; +const unsigned short Float16One = 0x3C00; + +template +inline constexpr bool isPow2(T x) +{ + static_assert(std::is_integral::value, "isPow2 must be called on an integer type."); + return (x & (x - 1)) == 0 && (x != 0); +} + +template +inline int log2(T x) +{ + static_assert(std::is_integral::value, "log2 must be called on an integer type."); + int r = 0; + while ((x >> r) > 1) + r++; + return r; +} + +inline unsigned int ceilPow2(unsigned int x) +{ + if (x != 0) + x--; + x |= x >> 1; + x |= x >> 2; + x |= x >> 4; + x |= x >> 8; + x |= x >> 16; + x++; + + return x; +} + +template +inline DestT clampCast(SrcT value) +{ + // For floating-point types with denormalization, min returns the minimum positive normalized + // value. To find the value that has no values less than it, use numeric_limits::lowest. + constexpr const long double destLo = + static_cast(std::numeric_limits::lowest()); + constexpr const long double destHi = + static_cast(std::numeric_limits::max()); + constexpr const long double srcLo = + static_cast(std::numeric_limits::lowest()); + constexpr long double srcHi = static_cast(std::numeric_limits::max()); + + if (destHi < srcHi) + { + DestT destMax = std::numeric_limits::max(); + if (value >= static_cast(destMax)) + { + return destMax; + } + } + + if (destLo > srcLo) + { + DestT destLow = std::numeric_limits::lowest(); + if (value <= static_cast(destLow)) + { + return destLow; + } + } + + return static_cast(value); +} + +// Specialize clampCast for bool->int conversion to avoid MSVS 2015 performance warning when the max +// value is casted to the source type. +template <> +inline unsigned int clampCast(bool value) +{ + return static_cast(value); +} + +template <> +inline int clampCast(bool value) +{ + return static_cast(value); +} + +template +inline T clamp(T x, MIN min, MAX max) +{ + // Since NaNs fail all comparison tests, a NaN value will default to min + return x > min ? (x > max ? max : x) : min; +} + +template +T clampForBitCount(T value, size_t bitCount) +{ + static_assert(std::numeric_limits::is_integer, "T must be an integer."); + + if (bitCount == 0) + { + constexpr T kZero = 0; + return kZero; + } + ASSERT(bitCount <= sizeof(T) * 8); + + constexpr bool kIsSigned = std::numeric_limits::is_signed; + ASSERT((bitCount > 1) || !kIsSigned); + + T min = 0; + T max = 0; + if (bitCount == sizeof(T) * 8) + { + min = std::numeric_limits::min(); + max = std::numeric_limits::max(); + } + else + { + constexpr T kOne = 1; + min = (kIsSigned) ? -1 * (kOne << (bitCount - 1)) : 0; + max = (kIsSigned) ? (kOne << (bitCount - 1)) - 1 : (kOne << bitCount) - 1; + } + + return gl::clamp(value, min, max); +} + +inline float clamp01(float x) +{ + return clamp(x, 0.0f, 1.0f); +} + +template +inline unsigned int unorm(float x) +{ + const unsigned int max = 0xFFFFFFFF >> (32 - n); + + if (x > 1) + { + return max; + } + else if (x < 0) + { + return 0; + } + else + { + return (unsigned int)(max * x + 0.5f); + } +} + +inline bool supportsSSE2() +{ +#if defined(ANGLE_USE_SSE) + static bool checked = false; + static bool supports = false; + + if (checked) + { + return supports; + } + +# if defined(ANGLE_PLATFORM_WINDOWS) && !defined(_M_ARM) && !defined(_M_ARM64) + { + int info[4]; + __cpuid(info, 0); + + if (info[0] >= 1) + { + __cpuid(info, 1); + + supports = (info[3] >> 26) & 1; + } + } +# endif // defined(ANGLE_PLATFORM_WINDOWS) && !defined(_M_ARM) && !defined(_M_ARM64) + checked = true; + return supports; +#else // defined(ANGLE_USE_SSE) + return false; +#endif +} + +template +destType bitCast(const sourceType &source) +{ + size_t copySize = std::min(sizeof(destType), sizeof(sourceType)); + destType output; + memcpy(&output, &source, copySize); + return output; +} + +// https://stackoverflow.com/a/37581284 +template +static constexpr double normalize(T value) +{ + return value < 0 ? -static_cast(value) / std::numeric_limits::min() + : static_cast(value) / std::numeric_limits::max(); +} + +inline unsigned short float32ToFloat16(float fp32) +{ + unsigned int fp32i = bitCast(fp32); + unsigned int sign = (fp32i & 0x80000000) >> 16; + unsigned int abs = fp32i & 0x7FFFFFFF; + + if (abs > 0x7F800000) + { // NaN + return 0x7FFF; + } + else if (abs > 0x47FFEFFF) + { // Infinity + return static_cast(sign | 0x7C00); + } + else if (abs < 0x38800000) // Denormal + { + unsigned int mantissa = (abs & 0x007FFFFF) | 0x00800000; + int e = 113 - (abs >> 23); + + if (e < 24) + { + abs = mantissa >> e; + } + else + { + abs = 0; + } + + return static_cast(sign | (abs + 0x00000FFF + ((abs >> 13) & 1)) >> 13); + } + else + { + return static_cast( + sign | (abs + 0xC8000000 + 0x00000FFF + ((abs >> 13) & 1)) >> 13); + } +} + +float float16ToFloat32(unsigned short h); + +unsigned int convertRGBFloatsTo999E5(float red, float green, float blue); +void convert999E5toRGBFloats(unsigned int input, float *red, float *green, float *blue); + +inline unsigned short float32ToFloat11(float fp32) +{ + const unsigned int float32MantissaMask = 0x7FFFFF; + const unsigned int float32ExponentMask = 0x7F800000; + const unsigned int float32SignMask = 0x80000000; + const unsigned int float32ValueMask = ~float32SignMask; + const unsigned int float32ExponentFirstBit = 23; + const unsigned int float32ExponentBias = 127; + + const unsigned short float11Max = 0x7BF; + const unsigned short float11MantissaMask = 0x3F; + const unsigned short float11ExponentMask = 0x7C0; + const unsigned short float11BitMask = 0x7FF; + const unsigned int float11ExponentBias = 14; + + const unsigned int float32Maxfloat11 = 0x477E0000; + const unsigned int float32MinNormfloat11 = 0x38800000; + const unsigned int float32MinDenormfloat11 = 0x35000080; + + const unsigned int float32Bits = bitCast(fp32); + const bool float32Sign = (float32Bits & float32SignMask) == float32SignMask; + + unsigned int float32Val = float32Bits & float32ValueMask; + + if ((float32Val & float32ExponentMask) == float32ExponentMask) + { + // INF or NAN + if ((float32Val & float32MantissaMask) != 0) + { + return float11ExponentMask | + (((float32Val >> 17) | (float32Val >> 11) | (float32Val >> 6) | (float32Val)) & + float11MantissaMask); + } + else if (float32Sign) + { + // -INF is clamped to 0 since float11 is positive only + return 0; + } + else + { + return float11ExponentMask; + } + } + else if (float32Sign) + { + // float11 is positive only, so clamp to zero + return 0; + } + else if (float32Val > float32Maxfloat11) + { + // The number is too large to be represented as a float11, set to max + return float11Max; + } + else if (float32Val < float32MinDenormfloat11) + { + // The number is too small to be represented as a denormalized float11, set to 0 + return 0; + } + else + { + if (float32Val < float32MinNormfloat11) + { + // The number is too small to be represented as a normalized float11 + // Convert it to a denormalized value. + const unsigned int shift = (float32ExponentBias - float11ExponentBias) - + (float32Val >> float32ExponentFirstBit); + ASSERT(shift < 32); + float32Val = + ((1 << float32ExponentFirstBit) | (float32Val & float32MantissaMask)) >> shift; + } + else + { + // Rebias the exponent to represent the value as a normalized float11 + float32Val += 0xC8000000; + } + + return ((float32Val + 0xFFFF + ((float32Val >> 17) & 1)) >> 17) & float11BitMask; + } +} + +inline unsigned short float32ToFloat10(float fp32) +{ + const unsigned int float32MantissaMask = 0x7FFFFF; + const unsigned int float32ExponentMask = 0x7F800000; + const unsigned int float32SignMask = 0x80000000; + const unsigned int float32ValueMask = ~float32SignMask; + const unsigned int float32ExponentFirstBit = 23; + const unsigned int float32ExponentBias = 127; + + const unsigned short float10Max = 0x3DF; + const unsigned short float10MantissaMask = 0x1F; + const unsigned short float10ExponentMask = 0x3E0; + const unsigned short float10BitMask = 0x3FF; + const unsigned int float10ExponentBias = 14; + + const unsigned int float32Maxfloat10 = 0x477C0000; + const unsigned int float32MinNormfloat10 = 0x38800000; + const unsigned int float32MinDenormfloat10 = 0x35800040; + + const unsigned int float32Bits = bitCast(fp32); + const bool float32Sign = (float32Bits & float32SignMask) == float32SignMask; + + unsigned int float32Val = float32Bits & float32ValueMask; + + if ((float32Val & float32ExponentMask) == float32ExponentMask) + { + // INF or NAN + if ((float32Val & float32MantissaMask) != 0) + { + return float10ExponentMask | + (((float32Val >> 18) | (float32Val >> 13) | (float32Val >> 3) | (float32Val)) & + float10MantissaMask); + } + else if (float32Sign) + { + // -INF is clamped to 0 since float10 is positive only + return 0; + } + else + { + return float10ExponentMask; + } + } + else if (float32Sign) + { + // float10 is positive only, so clamp to zero + return 0; + } + else if (float32Val > float32Maxfloat10) + { + // The number is too large to be represented as a float10, set to max + return float10Max; + } + else if (float32Val < float32MinDenormfloat10) + { + // The number is too small to be represented as a denormalized float10, set to 0 + return 0; + } + else + { + if (float32Val < float32MinNormfloat10) + { + // The number is too small to be represented as a normalized float10 + // Convert it to a denormalized value. + const unsigned int shift = (float32ExponentBias - float10ExponentBias) - + (float32Val >> float32ExponentFirstBit); + ASSERT(shift < 32); + float32Val = + ((1 << float32ExponentFirstBit) | (float32Val & float32MantissaMask)) >> shift; + } + else + { + // Rebias the exponent to represent the value as a normalized float10 + float32Val += 0xC8000000; + } + + return ((float32Val + 0x1FFFF + ((float32Val >> 18) & 1)) >> 18) & float10BitMask; + } +} + +inline float float11ToFloat32(unsigned short fp11) +{ + unsigned short exponent = (fp11 >> 6) & 0x1F; + unsigned short mantissa = fp11 & 0x3F; + + if (exponent == 0x1F) + { + // INF or NAN + return bitCast(0x7f800000 | (mantissa << 17)); + } + else + { + if (exponent != 0) + { + // normalized + } + else if (mantissa != 0) + { + // The value is denormalized + exponent = 1; + + do + { + exponent--; + mantissa <<= 1; + } while ((mantissa & 0x40) == 0); + + mantissa = mantissa & 0x3F; + } + else // The value is zero + { + exponent = static_cast(-112); + } + + return bitCast(((exponent + 112) << 23) | (mantissa << 17)); + } +} + +inline float float10ToFloat32(unsigned short fp10) +{ + unsigned short exponent = (fp10 >> 5) & 0x1F; + unsigned short mantissa = fp10 & 0x1F; + + if (exponent == 0x1F) + { + // INF or NAN + return bitCast(0x7f800000 | (mantissa << 17)); + } + else + { + if (exponent != 0) + { + // normalized + } + else if (mantissa != 0) + { + // The value is denormalized + exponent = 1; + + do + { + exponent--; + mantissa <<= 1; + } while ((mantissa & 0x20) == 0); + + mantissa = mantissa & 0x1F; + } + else // The value is zero + { + exponent = static_cast(-112); + } + + return bitCast(((exponent + 112) << 23) | (mantissa << 18)); + } +} + +// Converts to and from float and 16.16 fixed point format. +inline float ConvertFixedToFloat(int32_t fixedInput) +{ + return static_cast(fixedInput) / 65536.0f; +} + +inline uint32_t ConvertFloatToFixed(float floatInput) +{ + static constexpr uint32_t kHighest = 32767 * 65536 + 65535; + static constexpr uint32_t kLowest = static_cast(-32768 * 65536 + 65535); + + if (floatInput > 32767.65535) + { + return kHighest; + } + else if (floatInput < -32768.65535) + { + return kLowest; + } + else + { + return static_cast(floatInput * 65536); + } +} + +template +inline float normalizedToFloat(T input) +{ + static_assert(std::numeric_limits::is_integer, "T must be an integer."); + + if (sizeof(T) > 2) + { + // float has only a 23 bit mantissa, so we need to do the calculation in double precision + constexpr double inverseMax = 1.0 / std::numeric_limits::max(); + return static_cast(input * inverseMax); + } + else + { + constexpr float inverseMax = 1.0f / std::numeric_limits::max(); + return input * inverseMax; + } +} + +template +inline float normalizedToFloat(T input) +{ + static_assert(std::numeric_limits::is_integer, "T must be an integer."); + static_assert(inputBitCount < (sizeof(T) * 8), "T must have more bits than inputBitCount."); + ASSERT((input & ~((1 << inputBitCount) - 1)) == 0); + + if (inputBitCount > 23) + { + // float has only a 23 bit mantissa, so we need to do the calculation in double precision + constexpr double inverseMax = 1.0 / ((1 << inputBitCount) - 1); + return static_cast(input * inverseMax); + } + else + { + constexpr float inverseMax = 1.0f / ((1 << inputBitCount) - 1); + return input * inverseMax; + } +} + +template +inline T floatToNormalized(float input) +{ + if constexpr (sizeof(T) > 2) + { + // float has only a 23 bit mantissa, so we need to do the calculation in double precision + return static_cast(std::numeric_limits::max() * static_cast(input) + 0.5); + } + else + { + return static_cast(std::numeric_limits::max() * input + 0.5f); + } +} + +template +inline T floatToNormalized(float input) +{ + static_assert(outputBitCount < (sizeof(T) * 8), "T must have more bits than outputBitCount."); + + if (outputBitCount > 23) + { + // float has only a 23 bit mantissa, so we need to do the calculation in double precision + return static_cast(((1 << outputBitCount) - 1) * static_cast(input) + 0.5); + } + else + { + return static_cast(((1 << outputBitCount) - 1) * input + 0.5f); + } +} + +template +inline T getShiftedData(T input) +{ + static_assert(inputBitCount + inputBitStart <= (sizeof(T) * 8), + "T must have at least as many bits as inputBitCount + inputBitStart."); + const T mask = (1 << inputBitCount) - 1; + return (input >> inputBitStart) & mask; +} + +template +inline T shiftData(T input) +{ + static_assert(inputBitCount + inputBitStart <= (sizeof(T) * 8), + "T must have at least as many bits as inputBitCount + inputBitStart."); + const T mask = (1 << inputBitCount) - 1; + return (input & mask) << inputBitStart; +} + +inline unsigned int CountLeadingZeros(uint32_t x) +{ + // Use binary search to find the amount of leading zeros. + unsigned int zeros = 32u; + uint32_t y; + + y = x >> 16u; + if (y != 0) + { + zeros = zeros - 16u; + x = y; + } + y = x >> 8u; + if (y != 0) + { + zeros = zeros - 8u; + x = y; + } + y = x >> 4u; + if (y != 0) + { + zeros = zeros - 4u; + x = y; + } + y = x >> 2u; + if (y != 0) + { + zeros = zeros - 2u; + x = y; + } + y = x >> 1u; + if (y != 0) + { + return zeros - 2u; + } + return zeros - x; +} + +inline unsigned char average(unsigned char a, unsigned char b) +{ + return ((a ^ b) >> 1) + (a & b); +} + +inline signed char average(signed char a, signed char b) +{ + return ((short)a + (short)b) / 2; +} + +inline unsigned short average(unsigned short a, unsigned short b) +{ + return ((a ^ b) >> 1) + (a & b); +} + +inline signed short average(signed short a, signed short b) +{ + return ((int)a + (int)b) / 2; +} + +inline unsigned int average(unsigned int a, unsigned int b) +{ + return ((a ^ b) >> 1) + (a & b); +} + +inline int average(int a, int b) +{ + long long average = (static_cast(a) + static_cast(b)) / 2LL; + return static_cast(average); +} + +inline float average(float a, float b) +{ + return (a + b) * 0.5f; +} + +inline unsigned short averageHalfFloat(unsigned short a, unsigned short b) +{ + return float32ToFloat16((float16ToFloat32(a) + float16ToFloat32(b)) * 0.5f); +} + +inline unsigned int averageFloat11(unsigned int a, unsigned int b) +{ + return float32ToFloat11((float11ToFloat32(static_cast(a)) + + float11ToFloat32(static_cast(b))) * + 0.5f); +} + +inline unsigned int averageFloat10(unsigned int a, unsigned int b) +{ + return float32ToFloat10((float10ToFloat32(static_cast(a)) + + float10ToFloat32(static_cast(b))) * + 0.5f); +} + +template +class Range +{ + public: + Range() {} + Range(T lo, T hi) : mLow(lo), mHigh(hi) {} + + T length() const { return (empty() ? 0 : (mHigh - mLow)); } + + bool intersects(Range other) + { + if (mLow <= other.mLow) + { + return other.mLow < mHigh; + } + else + { + return mLow < other.mHigh; + } + } + + // Assumes that end is non-inclusive.. for example, extending to 5 will make "end" 6. + void extend(T value) + { + mLow = value < mLow ? value : mLow; + mHigh = value >= mHigh ? (value + 1) : mHigh; + } + + bool empty() const { return mHigh <= mLow; } + + bool contains(T value) const { return value >= mLow && value < mHigh; } + + class Iterator final + { + public: + Iterator(T value) : mCurrent(value) {} + + Iterator &operator++() + { + mCurrent++; + return *this; + } + bool operator==(const Iterator &other) const { return mCurrent == other.mCurrent; } + bool operator!=(const Iterator &other) const { return mCurrent != other.mCurrent; } + T operator*() const { return mCurrent; } + + private: + T mCurrent; + }; + + Iterator begin() const { return Iterator(mLow); } + + Iterator end() const { return Iterator(mHigh); } + + T low() const { return mLow; } + T high() const { return mHigh; } + + void invalidate() + { + mLow = std::numeric_limits::max(); + mHigh = std::numeric_limits::min(); + } + + private: + T mLow; + T mHigh; +}; + +typedef Range RangeI; +typedef Range RangeUI; + +struct IndexRange +{ + struct Undefined + {}; + IndexRange(Undefined) {} + IndexRange() : IndexRange(0, 0, 0) {} + IndexRange(size_t start_, size_t end_, size_t vertexIndexCount_) + : start(start_), end(end_), vertexIndexCount(vertexIndexCount_) + { + ASSERT(start <= end); + } + + // Number of vertices in the range. + size_t vertexCount() const { return (end - start) + 1; } + + // Inclusive range of indices that are not primitive restart + size_t start; + size_t end; + + // Number of non-primitive restart indices + size_t vertexIndexCount; +}; + +// Combine a floating-point value representing a mantissa (x) and an integer exponent (exp) into a +// floating-point value. As in GLSL ldexp() built-in. +inline float Ldexp(float x, int exp) +{ + if (exp > 128) + { + return std::numeric_limits::infinity(); + } + if (exp < -126) + { + return 0.0f; + } + double result = static_cast(x) * std::pow(2.0, static_cast(exp)); + return static_cast(result); +} + +// First, both normalized floating-point values are converted into 16-bit integer values. +// Then, the results are packed into the returned 32-bit unsigned integer. +// The first float value will be written to the least significant bits of the output; +// the last float value will be written to the most significant bits. +// The conversion of each value to fixed point is done as follows : +// packSnorm2x16 : round(clamp(c, -1, +1) * 32767.0) +inline uint32_t packSnorm2x16(float f1, float f2) +{ + int16_t leastSignificantBits = static_cast(roundf(clamp(f1, -1.0f, 1.0f) * 32767.0f)); + int16_t mostSignificantBits = static_cast(roundf(clamp(f2, -1.0f, 1.0f) * 32767.0f)); + return static_cast(mostSignificantBits) << 16 | + (static_cast(leastSignificantBits) & 0xFFFF); +} + +// First, unpacks a single 32-bit unsigned integer u into a pair of 16-bit unsigned integers. Then, +// each component is converted to a normalized floating-point value to generate the returned two +// float values. The first float value will be extracted from the least significant bits of the +// input; the last float value will be extracted from the most-significant bits. The conversion for +// unpacked fixed-point value to floating point is done as follows: unpackSnorm2x16 : clamp(f / +// 32767.0, -1, +1) +inline void unpackSnorm2x16(uint32_t u, float *f1, float *f2) +{ + int16_t leastSignificantBits = static_cast(u & 0xFFFF); + int16_t mostSignificantBits = static_cast(u >> 16); + *f1 = clamp(static_cast(leastSignificantBits) / 32767.0f, -1.0f, 1.0f); + *f2 = clamp(static_cast(mostSignificantBits) / 32767.0f, -1.0f, 1.0f); +} + +// First, both normalized floating-point values are converted into 16-bit integer values. +// Then, the results are packed into the returned 32-bit unsigned integer. +// The first float value will be written to the least significant bits of the output; +// the last float value will be written to the most significant bits. +// The conversion of each value to fixed point is done as follows: +// packUnorm2x16 : round(clamp(c, 0, +1) * 65535.0) +inline uint32_t packUnorm2x16(float f1, float f2) +{ + uint16_t leastSignificantBits = static_cast(roundf(clamp(f1, 0.0f, 1.0f) * 65535.0f)); + uint16_t mostSignificantBits = static_cast(roundf(clamp(f2, 0.0f, 1.0f) * 65535.0f)); + return static_cast(mostSignificantBits) << 16 | + static_cast(leastSignificantBits); +} + +// First, unpacks a single 32-bit unsigned integer u into a pair of 16-bit unsigned integers. Then, +// each component is converted to a normalized floating-point value to generate the returned two +// float values. The first float value will be extracted from the least significant bits of the +// input; the last float value will be extracted from the most-significant bits. The conversion for +// unpacked fixed-point value to floating point is done as follows: unpackUnorm2x16 : f / 65535.0 +inline void unpackUnorm2x16(uint32_t u, float *f1, float *f2) +{ + uint16_t leastSignificantBits = static_cast(u & 0xFFFF); + uint16_t mostSignificantBits = static_cast(u >> 16); + *f1 = static_cast(leastSignificantBits) / 65535.0f; + *f2 = static_cast(mostSignificantBits) / 65535.0f; +} + +// Helper functions intended to be used only here. +namespace priv +{ + +inline uint8_t ToPackedUnorm8(float f) +{ + return static_cast(roundf(clamp(f, 0.0f, 1.0f) * 255.0f)); +} + +inline int8_t ToPackedSnorm8(float f) +{ + return static_cast(roundf(clamp(f, -1.0f, 1.0f) * 127.0f)); +} + +} // namespace priv + +// Packs 4 normalized unsigned floating-point values to a single 32-bit unsigned integer. Works +// similarly to packUnorm2x16. The floats are clamped to the range 0.0 to 1.0, and written to the +// unsigned integer starting from the least significant bits. +inline uint32_t PackUnorm4x8(float f1, float f2, float f3, float f4) +{ + uint8_t bits[4]; + bits[0] = priv::ToPackedUnorm8(f1); + bits[1] = priv::ToPackedUnorm8(f2); + bits[2] = priv::ToPackedUnorm8(f3); + bits[3] = priv::ToPackedUnorm8(f4); + uint32_t result = 0u; + for (int i = 0; i < 4; ++i) + { + int shift = i * 8; + result |= (static_cast(bits[i]) << shift); + } + return result; +} + +// Unpacks 4 normalized unsigned floating-point values from a single 32-bit unsigned integer into f. +// Works similarly to unpackUnorm2x16. The floats are unpacked starting from the least significant +// bits. +inline void UnpackUnorm4x8(uint32_t u, float *f) +{ + for (int i = 0; i < 4; ++i) + { + int shift = i * 8; + uint8_t bits = static_cast((u >> shift) & 0xFF); + f[i] = static_cast(bits) / 255.0f; + } +} + +// Packs 4 normalized signed floating-point values to a single 32-bit unsigned integer. The floats +// are clamped to the range -1.0 to 1.0, and written to the unsigned integer starting from the least +// significant bits. +inline uint32_t PackSnorm4x8(float f1, float f2, float f3, float f4) +{ + int8_t bits[4]; + bits[0] = priv::ToPackedSnorm8(f1); + bits[1] = priv::ToPackedSnorm8(f2); + bits[2] = priv::ToPackedSnorm8(f3); + bits[3] = priv::ToPackedSnorm8(f4); + uint32_t result = 0u; + for (int i = 0; i < 4; ++i) + { + int shift = i * 8; + result |= ((static_cast(bits[i]) & 0xFF) << shift); + } + return result; +} + +// Unpacks 4 normalized signed floating-point values from a single 32-bit unsigned integer into f. +// Works similarly to unpackSnorm2x16. The floats are unpacked starting from the least significant +// bits, and clamped to the range -1.0 to 1.0. +inline void UnpackSnorm4x8(uint32_t u, float *f) +{ + for (int i = 0; i < 4; ++i) + { + int shift = i * 8; + int8_t bits = static_cast((u >> shift) & 0xFF); + f[i] = clamp(static_cast(bits) / 127.0f, -1.0f, 1.0f); + } +} + +// Returns an unsigned integer obtained by converting the two floating-point values to the 16-bit +// floating-point representation found in the OpenGL ES Specification, and then packing these +// two 16-bit integers into a 32-bit unsigned integer. +// f1: The 16 least-significant bits of the result; +// f2: The 16 most-significant bits. +inline uint32_t packHalf2x16(float f1, float f2) +{ + uint16_t leastSignificantBits = static_cast(float32ToFloat16(f1)); + uint16_t mostSignificantBits = static_cast(float32ToFloat16(f2)); + return static_cast(mostSignificantBits) << 16 | + static_cast(leastSignificantBits); +} + +// Returns two floating-point values obtained by unpacking a 32-bit unsigned integer into a pair of +// 16-bit values, interpreting those values as 16-bit floating-point numbers according to the OpenGL +// ES Specification, and converting them to 32-bit floating-point values. The first float value is +// obtained from the 16 least-significant bits of u; the second component is obtained from the 16 +// most-significant bits of u. +inline void unpackHalf2x16(uint32_t u, float *f1, float *f2) +{ + uint16_t leastSignificantBits = static_cast(u & 0xFFFF); + uint16_t mostSignificantBits = static_cast(u >> 16); + + *f1 = float16ToFloat32(leastSignificantBits); + *f2 = float16ToFloat32(mostSignificantBits); +} + +inline uint8_t sRGBToLinear(uint8_t srgbValue) +{ + float value = srgbValue / 255.0f; + if (value <= 0.04045f) + { + value = value / 12.92f; + } + else + { + value = std::pow((value + 0.055f) / 1.055f, 2.4f); + } + return static_cast(clamp(value * 255.0f + 0.5f, 0.0f, 255.0f)); +} + +inline uint8_t linearToSRGB(uint8_t linearValue) +{ + float value = linearValue / 255.0f; + if (value <= 0.0f) + { + value = 0.0f; + } + else if (value < 0.0031308f) + { + value = value * 12.92f; + } + else if (value < 1.0f) + { + value = std::pow(value, 0.41666f) * 1.055f - 0.055f; + } + else + { + value = 1.0f; + } + return static_cast(clamp(value * 255.0f + 0.5f, 0.0f, 255.0f)); +} + +// Reverse the order of the bits. +inline uint32_t BitfieldReverse(uint32_t value) +{ + // TODO(oetuaho@nvidia.com): Optimize this if needed. There don't seem to be compiler intrinsics + // for this, and right now it's not used in performance-critical paths. + uint32_t result = 0u; + for (size_t j = 0u; j < 32u; ++j) + { + result |= (((value >> j) & 1u) << (31u - j)); + } + return result; +} + +// Count the 1 bits. +#if defined(_MSC_VER) && !defined(__clang__) +# if defined(_M_IX86) || defined(_M_X64) +namespace priv +{ +// Check POPCNT instruction support and cache the result. +// https://docs.microsoft.com/en-us/cpp/intrinsics/popcnt16-popcnt-popcnt64#remarks +static const bool kHasPopcnt = [] { + int info[4]; + __cpuid(&info[0], 1); + return static_cast(info[2] & 0x800000); +}(); +} // namespace priv + +// Polyfills for x86/x64 CPUs without POPCNT. +// https://graphics.stanford.edu/~seander/bithacks.html#CountBitsSetParallel +inline int BitCountPolyfill(uint32_t bits) +{ + bits = bits - ((bits >> 1) & 0x55555555); + bits = (bits & 0x33333333) + ((bits >> 2) & 0x33333333); + bits = ((bits + (bits >> 4) & 0x0F0F0F0F) * 0x01010101) >> 24; + return static_cast(bits); +} + +inline int BitCountPolyfill(uint64_t bits) +{ + bits = bits - ((bits >> 1) & 0x5555555555555555ull); + bits = (bits & 0x3333333333333333ull) + ((bits >> 2) & 0x3333333333333333ull); + bits = ((bits + (bits >> 4) & 0x0F0F0F0F0F0F0F0Full) * 0x0101010101010101ull) >> 56; + return static_cast(bits); +} + +inline int BitCount(uint32_t bits) +{ + if (priv::kHasPopcnt) + { + return static_cast(__popcnt(bits)); + } + return BitCountPolyfill(bits); +} + +inline int BitCount(uint64_t bits) +{ + if (priv::kHasPopcnt) + { +# if defined(_M_X64) + return static_cast(__popcnt64(bits)); +# else // x86 + return static_cast(__popcnt(static_cast(bits >> 32)) + + __popcnt(static_cast(bits))); +# endif // defined(_M_X64) + } + return BitCountPolyfill(bits); +} + +# elif defined(_M_ARM) || defined(_M_ARM64) + +// MSVC's _CountOneBits* intrinsics are not defined for ARM64, moreover they do not use dedicated +// NEON instructions. + +inline int BitCount(uint32_t bits) +{ + // cast bits to 8x8 datatype and use VCNT on it + const uint8x8_t vsum = vcnt_u8(vcreate_u8(static_cast(bits))); + + // pairwise sums: 8x8 -> 16x4 -> 32x2 + return static_cast(vget_lane_u32(vpaddl_u16(vpaddl_u8(vsum)), 0)); +} + +inline int BitCount(uint64_t bits) +{ + // cast bits to 8x8 datatype and use VCNT on it + const uint8x8_t vsum = vcnt_u8(vcreate_u8(bits)); + + // pairwise sums: 8x8 -> 16x4 -> 32x2 -> 64x1 + return static_cast(vget_lane_u64(vpaddl_u32(vpaddl_u16(vpaddl_u8(vsum))), 0)); +} +# endif // defined(_M_IX86) || defined(_M_X64) +#endif // defined(_MSC_VER) && !defined(__clang__) + +#if defined(ANGLE_PLATFORM_POSIX) || defined(__clang__) +inline int BitCount(uint32_t bits) +{ + return __builtin_popcount(bits); +} + +inline int BitCount(uint64_t bits) +{ + return __builtin_popcountll(bits); +} +#endif // defined(ANGLE_PLATFORM_POSIX) || defined(__clang__) + +inline int BitCount(uint8_t bits) +{ + return BitCount(static_cast(bits)); +} + +inline int BitCount(uint16_t bits) +{ + return BitCount(static_cast(bits)); +} + +#if defined(ANGLE_PLATFORM_WINDOWS) +// Return the index of the least significant bit set. Indexing is such that bit 0 is the least +// significant bit. Implemented for different bit widths on different platforms. +inline unsigned long ScanForward(uint32_t bits) +{ + ASSERT(bits != 0u); + unsigned long firstBitIndex = 0ul; + unsigned char ret = _BitScanForward(&firstBitIndex, bits); + ASSERT(ret != 0u); + return firstBitIndex; +} + +inline unsigned long ScanForward(uint64_t bits) +{ + ASSERT(bits != 0u); + unsigned long firstBitIndex = 0ul; +# if defined(ANGLE_IS_64_BIT_CPU) + unsigned char ret = _BitScanForward64(&firstBitIndex, bits); +# else + unsigned char ret; + if (static_cast(bits) == 0) + { + ret = _BitScanForward(&firstBitIndex, static_cast(bits >> 32)); + firstBitIndex += 32ul; + } + else + { + ret = _BitScanForward(&firstBitIndex, static_cast(bits)); + } +# endif // defined(ANGLE_IS_64_BIT_CPU) + ASSERT(ret != 0u); + return firstBitIndex; +} + +// Return the index of the most significant bit set. Indexing is such that bit 0 is the least +// significant bit. +inline unsigned long ScanReverse(uint32_t bits) +{ + ASSERT(bits != 0u); + unsigned long lastBitIndex = 0ul; + unsigned char ret = _BitScanReverse(&lastBitIndex, bits); + ASSERT(ret != 0u); + return lastBitIndex; +} + +inline unsigned long ScanReverse(uint64_t bits) +{ + ASSERT(bits != 0u); + unsigned long lastBitIndex = 0ul; +# if defined(ANGLE_IS_64_BIT_CPU) + unsigned char ret = _BitScanReverse64(&lastBitIndex, bits); +# else + unsigned char ret; + if (static_cast(bits >> 32) == 0) + { + ret = _BitScanReverse(&lastBitIndex, static_cast(bits)); + } + else + { + ret = _BitScanReverse(&lastBitIndex, static_cast(bits >> 32)); + lastBitIndex += 32ul; + } +# endif // defined(ANGLE_IS_64_BIT_CPU) + ASSERT(ret != 0u); + return lastBitIndex; +} +#endif // defined(ANGLE_PLATFORM_WINDOWS) + +#if defined(ANGLE_PLATFORM_POSIX) +inline unsigned long ScanForward(uint32_t bits) +{ + ASSERT(bits != 0u); + return static_cast(__builtin_ctz(bits)); +} + +inline unsigned long ScanForward(uint64_t bits) +{ + ASSERT(bits != 0u); +# if defined(ANGLE_IS_64_BIT_CPU) + return static_cast(__builtin_ctzll(bits)); +# else + return static_cast(static_cast(bits) == 0 + ? __builtin_ctz(static_cast(bits >> 32)) + 32 + : __builtin_ctz(static_cast(bits))); +# endif // defined(ANGLE_IS_64_BIT_CPU) +} + +inline unsigned long ScanReverse(uint32_t bits) +{ + ASSERT(bits != 0u); + return static_cast(sizeof(uint32_t) * CHAR_BIT - 1 - __builtin_clz(bits)); +} + +inline unsigned long ScanReverse(uint64_t bits) +{ + ASSERT(bits != 0u); +# if defined(ANGLE_IS_64_BIT_CPU) + return static_cast(sizeof(uint64_t) * CHAR_BIT - 1 - __builtin_clzll(bits)); +# else + if (static_cast(bits >> 32) == 0) + { + return sizeof(uint32_t) * CHAR_BIT - 1 - __builtin_clz(static_cast(bits)); + } + else + { + return sizeof(uint32_t) * CHAR_BIT - 1 - __builtin_clz(static_cast(bits >> 32)) + + 32; + } +# endif // defined(ANGLE_IS_64_BIT_CPU) +} +#endif // defined(ANGLE_PLATFORM_POSIX) + +inline unsigned long ScanForward(uint8_t bits) +{ + return ScanForward(static_cast(bits)); +} + +inline unsigned long ScanForward(uint16_t bits) +{ + return ScanForward(static_cast(bits)); +} + +inline unsigned long ScanReverse(uint8_t bits) +{ + return ScanReverse(static_cast(bits)); +} + +inline unsigned long ScanReverse(uint16_t bits) +{ + return ScanReverse(static_cast(bits)); +} + +// Returns -1 on 0, otherwise the index of the least significant 1 bit as in GLSL. +template +int FindLSB(T bits) +{ + static_assert(std::is_integral::value, "must be integral type."); + if (bits == 0u) + { + return -1; + } + else + { + return static_cast(ScanForward(bits)); + } +} + +// Returns -1 on 0, otherwise the index of the most significant 1 bit as in GLSL. +template +int FindMSB(T bits) +{ + static_assert(std::is_integral::value, "must be integral type."); + if (bits == 0u) + { + return -1; + } + else + { + return static_cast(ScanReverse(bits)); + } +} + +// Returns whether the argument is Not a Number. +// IEEE 754 single precision NaN representation: Exponent(8 bits) - 255, Mantissa(23 bits) - +// non-zero. +inline bool isNaN(float f) +{ + // Exponent mask: ((1u << 8) - 1u) << 23 = 0x7f800000u + // Mantissa mask: ((1u << 23) - 1u) = 0x7fffffu + return ((bitCast(f) & 0x7f800000u) == 0x7f800000u) && + (bitCast(f) & 0x7fffffu); +} + +// Returns whether the argument is infinity. +// IEEE 754 single precision infinity representation: Exponent(8 bits) - 255, Mantissa(23 bits) - +// zero. +inline bool isInf(float f) +{ + // Exponent mask: ((1u << 8) - 1u) << 23 = 0x7f800000u + // Mantissa mask: ((1u << 23) - 1u) = 0x7fffffu + return ((bitCast(f) & 0x7f800000u) == 0x7f800000u) && + !(bitCast(f) & 0x7fffffu); +} + +namespace priv +{ +template +struct iSquareRoot +{ + static constexpr unsigned int solve() + { + return (R * R > N) + ? 0 + : ((R * R == N) ? R : static_cast(iSquareRoot::value)); + } + enum Result + { + value = iSquareRoot::solve() + }; +}; + +template +struct iSquareRoot +{ + enum result + { + value = N + }; +}; + +} // namespace priv + +template +constexpr unsigned int iSquareRoot() +{ + return priv::iSquareRoot::value; +} + +// Sum, difference and multiplication operations for signed ints that wrap on 32-bit overflow. +// +// Unsigned types are defined to do arithmetic modulo 2^n in C++. For signed types, overflow +// behavior is undefined. + +template +inline T WrappingSum(T lhs, T rhs) +{ + uint32_t lhsUnsigned = static_cast(lhs); + uint32_t rhsUnsigned = static_cast(rhs); + return static_cast(lhsUnsigned + rhsUnsigned); +} + +template +inline T WrappingDiff(T lhs, T rhs) +{ + uint32_t lhsUnsigned = static_cast(lhs); + uint32_t rhsUnsigned = static_cast(rhs); + return static_cast(lhsUnsigned - rhsUnsigned); +} + +inline int32_t WrappingMul(int32_t lhs, int32_t rhs) +{ + int64_t lhsWide = static_cast(lhs); + int64_t rhsWide = static_cast(rhs); + // The multiplication is guaranteed not to overflow. + int64_t resultWide = lhsWide * rhsWide; + // Implement the desired wrapping behavior by masking out the high-order 32 bits. + resultWide = resultWide & 0xffffffffLL; + // Casting to a narrower signed type is fine since the casted value is representable in the + // narrower type. + return static_cast(resultWide); +} + +inline float scaleScreenDimensionToNdc(float dimensionScreen, float viewportDimension) +{ + return 2.0f * dimensionScreen / viewportDimension; +} + +inline float scaleScreenCoordinateToNdc(float coordinateScreen, float viewportDimension) +{ + float halfShifted = coordinateScreen / viewportDimension; + return 2.0f * (halfShifted - 0.5f); +} + +} // namespace gl + +namespace rx +{ + +template +T roundUp(const T value, const T alignment) +{ + auto temp = value + alignment - static_cast(1); + return temp - temp % alignment; +} + +template +constexpr T roundUpPow2(const T value, const T alignment) +{ + ASSERT(gl::isPow2(alignment)); + return (value + alignment - 1) & ~(alignment - 1); +} + +template +constexpr T roundDownPow2(const T value, const T alignment) +{ + ASSERT(gl::isPow2(alignment)); + return value & ~(alignment - 1); +} + +template +angle::CheckedNumeric CheckedRoundUp(const T value, const T alignment) +{ + angle::CheckedNumeric checkedValue(value); + angle::CheckedNumeric checkedAlignment(alignment); + return roundUp(checkedValue, checkedAlignment); +} + +inline constexpr unsigned int UnsignedCeilDivide(unsigned int value, unsigned int divisor) +{ + unsigned int divided = value / divisor; + return (divided + ((value % divisor == 0) ? 0 : 1)); +} + +#if defined(__has_builtin) +# define ANGLE_HAS_BUILTIN(x) __has_builtin(x) +#else +# define ANGLE_HAS_BUILTIN(x) 0 +#endif + +#if defined(_MSC_VER) + +# define ANGLE_ROTL(x, y) _rotl(x, y) +# define ANGLE_ROTL64(x, y) _rotl64(x, y) +# define ANGLE_ROTR16(x, y) _rotr16(x, y) + +#elif defined(__clang__) && ANGLE_HAS_BUILTIN(__builtin_rotateleft32) && \ + ANGLE_HAS_BUILTIN(__builtin_rotateleft64) && ANGLE_HAS_BUILTIN(__builtin_rotateright16) + +# define ANGLE_ROTL(x, y) __builtin_rotateleft32(x, y) +# define ANGLE_ROTL64(x, y) __builtin_rotateleft64(x, y) +# define ANGLE_ROTR16(x, y) __builtin_rotateright16(x, y) + +#else + +inline uint32_t RotL(uint32_t x, int8_t r) +{ + return (x << r) | (x >> (32 - r)); +} + +inline uint64_t RotL64(uint64_t x, int8_t r) +{ + return (x << r) | (x >> (64 - r)); +} + +inline uint16_t RotR16(uint16_t x, int8_t r) +{ + return (x >> r) | (x << (16 - r)); +} + +# define ANGLE_ROTL(x, y) ::rx::RotL(x, y) +# define ANGLE_ROTL64(x, y) ::rx::RotL64(x, y) +# define ANGLE_ROTR16(x, y) ::rx::RotR16(x, y) + +#endif // namespace rx + +constexpr unsigned int Log2(unsigned int bytes) +{ + return bytes == 1 ? 0 : (1 + Log2(bytes / 2)); +} +} // namespace rx + +#endif // COMMON_MATHUTIL_H_ diff --git a/gfx/angle/checkout/src/common/matrix_utils.cpp b/gfx/angle/checkout/src/common/matrix_utils.cpp new file mode 100644 index 0000000000..59ab4ca437 --- /dev/null +++ b/gfx/angle/checkout/src/common/matrix_utils.cpp @@ -0,0 +1,285 @@ +// +// Copyright 2018 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// matrix_utils.cpp: Contains implementations for Mat4 methods. + +#include "common/matrix_utils.h" + +namespace angle +{ + +Mat4::Mat4() : Mat4(1.f, 0.f, 0.f, 0.f, 0.f, 1.f, 0.f, 0.f, 0.f, 0.f, 1.f, 0.f, 0.f, 0.f, 0.f, 1.f) +{} + +Mat4::Mat4(const Matrix generalMatrix) : Matrix(std::vector(16, 0), 4, 4) +{ + unsigned int minCols = std::min((unsigned int)4, generalMatrix.columns()); + unsigned int minRows = std::min((unsigned int)4, generalMatrix.rows()); + for (unsigned int i = 0; i < minCols; i++) + { + for (unsigned int j = 0; j < minRows; j++) + { + mElements[j * minCols + i] = generalMatrix.at(j, i); + } + } +} + +Mat4::Mat4(const std::vector &elements) : Matrix(elements, 4) {} + +Mat4::Mat4(const float *elements) : Matrix(elements, 4) {} + +Mat4::Mat4(float m00, + float m01, + float m02, + float m03, + float m10, + float m11, + float m12, + float m13, + float m20, + float m21, + float m22, + float m23, + float m30, + float m31, + float m32, + float m33) + : Matrix(std::vector(16, 0), 4, 4) +{ + mElements[0] = m00; + mElements[1] = m01; + mElements[2] = m02; + mElements[3] = m03; + mElements[4] = m10; + mElements[5] = m11; + mElements[6] = m12; + mElements[7] = m13; + mElements[8] = m20; + mElements[9] = m21; + mElements[10] = m22; + mElements[11] = m23; + mElements[12] = m30; + mElements[13] = m31; + mElements[14] = m32; + mElements[15] = m33; +} + +// static +Mat4 Mat4::Rotate(float angle, const Vector3 &axis) +{ + auto axis_normalized = axis.normalized(); + float angle_radians = angle * (3.14159265358979323f / 180.0f); + float c = cos(angle_radians); + float ci = 1.f - c; + float s = sin(angle_radians); + + float x = axis_normalized.x(); + float y = axis_normalized.y(); + float z = axis_normalized.z(); + + float x2 = x * x; + float y2 = y * y; + float z2 = z * z; + + float xy = x * y; + float yz = y * z; + float zx = z * x; + + float r00 = c + ci * x2; + float r01 = ci * xy + s * z; + float r02 = ci * zx - s * y; + float r03 = 0.f; + + float r10 = ci * xy - s * z; + float r11 = c + ci * y2; + float r12 = ci * yz + s * x; + float r13 = 0.f; + + float r20 = ci * zx + s * y; + float r21 = ci * yz - s * x; + float r22 = c + ci * z2; + float r23 = 0.f; + + float r30 = 0.f; + float r31 = 0.f; + float r32 = 0.f; + float r33 = 1.f; + + return Mat4(r00, r01, r02, r03, r10, r11, r12, r13, r20, r21, r22, r23, r30, r31, r32, r33); +} + +// static +Mat4 Mat4::Translate(const Vector3 &t) +{ + float r00 = 1.f; + float r01 = 0.f; + float r02 = 0.f; + float r03 = 0.f; + + float r10 = 0.f; + float r11 = 1.f; + float r12 = 0.f; + float r13 = 0.f; + + float r20 = 0.f; + float r21 = 0.f; + float r22 = 1.f; + float r23 = 0.f; + + float r30 = t.x(); + float r31 = t.y(); + float r32 = t.z(); + float r33 = 1.f; + + return Mat4(r00, r01, r02, r03, r10, r11, r12, r13, r20, r21, r22, r23, r30, r31, r32, r33); +} + +// static +Mat4 Mat4::Scale(const Vector3 &s) +{ + float r00 = s.x(); + float r01 = 0.f; + float r02 = 0.f; + float r03 = 0.f; + + float r10 = 0.f; + float r11 = s.y(); + float r12 = 0.f; + float r13 = 0.f; + + float r20 = 0.f; + float r21 = 0.f; + float r22 = s.z(); + float r23 = 0.f; + + float r30 = 0.f; + float r31 = 0.f; + float r32 = 0.f; + float r33 = 1.f; + + return Mat4(r00, r01, r02, r03, r10, r11, r12, r13, r20, r21, r22, r23, r30, r31, r32, r33); +} + +// static +Mat4 Mat4::Frustum(float l, float r, float b, float t, float n, float f) +{ + float nn = 2.f * n; + float fpn = f + n; + float fmn = f - n; + float tpb = t + b; + float tmb = t - b; + float rpl = r + l; + float rml = r - l; + + float r00 = nn / rml; + float r01 = 0.f; + float r02 = 0.f; + float r03 = 0.f; + + float r10 = 0.f; + float r11 = nn / tmb; + float r12 = 0.f; + float r13 = 0.f; + + float r20 = rpl / rml; + float r21 = tpb / tmb; + float r22 = -fpn / fmn; + float r23 = -1.f; + + float r30 = 0.f; + float r31 = 0.f; + float r32 = -nn * f / fmn; + float r33 = 0.f; + + return Mat4(r00, r01, r02, r03, r10, r11, r12, r13, r20, r21, r22, r23, r30, r31, r32, r33); +} + +// static +Mat4 Mat4::Perspective(float fov, float aspectRatio, float n, float f) +{ + const float frustumHeight = tanf(static_cast(fov / 360.0f * 3.14159265358979323)) * n; + const float frustumWidth = frustumHeight * aspectRatio; + return Frustum(-frustumWidth, frustumWidth, -frustumHeight, frustumHeight, n, f); +} + +// static +Mat4 Mat4::Ortho(float l, float r, float b, float t, float n, float f) +{ + float fpn = f + n; + float fmn = f - n; + float tpb = t + b; + float tmb = t - b; + float rpl = r + l; + float rml = r - l; + + float r00 = 2.f / rml; + float r01 = 0.f; + float r02 = 0.f; + float r03 = 0.f; + + float r10 = 0.f; + float r11 = 2.f / tmb; + float r12 = 0.f; + float r13 = 0.f; + + float r20 = 0.f; + float r21 = 0.f; + float r22 = -2.f / fmn; + float r23 = 0.f; + + float r30 = -rpl / rml; + float r31 = -tpb / tmb; + float r32 = -fpn / fmn; + float r33 = 1.f; + + return Mat4(r00, r01, r02, r03, r10, r11, r12, r13, r20, r21, r22, r23, r30, r31, r32, r33); +} + +Mat4 Mat4::product(const Mat4 &m) +{ + const float *a = mElements.data(); + const float *b = m.mElements.data(); + + return Mat4(a[0] * b[0] + a[4] * b[1] + a[8] * b[2] + a[12] * b[3], + a[1] * b[0] + a[5] * b[1] + a[9] * b[2] + a[13] * b[3], + a[2] * b[0] + a[6] * b[1] + a[10] * b[2] + a[14] * b[3], + a[3] * b[0] + a[7] * b[1] + a[11] * b[2] + a[15] * b[3], + + a[0] * b[4] + a[4] * b[5] + a[8] * b[6] + a[12] * b[7], + a[1] * b[4] + a[5] * b[5] + a[9] * b[6] + a[13] * b[7], + a[2] * b[4] + a[6] * b[5] + a[10] * b[6] + a[14] * b[7], + a[3] * b[4] + a[7] * b[5] + a[11] * b[6] + a[15] * b[7], + + a[0] * b[8] + a[4] * b[9] + a[8] * b[10] + a[12] * b[11], + a[1] * b[8] + a[5] * b[9] + a[9] * b[10] + a[13] * b[11], + a[2] * b[8] + a[6] * b[9] + a[10] * b[10] + a[14] * b[11], + a[3] * b[8] + a[7] * b[9] + a[11] * b[10] + a[15] * b[11], + + a[0] * b[12] + a[4] * b[13] + a[8] * b[14] + a[12] * b[15], + a[1] * b[12] + a[5] * b[13] + a[9] * b[14] + a[13] * b[15], + a[2] * b[12] + a[6] * b[13] + a[10] * b[14] + a[14] * b[15], + a[3] * b[12] + a[7] * b[13] + a[11] * b[14] + a[15] * b[15]); +} + +Vector4 Mat4::product(const Vector4 &b) +{ + return Vector4( + mElements[0] * b.x() + mElements[4] * b.y() + mElements[8] * b.z() + mElements[12] * b.w(), + mElements[1] * b.x() + mElements[5] * b.y() + mElements[9] * b.z() + mElements[13] * b.w(), + mElements[2] * b.x() + mElements[6] * b.y() + mElements[10] * b.z() + mElements[14] * b.w(), + mElements[3] * b.x() + mElements[7] * b.y() + mElements[11] * b.z() + + mElements[15] * b.w()); +} + +void Mat4::dump() +{ + printf("[ %f %f %f %f ]\n", mElements[0], mElements[4], mElements[8], mElements[12]); + printf("[ %f %f %f %f ]\n", mElements[1], mElements[5], mElements[9], mElements[13]); + printf("[ %f %f %f %f ]\n", mElements[2], mElements[6], mElements[10], mElements[14]); + printf("[ %f %f %f %f ]\n", mElements[3], mElements[7], mElements[11], mElements[15]); +} + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/matrix_utils.h b/gfx/angle/checkout/src/common/matrix_utils.h new file mode 100644 index 0000000000..7cca7a9461 --- /dev/null +++ b/gfx/angle/checkout/src/common/matrix_utils.h @@ -0,0 +1,424 @@ +// +// Copyright 2015 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// Matrix: +// Utility class implementing various matrix operations. +// Supports matrices with minimum 2 and maximum 4 number of rows/columns. +// +// TODO: Check if we can merge Matrix.h in sample_util with this and replace it with this +// implementation. +// TODO: Rename this file to Matrix.h once we remove Matrix.h in sample_util. + +#ifndef COMMON_MATRIX_UTILS_H_ +#define COMMON_MATRIX_UTILS_H_ + +#include + +#include "common/debug.h" +#include "common/mathutil.h" +#include "common/vector_utils.h" + +namespace angle +{ + +template +class Matrix +{ + public: + Matrix(const std::vector &elements, const unsigned int numRows, const unsigned int numCols) + : mElements(elements), mRows(numRows), mCols(numCols) + { + ASSERT(rows() >= 1 && rows() <= 4); + ASSERT(columns() >= 1 && columns() <= 4); + } + + Matrix(const std::vector &elements, const unsigned int size) + : mElements(elements), mRows(size), mCols(size) + { + ASSERT(rows() >= 1 && rows() <= 4); + ASSERT(columns() >= 1 && columns() <= 4); + } + + Matrix(const T *elements, const unsigned int size) : mRows(size), mCols(size) + { + ASSERT(rows() >= 1 && rows() <= 4); + ASSERT(columns() >= 1 && columns() <= 4); + for (size_t i = 0; i < size * size; i++) + mElements.push_back(elements[i]); + } + + const T &operator()(const unsigned int rowIndex, const unsigned int columnIndex) const + { + ASSERT(rowIndex < mRows); + ASSERT(columnIndex < mCols); + return mElements[rowIndex * columns() + columnIndex]; + } + + T &operator()(const unsigned int rowIndex, const unsigned int columnIndex) + { + ASSERT(rowIndex < mRows); + ASSERT(columnIndex < mCols); + return mElements[rowIndex * columns() + columnIndex]; + } + + const T &at(const unsigned int rowIndex, const unsigned int columnIndex) const + { + ASSERT(rowIndex < mRows); + ASSERT(columnIndex < mCols); + return operator()(rowIndex, columnIndex); + } + + Matrix operator*(const Matrix &m) + { + ASSERT(columns() == m.rows()); + + unsigned int resultRows = rows(); + unsigned int resultCols = m.columns(); + Matrix result(std::vector(resultRows * resultCols), resultRows, resultCols); + for (unsigned int i = 0; i < resultRows; i++) + { + for (unsigned int j = 0; j < resultCols; j++) + { + T tmp = 0.0f; + for (unsigned int k = 0; k < columns(); k++) + tmp += at(i, k) * m(k, j); + result(i, j) = tmp; + } + } + + return result; + } + + void operator*=(const Matrix &m) + { + ASSERT(columns() == m.rows()); + Matrix res = (*this) * m; + size_t numElts = res.elements().size(); + mElements.resize(numElts); + memcpy(mElements.data(), res.data(), numElts * sizeof(float)); + } + + bool operator==(const Matrix &m) const + { + ASSERT(columns() == m.columns()); + ASSERT(rows() == m.rows()); + return mElements == m.elements(); + } + + bool operator!=(const Matrix &m) const { return !(mElements == m.elements()); } + + bool nearlyEqual(T epsilon, const Matrix &m) const + { + ASSERT(columns() == m.columns()); + ASSERT(rows() == m.rows()); + const auto &otherElts = m.elements(); + for (size_t i = 0; i < otherElts.size(); i++) + { + if ((mElements[i] - otherElts[i] > epsilon) && (otherElts[i] - mElements[i] > epsilon)) + return false; + } + return true; + } + + unsigned int size() const + { + ASSERT(rows() == columns()); + return rows(); + } + + unsigned int rows() const { return mRows; } + + unsigned int columns() const { return mCols; } + + std::vector elements() const { return mElements; } + T *data() { return mElements.data(); } + const T *constData() const { return mElements.data(); } + + Matrix compMult(const Matrix &mat1) const + { + Matrix result(std::vector(mElements.size()), rows(), columns()); + for (unsigned int i = 0; i < rows(); i++) + { + for (unsigned int j = 0; j < columns(); j++) + { + T lhs = at(i, j); + T rhs = mat1(i, j); + result(i, j) = rhs * lhs; + } + } + + return result; + } + + Matrix outerProduct(const Matrix &mat1) const + { + unsigned int cols = mat1.columns(); + Matrix result(std::vector(rows() * cols), rows(), cols); + for (unsigned int i = 0; i < rows(); i++) + for (unsigned int j = 0; j < cols; j++) + result(i, j) = at(i, 0) * mat1(0, j); + + return result; + } + + Matrix transpose() const + { + Matrix result(std::vector(mElements.size()), columns(), rows()); + for (unsigned int i = 0; i < columns(); i++) + for (unsigned int j = 0; j < rows(); j++) + result(i, j) = at(j, i); + + return result; + } + + T determinant() const + { + ASSERT(rows() == columns()); + + switch (size()) + { + case 2: + return at(0, 0) * at(1, 1) - at(0, 1) * at(1, 0); + + case 3: + return at(0, 0) * at(1, 1) * at(2, 2) + at(0, 1) * at(1, 2) * at(2, 0) + + at(0, 2) * at(1, 0) * at(2, 1) - at(0, 2) * at(1, 1) * at(2, 0) - + at(0, 1) * at(1, 0) * at(2, 2) - at(0, 0) * at(1, 2) * at(2, 1); + + case 4: + { + const float minorMatrices[4][3 * 3] = {{ + at(1, 1), + at(2, 1), + at(3, 1), + at(1, 2), + at(2, 2), + at(3, 2), + at(1, 3), + at(2, 3), + at(3, 3), + }, + { + at(1, 0), + at(2, 0), + at(3, 0), + at(1, 2), + at(2, 2), + at(3, 2), + at(1, 3), + at(2, 3), + at(3, 3), + }, + { + at(1, 0), + at(2, 0), + at(3, 0), + at(1, 1), + at(2, 1), + at(3, 1), + at(1, 3), + at(2, 3), + at(3, 3), + }, + { + at(1, 0), + at(2, 0), + at(3, 0), + at(1, 1), + at(2, 1), + at(3, 1), + at(1, 2), + at(2, 2), + at(3, 2), + }}; + return at(0, 0) * Matrix(minorMatrices[0], 3).determinant() - + at(0, 1) * Matrix(minorMatrices[1], 3).determinant() + + at(0, 2) * Matrix(minorMatrices[2], 3).determinant() - + at(0, 3) * Matrix(minorMatrices[3], 3).determinant(); + } + + default: + UNREACHABLE(); + break; + } + + return T(); + } + + Matrix inverse() const + { + ASSERT(rows() == columns()); + + Matrix cof(std::vector(mElements.size()), rows(), columns()); + switch (size()) + { + case 2: + cof(0, 0) = at(1, 1); + cof(0, 1) = -at(1, 0); + cof(1, 0) = -at(0, 1); + cof(1, 1) = at(0, 0); + break; + + case 3: + cof(0, 0) = at(1, 1) * at(2, 2) - at(2, 1) * at(1, 2); + cof(0, 1) = -(at(1, 0) * at(2, 2) - at(2, 0) * at(1, 2)); + cof(0, 2) = at(1, 0) * at(2, 1) - at(2, 0) * at(1, 1); + cof(1, 0) = -(at(0, 1) * at(2, 2) - at(2, 1) * at(0, 2)); + cof(1, 1) = at(0, 0) * at(2, 2) - at(2, 0) * at(0, 2); + cof(1, 2) = -(at(0, 0) * at(2, 1) - at(2, 0) * at(0, 1)); + cof(2, 0) = at(0, 1) * at(1, 2) - at(1, 1) * at(0, 2); + cof(2, 1) = -(at(0, 0) * at(1, 2) - at(1, 0) * at(0, 2)); + cof(2, 2) = at(0, 0) * at(1, 1) - at(1, 0) * at(0, 1); + break; + + case 4: + cof(0, 0) = at(1, 1) * at(2, 2) * at(3, 3) + at(2, 1) * at(3, 2) * at(1, 3) + + at(3, 1) * at(1, 2) * at(2, 3) - at(1, 1) * at(3, 2) * at(2, 3) - + at(2, 1) * at(1, 2) * at(3, 3) - at(3, 1) * at(2, 2) * at(1, 3); + cof(0, 1) = -(at(1, 0) * at(2, 2) * at(3, 3) + at(2, 0) * at(3, 2) * at(1, 3) + + at(3, 0) * at(1, 2) * at(2, 3) - at(1, 0) * at(3, 2) * at(2, 3) - + at(2, 0) * at(1, 2) * at(3, 3) - at(3, 0) * at(2, 2) * at(1, 3)); + cof(0, 2) = at(1, 0) * at(2, 1) * at(3, 3) + at(2, 0) * at(3, 1) * at(1, 3) + + at(3, 0) * at(1, 1) * at(2, 3) - at(1, 0) * at(3, 1) * at(2, 3) - + at(2, 0) * at(1, 1) * at(3, 3) - at(3, 0) * at(2, 1) * at(1, 3); + cof(0, 3) = -(at(1, 0) * at(2, 1) * at(3, 2) + at(2, 0) * at(3, 1) * at(1, 2) + + at(3, 0) * at(1, 1) * at(2, 2) - at(1, 0) * at(3, 1) * at(2, 2) - + at(2, 0) * at(1, 1) * at(3, 2) - at(3, 0) * at(2, 1) * at(1, 2)); + cof(1, 0) = -(at(0, 1) * at(2, 2) * at(3, 3) + at(2, 1) * at(3, 2) * at(0, 3) + + at(3, 1) * at(0, 2) * at(2, 3) - at(0, 1) * at(3, 2) * at(2, 3) - + at(2, 1) * at(0, 2) * at(3, 3) - at(3, 1) * at(2, 2) * at(0, 3)); + cof(1, 1) = at(0, 0) * at(2, 2) * at(3, 3) + at(2, 0) * at(3, 2) * at(0, 3) + + at(3, 0) * at(0, 2) * at(2, 3) - at(0, 0) * at(3, 2) * at(2, 3) - + at(2, 0) * at(0, 2) * at(3, 3) - at(3, 0) * at(2, 2) * at(0, 3); + cof(1, 2) = -(at(0, 0) * at(2, 1) * at(3, 3) + at(2, 0) * at(3, 1) * at(0, 3) + + at(3, 0) * at(0, 1) * at(2, 3) - at(0, 0) * at(3, 1) * at(2, 3) - + at(2, 0) * at(0, 1) * at(3, 3) - at(3, 0) * at(2, 1) * at(0, 3)); + cof(1, 3) = at(0, 0) * at(2, 1) * at(3, 2) + at(2, 0) * at(3, 1) * at(0, 2) + + at(3, 0) * at(0, 1) * at(2, 2) - at(0, 0) * at(3, 1) * at(2, 2) - + at(2, 0) * at(0, 1) * at(3, 2) - at(3, 0) * at(2, 1) * at(0, 2); + cof(2, 0) = at(0, 1) * at(1, 2) * at(3, 3) + at(1, 1) * at(3, 2) * at(0, 3) + + at(3, 1) * at(0, 2) * at(1, 3) - at(0, 1) * at(3, 2) * at(1, 3) - + at(1, 1) * at(0, 2) * at(3, 3) - at(3, 1) * at(1, 2) * at(0, 3); + cof(2, 1) = -(at(0, 0) * at(1, 2) * at(3, 3) + at(1, 0) * at(3, 2) * at(0, 3) + + at(3, 0) * at(0, 2) * at(1, 3) - at(0, 0) * at(3, 2) * at(1, 3) - + at(1, 0) * at(0, 2) * at(3, 3) - at(3, 0) * at(1, 2) * at(0, 3)); + cof(2, 2) = at(0, 0) * at(1, 1) * at(3, 3) + at(1, 0) * at(3, 1) * at(0, 3) + + at(3, 0) * at(0, 1) * at(1, 3) - at(0, 0) * at(3, 1) * at(1, 3) - + at(1, 0) * at(0, 1) * at(3, 3) - at(3, 0) * at(1, 1) * at(0, 3); + cof(2, 3) = -(at(0, 0) * at(1, 1) * at(3, 2) + at(1, 0) * at(3, 1) * at(0, 2) + + at(3, 0) * at(0, 1) * at(1, 2) - at(0, 0) * at(3, 1) * at(1, 2) - + at(1, 0) * at(0, 1) * at(3, 2) - at(3, 0) * at(1, 1) * at(0, 2)); + cof(3, 0) = -(at(0, 1) * at(1, 2) * at(2, 3) + at(1, 1) * at(2, 2) * at(0, 3) + + at(2, 1) * at(0, 2) * at(1, 3) - at(0, 1) * at(2, 2) * at(1, 3) - + at(1, 1) * at(0, 2) * at(2, 3) - at(2, 1) * at(1, 2) * at(0, 3)); + cof(3, 1) = at(0, 0) * at(1, 2) * at(2, 3) + at(1, 0) * at(2, 2) * at(0, 3) + + at(2, 0) * at(0, 2) * at(1, 3) - at(0, 0) * at(2, 2) * at(1, 3) - + at(1, 0) * at(0, 2) * at(2, 3) - at(2, 0) * at(1, 2) * at(0, 3); + cof(3, 2) = -(at(0, 0) * at(1, 1) * at(2, 3) + at(1, 0) * at(2, 1) * at(0, 3) + + at(2, 0) * at(0, 1) * at(1, 3) - at(0, 0) * at(2, 1) * at(1, 3) - + at(1, 0) * at(0, 1) * at(2, 3) - at(2, 0) * at(1, 1) * at(0, 3)); + cof(3, 3) = at(0, 0) * at(1, 1) * at(2, 2) + at(1, 0) * at(2, 1) * at(0, 2) + + at(2, 0) * at(0, 1) * at(1, 2) - at(0, 0) * at(2, 1) * at(1, 2) - + at(1, 0) * at(0, 1) * at(2, 2) - at(2, 0) * at(1, 1) * at(0, 2); + break; + + default: + UNREACHABLE(); + break; + } + + // The inverse of A is the transpose of the cofactor matrix times the reciprocal of the + // determinant of A. + Matrix adjugateMatrix(cof.transpose()); + T det = determinant(); + Matrix result(std::vector(mElements.size()), rows(), columns()); + for (unsigned int i = 0; i < rows(); i++) + for (unsigned int j = 0; j < columns(); j++) + result(i, j) = (det != static_cast(0)) ? adjugateMatrix(i, j) / det : T(); + + return result; + } + + void setToIdentity() + { + ASSERT(rows() == columns()); + + const auto one = T(1); + const auto zero = T(0); + + for (auto &e : mElements) + e = zero; + + for (unsigned int i = 0; i < rows(); ++i) + { + const auto pos = i * columns() + (i % columns()); + mElements[pos] = one; + } + } + + template + static void setToIdentity(T (&matrix)[Size]) + { + static_assert(gl::iSquareRoot() != 0, "Matrix is not square."); + + const auto cols = gl::iSquareRoot(); + const auto one = T(1); + const auto zero = T(0); + + for (auto &e : matrix) + e = zero; + + for (unsigned int i = 0; i < cols; ++i) + { + const auto pos = i * cols + (i % cols); + matrix[pos] = one; + } + } + + protected: + std::vector mElements; + unsigned int mRows; + unsigned int mCols; +}; + +class Mat4 : public Matrix +{ + public: + Mat4(); + Mat4(const Matrix generalMatrix); + Mat4(const std::vector &elements); + Mat4(const float *elements); + Mat4(float m00, + float m01, + float m02, + float m03, + float m10, + float m11, + float m12, + float m13, + float m20, + float m21, + float m22, + float m23, + float m30, + float m31, + float m32, + float m33); + + static Mat4 Rotate(float angle, const Vector3 &axis); + static Mat4 Translate(const Vector3 &t); + static Mat4 Scale(const Vector3 &s); + static Mat4 Frustum(float l, float r, float b, float t, float n, float f); + static Mat4 Perspective(float fov, float aspectRatio, float n, float f); + static Mat4 Ortho(float l, float r, float b, float t, float n, float f); + + Mat4 product(const Mat4 &m); + Vector4 product(const Vector4 &b); + void dump(); +}; + +} // namespace angle + +#endif // COMMON_MATRIX_UTILS_H_ diff --git a/gfx/angle/checkout/src/common/platform.h b/gfx/angle/checkout/src/common/platform.h new file mode 100644 index 0000000000..77267ab680 --- /dev/null +++ b/gfx/angle/checkout/src/common/platform.h @@ -0,0 +1,209 @@ +// +// Copyright 2014 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// platform.h: Operating system specific includes and defines. + +#ifndef COMMON_PLATFORM_H_ +#define COMMON_PLATFORM_H_ + +#if defined(_WIN32) +# define ANGLE_PLATFORM_WINDOWS 1 +#elif defined(__Fuchsia__) +# define ANGLE_PLATFORM_FUCHSIA 1 +# define ANGLE_PLATFORM_POSIX 1 +#elif defined(__APPLE__) +# define ANGLE_PLATFORM_APPLE 1 +# define ANGLE_PLATFORM_POSIX 1 +#elif defined(ANDROID) +# define ANGLE_PLATFORM_ANDROID 1 +# define ANGLE_PLATFORM_POSIX 1 +#elif defined(__ggp__) +# define ANGLE_PLATFORM_GGP 1 +# define ANGLE_PLATFORM_POSIX 1 +#elif defined(__linux__) || defined(EMSCRIPTEN) +# define ANGLE_PLATFORM_LINUX 1 +# define ANGLE_PLATFORM_POSIX 1 +#elif defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || \ + defined(__DragonFly__) || defined(__sun) || defined(__GLIBC__) || defined(__GNU__) || \ + defined(__QNX__) || defined(__Fuchsia__) || defined(__HAIKU__) +# define ANGLE_PLATFORM_POSIX 1 +#else +# error Unsupported platform. +#endif + +#ifdef ANGLE_PLATFORM_WINDOWS +# ifndef STRICT +# define STRICT 1 +# endif +# ifndef WIN32_LEAN_AND_MEAN +# define WIN32_LEAN_AND_MEAN 1 +# endif +# ifndef NOMINMAX +# define NOMINMAX 1 +# endif + +# include + +# if defined(WINAPI_FAMILY) && (WINAPI_FAMILY != WINAPI_FAMILY_DESKTOP_APP) +# define ANGLE_ENABLE_WINDOWS_UWP 1 +# endif + +# if defined(ANGLE_ENABLE_D3D9) +# include +# include +# endif + +// Include D3D11 headers when OpenGL is enabled on Windows for interop extensions. +# if defined(ANGLE_ENABLE_D3D11) || defined(ANGLE_ENABLE_OPENGL) +# include +# include +# include +# include +# include +# include +# include +# include +# include +# endif + +# if defined(ANGLE_ENABLE_D3D9) || defined(ANGLE_ENABLE_D3D11) +# include +# endif + +# if defined(ANGLE_ENABLE_WINDOWS_UWP) +# include +# if defined(_DEBUG) +# include +# include +# endif +# endif + +// Include to ensure tests related files can be built when building +// vulkan only backend ANGLE on windows. +# if defined(ANGLE_ENABLE_VULKAN) +# include +# endif + +// Macros 'near', 'far', 'NEAR' and 'FAR' are defined by 'shared/minwindef.h' in the Windows SDK. +// Macros 'near' and 'far' are empty. They are not used by other Windows headers and are undefined +// here to avoid identifier conflicts. Macros 'NEAR' and 'FAR' contain 'near' and 'far'. They are +// used by other Windows headers and are cleared here to avoid compilation errors. +# undef near +# undef far +# undef NEAR +# undef FAR +# define NEAR +# define FAR +#endif + +#if defined(_MSC_VER) && !defined(_M_ARM) && !defined(_M_ARM64) +# include +# define ANGLE_USE_SSE +#elif defined(__GNUC__) && (defined(__x86_64__) || defined(__i386__)) +# include +# define ANGLE_USE_SSE +#endif + +// Mips and arm devices need to include stddef for size_t. +#if defined(__mips__) || defined(__arm__) || defined(__aarch64__) +# include +#endif + +// The MemoryBarrier function name collides with a macro under Windows +// We will undef the macro so that the function name does not get replaced +#undef MemoryBarrier + +// Macro for hinting that an expression is likely to be true/false. +#if !defined(ANGLE_LIKELY) || !defined(ANGLE_UNLIKELY) +# if defined(__GNUC__) || defined(__clang__) +# define ANGLE_LIKELY(x) __builtin_expect(!!(x), 1) +# define ANGLE_UNLIKELY(x) __builtin_expect(!!(x), 0) +# else +# define ANGLE_LIKELY(x) (x) +# define ANGLE_UNLIKELY(x) (x) +# endif // defined(__GNUC__) || defined(__clang__) +#endif // !defined(ANGLE_LIKELY) || !defined(ANGLE_UNLIKELY) + +#ifdef ANGLE_PLATFORM_APPLE +# include +# if TARGET_OS_OSX +# define ANGLE_PLATFORM_MACOS 1 +# elif TARGET_OS_IPHONE +# define ANGLE_PLATFORM_IOS 1 +# if TARGET_OS_SIMULATOR +# define ANGLE_PLATFORM_IOS_SIMULATOR 1 +# endif +# if TARGET_OS_MACCATALYST +# define ANGLE_PLATFORM_MACCATALYST 1 +# endif +# elif TARGET_OS_WATCH +# define ANGLE_PLATFORM_WATCHOS 1 +# if TARGET_OS_SIMULATOR +# define ANGLE_PLATFORM_IOS_SIMULATOR 1 +# endif +# elif TARGET_OS_TV +# define ANGLE_PLATFORM_APPLETV 1 +# if TARGET_OS_SIMULATOR +# define ANGLE_PLATFORM_IOS_SIMULATOR 1 +# endif +# endif +# // This might be useful globally. At the moment it is used +# // to differentiate MacCatalyst on Intel and Apple Silicon. +# if defined(__arm64__) || defined(__aarch64__) +# define ANGLE_CPU_ARM64 1 +# endif +# // EAGL should be enabled on iOS, but not Mac Catalyst unless it is running on Apple Silicon. +# if (defined(ANGLE_PLATFORM_IOS) && !defined(ANGLE_PLATFORM_MACCATALYST)) || \ + (defined(ANGLE_PLATFORM_MACCATALYST) && defined(ANGLE_CPU_ARM64)) +# define ANGLE_ENABLE_EAGL +# endif +# // Identify Metal API >= what shipped on macOS Catalina. +# if (defined(ANGLE_PLATFORM_MACOS) && __MAC_OS_X_VERSION_MAX_ALLOWED >= 101500) || \ + (defined(ANGLE_PLATFORM_IOS) && __IPHONE_OS_VERSION_MAX_ALLOWED >= 130000) +# define ANGLE_WITH_MODERN_METAL_API 1 +# endif +#endif + +// Define ANGLE_WITH_ASAN macro. +#if defined(__has_feature) +# if __has_feature(address_sanitizer) +# define ANGLE_WITH_ASAN 1 +# endif +#endif + +// Define ANGLE_WITH_MSAN macro. +#if defined(__has_feature) +# if __has_feature(memory_sanitizer) +# define ANGLE_WITH_MSAN 1 +# endif +#endif + +// Define ANGLE_WITH_TSAN macro. +#if defined(__has_feature) +# if __has_feature(thread_sanitizer) +# define ANGLE_WITH_TSAN 1 +# endif +#endif + +// Define ANGLE_WITH_UBSAN macro. +#if defined(__has_feature) +# if __has_feature(undefined_behavior_sanitizer) +# define ANGLE_WITH_UBSAN 1 +# endif +#endif + +#if defined(ANGLE_WITH_ASAN) || defined(ANGLE_WITH_TSAN) || defined(ANGLE_WITH_UBSAN) +# define ANGLE_WITH_SANITIZER 1 +#endif // defined(ANGLE_WITH_ASAN) || defined(ANGLE_WITH_TSAN) || defined(ANGLE_WITH_UBSAN) + +#include +#if INTPTR_MAX == INT64_MAX +# define ANGLE_IS_64_BIT_CPU 1 +#else +# define ANGLE_IS_32_BIT_CPU 1 +#endif + +#endif // COMMON_PLATFORM_H_ diff --git a/gfx/angle/checkout/src/common/spirv/spirv_types.h b/gfx/angle/checkout/src/common/spirv/spirv_types.h new file mode 100644 index 0000000000..faf2174481 --- /dev/null +++ b/gfx/angle/checkout/src/common/spirv/spirv_types.h @@ -0,0 +1,133 @@ +// +// Copyright 2021 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// spirv_types.h: +// Strong types for SPIR-V Ids to prevent mistakes when using the builder and parser APIs. +// + +#ifndef COMMON_SPIRV_TYPES_H_ +#define COMMON_SPIRV_TYPES_H_ + +#include "common/FastVector.h" + +#include + +namespace angle +{ +namespace spirv +{ +template +class BoxedUint32 +{ + public: + BoxedUint32() : mValue{0} {} + explicit BoxedUint32(uint32_t value) : mValue{value} {} + template + T as() const + { + return T{mValue}; + } + BoxedUint32(const BoxedUint32 &other) = default; + BoxedUint32 &operator=(const BoxedUint32 &other) = default; + operator uint32_t() const { return mValue.value; } + bool operator==(const BoxedUint32 &other) const { return mValue.value == other.mValue.value; } + // Applicable to ids, which cannot be 0. + bool valid() const { return static_cast(mValue.value); } + + private: + Helper mValue; +}; + +struct IdRefHelper +{ + uint32_t value; +}; +struct LiteralIntegerHelper +{ + uint32_t value; +}; + +using IdRef = BoxedUint32; + +template <> +inline BoxedUint32::operator uint32_t() const +{ + ASSERT(valid()); + return mValue.value; +} + +// IdResult, IdResultType, IdMemorySemantics and IdScope are all translated as IdRef. This makes +// the type verification weaker, but stops the API from becoming tediously verbose. +using IdResult = IdRef; +using IdResultType = IdRef; +using IdMemorySemantics = IdRef; +using IdScope = IdRef; +using LiteralInteger = BoxedUint32; +using LiteralString = const char *; +// Note: In ANGLE's use cases, all literals fit in 32 bits. +using LiteralContextDependentNumber = LiteralInteger; +// TODO(syoussefi): To be made stronger when generating SPIR-V from the translator. +// http://anglebug.com/4889 +using LiteralExtInstInteger = LiteralInteger; + +struct PairLiteralIntegerIdRef +{ + LiteralInteger literal; + IdRef id; +}; + +struct PairIdRefLiteralInteger +{ + IdRef id; + LiteralInteger literal; +}; + +struct PairIdRefIdRef +{ + IdRef id1; + IdRef id2; +}; + +// Some instructions need 4 components. The drivers uniform struct in ANGLE has 8 fields. A value +// of 8 means almost no instruction would end up making dynamic allocations. Notable exceptions are +// user-defined structs/blocks and OpEntryPoint. +constexpr size_t kFastVectorSize = 8; + +template +using FastVectorHelper = angle::FastVector; + +using IdRefList = FastVectorHelper; +using LiteralIntegerList = FastVectorHelper; +using PairLiteralIntegerIdRefList = FastVectorHelper; +using PairIdRefLiteralIntegerList = FastVectorHelper; +using PairIdRefIdRefList = FastVectorHelper; + +// Id 0 is invalid in SPIR-V. +constexpr uint32_t kMinValidId = 1; + +// The SPIR-V blob is a sequence of uint32_t's +using Blob = std::vector; + +// Format of the SPIR-V header. +// SPIR-V 1.0 Table 1: First Words of Physical Layout +enum HeaderIndex +{ + kHeaderIndexMagic = 0, + kHeaderIndexVersion = 1, + kHeaderIndexGenerator = 2, + kHeaderIndexIndexBound = 3, + kHeaderIndexSchema = 4, + kHeaderIndexInstructions = 5, +}; + +// Returns whether SPIR-V is valid. Useful for ASSERTs. Automatically generates a warning if +// SPIR-V is not valid. +bool Validate(const Blob &blob); +void Print(const Blob &blob); + +} // namespace spirv +} // namespace angle + +#endif // COMMON_SPIRV_TYPES_H_ diff --git a/gfx/angle/checkout/src/common/string_utils.cpp b/gfx/angle/checkout/src/common/string_utils.cpp new file mode 100644 index 0000000000..192d82917c --- /dev/null +++ b/gfx/angle/checkout/src/common/string_utils.cpp @@ -0,0 +1,357 @@ +// +// Copyright 2015 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// string_utils: +// String helper functions. +// + +#include "common/string_utils.h" + +#include +#include +#include +#include +#include +#include + +#include "common/platform.h" +#include "common/system_utils.h" + +namespace +{ + +bool EndsWithSuffix(const char *str, + const size_t strLen, + const char *suffix, + const size_t suffixLen) +{ + return suffixLen <= strLen && strncmp(str + strLen - suffixLen, suffix, suffixLen) == 0; +} + +} // anonymous namespace + +namespace angle +{ + +const char kWhitespaceASCII[] = " \f\n\r\t\v"; + +std::vector SplitString(const std::string &input, + const std::string &delimiters, + WhitespaceHandling whitespace, + SplitResult resultType) +{ + std::vector result; + if (input.empty()) + { + return result; + } + + std::string::size_type start = 0; + while (start != std::string::npos) + { + auto end = input.find_first_of(delimiters, start); + + std::string piece; + if (end == std::string::npos) + { + piece = input.substr(start); + start = std::string::npos; + } + else + { + piece = input.substr(start, end - start); + start = end + 1; + } + + if (whitespace == TRIM_WHITESPACE) + { + piece = TrimString(piece, kWhitespaceASCII); + } + + if (resultType == SPLIT_WANT_ALL || !piece.empty()) + { + result.push_back(std::move(piece)); + } + } + + return result; +} + +void SplitStringAlongWhitespace(const std::string &input, std::vector *tokensOut) +{ + + std::istringstream stream(input); + std::string line; + + while (std::getline(stream, line)) + { + size_t prev = 0, pos; + while ((pos = line.find_first_of(kWhitespaceASCII, prev)) != std::string::npos) + { + if (pos > prev) + tokensOut->push_back(line.substr(prev, pos - prev)); + prev = pos + 1; + } + if (prev < line.length()) + tokensOut->push_back(line.substr(prev, std::string::npos)); + } +} + +std::string TrimString(const std::string &input, const std::string &trimChars) +{ + auto begin = input.find_first_not_of(trimChars); + if (begin == std::string::npos) + { + return ""; + } + + std::string::size_type end = input.find_last_not_of(trimChars); + if (end == std::string::npos) + { + return input.substr(begin); + } + + return input.substr(begin, end - begin + 1); +} + +std::string GetPrefix(const std::string &input, size_t offset, const char *delimiter) +{ + size_t match = input.find(delimiter, offset); + if (match == std::string::npos) + { + return input.substr(offset); + } + return input.substr(offset, match - offset); +} + +std::string GetPrefix(const std::string &input, size_t offset, char delimiter) +{ + size_t match = input.find(delimiter, offset); + if (match == std::string::npos) + { + return input.substr(offset); + } + return input.substr(offset, match - offset); +} + +bool HexStringToUInt(const std::string &input, unsigned int *uintOut) +{ + unsigned int offset = 0; + + if (input.size() >= 2 && input[0] == '0' && input[1] == 'x') + { + offset = 2u; + } + + // Simple validity check + if (input.find_first_not_of("0123456789ABCDEFabcdef", offset) != std::string::npos) + { + return false; + } + + std::stringstream inStream(input); + inStream >> std::hex >> *uintOut; + return !inStream.fail(); +} + +bool ReadFileToString(const std::string &path, std::string *stringOut) +{ + std::ifstream inFile(path.c_str()); + if (inFile.fail()) + { + return false; + } + + inFile.seekg(0, std::ios::end); + stringOut->reserve(static_cast(inFile.tellg())); + inFile.seekg(0, std::ios::beg); + + stringOut->assign(std::istreambuf_iterator(inFile), std::istreambuf_iterator()); + return !inFile.fail(); +} + +bool BeginsWith(const std::string &str, const std::string &prefix) +{ + return strncmp(str.c_str(), prefix.c_str(), prefix.length()) == 0; +} + +bool BeginsWith(const std::string &str, const char *prefix) +{ + return strncmp(str.c_str(), prefix, strlen(prefix)) == 0; +} + +bool BeginsWith(const char *str, const char *prefix) +{ + return strncmp(str, prefix, strlen(prefix)) == 0; +} + +bool BeginsWith(const std::string &str, const std::string &prefix, const size_t prefixLength) +{ + return strncmp(str.c_str(), prefix.c_str(), prefixLength) == 0; +} + +bool EndsWith(const std::string &str, const std::string &suffix) +{ + return EndsWithSuffix(str.c_str(), str.length(), suffix.c_str(), suffix.length()); +} + +bool EndsWith(const std::string &str, const char *suffix) +{ + return EndsWithSuffix(str.c_str(), str.length(), suffix, strlen(suffix)); +} + +bool EndsWith(const char *str, const char *suffix) +{ + return EndsWithSuffix(str, strlen(str), suffix, strlen(suffix)); +} + +bool ContainsToken(const std::string &tokenStr, char delimiter, const std::string &token) +{ + if (token.empty()) + { + return false; + } + // Compare token with all sub-strings terminated by delimiter or end of string + std::string::size_type start = 0u; + do + { + std::string::size_type end = tokenStr.find(delimiter, start); + if (end == std::string::npos) + { + end = tokenStr.length(); + } + const std::string::size_type length = end - start; + if (length == token.length() && tokenStr.compare(start, length, token) == 0) + { + return true; + } + start = end + 1u; + } while (start < tokenStr.size()); + return false; +} + +void ToLower(std::string *str) +{ + for (char &ch : *str) + { + ch = static_cast(::tolower(ch)); + } +} + +void ToUpper(std::string *str) +{ + for (char &ch : *str) + { + ch = static_cast(::toupper(ch)); + } +} + +bool ReplaceSubstring(std::string *str, + const std::string &substring, + const std::string &replacement) +{ + size_t replacePos = str->find(substring); + if (replacePos == std::string::npos) + { + return false; + } + str->replace(replacePos, substring.size(), replacement); + return true; +} + +int ReplaceAllSubstrings(std::string *str, + const std::string &substring, + const std::string &replacement) +{ + int count = 0; + while (ReplaceSubstring(str, substring, replacement)) + { + count++; + } + return count; +} + +std::string ToCamelCase(const std::string &str) +{ + std::string result; + + bool lastWasUnderscore = false; + for (char c : str) + { + if (c == '_') + { + lastWasUnderscore = true; + continue; + } + + if (lastWasUnderscore) + { + c = static_cast(std::toupper(c)); + lastWasUnderscore = false; + } + result += c; + } + + return result; +} + +std::vector GetStringsFromEnvironmentVarOrAndroidProperty(const char *varName, + const char *propertyName, + const char *separator) +{ + std::string environment = GetEnvironmentVarOrAndroidProperty(varName, propertyName); + return SplitString(environment, separator, TRIM_WHITESPACE, SPLIT_WANT_NONEMPTY); +} + +std::vector GetCachedStringsFromEnvironmentVarOrAndroidProperty( + const char *varName, + const char *propertyName, + const char *separator) +{ + std::string environment = GetEnvironmentVarOrAndroidProperty(varName, propertyName); + return SplitString(environment, separator, TRIM_WHITESPACE, SPLIT_WANT_NONEMPTY); +} + +// glob can have * as wildcard +bool NamesMatchWithWildcard(const char *glob, const char *name) +{ + // Find the first * in glob. + const char *firstWildcard = strchr(glob, '*'); + + // If there are no wildcards, match the strings precisely. + if (firstWildcard == nullptr) + { + return strcmp(glob, name) == 0; + } + + // Otherwise, match up to the wildcard first. + size_t preWildcardLen = firstWildcard - glob; + if (strncmp(glob, name, preWildcardLen) != 0) + { + return false; + } + + const char *postWildcardRef = glob + preWildcardLen + 1; + + // As a small optimization, if the wildcard is the last character in glob, accept the match + // already. + if (postWildcardRef[0] == '\0') + { + return true; + } + + // Try to match the wildcard with a number of characters. + for (size_t matchSize = 0; name[matchSize] != '\0'; ++matchSize) + { + if (NamesMatchWithWildcard(postWildcardRef, name + matchSize)) + { + return true; + } + } + + return false; +} + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/string_utils.h b/gfx/angle/checkout/src/common/string_utils.h new file mode 100644 index 0000000000..7be7efe983 --- /dev/null +++ b/gfx/angle/checkout/src/common/string_utils.h @@ -0,0 +1,125 @@ +// +// Copyright 2015 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// string_utils: +// String helper functions. +// + +#ifndef LIBANGLE_STRING_UTILS_H_ +#define LIBANGLE_STRING_UTILS_H_ + +#include +#include + +#include "common/Optional.h" + +namespace angle +{ + +extern const char kWhitespaceASCII[]; + +enum WhitespaceHandling +{ + KEEP_WHITESPACE, + TRIM_WHITESPACE, +}; + +enum SplitResult +{ + SPLIT_WANT_ALL, + SPLIT_WANT_NONEMPTY, +}; + +std::vector SplitString(const std::string &input, + const std::string &delimiters, + WhitespaceHandling whitespace, + SplitResult resultType); + +void SplitStringAlongWhitespace(const std::string &input, std::vector *tokensOut); + +std::string TrimString(const std::string &input, const std::string &trimChars); + +// Return the substring starting at offset and up to the first occurance of the |delimeter|. +std::string GetPrefix(const std::string &input, size_t offset, const char *delimiter); +std::string GetPrefix(const std::string &input, size_t offset, char delimiter); + +bool HexStringToUInt(const std::string &input, unsigned int *uintOut); + +bool ReadFileToString(const std::string &path, std::string *stringOut); + +// Check if the string str begins with the given prefix. +// The comparison is case sensitive. +bool BeginsWith(const std::string &str, const std::string &prefix); + +// Check if the string str begins with the given prefix. +// Prefix may not be NULL and needs to be NULL terminated. +// The comparison is case sensitive. +bool BeginsWith(const std::string &str, const char *prefix); + +// Check if the string str begins with the given prefix. +// str and prefix may not be NULL and need to be NULL terminated. +// The comparison is case sensitive. +bool BeginsWith(const char *str, const char *prefix); + +// Check if the string str begins with the first prefixLength characters of the given prefix. +// The length of the prefix string should be greater than or equal to prefixLength. +// The comparison is case sensitive. +bool BeginsWith(const std::string &str, const std::string &prefix, const size_t prefixLength); + +// Check if the string str ends with the given suffix. +// The comparison is case sensitive. +bool EndsWith(const std::string &str, const std::string &suffix); + +// Check if the string str ends with the given suffix. +// Suffix may not be NULL and needs to be NULL terminated. +// The comparison is case sensitive. +bool EndsWith(const std::string &str, const char *suffix); + +// Check if the string str ends with the given suffix. +// str and suffix may not be NULL and need to be NULL terminated. +// The comparison is case sensitive. +bool EndsWith(const char *str, const char *suffix); + +// Check if the given token string contains the given token. +// The tokens are separated by the given delimiter. +// The comparison is case sensitive. +bool ContainsToken(const std::string &tokenStr, char delimiter, const std::string &token); + +// Convert to lower-case. +void ToLower(std::string *str); + +// Convert to upper-case. +void ToUpper(std::string *str); + +// Replaces the substring 'substring' in 'str' with 'replacement'. Returns true if successful. +bool ReplaceSubstring(std::string *str, + const std::string &substring, + const std::string &replacement); + +// Replaces all substrings 'substring' in 'str' with 'replacement'. Returns count of replacements. +int ReplaceAllSubstrings(std::string *str, + const std::string &substring, + const std::string &replacement); + +// Takes a snake_case string and turns it into camelCase. +std::string ToCamelCase(const std::string &str); + +// Split up a string parsed from an environment variable. +std::vector GetStringsFromEnvironmentVarOrAndroidProperty(const char *varName, + const char *propertyName, + const char *separator); + +// Split up a string parsed from environment variable or via Android property, use cached result if +// available. +std::vector GetCachedStringsFromEnvironmentVarOrAndroidProperty( + const char *varName, + const char *propertyName, + const char *separator); + +// glob can have * as wildcard +bool NamesMatchWithWildcard(const char *glob, const char *name); +} // namespace angle + +#endif // LIBANGLE_STRING_UTILS_H_ diff --git a/gfx/angle/checkout/src/common/system_utils.cpp b/gfx/angle/checkout/src/common/system_utils.cpp new file mode 100644 index 0000000000..89b632bc17 --- /dev/null +++ b/gfx/angle/checkout/src/common/system_utils.cpp @@ -0,0 +1,267 @@ +// +// Copyright 2018 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// system_utils.cpp: Implementation of common functions + +#include "common/system_utils.h" +#include "common/debug.h" + +#include +#include + +#if defined(ANGLE_PLATFORM_ANDROID) +# include +#endif + +#if defined(ANGLE_PLATFORM_APPLE) +# include +# include +#endif + +namespace angle +{ +std::string GetExecutableName() +{ +#if defined(ANGLE_PLATFORM_ANDROID) && __ANDROID_API__ >= 21 + // Support for "getprogname" function in bionic was introduced in L (API level 21) + const char *executableName = getprogname(); + return (executableName) ? std::string(executableName) : "ANGLE"; +#else + std::string executableName = GetExecutablePath(); + size_t lastPathSepLoc = executableName.find_last_of(GetPathSeparator()); + return (lastPathSepLoc > 0 ? executableName.substr(lastPathSepLoc + 1, executableName.length()) + : "ANGLE"); +#endif // ANGLE_PLATFORM_ANDROID +} + +// On Android return value cached in the process environment, if none, call +// GetEnvironmentVarOrUnCachedAndroidProperty if not in environment. +std::string GetEnvironmentVarOrAndroidProperty(const char *variableName, const char *propertyName) +{ +#if defined(ANGLE_PLATFORM_ANDROID) && __ANDROID_API__ >= 21 + // Can't use GetEnvironmentVar here because that won't allow us to distinguish between the + // environment being set to an empty string vs. not set at all. + const char *variableValue = getenv(variableName); + if (variableValue != nullptr) + { + std::string value(variableValue); + return value; + } +#endif + return GetEnvironmentVarOrUnCachedAndroidProperty(variableName, propertyName); +} + +// On Android call out to 'getprop' on a shell to get an Android property. On desktop, return +// the value of the environment variable. +std::string GetEnvironmentVarOrUnCachedAndroidProperty(const char *variableName, + const char *propertyName) +{ +#if defined(ANGLE_PLATFORM_ANDROID) && __ANDROID_API__ >= 26 + std::string propertyValue; + + const prop_info *propertyInfo = __system_property_find(propertyName); + if (propertyInfo != nullptr) + { + __system_property_read_callback( + propertyInfo, + [](void *cookie, const char *, const char *value, unsigned) { + auto propertyValue = reinterpret_cast(cookie); + *propertyValue = value; + }, + &propertyValue); + } + + return propertyValue; +#else + // Return the environment variable's value. + return GetEnvironmentVar(variableName); +#endif // ANGLE_PLATFORM_ANDROID +} + +// Look up a property and add it to the application's environment. +// Adding to the env is a performance optimization, as getting properties is expensive. +// This should only be used in non-Release paths, i.e. when using FrameCapture or DebugUtils. +// It can cause race conditions in stress testing. See http://anglebug.com/6822 +std::string GetAndSetEnvironmentVarOrUnCachedAndroidProperty(const char *variableName, + const char *propertyName) +{ + std::string value = GetEnvironmentVarOrUnCachedAndroidProperty(variableName, propertyName); + +#if defined(ANGLE_PLATFORM_ANDROID) + if (!value.empty()) + { + // Set the environment variable with the value to improve future lookups (avoids + SetEnvironmentVar(variableName, value.c_str()); + } +#endif + + return value; +} + +bool GetBoolEnvironmentVar(const char *variableName) +{ + std::string envVarString = GetEnvironmentVar(variableName); + return (!envVarString.empty() && envVarString == "1"); +} + +bool PrependPathToEnvironmentVar(const char *variableName, const char *path) +{ + std::string oldValue = GetEnvironmentVar(variableName); + const char *newValue = nullptr; + std::string buf; + if (oldValue.empty()) + { + newValue = path; + } + else + { + buf = path; + buf += GetPathSeparatorForEnvironmentVar(); + buf += oldValue; + newValue = buf.c_str(); + } + return SetEnvironmentVar(variableName, newValue); +} + +bool IsFullPath(std::string dirName) +{ + if (dirName.find(GetRootDirectory()) == 0) + { + return true; + } + return false; +} + +std::string ConcatenatePath(std::string first, std::string second) +{ + if (first.empty()) + { + return second; + } + if (second.empty()) + { + return first; + } + if (IsFullPath(second)) + { + return second; + } + bool firstRedundantPathSeparator = first.find_last_of(GetPathSeparator()) == first.length() - 1; + bool secondRedundantPathSeparator = second.find(GetPathSeparator()) == 0; + if (firstRedundantPathSeparator && secondRedundantPathSeparator) + { + return first + second.substr(1); + } + else if (firstRedundantPathSeparator || secondRedundantPathSeparator) + { + return first + second; + } + return first + GetPathSeparator() + second; +} + +Optional CreateTemporaryFile() +{ + const Optional tempDir = GetTempDirectory(); + if (!tempDir.valid()) + return Optional::Invalid(); + + return CreateTemporaryFileInDirectory(tempDir.value()); +} + +PageFaultHandler::PageFaultHandler(PageFaultCallback callback) : mCallback(callback) {} +PageFaultHandler::~PageFaultHandler() {} + +Library *OpenSharedLibrary(const char *libraryName, SearchType searchType) +{ + void *libraryHandle = OpenSystemLibraryAndGetError(libraryName, searchType, nullptr); + return new Library(libraryHandle); +} + +Library *OpenSharedLibraryWithExtension(const char *libraryName, SearchType searchType) +{ + void *libraryHandle = + OpenSystemLibraryWithExtensionAndGetError(libraryName, searchType, nullptr); + return new Library(libraryHandle); +} + +Library *OpenSharedLibraryAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut) +{ + void *libraryHandle = OpenSystemLibraryAndGetError(libraryName, searchType, errorOut); + return new Library(libraryHandle); +} + +Library *OpenSharedLibraryWithExtensionAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut) +{ + void *libraryHandle = + OpenSystemLibraryWithExtensionAndGetError(libraryName, searchType, errorOut); + return new Library(libraryHandle); +} + +void *OpenSystemLibrary(const char *libraryName, SearchType searchType) +{ + return OpenSystemLibraryAndGetError(libraryName, searchType, nullptr); +} + +void *OpenSystemLibraryWithExtension(const char *libraryName, SearchType searchType) +{ + return OpenSystemLibraryWithExtensionAndGetError(libraryName, searchType, nullptr); +} + +void *OpenSystemLibraryAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut) +{ + std::string libraryWithExtension = std::string(libraryName) + "." + GetSharedLibraryExtension(); +#if ANGLE_PLATFORM_IOS + // On iOS, libraryWithExtension is a directory in which the library resides. + // The actual library name doesn't have an extension at all. + // E.g. "libEGL.framework/libEGL" + libraryWithExtension = libraryWithExtension + "/" + libraryName; +#endif + return OpenSystemLibraryWithExtensionAndGetError(libraryWithExtension.c_str(), searchType, + errorOut); +} + +std::string StripFilenameFromPath(const std::string &path) +{ + size_t lastPathSepLoc = path.find_last_of("\\/"); + return (lastPathSepLoc != std::string::npos) ? path.substr(0, lastPathSepLoc) : ""; +} + +static std::atomic globalThreadSerial(1); + +#if defined(ANGLE_PLATFORM_APPLE) +// https://anglebug.com/6479, similar to egl::GetCurrentThread() in libGLESv2/global_state.cpp +uint64_t GetCurrentThreadUniqueId() +{ + static pthread_key_t tlsIndex; + static dispatch_once_t once; + dispatch_once(&once, ^{ + ASSERT(pthread_key_create(&tlsIndex, nullptr) == 0); + }); + + void *tlsValue = pthread_getspecific(tlsIndex); + if (tlsValue == nullptr) + { + uint64_t threadId = globalThreadSerial++; + ASSERT(pthread_setspecific(tlsIndex, reinterpret_cast(threadId)) == 0); + return threadId; + } + return reinterpret_cast(tlsValue); +} +#else +uint64_t GetCurrentThreadUniqueId() +{ + thread_local uint64_t threadId(globalThreadSerial++); + return threadId; +} +#endif + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/system_utils.h b/gfx/angle/checkout/src/common/system_utils.h new file mode 100644 index 0000000000..d9e435afaa --- /dev/null +++ b/gfx/angle/checkout/src/common/system_utils.h @@ -0,0 +1,224 @@ +// +// Copyright 2014 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// system_utils.h: declaration of OS-specific utility functions + +#ifndef COMMON_SYSTEM_UTILS_H_ +#define COMMON_SYSTEM_UTILS_H_ + +#include "common/Optional.h" +#include "common/angleutils.h" + +#include +#include +#include + +namespace angle +{ +std::string GetExecutableName(); +std::string GetExecutablePath(); +std::string GetExecutableDirectory(); +std::string GetModuleDirectory(); +const char *GetSharedLibraryExtension(); +const char *GetExecutableExtension(); +char GetPathSeparator(); +Optional GetCWD(); +bool SetCWD(const char *dirName); +bool SetEnvironmentVar(const char *variableName, const char *value); +bool UnsetEnvironmentVar(const char *variableName); +bool GetBoolEnvironmentVar(const char *variableName); +std::string GetEnvironmentVar(const char *variableName); +std::string GetEnvironmentVarOrUnCachedAndroidProperty(const char *variableName, + const char *propertyName); +std::string GetAndSetEnvironmentVarOrUnCachedAndroidProperty(const char *variableName, + const char *propertyName); +std::string GetEnvironmentVarOrAndroidProperty(const char *variableName, const char *propertyName); +const char *GetPathSeparatorForEnvironmentVar(); +bool PrependPathToEnvironmentVar(const char *variableName, const char *path); +bool IsDirectory(const char *filename); +bool IsFullPath(std::string dirName); +std::string GetRootDirectory(); +std::string ConcatenatePath(std::string first, std::string second); + +Optional GetTempDirectory(); +Optional CreateTemporaryFileInDirectory(const std::string &directory); +Optional CreateTemporaryFile(); + +// Get absolute time in seconds. Use this function to get an absolute time with an unknown origin. +double GetCurrentSystemTime(); +// Get CPU time for current process in seconds. +double GetCurrentProcessCpuTime(); + +// Unique thread id (std::this_thread::get_id() gets recycled!) +uint64_t GetCurrentThreadUniqueId(); + +// Run an application and get the output. Gets a nullptr-terminated set of args to execute the +// application with, and returns the stdout and stderr outputs as well as the exit code. +// +// Pass nullptr for stdoutOut/stderrOut if you don't need to capture. exitCodeOut is required. +// +// Returns false if it fails to actually execute the application. +bool RunApp(const std::vector &args, + std::string *stdoutOut, + std::string *stderrOut, + int *exitCodeOut); + +// Use SYSTEM_DIR to bypass loading ANGLE libraries with the same name as system DLLS +// (e.g. opengl32.dll) +enum class SearchType +{ + // Try to find the library in the same directory as the current module + ModuleDir, + // Load the library from the system directories + SystemDir, + // Get a reference to an already loaded shared library. + AlreadyLoaded, +}; + +void *OpenSystemLibrary(const char *libraryName, SearchType searchType); +void *OpenSystemLibraryWithExtension(const char *libraryName, SearchType searchType); +void *OpenSystemLibraryAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut); +void *OpenSystemLibraryWithExtensionAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut); + +void *GetLibrarySymbol(void *libraryHandle, const char *symbolName); +std::string GetLibraryPath(void *libraryHandle); +void CloseSystemLibrary(void *libraryHandle); + +class Library : angle::NonCopyable +{ + public: + Library() {} + Library(void *libraryHandle) : mLibraryHandle(libraryHandle) {} + ~Library() { close(); } + + [[nodiscard]] bool open(const char *libraryName, SearchType searchType) + { + close(); + mLibraryHandle = OpenSystemLibrary(libraryName, searchType); + return mLibraryHandle != nullptr; + } + + [[nodiscard]] bool openWithExtension(const char *libraryName, SearchType searchType) + { + close(); + mLibraryHandle = OpenSystemLibraryWithExtension(libraryName, searchType); + return mLibraryHandle != nullptr; + } + + [[nodiscard]] bool openAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut) + { + close(); + mLibraryHandle = OpenSystemLibraryAndGetError(libraryName, searchType, errorOut); + return mLibraryHandle != nullptr; + } + + [[nodiscard]] bool openWithExtensionAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut) + { + close(); + mLibraryHandle = + OpenSystemLibraryWithExtensionAndGetError(libraryName, searchType, errorOut); + return mLibraryHandle != nullptr; + } + + void close() + { + if (mLibraryHandle) + { + CloseSystemLibrary(mLibraryHandle); + mLibraryHandle = nullptr; + } + } + + void *getSymbol(const char *symbolName) { return GetLibrarySymbol(mLibraryHandle, symbolName); } + + void *getNative() const { return mLibraryHandle; } + + std::string getPath() const { return GetLibraryPath(mLibraryHandle); } + + template + void getAs(const char *symbolName, FuncT *funcOut) + { + *funcOut = reinterpret_cast(getSymbol(symbolName)); + } + + private: + void *mLibraryHandle = nullptr; +}; + +Library *OpenSharedLibrary(const char *libraryName, SearchType searchType); +Library *OpenSharedLibraryWithExtension(const char *libraryName, SearchType searchType); +Library *OpenSharedLibraryAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut); +Library *OpenSharedLibraryWithExtensionAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut); + +// Returns true if the process is currently being debugged. +bool IsDebuggerAttached(); + +// Calls system APIs to break into the debugger. +void BreakDebugger(); + +uint64_t GetProcessMemoryUsageKB(); + +bool ProtectMemory(uintptr_t start, size_t size); +bool UnprotectMemory(uintptr_t start, size_t size); + +size_t GetPageSize(); + +// Return type of the PageFaultCallback +enum class PageFaultHandlerRangeType +{ + // The memory address was known by the page fault handler + InRange, + // The memory address was not in the page fault handler's range + // and the signal will be forwarded to the default page handler. + OutOfRange, +}; + +using PageFaultCallback = std::function; + +class PageFaultHandler : angle::NonCopyable +{ + public: + PageFaultHandler(PageFaultCallback callback); + virtual ~PageFaultHandler(); + + // Registers OS level page fault handler for memory protection signals + // and enables reception on PageFaultCallback + virtual bool enable() = 0; + + // Unregisters OS level page fault handler and deactivates PageFaultCallback + virtual bool disable() = 0; + + protected: + PageFaultCallback mCallback; +}; + +// Creates single instance page fault handler +PageFaultHandler *CreatePageFaultHandler(PageFaultCallback callback); + +#ifdef ANGLE_PLATFORM_WINDOWS +// Convert an UTF-16 wstring to an UTF-8 string. +std::string Narrow(const std::wstring_view &utf16); + +// Convert an UTF-8 string to an UTF-16 wstring. +std::wstring Widen(const std::string_view &utf8); +#endif + +std::string StripFilenameFromPath(const std::string &path); +} // namespace angle + +#endif // COMMON_SYSTEM_UTILS_H_ diff --git a/gfx/angle/checkout/src/common/system_utils_apple.cpp b/gfx/angle/checkout/src/common/system_utils_apple.cpp new file mode 100644 index 0000000000..532714248c --- /dev/null +++ b/gfx/angle/checkout/src/common/system_utils_apple.cpp @@ -0,0 +1,59 @@ +// +// Copyright 2020 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// system_utils_apple.cpp: Implementation of OS-specific functions for Apple platforms + +#include "system_utils.h" + +#include + +#include +#include +#include +#include +#include +#include + +#include + +namespace angle +{ +std::string GetExecutablePath() +{ + std::string result; + + uint32_t size = 0; + _NSGetExecutablePath(nullptr, &size); + + std::vector buffer; + buffer.resize(size + 1); + + _NSGetExecutablePath(buffer.data(), &size); + buffer[size] = '\0'; + + if (!strrchr(buffer.data(), '/')) + { + return ""; + } + return buffer.data(); +} + +std::string GetExecutableDirectory() +{ + std::string executablePath = GetExecutablePath(); + size_t lastPathSepLoc = executablePath.find_last_of("/"); + return (lastPathSepLoc != std::string::npos) ? executablePath.substr(0, lastPathSepLoc) : ""; +} + +double GetCurrentSystemTime() +{ + mach_timebase_info_data_t timebaseInfo; + mach_timebase_info(&timebaseInfo); + + double secondCoeff = timebaseInfo.numer * 1e-9 / timebaseInfo.denom; + return secondCoeff * mach_absolute_time(); +} +} // namespace angle diff --git a/gfx/angle/checkout/src/common/system_utils_linux.cpp b/gfx/angle/checkout/src/common/system_utils_linux.cpp new file mode 100644 index 0000000000..da0ed86028 --- /dev/null +++ b/gfx/angle/checkout/src/common/system_utils_linux.cpp @@ -0,0 +1,55 @@ +// +// Copyright 2015 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// system_utils_linux.cpp: Implementation of OS-specific functions for Linux + +#include "system_utils.h" + +#include +#include +#include +#include + +#include + +namespace angle +{ +std::string GetExecutablePath() +{ + // We cannot use lstat to get the size of /proc/self/exe as it always returns 0 + // so we just use a big buffer and hope the path fits in it. + char path[4096]; + + ssize_t result = readlink("/proc/self/exe", path, sizeof(path) - 1); + if (result < 0 || static_cast(result) >= sizeof(path) - 1) + { + return ""; + } + + path[result] = '\0'; + return path; +} + +std::string GetExecutableDirectory() +{ + std::string executablePath = GetExecutablePath(); + size_t lastPathSepLoc = executablePath.find_last_of("/"); + return (lastPathSepLoc != std::string::npos) ? executablePath.substr(0, lastPathSepLoc) : ""; +} + +const char *GetSharedLibraryExtension() +{ + return "so"; +} + +double GetCurrentSystemTime() +{ + struct timespec currentTime; + clock_gettime(CLOCK_MONOTONIC, ¤tTime); + return currentTime.tv_sec + currentTime.tv_nsec * 1e-9; +} + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/system_utils_mac.cpp b/gfx/angle/checkout/src/common/system_utils_mac.cpp new file mode 100644 index 0000000000..2c48a7eb04 --- /dev/null +++ b/gfx/angle/checkout/src/common/system_utils_mac.cpp @@ -0,0 +1,28 @@ +// +// Copyright 2015 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// system_utils_osx.cpp: Implementation of OS-specific functions for OSX + +#include "system_utils.h" + +#include + +#include +#include +#include +#include +#include +#include + +#include + +namespace angle +{ +const char *GetSharedLibraryExtension() +{ + return "dylib"; +} +} // namespace angle diff --git a/gfx/angle/checkout/src/common/system_utils_posix.cpp b/gfx/angle/checkout/src/common/system_utils_posix.cpp new file mode 100644 index 0000000000..ab0faee0bc --- /dev/null +++ b/gfx/angle/checkout/src/common/system_utils_posix.cpp @@ -0,0 +1,470 @@ +// +// Copyright 2018 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// system_utils_posix.cpp: Implementation of POSIX OS-specific functions. + +#include "common/debug.h" +#include "system_utils.h" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "common/string_utils.h" + +#ifdef ANGLE_PLATFORM_FUCHSIA +# include +# include +#else +# include +#endif + +namespace angle +{ + +namespace +{ +std::string GetModulePath(void *moduleOrSymbol) +{ + Dl_info dlInfo; + if (dladdr(moduleOrSymbol, &dlInfo) == 0) + { + return ""; + } + + return dlInfo.dli_fname; +} + +void *OpenPosixLibrary(const std::string &fullPath, int extraFlags, std::string *errorOut) +{ + void *module = dlopen(fullPath.c_str(), RTLD_NOW | extraFlags); + if (module) + { + if (errorOut) + { + *errorOut = fullPath; + } + } + else if (errorOut) + { + *errorOut = "dlopen("; + *errorOut += fullPath; + *errorOut += ") failed with error: "; + *errorOut += dlerror(); + struct stat sfile; + if (-1 == stat(fullPath.c_str(), &sfile)) + { + *errorOut += ", stat() call failed."; + } + else + { + *errorOut += ", stat() info: "; + struct passwd *pwuser = getpwuid(sfile.st_uid); + if (pwuser) + { + *errorOut += "owner: "; + *errorOut += pwuser->pw_name; + *errorOut += ", "; + } + struct group *grpnam = getgrgid(sfile.st_gid); + if (grpnam) + { + *errorOut += "group: "; + *errorOut += grpnam->gr_name; + *errorOut += ", "; + } + *errorOut += "perms: "; + *errorOut += std::to_string(sfile.st_mode); + *errorOut += ", links: "; + *errorOut += std::to_string(sfile.st_nlink); + *errorOut += ", size: "; + *errorOut += std::to_string(sfile.st_size); + } + } + return module; +} +} // namespace + +Optional GetCWD() +{ + std::array pathBuf; + char *result = getcwd(pathBuf.data(), pathBuf.size()); + if (result == nullptr) + { + return Optional::Invalid(); + } + return std::string(pathBuf.data()); +} + +bool SetCWD(const char *dirName) +{ + return (chdir(dirName) == 0); +} + +bool UnsetEnvironmentVar(const char *variableName) +{ + return (unsetenv(variableName) == 0); +} + +bool SetEnvironmentVar(const char *variableName, const char *value) +{ + return (setenv(variableName, value, 1) == 0); +} + +std::string GetEnvironmentVar(const char *variableName) +{ + const char *value = getenv(variableName); + return (value == nullptr ? std::string() : std::string(value)); +} + +const char *GetPathSeparatorForEnvironmentVar() +{ + return ":"; +} + +std::string GetModuleDirectoryAndGetError(std::string *errorOut) +{ + std::string directory; + static int placeholderSymbol = 0; + std::string moduleName = GetModulePath(&placeholderSymbol); + if (!moduleName.empty()) + { + directory = moduleName.substr(0, moduleName.find_last_of('/') + 1); + } + + // Ensure we return the full path to the module, not the relative path + if (!IsFullPath(directory)) + { + if (errorOut) + { + *errorOut += "Directory: '"; + *errorOut += directory; + *errorOut += "' is not full path"; + } + Optional cwd = GetCWD(); + if (cwd.valid()) + { + directory = ConcatenatePath(cwd.value(), directory); + if (errorOut) + { + *errorOut += ", so it has been modified to: '"; + *errorOut += directory; + *errorOut += "'. "; + } + } + else if (errorOut) + { + *errorOut += " and getcwd was invalid. "; + } + } + return directory; +} + +std::string GetModuleDirectory() +{ + return GetModuleDirectoryAndGetError(nullptr); +} + +void *OpenSystemLibraryWithExtensionAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut) +{ + std::string directory; + if (searchType == SearchType::ModuleDir) + { +#if ANGLE_PLATFORM_IOS + // On iOS, shared libraries must be loaded from within the app bundle. + directory = GetExecutableDirectory() + "/Frameworks/"; +#elif ANGLE_PLATFORM_FUCHSIA + // On Fuchsia the dynamic loader always looks up libraries in /pkg/lib + // and disallows loading of libraries via absolute paths. + directory = ""; +#else + directory = GetModuleDirectoryAndGetError(errorOut); +#endif + } + + int extraFlags = 0; + if (searchType == SearchType::AlreadyLoaded) + { + extraFlags = RTLD_NOLOAD; + } + + std::string fullPath = directory + libraryName; + return OpenPosixLibrary(fullPath, extraFlags, errorOut); +} + +void *GetLibrarySymbol(void *libraryHandle, const char *symbolName) +{ + if (!libraryHandle) + { + return nullptr; + } + + return dlsym(libraryHandle, symbolName); +} + +std::string GetLibraryPath(void *libraryHandle) +{ + if (!libraryHandle) + { + return ""; + } + + return GetModulePath(libraryHandle); +} + +void CloseSystemLibrary(void *libraryHandle) +{ + if (libraryHandle) + { + dlclose(libraryHandle); + } +} + +bool IsDirectory(const char *filename) +{ + struct stat st; + int result = stat(filename, &st); + return result == 0 && ((st.st_mode & S_IFDIR) == S_IFDIR); +} + +bool IsDebuggerAttached() +{ + // This could have a fuller implementation. + // See https://cs.chromium.org/chromium/src/base/debug/debugger_posix.cc + return false; +} + +void BreakDebugger() +{ + // This could have a fuller implementation. + // See https://cs.chromium.org/chromium/src/base/debug/debugger_posix.cc + abort(); +} + +const char *GetExecutableExtension() +{ + return ""; +} + +char GetPathSeparator() +{ + return '/'; +} + +std::string GetRootDirectory() +{ + return "/"; +} + +Optional GetTempDirectory() +{ + const char *tmp = getenv("TMPDIR"); + if (tmp != nullptr) + { + return std::string(tmp); + } + +#if defined(ANGLE_PLATFORM_ANDROID) + // Not used right now in the ANGLE test runner. + // return PathService::Get(DIR_CACHE, path); + return Optional::Invalid(); +#else + return std::string("/tmp"); +#endif +} + +Optional CreateTemporaryFileInDirectory(const std::string &directory) +{ + std::string tempFileTemplate = directory + "/.angle.XXXXXX"; + + char tempFile[1000]; + strcpy(tempFile, tempFileTemplate.c_str()); + + int fd = mkstemp(tempFile); + close(fd); + + if (fd != -1) + { + return std::string(tempFile); + } + + return Optional::Invalid(); +} + +double GetCurrentProcessCpuTime() +{ +#ifdef ANGLE_PLATFORM_FUCHSIA + static zx_handle_t me = zx_process_self(); + zx_info_task_runtime_t task_runtime; + zx_object_get_info(me, ZX_INFO_TASK_RUNTIME, &task_runtime, sizeof(task_runtime), nullptr, + nullptr); + return static_cast(task_runtime.cpu_time) * 1e-9; +#else + // We could also have used /proc/stat, but that requires us to read the + // filesystem and convert from jiffies. /proc/stat also relies on jiffies + // (lower resolution) while getrusage can potentially use a sched_clock() + // underneath that has higher resolution. + struct rusage usage; + getrusage(RUSAGE_SELF, &usage); + double userTime = usage.ru_utime.tv_sec + usage.ru_utime.tv_usec * 1e-6; + double systemTime = usage.ru_stime.tv_sec + usage.ru_stime.tv_usec * 1e-6; + return userTime + systemTime; +#endif +} + +namespace +{ +bool SetMemoryProtection(uintptr_t start, size_t size, int protections) +{ + int ret = mprotect(reinterpret_cast(start), size, protections); + if (ret < 0) + { + perror("mprotect failed"); + } + return ret == 0; +} + +class PosixPageFaultHandler : public PageFaultHandler +{ + public: + PosixPageFaultHandler(PageFaultCallback callback) : PageFaultHandler(callback) {} + ~PosixPageFaultHandler() override {} + + bool enable() override; + bool disable() override; + void handle(int sig, siginfo_t *info, void *unused); + + private: + struct sigaction mDefaultBusAction = {}; + struct sigaction mDefaultSegvAction = {}; +}; + +PosixPageFaultHandler *gPosixPageFaultHandler = nullptr; +void SegfaultHandlerFunction(int sig, siginfo_t *info, void *unused) +{ + gPosixPageFaultHandler->handle(sig, info, unused); +} + +void PosixPageFaultHandler::handle(int sig, siginfo_t *info, void *unused) +{ + bool found = false; + if ((sig == SIGSEGV || sig == SIGBUS) && + (info->si_code == SEGV_ACCERR || info->si_code == SEGV_MAPERR)) + { + found = mCallback(reinterpret_cast(info->si_addr)) == + PageFaultHandlerRangeType::InRange; + } + + // Fall back to default signal handler + if (!found) + { + if (sig == SIGSEGV) + { + mDefaultSegvAction.sa_sigaction(sig, info, unused); + } + else if (sig == SIGBUS) + { + mDefaultBusAction.sa_sigaction(sig, info, unused); + } + else + { + UNREACHABLE(); + } + } +} + +bool PosixPageFaultHandler::disable() +{ + return sigaction(SIGSEGV, &mDefaultSegvAction, nullptr) == 0 && + sigaction(SIGBUS, &mDefaultBusAction, nullptr) == 0; +} + +bool PosixPageFaultHandler::enable() +{ + struct sigaction sigAction = {}; + sigAction.sa_flags = SA_SIGINFO; + sigAction.sa_sigaction = &SegfaultHandlerFunction; + sigemptyset(&sigAction.sa_mask); + + // Some POSIX implementations use SIGBUS for mprotect faults + return sigaction(SIGSEGV, &sigAction, &mDefaultSegvAction) == 0 && + sigaction(SIGBUS, &sigAction, &mDefaultBusAction) == 0; +} +} // namespace + +// Set write protection +bool ProtectMemory(uintptr_t start, size_t size) +{ + return SetMemoryProtection(start, size, PROT_READ); +} + +// Allow reading and writing +bool UnprotectMemory(uintptr_t start, size_t size) +{ + return SetMemoryProtection(start, size, PROT_READ | PROT_WRITE); +} + +size_t GetPageSize() +{ + long pageSize = sysconf(_SC_PAGE_SIZE); + if (pageSize < 0) + { + perror("Could not get sysconf page size"); + return 0; + } + return static_cast(pageSize); +} + +PageFaultHandler *CreatePageFaultHandler(PageFaultCallback callback) +{ + gPosixPageFaultHandler = new PosixPageFaultHandler(callback); + return gPosixPageFaultHandler; +} + +uint64_t GetProcessMemoryUsageKB() +{ + FILE *file = fopen("/proc/self/status", "r"); + + if (!file) + { + return 0; + } + + const char *kSearchString = "VmRSS:"; + constexpr size_t kMaxLineSize = 100; + std::array line = {}; + + uint64_t kb = 0; + + while (fgets(line.data(), line.size(), file) != nullptr) + { + if (strncmp(line.data(), kSearchString, strlen(kSearchString)) == 0) + { + std::vector strings; + SplitStringAlongWhitespace(line.data(), &strings); + + sscanf(strings[1].c_str(), "%" SCNu64, &kb); + break; + } + } + fclose(file); + + return kb; +} +} // namespace angle diff --git a/gfx/angle/checkout/src/common/system_utils_win.cpp b/gfx/angle/checkout/src/common/system_utils_win.cpp new file mode 100644 index 0000000000..8770235cd7 --- /dev/null +++ b/gfx/angle/checkout/src/common/system_utils_win.cpp @@ -0,0 +1,264 @@ +// +// Copyright 2014 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// + +// system_utils_win.cpp: Implementation of OS-specific functions for Windows + +#include "system_utils.h" + +#include +#include +#include +#include + +namespace angle +{ + +namespace +{ + +std::string GetPath(HMODULE module) +{ + std::array executableFileBuf; + DWORD executablePathLen = GetModuleFileNameW(module, executableFileBuf.data(), + static_cast(executableFileBuf.size())); + return Narrow(executablePathLen > 0 ? executableFileBuf.data() : L""); +} + +std::string GetDirectory(HMODULE module) +{ + std::string executablePath = GetPath(module); + return StripFilenameFromPath(executablePath); +} + +} // anonymous namespace + +std::string GetExecutablePath() +{ + return GetPath(nullptr); +} + +std::string GetExecutableDirectory() +{ + return GetDirectory(nullptr); +} + +const char *GetSharedLibraryExtension() +{ + return "dll"; +} + +Optional GetCWD() +{ + std::array pathBuf; + DWORD result = GetCurrentDirectoryW(static_cast(pathBuf.size()), pathBuf.data()); + if (result == 0) + { + return Optional::Invalid(); + } + return Narrow(pathBuf.data()); +} + +bool SetCWD(const char *dirName) +{ + return (SetCurrentDirectoryW(Widen(dirName).c_str()) == TRUE); +} + +const char *GetPathSeparatorForEnvironmentVar() +{ + return ";"; +} + +double GetCurrentSystemTime() +{ + LARGE_INTEGER frequency = {}; + QueryPerformanceFrequency(&frequency); + + LARGE_INTEGER curTime; + QueryPerformanceCounter(&curTime); + + return static_cast(curTime.QuadPart) / frequency.QuadPart; +} + +double GetCurrentProcessCpuTime() +{ + FILETIME creationTime = {}; + FILETIME exitTime = {}; + FILETIME kernelTime = {}; + FILETIME userTime = {}; + + // Note this will not give accurate results if the current thread is + // scheduled for less than the tick rate, which is often 15 ms. In that + // case, GetProcessTimes will not return different values, making it + // possible to end up with 0 ms for a process that takes 93% of a core + // (14/15 ms)! An alternative is QueryProcessCycleTime but there is no + // simple way to convert cycles back to seconds, and on top of that, it's + // not supported pre-Windows Vista. + + // Returns 100-ns intervals, so we want to divide by 1e7 to get seconds + GetProcessTimes(GetCurrentProcess(), &creationTime, &exitTime, &kernelTime, &userTime); + + ULARGE_INTEGER kernelInt64; + kernelInt64.LowPart = kernelTime.dwLowDateTime; + kernelInt64.HighPart = kernelTime.dwHighDateTime; + double systemTimeSeconds = static_cast(kernelInt64.QuadPart) * 1e-7; + + ULARGE_INTEGER userInt64; + userInt64.LowPart = userTime.dwLowDateTime; + userInt64.HighPart = userTime.dwHighDateTime; + double userTimeSeconds = static_cast(userInt64.QuadPart) * 1e-7; + + return systemTimeSeconds + userTimeSeconds; +} + +bool IsDirectory(const char *filename) +{ + WIN32_FILE_ATTRIBUTE_DATA fileInformation; + + BOOL result = + GetFileAttributesExW(Widen(filename).c_str(), GetFileExInfoStandard, &fileInformation); + if (result) + { + DWORD attribs = fileInformation.dwFileAttributes; + return (attribs != INVALID_FILE_ATTRIBUTES) && ((attribs & FILE_ATTRIBUTE_DIRECTORY) > 0); + } + + return false; +} + +bool IsDebuggerAttached() +{ + return !!::IsDebuggerPresent(); +} + +void BreakDebugger() +{ + __debugbreak(); +} + +const char *GetExecutableExtension() +{ + return ".exe"; +} + +char GetPathSeparator() +{ + return '\\'; +} + +std::string GetModuleDirectory() +{ +// GetModuleHandleEx is unavailable on UWP +#if !defined(ANGLE_IS_WINUWP) + static int placeholderSymbol = 0; + HMODULE module = nullptr; + if (GetModuleHandleExW( + GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS | GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT, + reinterpret_cast(&placeholderSymbol), &module)) + { + return GetDirectory(module); + } +#endif + return GetDirectory(nullptr); +} + +std::string GetRootDirectory() +{ + return "C:\\"; +} + +Optional GetTempDirectory() +{ + char tempDirOut[MAX_PATH + 1]; + GetTempPathA(MAX_PATH + 1, tempDirOut); + std::string tempDir = std::string(tempDirOut); + + if (tempDir.length() < 0 || tempDir.length() > MAX_PATH) + { + return Optional::Invalid(); + } + + if (tempDir.length() > 0 && tempDir.back() == '\\') + { + tempDir.pop_back(); + } + + return tempDir; +} + +Optional CreateTemporaryFileInDirectory(const std::string &directory) +{ + char fileName[MAX_PATH + 1]; + if (GetTempFileNameA(directory.c_str(), "ANGLE", 0, fileName) == 0) + return Optional::Invalid(); + + return std::string(fileName); +} + +std::string GetLibraryPath(void *libraryHandle) +{ + if (!libraryHandle) + { + return ""; + } + + std::array buffer; + if (GetModuleFileNameW(reinterpret_cast(libraryHandle), buffer.data(), + buffer.size()) == 0) + { + return ""; + } + + return Narrow(buffer.data()); +} + +void *GetLibrarySymbol(void *libraryHandle, const char *symbolName) +{ + if (!libraryHandle) + { + fprintf(stderr, "Module was not loaded\n"); + return nullptr; + } + + return reinterpret_cast( + GetProcAddress(reinterpret_cast(libraryHandle), symbolName)); +} + +void CloseSystemLibrary(void *libraryHandle) +{ + if (libraryHandle) + { + FreeLibrary(reinterpret_cast(libraryHandle)); + } +} +std::string Narrow(const std::wstring_view &utf16) +{ + if (utf16.empty()) + { + return {}; + } + int requiredSize = WideCharToMultiByte(CP_UTF8, 0, utf16.data(), static_cast(utf16.size()), + nullptr, 0, nullptr, nullptr); + std::string utf8(requiredSize, '\0'); + WideCharToMultiByte(CP_UTF8, 0, utf16.data(), static_cast(utf16.size()), &utf8[0], + requiredSize, nullptr, nullptr); + return utf8; +} + +std::wstring Widen(const std::string_view &utf8) +{ + if (utf8.empty()) + { + return {}; + } + int requiredSize = + MultiByteToWideChar(CP_UTF8, 0, utf8.data(), static_cast(utf8.size()), nullptr, 0); + std::wstring utf16(requiredSize, L'\0'); + MultiByteToWideChar(CP_UTF8, 0, utf8.data(), static_cast(utf8.size()), &utf16[0], + requiredSize); + return utf16; +} + +} // namespace angle diff --git a/gfx/angle/checkout/src/common/system_utils_win32.cpp b/gfx/angle/checkout/src/common/system_utils_win32.cpp new file mode 100644 index 0000000000..5bcfa2347e --- /dev/null +++ b/gfx/angle/checkout/src/common/system_utils_win32.cpp @@ -0,0 +1,235 @@ +// +// Copyright 2019 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// system_utils_win32.cpp: Implementation of OS-specific functions for Windows. + +#include "common/FastVector.h" +#include "system_utils.h" + +#include + +// Must be included in this order. +// clang-format off +#include +#include +// clang-format on + +namespace angle +{ +bool UnsetEnvironmentVar(const char *variableName) +{ + return (SetEnvironmentVariableW(Widen(variableName).c_str(), nullptr) == TRUE); +} + +bool SetEnvironmentVar(const char *variableName, const char *value) +{ + return (SetEnvironmentVariableW(Widen(variableName).c_str(), Widen(value).c_str()) == TRUE); +} + +std::string GetEnvironmentVar(const char *variableName) +{ + std::wstring variableNameUtf16 = Widen(variableName); + FastVector value; + + DWORD result; + + // First get the length of the variable, including the null terminator + result = GetEnvironmentVariableW(variableNameUtf16.c_str(), nullptr, 0); + + // Zero means the variable was not found, so return now. + if (result == 0) + { + return std::string(); + } + + // Now size the vector to fit the data, and read the environment variable. + value.resize(result, 0); + result = GetEnvironmentVariableW(variableNameUtf16.c_str(), value.data(), result); + + return Narrow(value.data()); +} + +void *OpenSystemLibraryWithExtensionAndGetError(const char *libraryName, + SearchType searchType, + std::string *errorOut) +{ + char buffer[MAX_PATH]; + int ret = snprintf(buffer, MAX_PATH, "%s.%s", libraryName, GetSharedLibraryExtension()); + if (ret <= 0 || ret >= MAX_PATH) + { + fprintf(stderr, "Error loading shared library: 0x%x", ret); + return nullptr; + } + + HMODULE libraryModule = nullptr; + + switch (searchType) + { + case SearchType::ModuleDir: + { + std::string moduleRelativePath = ConcatenatePath(GetModuleDirectory(), libraryName); + if (errorOut) + { + *errorOut = moduleRelativePath; + } + libraryModule = LoadLibraryW(Widen(moduleRelativePath).c_str()); + break; + } + + case SearchType::SystemDir: + { + if (errorOut) + { + *errorOut = libraryName; + } + libraryModule = + LoadLibraryExW(Widen(libraryName).c_str(), nullptr, LOAD_LIBRARY_SEARCH_SYSTEM32); + break; + } + + case SearchType::AlreadyLoaded: + { + if (errorOut) + { + *errorOut = libraryName; + } + libraryModule = GetModuleHandleW(Widen(libraryName).c_str()); + break; + } + } + + return reinterpret_cast(libraryModule); +} + +namespace +{ +class Win32PageFaultHandler : public PageFaultHandler +{ + public: + Win32PageFaultHandler(PageFaultCallback callback) : PageFaultHandler(callback) {} + ~Win32PageFaultHandler() override {} + + bool enable() override; + bool disable() override; + + LONG handle(PEXCEPTION_POINTERS pExceptionInfo); + + private: + void *mVectoredExceptionHandler = nullptr; +}; + +Win32PageFaultHandler *gWin32PageFaultHandler = nullptr; +static LONG CALLBACK VectoredExceptionHandler(PEXCEPTION_POINTERS info) +{ + return gWin32PageFaultHandler->handle(info); +} + +bool SetMemoryProtection(uintptr_t start, size_t size, DWORD protections) +{ + DWORD oldProtect; + BOOL res = VirtualProtect(reinterpret_cast(start), size, protections, &oldProtect); + if (!res) + { + DWORD lastError = GetLastError(); + fprintf(stderr, "VirtualProtect failed: 0x%lx\n", lastError); + return false; + } + + return true; +} + +LONG Win32PageFaultHandler::handle(PEXCEPTION_POINTERS info) +{ + bool found = false; + + if (info->ExceptionRecord->ExceptionCode == EXCEPTION_ACCESS_VIOLATION && + info->ExceptionRecord->NumberParameters >= 2 && + info->ExceptionRecord->ExceptionInformation[0] == 1) + { + found = mCallback(static_cast(info->ExceptionRecord->ExceptionInformation[1])) == + PageFaultHandlerRangeType::InRange; + } + + if (found) + { + return EXCEPTION_CONTINUE_EXECUTION; + } + else + { + return EXCEPTION_CONTINUE_SEARCH; + } +} + +bool Win32PageFaultHandler::disable() +{ + if (mVectoredExceptionHandler) + { + ULONG res = RemoveVectoredExceptionHandler(mVectoredExceptionHandler); + mVectoredExceptionHandler = nullptr; + if (res == 0) + { + DWORD lastError = GetLastError(); + fprintf(stderr, "RemoveVectoredExceptionHandler failed: 0x%lx\n", lastError); + return false; + } + } + return true; +} + +bool Win32PageFaultHandler::enable() +{ + if (mVectoredExceptionHandler) + { + return true; + } + + PVECTORED_EXCEPTION_HANDLER handler = + reinterpret_cast(&VectoredExceptionHandler); + + mVectoredExceptionHandler = AddVectoredExceptionHandler(1, handler); + + if (!mVectoredExceptionHandler) + { + DWORD lastError = GetLastError(); + fprintf(stderr, "AddVectoredExceptionHandler failed: 0x%lx\n", lastError); + return false; + } + return true; +} +} // namespace + +// Set write protection +bool ProtectMemory(uintptr_t start, size_t size) +{ + return SetMemoryProtection(start, size, PAGE_READONLY); +} + +// Allow reading and writing +bool UnprotectMemory(uintptr_t start, size_t size) +{ + return SetMemoryProtection(start, size, PAGE_READWRITE); +} + +size_t GetPageSize() +{ + SYSTEM_INFO info; + GetSystemInfo(&info); + return static_cast(info.dwPageSize); +} + +PageFaultHandler *CreatePageFaultHandler(PageFaultCallback callback) +{ + gWin32PageFaultHandler = new Win32PageFaultHandler(callback); + return gWin32PageFaultHandler; +} + +uint64_t GetProcessMemoryUsageKB() +{ + PROCESS_MEMORY_COUNTERS_EX pmc; + ::GetProcessMemoryInfo(::GetCurrentProcess(), reinterpret_cast(&pmc), + sizeof(pmc)); + return static_cast(pmc.PrivateUsage) / 1024ull; +} +} // namespace angle diff --git a/gfx/angle/checkout/src/common/third_party/base/anglebase/base_export.h b/gfx/angle/checkout/src/common/third_party/base/anglebase/base_export.h new file mode 100644 index 0000000000..426047a992 --- /dev/null +++ b/gfx/angle/checkout/src/common/third_party/base/anglebase/base_export.h @@ -0,0 +1,13 @@ +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// base_export.h: Compatiblity hacks for importing Chromium's base/SHA1. + +#ifndef ANGLEBASE_BASE_EXPORT_H_ +#define ANGLEBASE_BASE_EXPORT_H_ + +#define ANGLEBASE_EXPORT + +#endif // ANGLEBASE_BASE_EXPORT_H_ diff --git a/gfx/angle/checkout/src/common/third_party/base/anglebase/containers/mru_cache.h b/gfx/angle/checkout/src/common/third_party/base/anglebase/containers/mru_cache.h new file mode 100644 index 0000000000..30b564aff6 --- /dev/null +++ b/gfx/angle/checkout/src/common/third_party/base/anglebase/containers/mru_cache.h @@ -0,0 +1,275 @@ +// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// This file contains a template for a Most Recently Used cache that allows +// constant-time access to items using a key, but easy identification of the +// least-recently-used items for removal. Each key can only be associated with +// one payload item at a time. +// +// The key object will be stored twice, so it should support efficient copying. +// +// NOTE: While all operations are O(1), this code is written for +// legibility rather than optimality. If future profiling identifies this as +// a bottleneck, there is room for smaller values of 1 in the O(1). :] + +#ifndef ANGLEBASE_CONTAINERS_MRU_CACHE_H_ +#define ANGLEBASE_CONTAINERS_MRU_CACHE_H_ + +#include + +#include +#include +#include +#include +#include +#include + +#include "anglebase/logging.h" +#include "anglebase/macros.h" + +namespace angle +{ + +namespace base +{ + +// MRUCacheBase ---------------------------------------------------------------- + +// This template is used to standardize map type containers that can be used +// by MRUCacheBase. This level of indirection is necessary because of the way +// that template template params and default template params interact. +template +struct MRUCacheStandardMap +{ + typedef std::map Type; +}; + +// Base class for the MRU cache specializations defined below. +template class MapType = MRUCacheStandardMap> +class MRUCacheBase +{ + public: + // The payload of the list. This maintains a copy of the key so we can + // efficiently delete things given an element of the list. + typedef std::pair value_type; + + private: + typedef std::list PayloadList; + typedef + typename MapType::Type KeyIndex; + + public: + typedef typename PayloadList::size_type size_type; + + typedef typename PayloadList::iterator iterator; + typedef typename PayloadList::const_iterator const_iterator; + typedef typename PayloadList::reverse_iterator reverse_iterator; + typedef typename PayloadList::const_reverse_iterator const_reverse_iterator; + + enum + { + NO_AUTO_EVICT = 0 + }; + + // The max_size is the size at which the cache will prune its members to when + // a new item is inserted. If the caller wants to manager this itself (for + // example, maybe it has special work to do when something is evicted), it + // can pass NO_AUTO_EVICT to not restrict the cache size. + explicit MRUCacheBase(size_type max_size) : max_size_(max_size) {} + + virtual ~MRUCacheBase() {} + + size_type max_size() const { return max_size_; } + + // Inserts a payload item with the given key. If an existing item has + // the same key, it is removed prior to insertion. An iterator indicating the + // inserted item will be returned (this will always be the front of the list). + // + // The payload will be forwarded. + template + iterator Put(const KeyType &key, Payload &&payload) + { + // Remove any existing payload with that key. + typename KeyIndex::iterator index_iter = index_.find(key); + if (index_iter != index_.end()) + { + // Erase the reference to it. The index reference will be replaced in the + // code below. + Erase(index_iter->second); + } + else if (max_size_ != NO_AUTO_EVICT) + { + // New item is being inserted which might make it larger than the maximum + // size: kick the oldest thing out if necessary. + ShrinkToSize(max_size_ - 1); + } + + ordering_.emplace_front(key, std::forward(payload)); + index_.emplace(key, ordering_.begin()); + return ordering_.begin(); + } + + // Retrieves the contents of the given key, or end() if not found. This method + // has the side effect of moving the requested item to the front of the + // recency list. + iterator Get(const KeyType &key) + { + typename KeyIndex::iterator index_iter = index_.find(key); + if (index_iter == index_.end()) + return end(); + typename PayloadList::iterator iter = index_iter->second; + + // Move the touched item to the front of the recency ordering. + ordering_.splice(ordering_.begin(), ordering_, iter); + return ordering_.begin(); + } + + // Retrieves the payload associated with a given key and returns it via + // result without affecting the ordering (unlike Get). + iterator Peek(const KeyType &key) + { + typename KeyIndex::const_iterator index_iter = index_.find(key); + if (index_iter == index_.end()) + return end(); + return index_iter->second; + } + + const_iterator Peek(const KeyType &key) const + { + typename KeyIndex::const_iterator index_iter = index_.find(key); + if (index_iter == index_.end()) + return end(); + return index_iter->second; + } + + // Exchanges the contents of |this| by the contents of the |other|. + void Swap(MRUCacheBase &other) + { + ordering_.swap(other.ordering_); + index_.swap(other.index_); + std::swap(max_size_, other.max_size_); + } + + // Erases the item referenced by the given iterator. An iterator to the item + // following it will be returned. The iterator must be valid. + iterator Erase(iterator pos) + { + index_.erase(pos->first); + return ordering_.erase(pos); + } + + // MRUCache entries are often processed in reverse order, so we add this + // convenience function (not typically defined by STL containers). + reverse_iterator Erase(reverse_iterator pos) + { + // We have to actually give it the incremented iterator to delete, since + // the forward iterator that base() returns is actually one past the item + // being iterated over. + return reverse_iterator(Erase((++pos).base())); + } + + // Shrinks the cache so it only holds |new_size| items. If |new_size| is + // bigger or equal to the current number of items, this will do nothing. + void ShrinkToSize(size_type new_size) + { + for (size_type i = size(); i > new_size; i--) + Erase(rbegin()); + } + + // Deletes everything from the cache. + void Clear() + { + index_.clear(); + ordering_.clear(); + } + + // Returns the number of elements in the cache. + size_type size() const + { + // We don't use ordering_.size() for the return value because + // (as a linked list) it can be O(n). + DCHECK(index_.size() == ordering_.size()); + return index_.size(); + } + + // Allows iteration over the list. Forward iteration starts with the most + // recent item and works backwards. + // + // Note that since these iterators are actually iterators over a list, you + // can keep them as you insert or delete things (as long as you don't delete + // the one you are pointing to) and they will still be valid. + iterator begin() { return ordering_.begin(); } + const_iterator begin() const { return ordering_.begin(); } + iterator end() { return ordering_.end(); } + const_iterator end() const { return ordering_.end(); } + + reverse_iterator rbegin() { return ordering_.rbegin(); } + const_reverse_iterator rbegin() const { return ordering_.rbegin(); } + reverse_iterator rend() { return ordering_.rend(); } + const_reverse_iterator rend() const { return ordering_.rend(); } + + bool empty() const { return ordering_.empty(); } + + private: + PayloadList ordering_; + KeyIndex index_; + + size_type max_size_; + + DISALLOW_COPY_AND_ASSIGN(MRUCacheBase); +}; + +// MRUCache -------------------------------------------------------------------- + +// A container that does not do anything to free its data. Use this when storing +// value types (as opposed to pointers) in the list. +template > +class MRUCache : public MRUCacheBase +{ + private: + using ParentType = MRUCacheBase; + + public: + // See MRUCacheBase, noting the possibility of using NO_AUTO_EVICT. + explicit MRUCache(typename ParentType::size_type max_size) : ParentType(max_size) {} + virtual ~MRUCache() {} + + private: + DISALLOW_COPY_AND_ASSIGN(MRUCache); +}; + +// HashingMRUCache ------------------------------------------------------------ + +template +struct MRUCacheHashMap +{ + typedef std::unordered_map Type; +}; + +// This class is similar to MRUCache, except that it uses std::unordered_map as +// the map type instead of std::map. Note that your KeyType must be hashable to +// use this cache or you need to provide a hashing class. +template > +class HashingMRUCache : public MRUCacheBase +{ + private: + using ParentType = MRUCacheBase; + + public: + // See MRUCacheBase, noting the possibility of using NO_AUTO_EVICT. + explicit HashingMRUCache(typename ParentType::size_type max_size) : ParentType(max_size) {} + virtual ~HashingMRUCache() override {} + + private: + DISALLOW_COPY_AND_ASSIGN(HashingMRUCache); +}; + +} // namespace base + +} // namespace angle + +#endif // ANGLEBASE_CONTAINERS_MRU_CACHE_H_ diff --git a/gfx/angle/checkout/src/common/third_party/base/anglebase/logging.h b/gfx/angle/checkout/src/common/third_party/base/anglebase/logging.h new file mode 100644 index 0000000000..73f81e87f2 --- /dev/null +++ b/gfx/angle/checkout/src/common/third_party/base/anglebase/logging.h @@ -0,0 +1,26 @@ +// +// Copyright 2016 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// logging.h: Compatiblity hacks for importing Chromium's base/numerics. + +#ifndef ANGLEBASE_LOGGING_H_ +#define ANGLEBASE_LOGGING_H_ + +#include "common/debug.h" + +#ifndef DCHECK +# define DCHECK(X) ASSERT(X) +#endif + +#ifndef CHECK +# define CHECK(X) ASSERT(X) +#endif + +// Unfortunately ANGLE relies on ASSERT being an empty statement, which these libs don't respect. +#ifndef NOTREACHED +# define NOTREACHED() ({ UNREACHABLE(); }) +#endif + +#endif // ANGLEBASE_LOGGING_H_ diff --git a/gfx/angle/checkout/src/common/third_party/base/anglebase/macros.h b/gfx/angle/checkout/src/common/third_party/base/anglebase/macros.h new file mode 100644 index 0000000000..06391784e4 --- /dev/null +++ b/gfx/angle/checkout/src/common/third_party/base/anglebase/macros.h @@ -0,0 +1,17 @@ +// +// Copyright 2017 The ANGLE Project Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. +// +// macros.h: Compatiblity hacks for importing Chromium's MRUCache. + +#ifndef ANGLEBASE_MACROS_H_ +#define ANGLEBASE_MACROS_H_ + +// A macro to disallow the copy constructor and operator= functions. +// This should be used in the private: declarations for a class. +#define DISALLOW_COPY_AND_ASSIGN(TypeName) \ + TypeName(const TypeName &) = delete; \ + void operator=(const TypeName &) = delete + +#endif // ANGLEBASE_MACROS_H_ diff --git a/gfx/angle/checkout/src/common/third_party/base/anglebase/no_destructor.h b/gfx/angle/checkout/src/common/third_party/base/anglebase/no_destructor.h new file mode 100644 index 0000000000..5090dd9817 --- /dev/null +++ b/gfx/angle/checkout/src/common/third_party/base/anglebase/no_destructor.h @@ -0,0 +1,106 @@ +// Copyright 2018 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef ANGLEBASE_NO_DESTRUCTOR_H_ +#define ANGLEBASE_NO_DESTRUCTOR_H_ + +#include +#include + +namespace angle +{ + +namespace base +{ + +// A wrapper that makes it easy to create an object of type T with static +// storage duration that: +// - is only constructed on first access +// - never invokes the destructor +// in order to satisfy the styleguide ban on global constructors and +// destructors. +// +// Runtime constant example: +// const std::string& GetLineSeparator() { +// // Forwards to std::string(size_t, char, const Allocator&) constructor. +// static const base::NoDestructor s(5, '-'); +// return *s; +// } +// +// More complex initialization with a lambda: +// const std::string& GetSessionNonce() { +// static const base::NoDestructor nonce([] { +// std::string s(16); +// crypto::RandString(s.data(), s.size()); +// return s; +// }()); +// return *nonce; +// } +// +// NoDestructor stores the object inline, so it also avoids a pointer +// indirection and a malloc. Also note that since C++11 static local variable +// initialization is thread-safe and so is this pattern. Code should prefer to +// use NoDestructor over: +// - A function scoped static T* or T& that is dynamically initialized. +// - A global base::LazyInstance. +// +// Note that since the destructor is never run, this *will* leak memory if used +// as a stack or member variable. Furthermore, a NoDestructor should never +// have global scope as that may require a static initializer. +template +class NoDestructor +{ + public: + // Not constexpr; just write static constexpr T x = ...; if the value should + // be a constexpr. + template + explicit NoDestructor(Args &&... args) + { + new (storage_) T(std::forward(args)...); + } + + // Allows copy and move construction of the contained type, to allow + // construction from an initializer list, e.g. for std::vector. + explicit NoDestructor(const T &x) { new (storage_) T(x); } + explicit NoDestructor(T &&x) { new (storage_) T(std::move(x)); } + + NoDestructor(const NoDestructor &) = delete; + NoDestructor &operator=(const NoDestructor &) = delete; + + ~NoDestructor() = default; + + const T &operator*() const { return *get(); } + T &operator*() { return *get(); } + + const T *operator->() const { return get(); } + T *operator->() { return get(); } + + const T *get() const { return reinterpret_cast(storage_); } + T *get() { return reinterpret_cast(storage_); } + + private: + alignas(T) char storage_[sizeof(T)]; + +#if defined(LEAK_SANITIZER) + // TODO(https://crbug.com/812277): This is a hack to work around the fact + // that LSan doesn't seem to treat NoDestructor as a root for reachability + // analysis. This means that code like this: + // static base::NoDestructor> v({1, 2, 3}); + // is considered a leak. Using the standard leak sanitizer annotations to + // suppress leaks doesn't work: std::vector is implicitly constructed before + // calling the base::NoDestructor constructor. + // + // Unfortunately, I haven't been able to demonstrate this issue in simpler + // reproductions: until that's resolved, hold an explicit pointer to the + // placement-new'd object in leak sanitizer mode to help LSan realize that + // objects allocated by the contained type are still reachable. + T *storage_ptr_ = reinterpret_cast(storage_); +#endif // defined(LEAK_SANITIZER) +}; + +} // namespace base + +} // namespace angle + +#endif // ANGLEBASE_NO_DESTRUCTOR_H_ diff --git a/gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/checked_math.h b/gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/checked_math.h new file mode 100644 index 0000000000..18bceb7468 --- /dev/null +++ b/gfx/angle/checkout/src/common/third_party/base/anglebase/numerics/checked_math.h @@ -0,0 +1,384 @@ +// Copyright 2017 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef BASE_NUMERICS_CHECKED_MATH_H_ +#define BASE_NUMERICS_CHECKED_MATH_H_ + +#include + +#include +#include + +#include "anglebase/numerics/checked_math_impl.h" + +namespace angle +{ +namespace base +{ +namespace internal +{ + +template +class CheckedNumeric +{ + static_assert(std::is_arithmetic::value, "CheckedNumeric: T must be a numeric type."); + + public: + template + friend class CheckedNumeric; + + using type = T; + + constexpr CheckedNumeric() = default; + + // Copy constructor. + template + constexpr CheckedNumeric(const CheckedNumeric &rhs) + : state_(rhs.state_.value(), rhs.IsValid()) + {} + + // This is not an explicit constructor because we implicitly upgrade regular + // numerics to CheckedNumerics to make them easier to use. + template + constexpr CheckedNumeric(Src value) // NOLINT(runtime/explicit) + : state_(value) + { + static_assert(std::is_arithmetic::value, "Argument must be numeric."); + } + + // This is not an explicit constructor because we want a seamless conversion + // from StrictNumeric types. + template + constexpr CheckedNumeric(StrictNumeric value) // NOLINT(runtime/explicit) + : state_(static_cast(value)) + {} + + // IsValid() - The public API to test if a CheckedNumeric is currently valid. + // A range checked destination type can be supplied using the Dst template + // parameter. + template + constexpr bool IsValid() const + { + return state_.is_valid() && IsValueInRangeForNumericType(state_.value()); + } + + // AssignIfValid(Dst) - Assigns the underlying value if it is currently valid + // and is within the range supported by the destination type. Returns true if + // successful and false otherwise. + template +#if defined(__clang__) || defined(__GNUC__) + __attribute__((warn_unused_result)) +#elif defined(_MSC_VER) + _Check_return_ +#endif + constexpr bool + AssignIfValid(Dst *result) const + { + return BASE_NUMERICS_LIKELY(IsValid()) + ? ((*result = static_cast(state_.value())), true) + : false; + } + + // ValueOrDie() - The primary accessor for the underlying value. If the + // current state is not valid it will CHECK and crash. + // A range checked destination type can be supplied using the Dst template + // parameter, which will trigger a CHECK if the value is not in bounds for + // the destination. + // The CHECK behavior can be overridden by supplying a handler as a + // template parameter, for test code, etc. However, the handler cannot access + // the underlying value, and it is not available through other means. + template + constexpr StrictNumeric ValueOrDie() const + { + return BASE_NUMERICS_LIKELY(IsValid()) ? static_cast(state_.value()) + : CheckHandler::template HandleFailure(); + } + + // ValueOrDefault(T default_value) - A convenience method that returns the + // current value if the state is valid, and the supplied default_value for + // any other state. + // A range checked destination type can be supplied using the Dst template + // parameter. WARNING: This function may fail to compile or CHECK at runtime + // if the supplied default_value is not within range of the destination type. + template + constexpr StrictNumeric ValueOrDefault(const Src default_value) const + { + return BASE_NUMERICS_LIKELY(IsValid()) ? static_cast(state_.value()) + : checked_cast(default_value); + } + + // Returns a checked numeric of the specified type, cast from the current + // CheckedNumeric. If the current state is invalid or the destination cannot + // represent the result then the returned CheckedNumeric will be invalid. + template + constexpr CheckedNumeric::type> Cast() const + { + return *this; + } + + // This friend method is available solely for providing more detailed logging + // in the tests. Do not implement it in production code, because the + // underlying values may change at any time. + template + friend U GetNumericValueForTest(const CheckedNumeric &src); + + // Prototypes for the supported arithmetic operator overloads. + template + constexpr CheckedNumeric &operator+=(const Src rhs); + template + constexpr CheckedNumeric &operator-=(const Src rhs); + template + constexpr CheckedNumeric &operator*=(const Src rhs); + template + constexpr CheckedNumeric &operator/=(const Src rhs); + template + constexpr CheckedNumeric &operator%=(const Src rhs); + template + constexpr CheckedNumeric &operator<<=(const Src rhs); + template + constexpr CheckedNumeric &operator>>=(const Src rhs); + template + constexpr CheckedNumeric &operator&=(const Src rhs); + template + constexpr CheckedNumeric &operator|=(const Src rhs); + template + constexpr CheckedNumeric &operator^=(const Src rhs); + + constexpr CheckedNumeric operator-() const + { + // Use an optimized code path for a known run-time variable. + if (!MustTreatAsConstexpr(state_.value()) && std::is_signed::value && + std::is_floating_point::value) + { + return FastRuntimeNegate(); + } + // The negation of two's complement int min is int min. + const bool is_valid = + IsValid() && (!std::is_signed::value || std::is_floating_point::value || + NegateWrapper(state_.value()) != std::numeric_limits::lowest()); + return CheckedNumeric(NegateWrapper(state_.value()), is_valid); + } + + constexpr CheckedNumeric operator~() const + { + return CheckedNumeric(InvertWrapper(state_.value()), + IsValid()); + } + + constexpr CheckedNumeric Abs() const + { + return !IsValueNegative(state_.value()) ? *this : -*this; + } + + template + constexpr CheckedNumeric::type> Max(const U rhs) const + { + return CheckMax(*this, rhs); + } + + template + constexpr CheckedNumeric::type> Min(const U rhs) const + { + return CheckMin(*this, rhs); + } + + // This function is available only for integral types. It returns an unsigned + // integer of the same width as the source type, containing the absolute value + // of the source, and properly handling signed min. + constexpr CheckedNumeric::type> UnsignedAbs() const + { + return CheckedNumeric::type>( + SafeUnsignedAbs(state_.value()), state_.is_valid()); + } + + constexpr CheckedNumeric &operator++() + { + *this += 1; + return *this; + } + + constexpr CheckedNumeric operator++(int) + { + CheckedNumeric value = *this; + *this += 1; + return value; + } + + constexpr CheckedNumeric &operator--() + { + *this -= 1; + return *this; + } + + constexpr CheckedNumeric operator--(int) + { + // TODO(pkasting): Consider std::exchange() once it's constexpr in C++20. + const CheckedNumeric value = *this; + *this -= 1; + return value; + } + + // These perform the actual math operations on the CheckedNumerics. + // Binary arithmetic operations. + template