From 03aeb850d26ed31a321a2468c0145b64bf3b2fac Mon Sep 17 00:00:00 2001 From: the_fiddler Date: Tue, 5 May 2009 20:24:09 +0000 Subject: [PATCH] Added non-EXT EXT_blend_color constants to BlendingFactorDest/Src enums (promoted by GL1.2). Added ARB_fragment_shaderFragmentShaderDerivativeHint to HintTarget enum (promoted by GL2.0). Fixes bug [#774]: "Some Token corrections" (http://www.opentk.com/node/774) --- Source/Bind/Specifications/GL2/enumext.spec | 18 +++++++++++++++++- Source/OpenTK/Graphics/GL/GLEnums.cs | 9 +++++++++ 2 files changed, 26 insertions(+), 1 deletion(-) diff --git a/Source/Bind/Specifications/GL2/enumext.spec b/Source/Bind/Specifications/GL2/enumext.spec index 52bee399..4443ee40 100644 --- a/Source/Bind/Specifications/GL2/enumext.spec +++ b/Source/Bind/Specifications/GL2/enumext.spec @@ -5421,6 +5421,19 @@ BlendEquationMode enum: MAX = 0x8008 FUNC_SUBTRACT = 0x800A # Equivalent to EXT_blend_subtract FUNC_REVERSE_SUBTRACT = 0x800B + +# Promoted from EXT_blend_color (pg. 178 of GL3.1 spec). +BlendingFactorDest enum: + CONSTANT_COLOR = 0x8001 + ONE_MINUS_CONSTANT_COLOR = 0x8002 + CONSTANT_ALPHA = 0x8003 + ONE_MINUS_CONSTANT_ALPHA = 0x8004 + +BlendingFactorSrc enum: + CONSTANT_COLOR = 0x8001 + ONE_MINUS_CONSTANT_COLOR = 0x8002 + CONSTANT_ALPHA = 0x8003 + ONE_MINUS_CONSTANT_ALPHA = 0x8004 # Version 1.3 @@ -5871,6 +5884,9 @@ GetPName enum: MAX_VERTEX_ATTRIBS = 0x8869 # ARB_vertex_shader CURRENT_PROGRAM = 0x8B8D # ARB_shader_objects (added for 2.0) +HintTarget enum: + FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B # ARB_fragment_shader + ActiveUniformType enum: use DataType FLOAT FLOAT_VEC2 = 0x8B50 # ARB_shader_objects @@ -6494,7 +6510,7 @@ GetPName enum: MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B ProgramParameter enum: - TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76 + TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76 TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F TRANSFORM_FEEDBACK_VARYINGS = 0x8C83 diff --git a/Source/OpenTK/Graphics/GL/GLEnums.cs b/Source/OpenTK/Graphics/GL/GLEnums.cs index 3e9165cc..e5abd201 100644 --- a/Source/OpenTK/Graphics/GL/GLEnums.cs +++ b/Source/OpenTK/Graphics/GL/GLEnums.cs @@ -136,9 +136,13 @@ namespace OpenTK.Graphics OneMinusDstAlpha = ((int)0X0305), DstColor = ((int)0X0306), OneMinusDstColor = ((int)0X0307), + ConstantColor = ((int)0X8001), ConstantColorExt = ((int)0X8001), + OneMinusConstantColor = ((int)0X8002), OneMinusConstantColorExt = ((int)0X8002), + ConstantAlpha = ((int)0X8003), ConstantAlphaExt = ((int)0X8003), + OneMinusConstantAlpha = ((int)0X8004), OneMinusConstantAlphaExt = ((int)0X8004), One = ((int)1), } @@ -153,9 +157,13 @@ namespace OpenTK.Graphics DstColor = ((int)0X0306), OneMinusDstColor = ((int)0X0307), SrcAlphaSaturate = ((int)0X0308), + ConstantColor = ((int)0X8001), ConstantColorExt = ((int)0X8001), + OneMinusConstantColor = ((int)0X8002), OneMinusConstantColorExt = ((int)0X8002), + ConstantAlpha = ((int)0X8003), ConstantAlphaExt = ((int)0X8003), + OneMinusConstantAlpha = ((int)0X8004), OneMinusConstantAlphaExt = ((int)0X8004), One = ((int)1), } @@ -1177,6 +1185,7 @@ namespace OpenTK.Graphics ConvolutionHintSgix = ((int)0X8316), VertexPreclipHintSgix = ((int)0X83ef), TextureCompressionHint = ((int)0X84ef), + FragmentShaderDerivativeHint = ((int)0X8b8b), } public enum HistogramTargetExt