Support GL_OES_texture_border_clamp
Added support for GL_TEXTURE_BORDER_COLOR and GL_CLAMP_TO_BORDER in
OpenGL/OpenGLES, Direct3D9 and Direct3D11 backends.
For integer textures in OpenGLES3 contexts these additional entry points
are available now:
void glTexParameterIivOES(enum target, enum pname, const int *params);
void glTexParameterIuivOES(enum target, enum pname, const uint *params);
void glGetTexParameterIivOES(enum target, enum pname, int *params);
void glGetTexParameterIuivOES(enum target, enum pname, uint *params);
void glSamplerParameterIivOES(uint sampler, enum pname, const int *params);
void glSamplerParameterIuivOES(uint sampler, enum pname, const uint *params);
void glGetSamplerParameterIivOES(uint sampler, enum pname, int *params);
void glGetSamplerParameterIuivOES(uint sampler, enum pname, uint *params);
BUG=angleproject:2890
TEST=angle_end2end_tests.TextureBorderClamp*
Change-Id: Iee3eeb399d8d7851b3b30694ad8f21a2111f5828
Reviewed-on: https://chromium-review.googlesource.com/c/1257824
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
diff --git a/src/common/Color.h b/src/common/Color.h
index ed33450..72f606d 100644
--- a/src/common/Color.h
+++ b/src/common/Color.h
@@ -48,6 +48,33 @@
typedef Color<int> ColorI;
typedef Color<unsigned int> 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) {}
@@ -63,10 +90,11 @@
{
template <typename T>
-using Color = angle::Color<T>;
-using ColorF = angle::ColorF;
-using ColorI = angle::ColorI;
-using ColorUI = angle::ColorUI;
+using Color = angle::Color<T>;
+using ColorF = angle::ColorF;
+using ColorI = angle::ColorI;
+using ColorUI = angle::ColorUI;
+using ColorGeneric = angle::ColorGeneric;
} // namespace gl
diff --git a/src/common/Color.inl b/src/common/Color.inl
index c307325..d7705b4 100644
--- a/src/common/Color.inl
+++ b/src/common/Color.inl
@@ -34,4 +34,36 @@
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/src/common/PackedGLEnums_autogen.cpp b/src/common/PackedGLEnums_autogen.cpp
index a394a8e..eccdbb4 100644
--- a/src/common/PackedGLEnums_autogen.cpp
+++ b/src/common/PackedGLEnums_autogen.cpp
@@ -1266,6 +1266,8 @@
{
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:
@@ -1281,6 +1283,8 @@
{
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:
diff --git a/src/common/PackedGLEnums_autogen.h b/src/common/PackedGLEnums_autogen.h
index 5e76179..3c4ee6d 100644
--- a/src/common/PackedGLEnums_autogen.h
+++ b/src/common/PackedGLEnums_autogen.h
@@ -494,11 +494,12 @@
enum class WrapMode : uint8_t
{
ClampToEdge = 0,
- MirroredRepeat = 1,
- Repeat = 2,
+ ClampToBorder = 1,
+ MirroredRepeat = 2,
+ Repeat = 3,
- InvalidEnum = 3,
- EnumCount = 3,
+ InvalidEnum = 4,
+ EnumCount = 4,
};
template <>
diff --git a/src/common/mathutil.h b/src/common/mathutil.h
index 830b617..9b76dd6 100644
--- a/src/common/mathutil.h
+++ b/src/common/mathutil.h
@@ -472,8 +472,17 @@
{
static_assert(std::numeric_limits<T>::is_integer, "T must be an integer.");
- const float inverseMax = 1.0f / std::numeric_limits<T>::max();
- return input * inverseMax;
+ 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<T>::max();
+ return static_cast<float>(input * inverseMax);
+ }
+ else
+ {
+ constexpr float inverseMax = 1.0f / std::numeric_limits<T>::max();
+ return input * inverseMax;
+ }
}
template <unsigned int inputBitCount, typename T>
@@ -482,21 +491,47 @@
static_assert(std::numeric_limits<T>::is_integer, "T must be an integer.");
static_assert(inputBitCount < (sizeof(T) * 8), "T must have more bits than inputBitCount.");
- const float inverseMax = 1.0f / ((1 << inputBitCount) - 1);
- return input * inverseMax;
+ 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<float>(input * inverseMax);
+ }
+ else
+ {
+ constexpr float inverseMax = 1.0f / ((1 << inputBitCount) - 1);
+ return input * inverseMax;
+ }
}
template <typename T>
inline T floatToNormalized(float input)
{
- return static_cast<T>(std::numeric_limits<T>::max() * input + 0.5f);
+ if (sizeof(T) > 2)
+ {
+ // float has only a 23 bit mantissa, so we need to do the calculation in double precision
+ return static_cast<T>(std::numeric_limits<T>::max() * static_cast<double>(input) + 0.5);
+ }
+ else
+ {
+ return static_cast<T>(std::numeric_limits<T>::max() * input + 0.5f);
+ }
}
template <unsigned int outputBitCount, typename T>
inline T floatToNormalized(float input)
{
static_assert(outputBitCount < (sizeof(T) * 8), "T must have more bits than outputBitCount.");
- return static_cast<T>(((1 << outputBitCount) - 1) * input + 0.5f);
+
+ if (outputBitCount > 23)
+ {
+ // float has only a 23 bit mantissa, so we need to do the calculation in double precision
+ return static_cast<T>(((1 << outputBitCount) - 1) * static_cast<double>(input) + 0.5);
+ }
+ else
+ {
+ return static_cast<T>(((1 << outputBitCount) - 1) * input + 0.5f);
+ }
}
template <unsigned int inputBitCount, unsigned int inputBitStart, typename T>
diff --git a/src/common/packed_gl_enums.json b/src/common/packed_gl_enums.json
index 1747a70..3d9ba78 100644
--- a/src/common/packed_gl_enums.json
+++ b/src/common/packed_gl_enums.json
@@ -261,6 +261,7 @@
"WrapMode":
{
"ClampToEdge": "GL_CLAMP_TO_EDGE",
+ "ClampToBorder": "GL_CLAMP_TO_BORDER",
"MirroredRepeat": "GL_MIRRORED_REPEAT",
"Repeat": "GL_REPEAT"
}
diff --git a/src/compiler/translator/BaseTypes.h b/src/compiler/translator/BaseTypes.h
index 45d18b2..60e5898 100644
--- a/src/compiler/translator/BaseTypes.h
+++ b/src/compiler/translator/BaseTypes.h
@@ -186,6 +186,31 @@
return false;
}
+inline bool IsIntegerSamplerUnsigned(TBasicType type)
+{
+ switch (type)
+ {
+ case EbtISampler2D:
+ case EbtISampler3D:
+ case EbtISamplerCube:
+ case EbtISampler2DArray:
+ case EbtISampler2DMS:
+ case EbtISampler2DMSArray:
+ return false;
+ case EbtUSampler2D:
+ case EbtUSampler3D:
+ case EbtUSamplerCube:
+ case EbtUSampler2DArray:
+ case EbtUSampler2DMS:
+ case EbtUSampler2DMSArray:
+ return true;
+ default:
+ assert(!IsIntegerSampler(type));
+ }
+
+ return false;
+}
+
inline bool IsSampler2DMS(TBasicType type)
{
switch (type)
diff --git a/src/compiler/translator/ResourcesHLSL.cpp b/src/compiler/translator/ResourcesHLSL.cpp
index 4cb4943..07223cf 100644
--- a/src/compiler/translator/ResourcesHLSL.cpp
+++ b/src/compiler/translator/ResourcesHLSL.cpp
@@ -509,6 +509,7 @@
" int internalFormatBits;\n"
" int wrapModes;\n"
" int padding;\n"
+ " int4 intBorderColor;\n"
" };\n"
" SamplerMetadata samplerMetadata["
<< mSamplerCount << "] : packoffset(" << reg << ");\n";
diff --git a/src/compiler/translator/TextureFunctionHLSL.cpp b/src/compiler/translator/TextureFunctionHLSL.cpp
index edaf6fd..c3bd27a 100644
--- a/src/compiler/translator/TextureFunctionHLSL.cpp
+++ b/src/compiler/translator/TextureFunctionHLSL.cpp
@@ -32,17 +32,26 @@
out << "int " << texCoordOutName << ";\n";
out << "float " << texCoordOutName << "Offset = " << texCoord << " + float(" << texCoordOffset
<< ") / " << size << ";\n";
+ out << "bool " << texCoordOutName << "UseBorderColor = false;\n";
// CLAMP_TO_EDGE
- out << "if (" << wrapMode << " == 1)\n";
+ out << "if (" << wrapMode << " == 0)\n";
out << "{\n";
out << " " << texCoordOutName << " = clamp(int(floor(" << size << " * " << texCoordOutName
<< "Offset)), 0, int(" << size << ") - 1);\n";
out << "}\n";
- // MIRRORED_REPEAT
+ // CLAMP_TO_BORDER
out << "else if (" << wrapMode << " == 3)\n";
out << "{\n";
+ out << " int texCoordInt = int(floor(" << size << " * " << texCoordOutName << "Offset));\n";
+ out << " " << texCoordOutName << " = clamp(texCoordInt, 0, int(" << size << ") - 1);\n";
+ out << " " << texCoordOutName << "UseBorderColor = (texCoordInt != " << texCoordOutName << ");\n";
+ out << "}\n";
+
+ // MIRRORED_REPEAT
+ out << "else if (" << wrapMode << " == 2)\n";
+ out << "{\n";
out << " float coordWrapped = 1.0 - abs(frac(abs(" << texCoordOutName
<< "Offset) * 0.5) * 2.0 - 1.0);\n";
out << " " << texCoordOutName << " = int(floor(" << size << " * coordWrapped));\n";
@@ -84,6 +93,8 @@
}
*texCoordY = ImmutableString("tiy");
+ bool tizAvailable = false;
+
if (IsSamplerArray(textureFunction.sampler))
{
*texCoordZ = ImmutableString("int(max(0, min(layers - 1, floor(0.5 + t.z))))");
@@ -99,8 +110,12 @@
{
OutputIntTexCoordWrap(out, "wrapR", "depth", *texCoordZ, "0", "tiz");
}
- *texCoordZ = ImmutableString("tiz");
+ *texCoordZ = ImmutableString("tiz");
+ tizAvailable = true;
}
+
+ out << "bool useBorderColor = tixUseBorderColor || tiyUseBorderColor"
+ << (tizAvailable ? " || tizUseBorderColor" : "") << ";\n";
}
void OutputHLSL4SampleFunctionPrefix(TInfoSinkBase &out,
@@ -907,6 +922,17 @@
{
out << " return ";
+ if (IsIntegerSampler(textureFunction.sampler) && !IsSamplerCube(textureFunction.sampler) &&
+ textureFunction.method != TextureFunctionHLSL::TextureFunction::FETCH)
+ {
+ out << " useBorderColor ? ";
+ if (IsIntegerSamplerUnsigned(textureFunction.sampler))
+ {
+ out << "asuint";
+ }
+ out << "(samplerMetadata[samplerIndex].intBorderColor) : ";
+ }
+
// HLSL intrinsic
if (outputType == SH_HLSL_3_0_OUTPUT)
{
diff --git a/src/libANGLE/Caps.cpp b/src/libANGLE/Caps.cpp
index 6f3e5b7..2136a9c 100644
--- a/src/libANGLE/Caps.cpp
+++ b/src/libANGLE/Caps.cpp
@@ -230,6 +230,7 @@
requestExtension(false),
bindGeneratesResource(false),
robustClientMemory(false),
+ textureBorderClamp(false),
textureSRGBDecode(false),
sRGBWriteControl(false),
colorBufferFloatRGB(false),
@@ -859,6 +860,7 @@
map["GL_EXT_color_buffer_float"] = enableableExtension(&Extensions::colorBufferFloat);
map["GL_OES_vertex_array_object"] = enableableExtension(&Extensions::vertexArrayObject);
map["GL_KHR_debug"] = esOnlyExtension(&Extensions::debug);
+ map["GL_OES_texture_border_clamp"] = enableableExtension(&Extensions::textureBorderClamp);
// TODO(jmadill): Enable this when complete.
//map["GL_KHR_no_error"] = esOnlyExtension(&Extensions::noError);
map["GL_ANGLE_lossy_etc_decode"] = enableableExtension(&Extensions::lossyETCDecode);
diff --git a/src/libANGLE/Caps.h b/src/libANGLE/Caps.h
index e427009..5da79e1 100644
--- a/src/libANGLE/Caps.h
+++ b/src/libANGLE/Caps.h
@@ -366,6 +366,9 @@
// GL_ANGLE_robust_client_memory
bool robustClientMemory;
+ // GL_OES_texture_border_clamp
+ bool textureBorderClamp;
+
// GL_EXT_texture_sRGB_decode
bool textureSRGBDecode;
diff --git a/src/libANGLE/Context.cpp b/src/libANGLE/Context.cpp
index f9a37c8..605a3bf 100644
--- a/src/libANGLE/Context.cpp
+++ b/src/libANGLE/Context.cpp
@@ -2074,7 +2074,7 @@
void Context::getTexParameterfv(TextureType target, GLenum pname, GLfloat *params)
{
- Texture *texture = getTargetTexture(target);
+ const Texture *const texture = getTargetTexture(target);
QueryTexParameterfv(texture, pname, params);
}
@@ -2089,10 +2089,22 @@
void Context::getTexParameteriv(TextureType target, GLenum pname, GLint *params)
{
- Texture *texture = getTargetTexture(target);
+ const Texture *const texture = getTargetTexture(target);
QueryTexParameteriv(texture, pname, params);
}
+void Context::getTexParameterIiv(TextureType target, GLenum pname, GLint *params)
+{
+ const Texture *const texture = getTargetTexture(target);
+ QueryTexParameterIiv(texture, pname, params);
+}
+
+void Context::getTexParameterIuiv(TextureType target, GLenum pname, GLuint *params)
+{
+ const Texture *const texture = getTargetTexture(target);
+ QueryTexParameterIuiv(texture, pname, params);
+}
+
void Context::getTexParameterivRobust(TextureType target,
GLenum pname,
GLsizei bufSize,
@@ -2157,14 +2169,14 @@
void Context::texParameterf(TextureType target, GLenum pname, GLfloat param)
{
- Texture *texture = getTargetTexture(target);
+ Texture *const texture = getTargetTexture(target);
SetTexParameterf(this, texture, pname, param);
onTextureChange(texture);
}
void Context::texParameterfv(TextureType target, GLenum pname, const GLfloat *params)
{
- Texture *texture = getTargetTexture(target);
+ Texture *const texture = getTargetTexture(target);
SetTexParameterfv(this, texture, pname, params);
onTextureChange(texture);
}
@@ -2179,18 +2191,32 @@
void Context::texParameteri(TextureType target, GLenum pname, GLint param)
{
- Texture *texture = getTargetTexture(target);
+ Texture *const texture = getTargetTexture(target);
SetTexParameteri(this, texture, pname, param);
onTextureChange(texture);
}
void Context::texParameteriv(TextureType target, GLenum pname, const GLint *params)
{
- Texture *texture = getTargetTexture(target);
+ Texture *const texture = getTargetTexture(target);
SetTexParameteriv(this, texture, pname, params);
onTextureChange(texture);
}
+void Context::texParameterIiv(TextureType target, GLenum pname, const GLint *params)
+{
+ Texture *const texture = getTargetTexture(target);
+ SetTexParameterIiv(this, texture, pname, params);
+ onTextureChange(texture);
+}
+
+void Context::texParameterIuiv(TextureType target, GLenum pname, const GLuint *params)
+{
+ Texture *const texture = getTargetTexture(target);
+ SetTexParameterIuiv(this, texture, pname, params);
+ onTextureChange(texture);
+}
+
void Context::texParameterivRobust(TextureType target,
GLenum pname,
GLsizei bufSize,
@@ -2869,18 +2895,32 @@
void Context::samplerParameteri(GLuint sampler, GLenum pname, GLint param)
{
- Sampler *samplerObject =
+ Sampler *const samplerObject =
mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
SetSamplerParameteri(this, samplerObject, pname, param);
}
void Context::samplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
{
- Sampler *samplerObject =
+ Sampler *const samplerObject =
mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
SetSamplerParameteriv(this, samplerObject, pname, param);
}
+void Context::samplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ Sampler *const samplerObject =
+ mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
+ SetSamplerParameterIiv(this, samplerObject, pname, param);
+}
+
+void Context::samplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ Sampler *const samplerObject =
+ mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
+ SetSamplerParameterIuiv(this, samplerObject, pname, param);
+}
+
void Context::samplerParameterivRobust(GLuint sampler,
GLenum pname,
GLsizei bufSize,
@@ -2907,14 +2947,14 @@
void Context::samplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
{
- Sampler *samplerObject =
+ Sampler *const samplerObject =
mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
SetSamplerParameterf(this, samplerObject, pname, param);
}
void Context::samplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
{
- Sampler *samplerObject =
+ Sampler *const samplerObject =
mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
SetSamplerParameterfv(this, samplerObject, pname, param);
}
@@ -2929,11 +2969,25 @@
void Context::getSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
{
- const Sampler *samplerObject =
+ const Sampler *const samplerObject =
mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
QuerySamplerParameteriv(samplerObject, pname, params);
}
+void Context::getSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ const Sampler *const samplerObject =
+ mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
+ QuerySamplerParameterIiv(samplerObject, pname, params);
+}
+
+void Context::getSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ const Sampler *const samplerObject =
+ mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
+ QuerySamplerParameterIuiv(samplerObject, pname, params);
+}
+
void Context::getSamplerParameterivRobust(GLuint sampler,
GLenum pname,
GLsizei bufSize,
@@ -2963,7 +3017,7 @@
void Context::getSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
{
- const Sampler *samplerObject =
+ const Sampler *const samplerObject =
mState.mSamplers->checkSamplerAllocation(mImplementation.get(), sampler);
QuerySamplerParameterfv(samplerObject, pname, params);
}
diff --git a/src/libANGLE/Context.h b/src/libANGLE/Context.h
index aa5307e..a533755 100644
--- a/src/libANGLE/Context.h
+++ b/src/libANGLE/Context.h
@@ -366,6 +366,8 @@
GLsizei *length,
GLfloat *params);
void getTexParameteriv(TextureType target, GLenum pname, GLint *params);
+ void getTexParameterIiv(TextureType target, GLenum pname, GLint *params);
+ void getTexParameterIuiv(TextureType target, GLenum pname, GLuint *params);
void getTexParameterivRobust(TextureType target,
GLenum pname,
GLsizei bufSize,
@@ -404,6 +406,8 @@
const GLfloat *params);
void texParameteri(TextureType target, GLenum pname, GLint param);
void texParameteriv(TextureType target, GLenum pname, const GLint *params);
+ void texParameterIiv(TextureType target, GLenum pname, const GLint *params);
+ void texParameterIuiv(TextureType target, GLenum pname, const GLuint *params);
void texParameterivRobust(TextureType target,
GLenum pname,
GLsizei bufSize,
@@ -418,6 +422,8 @@
const GLuint *params);
void samplerParameteri(GLuint sampler, GLenum pname, GLint param);
void samplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void samplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void samplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
void samplerParameterivRobust(GLuint sampler,
GLenum pname,
GLsizei bufSize,
@@ -438,6 +444,8 @@
const GLfloat *param);
void getSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void getSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void getSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
void getSamplerParameterivRobust(GLuint sampler,
GLenum pname,
GLsizei bufSize,
diff --git a/src/libANGLE/Sampler.cpp b/src/libANGLE/Sampler.cpp
index 520dac2..91ff699 100644
--- a/src/libANGLE/Sampler.cpp
+++ b/src/libANGLE/Sampler.cpp
@@ -149,6 +149,16 @@
return mState.getSRGBDecode();
}
+void Sampler::setBorderColor(const ColorGeneric &color)
+{
+ mState.setBorderColor(color);
+}
+
+const ColorGeneric &Sampler::getBorderColor() const
+{
+ return mState.getBorderColor();
+}
+
const SamplerState &Sampler::getSamplerState() const
{
return mState;
diff --git a/src/libANGLE/Sampler.h b/src/libANGLE/Sampler.h
index b58efb3..ad81a67 100644
--- a/src/libANGLE/Sampler.h
+++ b/src/libANGLE/Sampler.h
@@ -68,6 +68,9 @@
void setSRGBDecode(GLenum sRGBDecode);
GLenum getSRGBDecode() const;
+ void setBorderColor(const ColorGeneric &color);
+ const ColorGeneric &getBorderColor() const;
+
const SamplerState &getSamplerState() const;
rx::SamplerImpl *getImplementation() const;
diff --git a/src/libANGLE/Texture.cpp b/src/libANGLE/Texture.cpp
index f93a58d..7a89241 100644
--- a/src/libANGLE/Texture.cpp
+++ b/src/libANGLE/Texture.cpp
@@ -280,8 +280,10 @@
bool npotSupport = data.getExtensions().textureNPOT || data.getClientMajorVersion() >= 3;
if (!npotSupport)
{
- if ((samplerState.getWrapS() != GL_CLAMP_TO_EDGE && !isPow2(baseImageDesc.size.width)) ||
- (samplerState.getWrapT() != GL_CLAMP_TO_EDGE && !isPow2(baseImageDesc.size.height)))
+ if ((samplerState.getWrapS() != GL_CLAMP_TO_EDGE &&
+ samplerState.getWrapS() != GL_CLAMP_TO_BORDER && !isPow2(baseImageDesc.size.width)) ||
+ (samplerState.getWrapT() != GL_CLAMP_TO_EDGE &&
+ samplerState.getWrapT() != GL_CLAMP_TO_BORDER && !isPow2(baseImageDesc.size.height)))
{
return false;
}
@@ -1525,6 +1527,17 @@
return getFixedSampleLocations(imageIndex.getTarget(), imageIndex.getLevelIndex());
}
+void Texture::setBorderColor(const ColorGeneric &color)
+{
+ mState.mSamplerState.setBorderColor(color);
+ mDirtyBits.set(DIRTY_BIT_BORDER_COLOR);
+}
+
+const ColorGeneric &Texture::getBorderColor() const
+{
+ return mState.mSamplerState.getBorderColor();
+}
+
void Texture::setCrop(const gl::Rectangle &rect)
{
mState.setCrop(rect);
diff --git a/src/libANGLE/Texture.h b/src/libANGLE/Texture.h
index d7589d7..44f2482 100644
--- a/src/libANGLE/Texture.h
+++ b/src/libANGLE/Texture.h
@@ -393,6 +393,9 @@
bool getAttachmentFixedSampleLocations(const ImageIndex &imageIndex) const;
+ void setBorderColor(const ColorGeneric &color);
+ const ColorGeneric &getBorderColor() const;
+
// GLES1 emulation
void setCrop(const gl::Rectangle &rect);
const gl::Rectangle &getCrop() const;
@@ -423,6 +426,7 @@
DIRTY_BIT_COMPARE_MODE,
DIRTY_BIT_COMPARE_FUNC,
DIRTY_BIT_SRGB_DECODE,
+ DIRTY_BIT_BORDER_COLOR,
// Texture state
DIRTY_BIT_SWIZZLE_RED,
diff --git a/src/libANGLE/angletypes.cpp b/src/libANGLE/angletypes.cpp
index f5663df..893d206 100644
--- a/src/libANGLE/angletypes.cpp
+++ b/src/libANGLE/angletypes.cpp
@@ -202,6 +202,11 @@
mSRGBDecode = sRGBDecode;
}
+void SamplerState::setBorderColor(const ColorGeneric &color)
+{
+ mBorderColor = color;
+}
+
void SamplerState::updateWrapTCompareMode()
{
uint8_t wrap = static_cast<uint8_t>(FromGLenum<WrapMode>(mWrapT));
diff --git a/src/libANGLE/angletypes.h b/src/libANGLE/angletypes.h
index c339fe9..f9ad818 100644
--- a/src/libANGLE/angletypes.h
+++ b/src/libANGLE/angletypes.h
@@ -274,6 +274,10 @@
void setSRGBDecode(GLenum sRGBDecode);
+ void setBorderColor(const ColorGeneric &color);
+
+ const ColorGeneric &getBorderColor() const { return mBorderColor; }
+
bool sameCompleteness(const SamplerState &samplerState) const
{
return mCompleteness.packed == samplerState.mCompleteness.packed;
@@ -300,6 +304,8 @@
GLenum mSRGBDecode;
+ ColorGeneric mBorderColor;
+
union Completeness {
uint32_t packed;
PackedSamplerCompleteness typed;
diff --git a/src/libANGLE/entry_points_enum_autogen.h b/src/libANGLE/entry_points_enum_autogen.h
index 0c7d971..68b4a12 100644
--- a/src/libANGLE/entry_points_enum_autogen.h
+++ b/src/libANGLE/entry_points_enum_autogen.h
@@ -287,7 +287,9 @@
GetRenderbufferParameteriv,
GetRenderbufferParameterivOES,
GetRenderbufferParameterivRobustANGLE,
+ GetSamplerParameterIivOES,
GetSamplerParameterIivRobustANGLE,
+ GetSamplerParameterIuivOES,
GetSamplerParameterIuivRobustANGLE,
GetSamplerParameterfv,
GetSamplerParameterfvRobustANGLE,
@@ -311,7 +313,9 @@
GetTexLevelParameterfvRobustANGLE,
GetTexLevelParameteriv,
GetTexLevelParameterivRobustANGLE,
+ GetTexParameterIivOES,
GetTexParameterIivRobustANGLE,
+ GetTexParameterIuivOES,
GetTexParameterIuivRobustANGLE,
GetTexParameterfv,
GetTexParameterfvRobustANGLE,
@@ -485,7 +489,9 @@
SampleCoverage,
SampleCoveragex,
SampleMaski,
+ SamplerParameterIivOES,
SamplerParameterIivRobustANGLE,
+ SamplerParameterIuivOES,
SamplerParameterIuivRobustANGLE,
SamplerParameterf,
SamplerParameterfv,
@@ -532,7 +538,9 @@
TexImage2DRobustANGLE,
TexImage3D,
TexImage3DRobustANGLE,
+ TexParameterIivOES,
TexParameterIivRobustANGLE,
+ TexParameterIuivOES,
TexParameterIuivRobustANGLE,
TexParameterf,
TexParameterfv,
diff --git a/src/libANGLE/queryconversions.cpp b/src/libANGLE/queryconversions.cpp
index 9c6e1d1..f9c4430 100644
--- a/src/libANGLE/queryconversions.cpp
+++ b/src/libANGLE/queryconversions.cpp
@@ -89,6 +89,7 @@
template GLint CastFromGLintStateValue<GLint, GLenum>(GLenum pname, GLenum value);
template GLint64 CastFromGLintStateValue<GLint64, GLenum>(GLenum pname, GLenum value);
template GLuint CastFromGLintStateValue<GLuint, GLenum>(GLenum pname, GLenum value);
+template GLuint CastFromGLintStateValue<GLuint, GLint>(GLenum pname, GLint value);
template GLfloat CastFromGLintStateValue<GLfloat, GLint>(GLenum pname, GLint value);
template GLint CastFromGLintStateValue<GLint, GLint>(GLenum pname, GLint value);
template GLfloat CastFromGLintStateValue<GLfloat, bool>(GLenum pname, bool value);
@@ -124,6 +125,7 @@
template GLfloat CastFromStateValue<GLfloat, GLuint>(GLenum pname, GLuint value);
template GLfloat CastFromStateValue<GLfloat, GLfloat>(GLenum pname, GLfloat value);
template GLint CastFromStateValue<GLint, GLfloat>(GLenum pname, GLfloat value);
+template GLuint CastFromStateValue<GLuint, GLfloat>(GLenum pname, GLfloat value);
template GLuint CastFromStateValue<GLuint, GLint>(GLenum pname, GLint value);
template GLuint CastFromStateValue<GLuint, GLuint>(GLenum pname, GLuint value);
template GLint CastFromStateValue<GLint, GLboolean>(GLenum pname, GLboolean value);
@@ -157,9 +159,12 @@
template GLint CastQueryValueTo<GLint, GLfloat>(GLenum pname, GLfloat value);
template GLboolean CastQueryValueTo<GLboolean, GLint>(GLenum pname, GLint value);
template GLint CastQueryValueTo<GLint, GLint>(GLenum pname, GLint value);
+template GLint CastQueryValueTo<GLint, GLuint>(GLenum pname, GLuint value);
template GLfloat CastQueryValueTo<GLfloat, GLint>(GLenum pname, GLint value);
+template GLfloat CastQueryValueTo<GLfloat, GLuint>(GLenum pname, GLuint value);
template GLfloat CastQueryValueTo<GLfloat, GLfloat>(GLenum pname, GLfloat value);
template GLuint CastQueryValueTo<GLuint, GLint>(GLenum pname, GLint value);
+template GLuint CastQueryValueTo<GLuint, GLuint>(GLenum pname, GLuint value);
template GLuint CastQueryValueTo<GLuint, GLfloat>(GLenum pname, GLfloat value);
template <typename QueryT>
diff --git a/src/libANGLE/queryutils.cpp b/src/libANGLE/queryutils.cpp
index c9eed4d..5362515 100644
--- a/src/libANGLE/queryutils.cpp
+++ b/src/libANGLE/queryutils.cpp
@@ -32,6 +32,100 @@
namespace
{
+template <bool isPureInteger>
+ColorGeneric ConvertToColor(const GLfloat *params)
+{
+ if (isPureInteger)
+ {
+ UNREACHABLE();
+ return ColorGeneric(ColorI());
+ }
+ else
+ {
+ return ColorGeneric(ColorF::fromData(params));
+ }
+}
+
+template <bool isPureInteger>
+ColorGeneric ConvertToColor(const GLint *params)
+{
+ if (isPureInteger)
+ {
+ return ColorGeneric(ColorI(params[0], params[1], params[2], params[3]));
+ }
+ else
+ {
+ return ColorGeneric(ColorF(normalizedToFloat(params[0]), normalizedToFloat(params[1]),
+ normalizedToFloat(params[2]), normalizedToFloat(params[3])));
+ }
+}
+
+template <bool isPureInteger>
+ColorGeneric ConvertToColor(const GLuint *params)
+{
+ if (isPureInteger)
+ {
+ return ColorGeneric(ColorUI(params[0], params[1], params[2], params[3]));
+ }
+ else
+ {
+ UNREACHABLE();
+ return ColorGeneric(ColorF());
+ }
+}
+
+template <bool isPureInteger>
+void ConvertFromColor(const ColorGeneric &color, GLfloat *outParams)
+{
+ if (isPureInteger)
+ {
+ UNREACHABLE();
+ }
+ else
+ {
+ ASSERT(color.type == ColorGeneric::Type::Float);
+ color.colorF.writeData(outParams);
+ }
+}
+
+template <bool isPureInteger>
+void ConvertFromColor(const ColorGeneric &color, GLint *outParams)
+{
+ if (isPureInteger)
+ {
+ ASSERT(color.type == ColorGeneric::Type::Int);
+ outParams[0] = color.colorI.red;
+ outParams[1] = color.colorI.green;
+ outParams[2] = color.colorI.blue;
+ outParams[3] = color.colorI.alpha;
+ }
+ else
+ {
+ ASSERT(color.type == ColorGeneric::Type::Float);
+ outParams[0] = floatToNormalized<GLint>(color.colorF.red);
+ outParams[1] = floatToNormalized<GLint>(color.colorF.green);
+ outParams[2] = floatToNormalized<GLint>(color.colorF.blue);
+ outParams[3] = floatToNormalized<GLint>(color.colorF.alpha);
+ }
+}
+
+template <bool isPureInteger>
+void ConvertFromColor(const ColorGeneric &color, GLuint *outParams)
+{
+ if (isPureInteger)
+ {
+ ASSERT(color.type == ColorGeneric::Type::UInt);
+ outParams[0] = color.colorUI.red;
+ outParams[1] = color.colorUI.green;
+ outParams[2] = color.colorUI.blue;
+ outParams[3] = color.colorUI.alpha;
+ }
+ else
+ {
+ UNREACHABLE();
+ }
+}
+
template <typename ParamType>
void QueryTexLevelParameterBase(const Texture *texture,
TextureTarget target,
@@ -121,7 +215,7 @@
}
}
-template <typename ParamType>
+template <bool isPureInteger, typename ParamType>
void QueryTexParameterBase(const Texture *texture, GLenum pname, ParamType *params)
{
ASSERT(texture != nullptr);
@@ -207,13 +301,16 @@
case GL_MEMORY_SIZE_ANGLE:
*params = CastFromStateValue<ParamType>(pname, texture->getMemorySize());
break;
+ case GL_TEXTURE_BORDER_COLOR:
+ ConvertFromColor<isPureInteger>(texture->getBorderColor(), params);
+ break;
default:
UNREACHABLE();
break;
}
}
-template <typename ParamType>
+template <bool isPureInteger, typename ParamType>
void SetTexParameterBase(Context *context, Texture *texture, GLenum pname, const ParamType *params)
{
ASSERT(texture != nullptr);
@@ -289,13 +386,16 @@
case GL_GENERATE_MIPMAP:
texture->setGenerateMipmapHint(ConvertToGLenum(params[0]));
break;
+ case GL_TEXTURE_BORDER_COLOR:
+ texture->setBorderColor(ConvertToColor<isPureInteger>(params));
+ break;
default:
UNREACHABLE();
break;
}
}
-template <typename ParamType>
+template <bool isPureInteger, typename ParamType>
void QuerySamplerParameterBase(const Sampler *sampler, GLenum pname, ParamType *params)
{
switch (pname)
@@ -333,13 +433,16 @@
case GL_TEXTURE_SRGB_DECODE_EXT:
*params = CastFromGLintStateValue<ParamType>(pname, sampler->getSRGBDecode());
break;
+ case GL_TEXTURE_BORDER_COLOR:
+ ConvertFromColor<isPureInteger>(sampler->getBorderColor(), params);
+ break;
default:
UNREACHABLE();
break;
}
}
-template <typename ParamType>
+template <bool isPureInteger, typename ParamType>
void SetSamplerParameterBase(Context *context,
Sampler *sampler,
GLenum pname,
@@ -380,6 +483,9 @@
case GL_TEXTURE_SRGB_DECODE_EXT:
sampler->setSRGBDecode(ConvertToGLenum(pname, params[0]));
break;
+ case GL_TEXTURE_BORDER_COLOR:
+ sampler->setBorderColor(ConvertToColor<isPureInteger>(params));
+ break;
default:
UNREACHABLE();
break;
@@ -1226,22 +1332,42 @@
void QueryTexParameterfv(const Texture *texture, GLenum pname, GLfloat *params)
{
- QueryTexParameterBase(texture, pname, params);
+ QueryTexParameterBase<false>(texture, pname, params);
}
void QueryTexParameteriv(const Texture *texture, GLenum pname, GLint *params)
{
- QueryTexParameterBase(texture, pname, params);
+ QueryTexParameterBase<false>(texture, pname, params);
+}
+
+void QueryTexParameterIiv(const Texture *texture, GLenum pname, GLint *params)
+{
+ QueryTexParameterBase<true>(texture, pname, params);
+}
+
+void QueryTexParameterIuiv(const Texture *texture, GLenum pname, GLuint *params)
+{
+ QueryTexParameterBase<true>(texture, pname, params);
}
void QuerySamplerParameterfv(const Sampler *sampler, GLenum pname, GLfloat *params)
{
- QuerySamplerParameterBase(sampler, pname, params);
+ QuerySamplerParameterBase<false>(sampler, pname, params);
}
void QuerySamplerParameteriv(const Sampler *sampler, GLenum pname, GLint *params)
{
- QuerySamplerParameterBase(sampler, pname, params);
+ QuerySamplerParameterBase<false>(sampler, pname, params);
+}
+
+void QuerySamplerParameterIiv(const Sampler *sampler, GLenum pname, GLint *params)
+{
+ QuerySamplerParameterBase<true>(sampler, pname, params);
+}
+
+void QuerySamplerParameterIuiv(const Sampler *sampler, GLenum pname, GLuint *params)
+{
+ QuerySamplerParameterBase<true>(sampler, pname, params);
}
void QueryVertexAttribfv(const VertexAttribute &attrib,
@@ -1408,42 +1534,62 @@
void SetTexParameterf(Context *context, Texture *texture, GLenum pname, GLfloat param)
{
- SetTexParameterBase(context, texture, pname, ¶m);
+ SetTexParameterBase<false>(context, texture, pname, ¶m);
}
void SetTexParameterfv(Context *context, Texture *texture, GLenum pname, const GLfloat *params)
{
- SetTexParameterBase(context, texture, pname, params);
+ SetTexParameterBase<false>(context, texture, pname, params);
}
void SetTexParameteri(Context *context, Texture *texture, GLenum pname, GLint param)
{
- SetTexParameterBase(context, texture, pname, ¶m);
+ SetTexParameterBase<false>(context, texture, pname, ¶m);
}
void SetTexParameteriv(Context *context, Texture *texture, GLenum pname, const GLint *params)
{
- SetTexParameterBase(context, texture, pname, params);
+ SetTexParameterBase<false>(context, texture, pname, params);
+}
+
+void SetTexParameterIiv(Context *context, Texture *texture, GLenum pname, const GLint *params)
+{
+ SetTexParameterBase<true>(context, texture, pname, params);
+}
+
+void SetTexParameterIuiv(Context *context, Texture *texture, GLenum pname, const GLuint *params)
+{
+ SetTexParameterBase<true>(context, texture, pname, params);
}
void SetSamplerParameterf(Context *context, Sampler *sampler, GLenum pname, GLfloat param)
{
- SetSamplerParameterBase(context, sampler, pname, ¶m);
+ SetSamplerParameterBase<false>(context, sampler, pname, ¶m);
}
void SetSamplerParameterfv(Context *context, Sampler *sampler, GLenum pname, const GLfloat *params)
{
- SetSamplerParameterBase(context, sampler, pname, params);
+ SetSamplerParameterBase<false>(context, sampler, pname, params);
}
void SetSamplerParameteri(Context *context, Sampler *sampler, GLenum pname, GLint param)
{
- SetSamplerParameterBase(context, sampler, pname, ¶m);
+ SetSamplerParameterBase<false>(context, sampler, pname, ¶m);
}
void SetSamplerParameteriv(Context *context, Sampler *sampler, GLenum pname, const GLint *params)
{
- SetSamplerParameterBase(context, sampler, pname, params);
+ SetSamplerParameterBase<false>(context, sampler, pname, params);
+}
+
+void SetSamplerParameterIiv(Context *context, Sampler *sampler, GLenum pname, const GLint *params)
+{
+ SetSamplerParameterBase<true>(context, sampler, pname, params);
+}
+
+void SetSamplerParameterIuiv(Context *context, Sampler *sampler, GLenum pname, const GLuint *params)
+{
+ SetSamplerParameterBase<true>(context, sampler, pname, params);
}
void SetFramebufferParameteri(const Context *context,
@@ -2573,6 +2719,7 @@
switch (pname)
{
case GL_TEXTURE_CROP_RECT_OES:
+ case GL_TEXTURE_BORDER_COLOR:
return 4;
case GL_TEXTURE_MAG_FILTER:
case GL_TEXTURE_MIN_FILTER:
diff --git a/src/libANGLE/queryutils.h b/src/libANGLE/queryutils.h
index a6598ee..22995fc 100644
--- a/src/libANGLE/queryutils.h
+++ b/src/libANGLE/queryutils.h
@@ -60,8 +60,12 @@
GLint *params);
void QueryTexParameterfv(const Texture *texture, GLenum pname, GLfloat *params);
void QueryTexParameteriv(const Texture *texture, GLenum pname, GLint *params);
+void QueryTexParameterIiv(const Texture *texture, GLenum pname, GLint *params);
+void QueryTexParameterIuiv(const Texture *texture, GLenum pname, GLuint *params);
void QuerySamplerParameterfv(const Sampler *sampler, GLenum pname, GLfloat *params);
void QuerySamplerParameteriv(const Sampler *sampler, GLenum pname, GLint *params);
+void QuerySamplerParameterIiv(const Sampler *sampler, GLenum pname, GLint *params);
+void QuerySamplerParameterIuiv(const Sampler *sampler, GLenum pname, GLuint *params);
// Warning: you should ensure binding really matches attrib.bindingIndex before using the following
// functions.
@@ -111,11 +115,18 @@
void SetTexParameterfv(Context *context, Texture *texture, GLenum pname, const GLfloat *params);
void SetTexParameteri(Context *context, Texture *texture, GLenum pname, GLint param);
void SetTexParameteriv(Context *context, Texture *texture, GLenum pname, const GLint *params);
+void SetTexParameterIiv(Context *context, Texture *texture, GLenum pname, const GLint *params);
+void SetTexParameterIuiv(Context *context, Texture *texture, GLenum pname, const GLuint *params);
void SetSamplerParameterf(Context *context, Sampler *sampler, GLenum pname, GLfloat param);
void SetSamplerParameterfv(Context *context, Sampler *sampler, GLenum pname, const GLfloat *params);
void SetSamplerParameteri(Context *context, Sampler *sampler, GLenum pname, GLint param);
void SetSamplerParameteriv(Context *context, Sampler *sampler, GLenum pname, const GLint *params);
+void SetSamplerParameterIiv(Context *context, Sampler *sampler, GLenum pname, const GLint *params);
+void SetSamplerParameterIuiv(Context *context,
+ Sampler *sampler,
+ GLenum pname,
+ const GLuint *params);
void SetFramebufferParameteri(const Context *context,
Framebuffer *framebuffer,
diff --git a/src/libANGLE/renderer/d3d/d3d11/RenderStateCache.cpp b/src/libANGLE/renderer/d3d/d3d11/RenderStateCache.cpp
index 899b382..097093e 100644
--- a/src/libANGLE/renderer/d3d/d3d11/RenderStateCache.cpp
+++ b/src/libANGLE/renderer/d3d/d3d11/RenderStateCache.cpp
@@ -11,6 +11,7 @@
#include <float.h>
+#include "common/Color.h"
#include "common/debug.h"
#include "libANGLE/Context.h"
#include "libANGLE/Framebuffer.h"
@@ -250,10 +251,15 @@
samplerDesc.MaxAnisotropy =
gl_d3d11::ConvertMaxAnisotropy(samplerState.getMaxAnisotropy(), featureLevel);
samplerDesc.ComparisonFunc = gl_d3d11::ConvertComparison(samplerState.getCompareFunc());
- samplerDesc.BorderColor[0] = 0.0f;
- samplerDesc.BorderColor[1] = 0.0f;
- samplerDesc.BorderColor[2] = 0.0f;
- samplerDesc.BorderColor[3] = 0.0f;
+ angle::ColorF borderColor;
+ if (samplerState.getBorderColor().type == angle::ColorGeneric::Type::Float)
+ {
+ borderColor = samplerState.getBorderColor().colorF;
+ }
+ samplerDesc.BorderColor[0] = borderColor.red;
+ samplerDesc.BorderColor[1] = borderColor.green;
+ samplerDesc.BorderColor[2] = borderColor.blue;
+ samplerDesc.BorderColor[3] = borderColor.alpha;
samplerDesc.MinLOD = samplerState.getMinLod();
samplerDesc.MaxLOD = samplerState.getMaxLod();
diff --git a/src/libANGLE/renderer/d3d/d3d11/StateManager11.cpp b/src/libANGLE/renderer/d3d/d3d11/StateManager11.cpp
index 1e71120..539b6ce 100644
--- a/src/libANGLE/renderer/d3d/d3d11/StateManager11.cpp
+++ b/src/libANGLE/renderer/d3d/d3d11/StateManager11.cpp
@@ -115,10 +115,12 @@
switch (wrap)
{
case GL_CLAMP_TO_EDGE:
- return 0x1;
+ return 0x0;
case GL_REPEAT:
- return 0x2;
+ return 0x1;
case GL_MIRRORED_REPEAT:
+ return 0x2;
+ case GL_CLAMP_TO_BORDER:
return 0x3;
default:
UNREACHABLE();
@@ -301,7 +303,9 @@
mNumActiveShaderSamplers.fill(0);
}
-bool ShaderConstants11::updateSamplerMetadata(SamplerMetadata *data, const gl::Texture &texture)
+bool ShaderConstants11::updateSamplerMetadata(SamplerMetadata *data,
+ const gl::Texture &texture,
+ const gl::SamplerState &samplerState)
{
bool dirty = false;
unsigned int baseLevel = texture.getTextureState().getEffectiveBaseLevel();
@@ -369,17 +373,30 @@
data->internalFormatBits = internalFormatBits;
dirty = true;
}
- // Pack the wrap values into one integer so we can fit all the metadata in one 4-integer
- // vector.
- GLenum wrapS = texture.getWrapS();
- GLenum wrapT = texture.getWrapT();
- GLenum wrapR = texture.getWrapR();
+ // Pack the wrap values into one integer so we can fit all the metadata in two 4-integer
+ // vectors.
+ GLenum wrapS = samplerState.getWrapS();
+ GLenum wrapT = samplerState.getWrapT();
+ GLenum wrapR = samplerState.getWrapR();
int wrapModes = GetWrapBits(wrapS) | (GetWrapBits(wrapT) << 2) | (GetWrapBits(wrapR) << 4);
if (data->wrapModes != wrapModes)
{
data->wrapModes = wrapModes;
dirty = true;
}
+
+ const angle::ColorGeneric &borderColor(samplerState.getBorderColor());
+ constexpr int kBlack[4] = {0};
+ const void *const intBorderColor = (borderColor.type == angle::ColorGeneric::Type::Float)
+ ? kBlack
+ : borderColor.colorI.data();
+ ASSERT(static_cast<const void *>(borderColor.colorI.data()) ==
+ static_cast<const void *>(borderColor.colorUI.data()));
+ if (memcmp(data->intBorderColor, intBorderColor, sizeof(data->intBorderColor)) != 0)
+ {
+ memcpy(data->intBorderColor, intBorderColor, sizeof(data->intBorderColor));
+ dirty = true;
+ }
}
return dirty;
@@ -462,10 +479,12 @@
void ShaderConstants11::onSamplerChange(gl::ShaderType shaderType,
unsigned int samplerIndex,
- const gl::Texture &texture)
+ const gl::Texture &texture,
+ const gl::SamplerState &samplerState)
{
ASSERT(shaderType != gl::ShaderType::InvalidEnum);
- if (updateSamplerMetadata(&mShaderSamplerMetadata[shaderType][samplerIndex], texture))
+ if (updateSamplerMetadata(&mShaderSamplerMetadata[shaderType][samplerIndex], texture,
+ samplerState))
{
mNumActiveShaderSamplers[shaderType] = 0;
}
@@ -2504,7 +2523,7 @@
// sampler state since having it in contiguous memory makes it possible to memcpy to a constant
// buffer, and it doesn't affect the state set by
// PSSetSamplers/VSSetSamplers/CSSetSamplers/GSSetSamplers.
- mShaderConstants.onSamplerChange(type, index, *texture);
+ mShaderConstants.onSamplerChange(type, index, *texture, samplerState);
return angle::Result::Continue();
}
diff --git a/src/libANGLE/renderer/d3d/d3d11/StateManager11.h b/src/libANGLE/renderer/d3d/d3d11/StateManager11.h
index 210aad9..60c5a1d 100644
--- a/src/libANGLE/renderer/d3d/d3d11/StateManager11.h
+++ b/src/libANGLE/renderer/d3d/d3d11/StateManager11.h
@@ -47,7 +47,8 @@
bool presentPathFast);
void onSamplerChange(gl::ShaderType shaderType,
unsigned int samplerIndex,
- const gl::Texture &texture);
+ const gl::Texture &texture,
+ const gl::SamplerState &samplerState);
angle::Result updateBuffer(const gl::Context *context,
Renderer11 *renderer,
@@ -115,21 +116,27 @@
struct SamplerMetadata
{
- SamplerMetadata() : baseLevel(0), internalFormatBits(0), wrapModes(0), padding(0) {}
+ SamplerMetadata()
+ : baseLevel(0), internalFormatBits(0), wrapModes(0), padding(0), intBorderColor{0}
+ {
+ }
int baseLevel;
int internalFormatBits;
int wrapModes;
- int padding; // This just pads the struct to 16 bytes
+ int padding; // This just pads the struct to 32 bytes
+ int intBorderColor[4];
};
- static_assert(sizeof(SamplerMetadata) == 16u,
- "Sampler metadata struct must be one 4-vec / 16 bytes.");
+ static_assert(sizeof(SamplerMetadata) == 32u,
+ "Sampler metadata struct must be two 4-vec --> 32 bytes.");
static size_t GetShaderConstantsStructSize(gl::ShaderType shaderType);
// Return true if dirty.
- bool updateSamplerMetadata(SamplerMetadata *data, const gl::Texture &texture);
+ bool updateSamplerMetadata(SamplerMetadata *data,
+ const gl::Texture &texture,
+ const gl::SamplerState &samplerState);
Vertex mVertex;
Pixel mPixel;
diff --git a/src/libANGLE/renderer/d3d/d3d11/renderer11_utils.cpp b/src/libANGLE/renderer/d3d/d3d11/renderer11_utils.cpp
index 3c8b2e4..f02c439 100644
--- a/src/libANGLE/renderer/d3d/d3d11/renderer11_utils.cpp
+++ b/src/libANGLE/renderer/d3d/d3d11/renderer11_utils.cpp
@@ -1614,6 +1614,7 @@
extensions->multiviewMultisample =
(extensions->multiview && extensions->textureStorageMultisample2DArray);
extensions->copyTexture3d = true;
+ extensions->textureBorderClamp = true;
// D3D11 Feature Level 10_0+ uses SV_IsFrontFace in HLSL to emulate gl_FrontFacing.
// D3D11 Feature Level 9_3 doesn't support SV_IsFrontFace, and has no equivalent, so can't support gl_FrontFacing.
@@ -1949,6 +1950,8 @@
return D3D11_TEXTURE_ADDRESS_WRAP;
case GL_CLAMP_TO_EDGE:
return D3D11_TEXTURE_ADDRESS_CLAMP;
+ case GL_CLAMP_TO_BORDER:
+ return D3D11_TEXTURE_ADDRESS_BORDER;
case GL_MIRRORED_REPEAT:
return D3D11_TEXTURE_ADDRESS_MIRROR;
default:
diff --git a/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp b/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
index 2e564b1..cf5d8ce 100644
--- a/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
+++ b/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
@@ -964,6 +964,10 @@
static_cast<DWORD>(samplerState.getMaxAnisotropy()));
mDevice->SetSamplerState(d3dSampler, D3DSAMP_MAXANISOTROPY, maxAnisotropy);
}
+
+ ASSERT(texture->getBorderColor().type == angle::ColorGeneric::Type::Float);
+ mDevice->SetSamplerState(d3dSampler, D3DSAMP_BORDERCOLOR,
+ gl_d3d9::ConvertColor(texture->getBorderColor().colorF));
}
appliedSampler.forceSet = false;
diff --git a/src/libANGLE/renderer/d3d/d3d9/renderer9_utils.cpp b/src/libANGLE/renderer/d3d/d3d9/renderer9_utils.cpp
index 6d38193..c057597 100644
--- a/src/libANGLE/renderer/d3d/d3d9/renderer9_utils.cpp
+++ b/src/libANGLE/renderer/d3d/d3d9/renderer9_utils.cpp
@@ -126,6 +126,7 @@
{
case GL_REPEAT: d3dWrap = D3DTADDRESS_WRAP; break;
case GL_CLAMP_TO_EDGE: d3dWrap = D3DTADDRESS_CLAMP; break;
+ case GL_CLAMP_TO_BORDER: d3dWrap = D3DTADDRESS_BORDER; break;
case GL_MIRRORED_REPEAT: d3dWrap = D3DTADDRESS_MIRROR; break;
default: UNREACHABLE();
}
@@ -619,6 +620,7 @@
extensions->packSubimage = true;
extensions->syncQuery = extensions->fence;
extensions->copyTexture = true;
+ extensions->textureBorderClamp = true;
// D3D9 has no concept of separate masks and refs for front and back faces in the depth stencil
// state.
diff --git a/src/libANGLE/renderer/gl/SamplerGL.cpp b/src/libANGLE/renderer/gl/SamplerGL.cpp
index e18adbd..b456af6 100644
--- a/src/libANGLE/renderer/gl/SamplerGL.cpp
+++ b/src/libANGLE/renderer/gl/SamplerGL.cpp
@@ -14,6 +14,37 @@
namespace
{
+template <typename T>
+inline void SetSamplerParameter(const rx::FunctionsGL *functions,
+ GLuint sampler,
+ GLenum name,
+ const T &value)
+{
+ functions->samplerParameterf(sampler, name, static_cast<GLfloat>(value));
+}
+
+inline void SetSamplerParameter(const rx::FunctionsGL *functions,
+ GLuint sampler,
+ GLenum name,
+ const angle::ColorGeneric &value)
+{
+ switch (value.type)
+ {
+ case angle::ColorGeneric::Type::Float:
+ functions->samplerParameterfv(sampler, name, &value.colorF.red);
+ break;
+ case angle::ColorGeneric::Type::Int:
+ functions->samplerParameterIiv(sampler, name, &value.colorI.red);
+ break;
+ case angle::ColorGeneric::Type::UInt:
+ functions->samplerParameterIuiv(sampler, name, &value.colorUI.red);
+ break;
+ default:
+ UNREACHABLE();
+ break;
+ }
+}
+
template <typename Getter, typename Setter>
static inline void SyncSamplerStateMember(const rx::FunctionsGL *functions,
GLuint sampler,
@@ -26,7 +57,7 @@
if ((curState.*getter)() != (newState.*getter)())
{
(curState.*setter)((newState.*getter)());
- functions->samplerParameterf(sampler, name, static_cast<GLfloat>((curState.*getter)()));
+ SetSamplerParameter(functions, sampler, name, (newState.*getter)());
}
}
}
@@ -66,6 +97,7 @@
SyncSamplerStateMember(mFunctions, mSamplerID, mState, mAppliedSamplerState, GL_TEXTURE_COMPARE_MODE, &gl::SamplerState::getCompareMode, &gl::SamplerState::setCompareMode);
SyncSamplerStateMember(mFunctions, mSamplerID, mState, mAppliedSamplerState, GL_TEXTURE_COMPARE_FUNC, &gl::SamplerState::getCompareFunc, &gl::SamplerState::setCompareFunc);
SyncSamplerStateMember(mFunctions, mSamplerID, mState, mAppliedSamplerState, GL_TEXTURE_SRGB_DECODE_EXT, &gl::SamplerState::getSRGBDecode, &gl::SamplerState::setSRGBDecode);
+ SyncSamplerStateMember(mFunctions, mSamplerID, mState, mAppliedSamplerState, GL_TEXTURE_BORDER_COLOR, &gl::SamplerState::getBorderColor, &gl::SamplerState::setBorderColor);
// clang-format on
}
diff --git a/src/libANGLE/renderer/gl/TextureGL.cpp b/src/libANGLE/renderer/gl/TextureGL.cpp
index 1ea4573..03ed1b8 100644
--- a/src/libANGLE/renderer/gl/TextureGL.cpp
+++ b/src/libANGLE/renderer/gl/TextureGL.cpp
@@ -1224,6 +1224,30 @@
functions->texParameteri(ToGLenum(getType()), GL_TEXTURE_SRGB_DECODE_EXT,
mAppliedSampler.getSRGBDecode());
break;
+ case gl::Texture::DIRTY_BIT_BORDER_COLOR:
+ {
+ const angle::ColorGeneric &borderColor(mState.getSamplerState().getBorderColor());
+ mAppliedSampler.setBorderColor(borderColor);
+ switch (borderColor.type)
+ {
+ case angle::ColorGeneric::Type::Float:
+ functions->texParameterfv(ToGLenum(getType()), GL_TEXTURE_BORDER_COLOR,
+ &borderColor.colorF.red);
+ break;
+ case angle::ColorGeneric::Type::Int:
+ functions->texParameterIiv(ToGLenum(getType()), GL_TEXTURE_BORDER_COLOR,
+ &borderColor.colorI.red);
+ break;
+ case angle::ColorGeneric::Type::UInt:
+ functions->texParameterIuiv(ToGLenum(getType()), GL_TEXTURE_BORDER_COLOR,
+ &borderColor.colorUI.red);
+ break;
+ default:
+ UNREACHABLE();
+ break;
+ }
+ break;
+ }
// Texture state
case gl::Texture::DIRTY_BIT_SWIZZLE_RED:
diff --git a/src/libANGLE/renderer/gl/renderergl_utils.cpp b/src/libANGLE/renderer/gl/renderergl_utils.cpp
index 71c105a..6d853ba 100644
--- a/src/libANGLE/renderer/gl/renderergl_utils.cpp
+++ b/src/libANGLE/renderer/gl/renderergl_utils.cpp
@@ -975,6 +975,10 @@
functions->hasGLExtension("GL_EXT_framebuffer_object") ||
functions->isAtLeastGLES(gl::Version(3, 0)) ||
functions->hasGLESExtension("GL_OES_fbo_render_mipmap");
+ extensions->textureBorderClamp = functions->standard == STANDARD_GL_DESKTOP ||
+ functions->hasGLESExtension("GL_OES_texture_border_clamp") ||
+ functions->hasGLESExtension("GL_EXT_texture_border_clamp") ||
+ functions->hasGLESExtension("GL_NV_texture_border_clamp");
extensions->instancedArrays = functions->isAtLeastGL(gl::Version(3, 1)) ||
(functions->hasGLExtension("GL_ARB_instanced_arrays") &&
(functions->hasGLExtension("GL_ARB_draw_instanced") ||
diff --git a/src/libANGLE/renderer/vulkan/vk_caps_utils.cpp b/src/libANGLE/renderer/vulkan/vk_caps_utils.cpp
index ae95155..fa7fb72 100644
--- a/src/libANGLE/renderer/vulkan/vk_caps_utils.cpp
+++ b/src/libANGLE/renderer/vulkan/vk_caps_utils.cpp
@@ -48,6 +48,7 @@
outExtensions->copyTexture = true;
outExtensions->debugMarker = true;
outExtensions->robustness = true;
+ outExtensions->textureBorderClamp = false; // not implemented yet
// We use secondary command buffers almost everywhere and they require a feature to be
// able to execute in the presence of queries. As a result, we won't support queries
diff --git a/src/libANGLE/validationES.cpp b/src/libANGLE/validationES.cpp
index 37c424d..2322240 100644
--- a/src/libANGLE/validationES.cpp
+++ b/src/libANGLE/validationES.cpp
@@ -229,6 +229,14 @@
case GL_CLAMP_TO_EDGE:
break;
+ case GL_CLAMP_TO_BORDER:
+ if (!context->getExtensions().textureBorderClamp)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidEnum(), ExtensionNotEnabled);
+ return false;
+ }
+ break;
+
case GL_REPEAT:
case GL_MIRRORED_REPEAT:
if (restrictedWrapModes)
@@ -462,6 +470,12 @@
return false;
}
}
+
+unsigned int GetSamplerParameterCount(GLenum pname)
+{
+ return pname == GL_TEXTURE_BORDER_COLOR ? 4 : 1;
+}
+
} // anonymous namespace
void SetRobustLengthParam(GLsizei *length, GLsizei value)
@@ -4703,7 +4717,7 @@
return false;
}
- return ValidateTexParameterBase(context, target, pname, bufSize, params);
+ return ValidateTexParameterBase(context, target, pname, bufSize, true, params);
}
bool ValidateTexParameterivRobustANGLE(Context *context,
@@ -4717,7 +4731,7 @@
return false;
}
- return ValidateTexParameterBase(context, target, pname, bufSize, params);
+ return ValidateTexParameterBase(context, target, pname, bufSize, true, params);
}
bool ValidateTexParameterIivRobustANGLE(Context *context,
@@ -4829,7 +4843,7 @@
return false;
}
- return ValidateSamplerParameterBase(context, sampler, pname, bufSize, params);
+ return ValidateSamplerParameterBase(context, sampler, pname, bufSize, true, params);
}
bool ValidateSamplerParameterivRobustANGLE(Context *context,
@@ -4843,7 +4857,7 @@
return false;
}
- return ValidateSamplerParameterBase(context, sampler, pname, bufSize, params);
+ return ValidateSamplerParameterBase(context, sampler, pname, bufSize, true, params);
}
bool ValidateSamplerParameterIivRobustANGLE(Context *context,
@@ -5531,6 +5545,14 @@
}
break;
+ case GL_TEXTURE_BORDER_COLOR:
+ if (!context->getExtensions().textureBorderClamp)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidEnum(), ExtensionNotEnabled);
+ return false;
+ }
+ break;
+
default:
ANGLE_VALIDATION_ERR(context, InvalidEnum(), EnumNotSupported);
return false;
@@ -5880,6 +5902,7 @@
TextureType target,
GLenum pname,
GLsizei bufSize,
+ bool vectorParams,
const ParamType *params)
{
if (!ValidTextureTarget(context, target) && !ValidTextureExternalTarget(context, target))
@@ -5960,6 +5983,7 @@
case GL_TEXTURE_MAX_LOD:
case GL_TEXTURE_COMPARE_MODE:
case GL_TEXTURE_COMPARE_FUNC:
+ case GL_TEXTURE_BORDER_COLOR:
context->handleError(InvalidEnum()
<< "Invalid parameter for 2D multisampled textures.");
return false;
@@ -6130,13 +6154,39 @@
break;
case GL_GENERATE_MIPMAP:
- case GL_TEXTURE_CROP_RECT_OES:
if (context->getClientMajorVersion() > 1)
{
ANGLE_VALIDATION_ERR(context, InvalidEnum(), GLES1Only);
return false;
}
break;
+
+ case GL_TEXTURE_CROP_RECT_OES:
+ if (context->getClientMajorVersion() > 1)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidEnum(), GLES1Only);
+ return false;
+ }
+ if (!vectorParams)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidOperation(), InsufficientBufferSize);
+ return false;
+ }
+ break;
+
+ case GL_TEXTURE_BORDER_COLOR:
+ if (!context->getExtensions().textureBorderClamp)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidEnum(), ExtensionNotEnabled);
+ return false;
+ }
+ if (!vectorParams)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidEnum(), InsufficientBufferSize);
+ return false;
+ }
+ break;
+
default:
ANGLE_VALIDATION_ERR(context, InvalidEnum(), EnumNotSupported);
return false;
@@ -6145,8 +6195,24 @@
return true;
}
-template bool ValidateTexParameterBase(Context *, TextureType, GLenum, GLsizei, const GLfloat *);
-template bool ValidateTexParameterBase(Context *, TextureType, GLenum, GLsizei, const GLint *);
+template bool ValidateTexParameterBase(Context *,
+ TextureType,
+ GLenum,
+ GLsizei,
+ bool,
+ const GLfloat *);
+template bool ValidateTexParameterBase(Context *,
+ TextureType,
+ GLenum,
+ GLsizei,
+ bool,
+ const GLint *);
+template bool ValidateTexParameterBase(Context *,
+ TextureType,
+ GLenum,
+ GLsizei,
+ bool,
+ const GLuint *);
bool ValidateVertexAttribIndex(Context *context, GLuint index)
{
@@ -6227,6 +6293,7 @@
GLuint sampler,
GLenum pname,
GLsizei bufSize,
+ bool vectorParams,
ParamType *params)
{
if (context->getClientMajorVersion() < 3)
@@ -6241,7 +6308,7 @@
return false;
}
- const GLsizei minBufSize = 1;
+ const GLsizei minBufSize = GetSamplerParameterCount(pname);
if (bufSize >= 0 && bufSize < minBufSize)
{
ANGLE_VALIDATION_ERR(context, InvalidOperation(), InsufficientBufferSize);
@@ -6309,6 +6376,19 @@
}
break;
+ case GL_TEXTURE_BORDER_COLOR:
+ if (!context->getExtensions().textureBorderClamp)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidEnum(), ExtensionNotEnabled);
+ return false;
+ }
+ if (!vectorParams)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidEnum(), InsufficientBufferSize);
+ return false;
+ }
+ break;
+
default:
ANGLE_VALIDATION_ERR(context, InvalidEnum(), EnumNotSupported);
return false;
@@ -6317,8 +6397,14 @@
return true;
}
-template bool ValidateSamplerParameterBase(Context *, GLuint, GLenum, GLsizei, GLfloat *);
-template bool ValidateSamplerParameterBase(Context *, GLuint, GLenum, GLsizei, GLint *);
+template bool ValidateSamplerParameterBase(Context *, GLuint, GLenum, GLsizei, bool, GLfloat *);
+template bool ValidateSamplerParameterBase(Context *, GLuint, GLenum, GLsizei, bool, GLint *);
+template bool ValidateSamplerParameterBase(Context *,
+ GLuint,
+ GLenum,
+ GLsizei,
+ bool,
+ const GLuint *);
bool ValidateGetSamplerParameterBase(Context *context,
GLuint sampler,
@@ -6370,6 +6456,14 @@
}
break;
+ case GL_TEXTURE_BORDER_COLOR:
+ if (!context->getExtensions().textureBorderClamp)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidEnum(), ExtensionNotEnabled);
+ return false;
+ }
+ break;
+
default:
ANGLE_VALIDATION_ERR(context, InvalidEnum(), EnumNotSupported);
return false;
@@ -6377,7 +6471,7 @@
if (length)
{
- *length = 1;
+ *length = GetSamplerParameterCount(pname);
}
return true;
}
diff --git a/src/libANGLE/validationES.h b/src/libANGLE/validationES.h
index b6d9c2b..5afc576 100644
--- a/src/libANGLE/validationES.h
+++ b/src/libANGLE/validationES.h
@@ -524,6 +524,7 @@
TextureType target,
GLenum pname,
GLsizei bufSize,
+ bool vectorParams,
const ParamType *params);
bool ValidateTexParameterfvRobustANGLE(Context *context,
TextureType target,
@@ -680,6 +681,7 @@
GLuint sampler,
GLenum pname,
GLsizei bufSize,
+ bool vectorParams,
ParamType *params);
bool ValidateGetInternalFormativBase(Context *context,
diff --git a/src/libANGLE/validationES1.cpp b/src/libANGLE/validationES1.cpp
index 6967a6c..b8b73e7 100644
--- a/src/libANGLE/validationES1.cpp
+++ b/src/libANGLE/validationES1.cpp
@@ -1312,7 +1312,7 @@
{
ANGLE_VALIDATE_IS_GLES1(context);
GLfloat paramf = FixedToFloat(param);
- return ValidateTexParameterBase(context, target, pname, 1, ¶mf);
+ return ValidateTexParameterBase(context, target, pname, -1, false, ¶mf);
}
bool ValidateTexParameterxv(Context *context,
@@ -1326,7 +1326,7 @@
{
paramsf[i] = FixedToFloat(params[i]);
}
- return ValidateTexParameterBase(context, target, pname, -1, paramsf);
+ return ValidateTexParameterBase(context, target, pname, -1, true, paramsf);
}
bool ValidateTranslatef(Context *context, GLfloat x, GLfloat y, GLfloat z)
diff --git a/src/libANGLE/validationES2.cpp b/src/libANGLE/validationES2.cpp
index 8db6a85..e754e5d 100644
--- a/src/libANGLE/validationES2.cpp
+++ b/src/libANGLE/validationES2.cpp
@@ -6203,6 +6203,32 @@
return ValidateGetTexParameterBase(context, target, pname, nullptr);
}
+bool ValidateGetTexParameterIivOES(Context *context,
+ TextureType target,
+ GLenum pname,
+ GLint *params)
+{
+ if (context->getClientMajorVersion() < 3)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidOperation(), ES3Required);
+ return false;
+ }
+ return ValidateGetTexParameterBase(context, target, pname, nullptr);
+}
+
+bool ValidateGetTexParameterIuivOES(Context *context,
+ TextureType target,
+ GLenum pname,
+ GLuint *params)
+{
+ if (context->getClientMajorVersion() < 3)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidOperation(), ES3Required);
+ return false;
+ }
+ return ValidateGetTexParameterBase(context, target, pname, nullptr);
+}
+
bool ValidateGetUniformfv(Context *context, GLuint program, GLint location, GLfloat *params)
{
return ValidateGetUniformBase(context, program, location);
@@ -6274,7 +6300,7 @@
bool ValidateTexParameterf(Context *context, TextureType target, GLenum pname, GLfloat param)
{
- return ValidateTexParameterBase(context, target, pname, 1, ¶m);
+ return ValidateTexParameterBase(context, target, pname, -1, false, ¶m);
}
bool ValidateTexParameterfv(Context *context,
@@ -6282,17 +6308,43 @@
GLenum pname,
const GLfloat *params)
{
- return ValidateTexParameterBase(context, target, pname, -1, params);
+ return ValidateTexParameterBase(context, target, pname, -1, true, params);
}
bool ValidateTexParameteri(Context *context, TextureType target, GLenum pname, GLint param)
{
- return ValidateTexParameterBase(context, target, pname, 1, ¶m);
+ return ValidateTexParameterBase(context, target, pname, -1, false, ¶m);
}
bool ValidateTexParameteriv(Context *context, TextureType target, GLenum pname, const GLint *params)
{
- return ValidateTexParameterBase(context, target, pname, -1, params);
+ return ValidateTexParameterBase(context, target, pname, -1, true, params);
+}
+
+bool ValidateTexParameterIivOES(Context *context,
+ TextureType target,
+ GLenum pname,
+ const GLint *params)
+{
+ if (context->getClientMajorVersion() < 3)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidOperation(), ES3Required);
+ return false;
+ }
+ return ValidateTexParameterBase(context, target, pname, -1, true, params);
+}
+
+bool ValidateTexParameterIuivOES(Context *context,
+ TextureType target,
+ GLenum pname,
+ const GLuint *params)
+{
+ if (context->getClientMajorVersion() < 3)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidOperation(), ES3Required);
+ return false;
+ }
+ return ValidateTexParameterBase(context, target, pname, -1, true, params);
}
bool ValidateUseProgram(Context *context, GLuint program)
diff --git a/src/libANGLE/validationES2.h b/src/libANGLE/validationES2.h
index 7ee5029..30589c7 100644
--- a/src/libANGLE/validationES2.h
+++ b/src/libANGLE/validationES2.h
@@ -648,6 +648,14 @@
bool ValidateGetShaderiv(Context *context, GLuint shader, GLenum pname, GLint *params);
bool ValidateGetTexParameterfv(Context *context, TextureType target, GLenum pname, GLfloat *params);
bool ValidateGetTexParameteriv(Context *context, TextureType target, GLenum pname, GLint *params);
+bool ValidateGetTexParameterIivOES(Context *context,
+ TextureType target,
+ GLenum pname,
+ GLint *params);
+bool ValidateGetTexParameterIuivOES(Context *context,
+ TextureType target,
+ GLenum pname,
+ GLuint *params);
bool ValidateGetUniformfv(Context *context, GLuint program, GLint location, GLfloat *params);
bool ValidateGetUniformiv(Context *context, GLuint program, GLint location, GLint *params);
bool ValidateGetVertexAttribfv(Context *context, GLuint index, GLenum pname, GLfloat *params);
@@ -673,6 +681,14 @@
TextureType target,
GLenum pname,
const GLint *params);
+bool ValidateTexParameterIivOES(Context *context,
+ TextureType target,
+ GLenum pname,
+ const GLint *params);
+bool ValidateTexParameterIuivOES(Context *context,
+ TextureType target,
+ GLenum pname,
+ const GLuint *params);
bool ValidateUniform1iv(Context *context, GLint location, GLsizei count, const GLint *value);
bool ValidateUseProgram(Context *context, GLuint program);
diff --git a/src/libANGLE/validationES3.cpp b/src/libANGLE/validationES3.cpp
index cd2a286..d5719fc 100644
--- a/src/libANGLE/validationES3.cpp
+++ b/src/libANGLE/validationES3.cpp
@@ -4023,9 +4023,35 @@
return ValidateGetSamplerParameterBase(context, sampler, pname, nullptr);
}
+bool ValidateGetSamplerParameterIivOES(Context *context,
+ GLuint sampler,
+ GLenum pname,
+ const GLint *params)
+{
+ if (context->getClientMajorVersion() < 3)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidOperation(), ES3Required);
+ return false;
+ }
+ return ValidateGetSamplerParameterBase(context, sampler, pname, nullptr);
+}
+
+bool ValidateGetSamplerParameterIuivOES(Context *context,
+ GLuint sampler,
+ GLenum pname,
+ const GLuint *params)
+{
+ if (context->getClientMajorVersion() < 3)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidOperation(), ES3Required);
+ return false;
+ }
+ return ValidateGetSamplerParameterBase(context, sampler, pname, nullptr);
+}
+
bool ValidateSamplerParameterf(Context *context, GLuint sampler, GLenum pname, GLfloat param)
{
- return ValidateSamplerParameterBase(context, sampler, pname, -1, ¶m);
+ return ValidateSamplerParameterBase(context, sampler, pname, -1, false, ¶m);
}
bool ValidateSamplerParameterfv(Context *context,
@@ -4033,17 +4059,43 @@
GLenum pname,
const GLfloat *params)
{
- return ValidateSamplerParameterBase(context, sampler, pname, -1, params);
+ return ValidateSamplerParameterBase(context, sampler, pname, -1, true, params);
}
bool ValidateSamplerParameteri(Context *context, GLuint sampler, GLenum pname, GLint param)
{
- return ValidateSamplerParameterBase(context, sampler, pname, -1, ¶m);
+ return ValidateSamplerParameterBase(context, sampler, pname, -1, false, ¶m);
}
bool ValidateSamplerParameteriv(Context *context, GLuint sampler, GLenum pname, const GLint *params)
{
- return ValidateSamplerParameterBase(context, sampler, pname, -1, params);
+ return ValidateSamplerParameterBase(context, sampler, pname, -1, true, params);
+}
+
+bool ValidateSamplerParameterIivOES(Context *context,
+ GLuint sampler,
+ GLenum pname,
+ const GLint *params)
+{
+ if (context->getClientMajorVersion() < 3)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidOperation(), ES3Required);
+ return false;
+ }
+ return ValidateSamplerParameterBase(context, sampler, pname, -1, true, params);
+}
+
+bool ValidateSamplerParameterIuivOES(Context *context,
+ GLuint sampler,
+ GLenum pname,
+ const GLuint *params)
+{
+ if (context->getClientMajorVersion() < 3)
+ {
+ ANGLE_VALIDATION_ERR(context, InvalidOperation(), ES3Required);
+ return false;
+ }
+ return ValidateSamplerParameterBase(context, sampler, pname, -1, true, params);
}
bool ValidateGetVertexAttribIiv(Context *context, GLuint index, GLenum pname, GLint *params)
diff --git a/src/libANGLE/validationES3.h b/src/libANGLE/validationES3.h
index 5f72e24..5a072a3 100644
--- a/src/libANGLE/validationES3.h
+++ b/src/libANGLE/validationES3.h
@@ -608,13 +608,29 @@
GLuint sampler,
GLenum pname,
const GLint *params);
+bool ValidateSamplerParameterIivOES(Context *context,
+ GLuint sampler,
+ GLenum pname,
+ const GLint *params);
+bool ValidateSamplerParameterIuivOES(Context *context,
+ GLuint sampler,
+ GLenum pname,
+ const GLuint *params);
bool ValidateSamplerParameterf(Context *context, GLuint sampler, GLenum pname, GLfloat param);
bool ValidateSamplerParameterfv(Context *context,
GLuint sampler,
GLenum pname,
const GLfloat *params);
-bool ValidateGetSamplerParameteriv(Context *context, GLuint sampler, GLenum pname, GLint *params);
bool ValidateGetSamplerParameterfv(Context *context, GLuint sampler, GLenum pname, GLfloat *params);
+bool ValidateGetSamplerParameteriv(Context *context, GLuint sampler, GLenum pname, GLint *params);
+bool ValidateGetSamplerParameterIivOES(Context *context,
+ GLuint sampler,
+ GLenum pname,
+ const GLint *params);
+bool ValidateGetSamplerParameterIuivOES(Context *context,
+ GLuint sampler,
+ GLenum pname,
+ const GLuint *params);
bool ValidateGetInternalformativ(Context *context,
GLenum target,
GLenum internalformat,
diff --git a/src/libGLESv2/entry_points_gles_ext_autogen.cpp b/src/libGLESv2/entry_points_gles_ext_autogen.cpp
index f184ddb..46da993 100644
--- a/src/libGLESv2/entry_points_gles_ext_autogen.cpp
+++ b/src/libGLESv2/entry_points_gles_ext_autogen.cpp
@@ -4638,6 +4638,163 @@
return GetDefaultReturnValue<EntryPoint::QueryMatrixxOES, GLbitfield>();
}
+// GL_OES_texture_border_clamp
+void GL_APIENTRY GetSamplerParameterIivOES(GLuint sampler, GLenum pname, GLint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLuint sampler = %u, GLenum pname = 0x%X, GLint *params = 0x%0.8p)", sampler, pname,
+ params);
+
+ Context *context = GetValidGlobalContext();
+ if (context)
+ {
+ context->gatherParams<EntryPoint::GetSamplerParameterIivOES>(sampler, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateGetSamplerParameterIivOES(context, sampler, pname, params))
+ {
+ context->getSamplerParameterIiv(sampler, pname, params);
+ }
+ }
+}
+
+void GL_APIENTRY GetSamplerParameterIuivOES(GLuint sampler, GLenum pname, GLuint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLuint sampler = %u, GLenum pname = 0x%X, GLuint *params = 0x%0.8p)", sampler, pname,
+ params);
+
+ Context *context = GetValidGlobalContext();
+ if (context)
+ {
+ context->gatherParams<EntryPoint::GetSamplerParameterIuivOES>(sampler, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateGetSamplerParameterIuivOES(context, sampler, pname, params))
+ {
+ context->getSamplerParameterIuiv(sampler, pname, params);
+ }
+ }
+}
+
+void GL_APIENTRY GetTexParameterIivOES(GLenum target, GLenum pname, GLint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLenum target = 0x%X, GLenum pname = 0x%X, GLint *params = 0x%0.8p)", target, pname,
+ params);
+
+ Context *context = GetValidGlobalContext();
+ if (context)
+ {
+ TextureType targetPacked = FromGLenum<TextureType>(target);
+ context->gatherParams<EntryPoint::GetTexParameterIivOES>(targetPacked, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateGetTexParameterIivOES(context, targetPacked, pname, params))
+ {
+ context->getTexParameterIiv(targetPacked, pname, params);
+ }
+ }
+}
+
+void GL_APIENTRY GetTexParameterIuivOES(GLenum target, GLenum pname, GLuint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLenum target = 0x%X, GLenum pname = 0x%X, GLuint *params = 0x%0.8p)", target, pname,
+ params);
+
+ Context *context = GetValidGlobalContext();
+ if (context)
+ {
+ TextureType targetPacked = FromGLenum<TextureType>(target);
+ context->gatherParams<EntryPoint::GetTexParameterIuivOES>(targetPacked, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateGetTexParameterIuivOES(context, targetPacked, pname, params))
+ {
+ context->getTexParameterIuiv(targetPacked, pname, params);
+ }
+ }
+}
+
+void GL_APIENTRY SamplerParameterIivOES(GLuint sampler, GLenum pname, const GLint *param)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLuint sampler = %u, GLenum pname = 0x%X, const GLint *param = 0x%0.8p)", sampler,
+ pname, param);
+
+ Context *context = GetValidGlobalContext();
+ if (context)
+ {
+ context->gatherParams<EntryPoint::SamplerParameterIivOES>(sampler, pname, param);
+
+ if (context->skipValidation() ||
+ ValidateSamplerParameterIivOES(context, sampler, pname, param))
+ {
+ context->samplerParameterIiv(sampler, pname, param);
+ }
+ }
+}
+
+void GL_APIENTRY SamplerParameterIuivOES(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLuint sampler = %u, GLenum pname = 0x%X, const GLuint *param = 0x%0.8p)", sampler,
+ pname, param);
+
+ Context *context = GetValidGlobalContext();
+ if (context)
+ {
+ context->gatherParams<EntryPoint::SamplerParameterIuivOES>(sampler, pname, param);
+
+ if (context->skipValidation() ||
+ ValidateSamplerParameterIuivOES(context, sampler, pname, param))
+ {
+ context->samplerParameterIuiv(sampler, pname, param);
+ }
+ }
+}
+
+void GL_APIENTRY TexParameterIivOES(GLenum target, GLenum pname, const GLint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLenum target = 0x%X, GLenum pname = 0x%X, const GLint *params = 0x%0.8p)", target,
+ pname, params);
+
+ Context *context = GetValidGlobalContext();
+ if (context)
+ {
+ TextureType targetPacked = FromGLenum<TextureType>(target);
+ context->gatherParams<EntryPoint::TexParameterIivOES>(targetPacked, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateTexParameterIivOES(context, targetPacked, pname, params))
+ {
+ context->texParameterIiv(targetPacked, pname, params);
+ }
+ }
+}
+
+void GL_APIENTRY TexParameterIuivOES(GLenum target, GLenum pname, const GLuint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLenum target = 0x%X, GLenum pname = 0x%X, const GLuint *params = 0x%0.8p)", target,
+ pname, params);
+
+ Context *context = GetValidGlobalContext();
+ if (context)
+ {
+ TextureType targetPacked = FromGLenum<TextureType>(target);
+ context->gatherParams<EntryPoint::TexParameterIuivOES>(targetPacked, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateTexParameterIuivOES(context, targetPacked, pname, params))
+ {
+ context->texParameterIuiv(targetPacked, pname, params);
+ }
+ }
+}
+
// GL_OES_texture_cube_map
void GL_APIENTRY GetTexGenfvOES(GLenum coord, GLenum pname, GLfloat *params)
{
@@ -9931,6 +10088,52 @@
}
}
+void GL_APIENTRY GetSamplerParameterIivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ GLint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLuint sampler = %u, GLenum pname = 0x%X, GLint *params = 0x%0.8p)", sampler, pname,
+ params);
+
+ Context *context = static_cast<gl::Context *>(ctx);
+ if (context)
+ {
+ ASSERT(context == GetValidGlobalContext());
+ context->gatherParams<EntryPoint::GetSamplerParameterIivOES>(sampler, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateGetSamplerParameterIivOES(context, sampler, pname, params))
+ {
+ context->getSamplerParameterIiv(sampler, pname, params);
+ }
+ }
+}
+
+void GL_APIENTRY GetSamplerParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ GLuint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLuint sampler = %u, GLenum pname = 0x%X, GLuint *params = 0x%0.8p)", sampler, pname,
+ params);
+
+ Context *context = static_cast<gl::Context *>(ctx);
+ if (context)
+ {
+ ASSERT(context == GetValidGlobalContext());
+ context->gatherParams<EntryPoint::GetSamplerParameterIuivOES>(sampler, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateGetSamplerParameterIuivOES(context, sampler, pname, params))
+ {
+ context->getSamplerParameterIuiv(sampler, pname, params);
+ }
+ }
+}
+
void GL_APIENTRY GetSamplerParameterfvContextANGLE(GLeglContext ctx,
GLuint sampler,
GLenum pname,
@@ -10339,6 +10542,54 @@
}
}
+void GL_APIENTRY GetTexParameterIivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ GLint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLenum target = 0x%X, GLenum pname = 0x%X, GLint *params = 0x%0.8p)", target, pname,
+ params);
+
+ Context *context = static_cast<gl::Context *>(ctx);
+ if (context)
+ {
+ ASSERT(context == GetValidGlobalContext());
+ TextureType targetPacked = FromGLenum<TextureType>(target);
+ context->gatherParams<EntryPoint::GetTexParameterIivOES>(targetPacked, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateGetTexParameterIivOES(context, targetPacked, pname, params))
+ {
+ context->getTexParameterIiv(targetPacked, pname, params);
+ }
+ }
+}
+
+void GL_APIENTRY GetTexParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ GLuint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLenum target = 0x%X, GLenum pname = 0x%X, GLuint *params = 0x%0.8p)", target, pname,
+ params);
+
+ Context *context = static_cast<gl::Context *>(ctx);
+ if (context)
+ {
+ ASSERT(context == GetValidGlobalContext());
+ TextureType targetPacked = FromGLenum<TextureType>(target);
+ context->gatherParams<EntryPoint::GetTexParameterIuivOES>(targetPacked, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateGetTexParameterIuivOES(context, targetPacked, pname, params))
+ {
+ context->getTexParameterIuiv(targetPacked, pname, params);
+ }
+ }
+}
+
void GL_APIENTRY GetTexParameterfvContextANGLE(GLeglContext ctx,
GLenum target,
GLenum pname,
@@ -13669,6 +13920,52 @@
}
}
+void GL_APIENTRY SamplerParameterIivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ const GLint *param)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLuint sampler = %u, GLenum pname = 0x%X, const GLint *param = 0x%0.8p)", sampler,
+ pname, param);
+
+ Context *context = static_cast<gl::Context *>(ctx);
+ if (context)
+ {
+ ASSERT(context == GetValidGlobalContext());
+ context->gatherParams<EntryPoint::SamplerParameterIivOES>(sampler, pname, param);
+
+ if (context->skipValidation() ||
+ ValidateSamplerParameterIivOES(context, sampler, pname, param))
+ {
+ context->samplerParameterIiv(sampler, pname, param);
+ }
+ }
+}
+
+void GL_APIENTRY SamplerParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ const GLuint *param)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLuint sampler = %u, GLenum pname = 0x%X, const GLuint *param = 0x%0.8p)", sampler,
+ pname, param);
+
+ Context *context = static_cast<gl::Context *>(ctx);
+ if (context)
+ {
+ ASSERT(context == GetValidGlobalContext());
+ context->gatherParams<EntryPoint::SamplerParameterIuivOES>(sampler, pname, param);
+
+ if (context->skipValidation() ||
+ ValidateSamplerParameterIuivOES(context, sampler, pname, param))
+ {
+ context->samplerParameterIuiv(sampler, pname, param);
+ }
+ }
+}
+
void GL_APIENTRY SamplerParameterfContextANGLE(GLeglContext ctx,
GLuint sampler,
GLenum pname,
@@ -14394,6 +14691,54 @@
}
}
+void GL_APIENTRY TexParameterIivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ const GLint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLenum target = 0x%X, GLenum pname = 0x%X, const GLint *params = 0x%0.8p)", target,
+ pname, params);
+
+ Context *context = static_cast<gl::Context *>(ctx);
+ if (context)
+ {
+ ASSERT(context == GetValidGlobalContext());
+ TextureType targetPacked = FromGLenum<TextureType>(target);
+ context->gatherParams<EntryPoint::TexParameterIivOES>(targetPacked, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateTexParameterIivOES(context, targetPacked, pname, params))
+ {
+ context->texParameterIiv(targetPacked, pname, params);
+ }
+ }
+}
+
+void GL_APIENTRY TexParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ const GLuint *params)
+{
+ ANGLE_SCOPED_GLOBAL_LOCK();
+ EVENT("(GLenum target = 0x%X, GLenum pname = 0x%X, const GLuint *params = 0x%0.8p)", target,
+ pname, params);
+
+ Context *context = static_cast<gl::Context *>(ctx);
+ if (context)
+ {
+ ASSERT(context == GetValidGlobalContext());
+ TextureType targetPacked = FromGLenum<TextureType>(target);
+ context->gatherParams<EntryPoint::TexParameterIuivOES>(targetPacked, pname, params);
+
+ if (context->skipValidation() ||
+ ValidateTexParameterIuivOES(context, targetPacked, pname, params))
+ {
+ context->texParameterIuiv(targetPacked, pname, params);
+ }
+ }
+}
+
void GL_APIENTRY TexParameterfContextANGLE(GLeglContext ctx,
GLenum target,
GLenum pname,
diff --git a/src/libGLESv2/entry_points_gles_ext_autogen.h b/src/libGLESv2/entry_points_gles_ext_autogen.h
index 061bd0a..7977c8a 100644
--- a/src/libGLESv2/entry_points_gles_ext_autogen.h
+++ b/src/libGLESv2/entry_points_gles_ext_autogen.h
@@ -836,6 +836,26 @@
// GL_OES_query_matrix
ANGLE_EXPORT GLbitfield GL_APIENTRY QueryMatrixxOES(GLfixed *mantissa, GLint *exponent);
+// GL_OES_texture_border_clamp
+ANGLE_EXPORT void GL_APIENTRY GetSamplerParameterIivOES(GLuint sampler,
+ GLenum pname,
+ GLint *params);
+ANGLE_EXPORT void GL_APIENTRY GetSamplerParameterIuivOES(GLuint sampler,
+ GLenum pname,
+ GLuint *params);
+ANGLE_EXPORT void GL_APIENTRY GetTexParameterIivOES(GLenum target, GLenum pname, GLint *params);
+ANGLE_EXPORT void GL_APIENTRY GetTexParameterIuivOES(GLenum target, GLenum pname, GLuint *params);
+ANGLE_EXPORT void GL_APIENTRY SamplerParameterIivOES(GLuint sampler,
+ GLenum pname,
+ const GLint *param);
+ANGLE_EXPORT void GL_APIENTRY SamplerParameterIuivOES(GLuint sampler,
+ GLenum pname,
+ const GLuint *param);
+ANGLE_EXPORT void GL_APIENTRY TexParameterIivOES(GLenum target, GLenum pname, const GLint *params);
+ANGLE_EXPORT void GL_APIENTRY TexParameterIuivOES(GLenum target,
+ GLenum pname,
+ const GLuint *params);
+
// GL_OES_texture_cube_map
ANGLE_EXPORT void GL_APIENTRY GetTexGenfvOES(GLenum coord, GLenum pname, GLfloat *params);
ANGLE_EXPORT void GL_APIENTRY GetTexGenivOES(GLenum coord, GLenum pname, GLint *params);
@@ -1668,6 +1688,14 @@
GLenum target,
GLenum pname,
GLint *params);
+ANGLE_EXPORT void GL_APIENTRY GetSamplerParameterIivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ GLint *params);
+ANGLE_EXPORT void GL_APIENTRY GetSamplerParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ GLuint *params);
ANGLE_EXPORT void GL_APIENTRY GetSamplerParameterfvContextANGLE(GLeglContext ctx,
GLuint sampler,
GLenum pname,
@@ -1739,6 +1767,14 @@
GLint level,
GLenum pname,
GLint *params);
+ANGLE_EXPORT void GL_APIENTRY GetTexParameterIivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ GLint *params);
+ANGLE_EXPORT void GL_APIENTRY GetTexParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ GLuint *params);
ANGLE_EXPORT void GL_APIENTRY GetTexParameterfvContextANGLE(GLeglContext ctx,
GLenum target,
GLenum pname,
@@ -2269,6 +2305,14 @@
ANGLE_EXPORT void GL_APIENTRY SampleMaskiContextANGLE(GLeglContext ctx,
GLuint maskNumber,
GLbitfield mask);
+ANGLE_EXPORT void GL_APIENTRY SamplerParameterIivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ const GLint *param);
+ANGLE_EXPORT void GL_APIENTRY SamplerParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ const GLuint *param);
ANGLE_EXPORT void GL_APIENTRY SamplerParameterfContextANGLE(GLeglContext ctx,
GLuint sampler,
GLenum pname,
@@ -2398,6 +2442,14 @@
GLenum format,
GLenum type,
const void *pixels);
+ANGLE_EXPORT void GL_APIENTRY TexParameterIivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ const GLint *params);
+ANGLE_EXPORT void GL_APIENTRY TexParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ const GLuint *params);
ANGLE_EXPORT void GL_APIENTRY TexParameterfContextANGLE(GLeglContext ctx,
GLenum target,
GLenum pname,
diff --git a/src/libGLESv2/libGLESv2_autogen.cpp b/src/libGLESv2/libGLESv2_autogen.cpp
index 0c7a73a..dbf0359 100644
--- a/src/libGLESv2/libGLESv2_autogen.cpp
+++ b/src/libGLESv2/libGLESv2_autogen.cpp
@@ -3978,6 +3978,47 @@
return gl::QueryMatrixxOES(mantissa, exponent);
}
+// GL_OES_texture_border_clamp
+void GL_APIENTRY glGetSamplerParameterIivOES(GLuint sampler, GLenum pname, GLint *params)
+{
+ return gl::GetSamplerParameterIivOES(sampler, pname, params);
+}
+
+void GL_APIENTRY glGetSamplerParameterIuivOES(GLuint sampler, GLenum pname, GLuint *params)
+{
+ return gl::GetSamplerParameterIuivOES(sampler, pname, params);
+}
+
+void GL_APIENTRY glGetTexParameterIivOES(GLenum target, GLenum pname, GLint *params)
+{
+ return gl::GetTexParameterIivOES(target, pname, params);
+}
+
+void GL_APIENTRY glGetTexParameterIuivOES(GLenum target, GLenum pname, GLuint *params)
+{
+ return gl::GetTexParameterIuivOES(target, pname, params);
+}
+
+void GL_APIENTRY glSamplerParameterIivOES(GLuint sampler, GLenum pname, const GLint *param)
+{
+ return gl::SamplerParameterIivOES(sampler, pname, param);
+}
+
+void GL_APIENTRY glSamplerParameterIuivOES(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ return gl::SamplerParameterIuivOES(sampler, pname, param);
+}
+
+void GL_APIENTRY glTexParameterIivOES(GLenum target, GLenum pname, const GLint *params)
+{
+ return gl::TexParameterIivOES(target, pname, params);
+}
+
+void GL_APIENTRY glTexParameterIuivOES(GLenum target, GLenum pname, const GLuint *params)
+{
+ return gl::TexParameterIuivOES(target, pname, params);
+}
+
// GL_OES_texture_cube_map
void GL_APIENTRY glGetTexGenfvOES(GLenum coord, GLenum pname, GLfloat *params)
{
@@ -5704,6 +5745,22 @@
return gl::GetRenderbufferParameterivOESContextANGLE(ctx, target, pname, params);
}
+void GL_APIENTRY glGetSamplerParameterIivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ GLint *params)
+{
+ return gl::GetSamplerParameterIivOESContextANGLE(ctx, sampler, pname, params);
+}
+
+void GL_APIENTRY glGetSamplerParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ GLuint *params)
+{
+ return gl::GetSamplerParameterIuivOESContextANGLE(ctx, sampler, pname, params);
+}
+
void GL_APIENTRY glGetSamplerParameterfvContextANGLE(GLeglContext ctx,
GLuint sampler,
GLenum pname,
@@ -5842,6 +5899,22 @@
return gl::GetTexLevelParameterivContextANGLE(ctx, target, level, pname, params);
}
+void GL_APIENTRY glGetTexParameterIivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ GLint *params)
+{
+ return gl::GetTexParameterIivOESContextANGLE(ctx, target, pname, params);
+}
+
+void GL_APIENTRY glGetTexParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ GLuint *params)
+{
+ return gl::GetTexParameterIuivOESContextANGLE(ctx, target, pname, params);
+}
+
void GL_APIENTRY glGetTexParameterfvContextANGLE(GLeglContext ctx,
GLenum target,
GLenum pname,
@@ -6926,6 +6999,22 @@
return gl::SampleMaskiContextANGLE(ctx, maskNumber, mask);
}
+void GL_APIENTRY glSamplerParameterIivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ const GLint *param)
+{
+ return gl::SamplerParameterIivOESContextANGLE(ctx, sampler, pname, param);
+}
+
+void GL_APIENTRY glSamplerParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLuint sampler,
+ GLenum pname,
+ const GLuint *param)
+{
+ return gl::SamplerParameterIuivOESContextANGLE(ctx, sampler, pname, param);
+}
+
void GL_APIENTRY glSamplerParameterfContextANGLE(GLeglContext ctx,
GLuint sampler,
GLenum pname,
@@ -7170,6 +7259,22 @@
border, format, type, pixels);
}
+void GL_APIENTRY glTexParameterIivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ const GLint *params)
+{
+ return gl::TexParameterIivOESContextANGLE(ctx, target, pname, params);
+}
+
+void GL_APIENTRY glTexParameterIuivOESContextANGLE(GLeglContext ctx,
+ GLenum target,
+ GLenum pname,
+ const GLuint *params)
+{
+ return gl::TexParameterIuivOESContextANGLE(ctx, target, pname, params);
+}
+
void GL_APIENTRY glTexParameterfContextANGLE(GLeglContext ctx,
GLenum target,
GLenum pname,
diff --git a/src/libGLESv2/libGLESv2_autogen.def b/src/libGLESv2/libGLESv2_autogen.def
index 537e1c2..5c26531 100644
--- a/src/libGLESv2/libGLESv2_autogen.def
+++ b/src/libGLESv2/libGLESv2_autogen.def
@@ -676,629 +676,647 @@
; GL_OES_query_matrix
glQueryMatrixxOES @591
+ ; GL_OES_texture_border_clamp
+ glGetSamplerParameterIivOES @592
+ glGetSamplerParameterIuivOES @593
+ glGetTexParameterIivOES @594
+ glGetTexParameterIuivOES @595
+ glSamplerParameterIivOES @596
+ glSamplerParameterIuivOES @597
+ glTexParameterIivOES @598
+ glTexParameterIuivOES @599
+
; GL_OES_texture_cube_map
- glGetTexGenfvOES @592
- glGetTexGenivOES @593
- glGetTexGenxvOES @594
- glTexGenfOES @595
- glTexGenfvOES @596
- glTexGeniOES @597
- glTexGenivOES @598
- glTexGenxOES @599
- glTexGenxvOES @600
+ glGetTexGenfvOES @600
+ glGetTexGenivOES @601
+ glGetTexGenxvOES @602
+ glTexGenfOES @603
+ glTexGenfvOES @604
+ glTexGeniOES @605
+ glTexGenivOES @606
+ glTexGenxOES @607
+ glTexGenxvOES @608
; GL_OES_texture_storage_multisample_2d_array
- glTexStorage3DMultisampleOES @601
+ glTexStorage3DMultisampleOES @609
; GL_OES_vertex_array_object
- glBindVertexArrayOES @602
- glDeleteVertexArraysOES @603
- glGenVertexArraysOES @604
- glIsVertexArrayOES @605
+ glBindVertexArrayOES @610
+ glDeleteVertexArraysOES @611
+ glGenVertexArraysOES @612
+ glIsVertexArrayOES @613
; EGL_ANGLE_explicit_context
- glActiveShaderProgramContextANGLE @606
- glActiveTextureContextANGLE @607
- glAlphaFuncContextANGLE @608
- glAlphaFuncxContextANGLE @609
- glAttachShaderContextANGLE @610
- glBeginQueryContextANGLE @611
- glBeginQueryEXTContextANGLE @612
- glBeginTransformFeedbackContextANGLE @613
- glBindAttribLocationContextANGLE @614
- glBindBufferContextANGLE @615
- glBindBufferBaseContextANGLE @616
- glBindBufferRangeContextANGLE @617
- glBindFragDataLocationEXTContextANGLE @618
- glBindFragDataLocationIndexedEXTContextANGLE @619
- glBindFramebufferContextANGLE @620
- glBindFramebufferOESContextANGLE @621
- glBindImageTextureContextANGLE @622
- glBindProgramPipelineContextANGLE @623
- glBindRenderbufferContextANGLE @624
- glBindRenderbufferOESContextANGLE @625
- glBindSamplerContextANGLE @626
- glBindTextureContextANGLE @627
- glBindTransformFeedbackContextANGLE @628
- glBindVertexArrayContextANGLE @629
- glBindVertexArrayOESContextANGLE @630
- glBindVertexBufferContextANGLE @631
- glBlendColorContextANGLE @632
- glBlendEquationContextANGLE @633
- glBlendEquationSeparateContextANGLE @634
- glBlendFuncContextANGLE @635
- glBlendFuncSeparateContextANGLE @636
- glBlitFramebufferContextANGLE @637
- glBlitFramebufferANGLEContextANGLE @638
- glBufferDataContextANGLE @639
- glBufferSubDataContextANGLE @640
- glCheckFramebufferStatusContextANGLE @641
- glCheckFramebufferStatusOESContextANGLE @642
- glClearContextANGLE @643
- glClearBufferfiContextANGLE @644
- glClearBufferfvContextANGLE @645
- glClearBufferivContextANGLE @646
- glClearBufferuivContextANGLE @647
- glClearColorContextANGLE @648
- glClearColorxContextANGLE @649
- glClearDepthfContextANGLE @650
- glClearDepthxContextANGLE @651
- glClearStencilContextANGLE @652
- glClientActiveTextureContextANGLE @653
- glClientWaitSyncContextANGLE @654
- glClipPlanefContextANGLE @655
- glClipPlanexContextANGLE @656
- glColor4fContextANGLE @657
- glColor4ubContextANGLE @658
- glColor4xContextANGLE @659
- glColorMaskContextANGLE @660
- glColorPointerContextANGLE @661
- glCompileShaderContextANGLE @662
- glCompressedTexImage2DContextANGLE @663
- glCompressedTexImage3DContextANGLE @664
- glCompressedTexSubImage2DContextANGLE @665
- glCompressedTexSubImage3DContextANGLE @666
- glCopyBufferSubDataContextANGLE @667
- glCopyTexImage2DContextANGLE @668
- glCopyTexSubImage2DContextANGLE @669
- glCopyTexSubImage3DContextANGLE @670
- glCreateProgramContextANGLE @671
- glCreateShaderContextANGLE @672
- glCreateShaderProgramvContextANGLE @673
- glCullFaceContextANGLE @674
- glCurrentPaletteMatrixOESContextANGLE @675
- glDebugMessageCallbackKHRContextANGLE @676
- glDebugMessageControlKHRContextANGLE @677
- glDebugMessageInsertKHRContextANGLE @678
- glDeleteBuffersContextANGLE @679
- glDeleteFencesNVContextANGLE @680
- glDeleteFramebuffersContextANGLE @681
- glDeleteFramebuffersOESContextANGLE @682
- glDeleteProgramContextANGLE @683
- glDeleteProgramPipelinesContextANGLE @684
- glDeleteQueriesContextANGLE @685
- glDeleteQueriesEXTContextANGLE @686
- glDeleteRenderbuffersContextANGLE @687
- glDeleteRenderbuffersOESContextANGLE @688
- glDeleteSamplersContextANGLE @689
- glDeleteShaderContextANGLE @690
- glDeleteSyncContextANGLE @691
- glDeleteTexturesContextANGLE @692
- glDeleteTransformFeedbacksContextANGLE @693
- glDeleteVertexArraysContextANGLE @694
- glDeleteVertexArraysOESContextANGLE @695
- glDepthFuncContextANGLE @696
- glDepthMaskContextANGLE @697
- glDepthRangefContextANGLE @698
- glDepthRangexContextANGLE @699
- glDetachShaderContextANGLE @700
- glDisableContextANGLE @701
- glDisableClientStateContextANGLE @702
- glDisableVertexAttribArrayContextANGLE @703
- glDiscardFramebufferEXTContextANGLE @704
- glDispatchComputeContextANGLE @705
- glDispatchComputeIndirectContextANGLE @706
- glDrawArraysContextANGLE @707
- glDrawArraysIndirectContextANGLE @708
- glDrawArraysInstancedContextANGLE @709
- glDrawArraysInstancedANGLEContextANGLE @710
- glDrawBuffersContextANGLE @711
- glDrawBuffersEXTContextANGLE @712
- glDrawElementsContextANGLE @713
- glDrawElementsIndirectContextANGLE @714
- glDrawElementsInstancedContextANGLE @715
- glDrawElementsInstancedANGLEContextANGLE @716
- glDrawRangeElementsContextANGLE @717
- glDrawTexfOESContextANGLE @718
- glDrawTexfvOESContextANGLE @719
- glDrawTexiOESContextANGLE @720
- glDrawTexivOESContextANGLE @721
- glDrawTexsOESContextANGLE @722
- glDrawTexsvOESContextANGLE @723
- glDrawTexxOESContextANGLE @724
- glDrawTexxvOESContextANGLE @725
- glEGLImageTargetRenderbufferStorageOESContextANGLE @726
- glEGLImageTargetTexture2DOESContextANGLE @727
- glEnableContextANGLE @728
- glEnableClientStateContextANGLE @729
- glEnableVertexAttribArrayContextANGLE @730
- glEndQueryContextANGLE @731
- glEndQueryEXTContextANGLE @732
- glEndTransformFeedbackContextANGLE @733
- glFenceSyncContextANGLE @734
- glFinishContextANGLE @735
- glFinishFenceNVContextANGLE @736
- glFlushContextANGLE @737
- glFlushMappedBufferRangeContextANGLE @738
- glFlushMappedBufferRangeEXTContextANGLE @739
- glFogfContextANGLE @740
- glFogfvContextANGLE @741
- glFogxContextANGLE @742
- glFogxvContextANGLE @743
- glFramebufferParameteriContextANGLE @744
- glFramebufferRenderbufferContextANGLE @745
- glFramebufferRenderbufferOESContextANGLE @746
- glFramebufferTexture2DContextANGLE @747
- glFramebufferTexture2DOESContextANGLE @748
- glFramebufferTextureEXTContextANGLE @749
- glFramebufferTextureLayerContextANGLE @750
- glFrontFaceContextANGLE @751
- glFrustumfContextANGLE @752
- glFrustumxContextANGLE @753
- glGenBuffersContextANGLE @754
- glGenFencesNVContextANGLE @755
- glGenFramebuffersContextANGLE @756
- glGenFramebuffersOESContextANGLE @757
- glGenProgramPipelinesContextANGLE @758
- glGenQueriesContextANGLE @759
- glGenQueriesEXTContextANGLE @760
- glGenRenderbuffersContextANGLE @761
- glGenRenderbuffersOESContextANGLE @762
- glGenSamplersContextANGLE @763
- glGenTexturesContextANGLE @764
- glGenTransformFeedbacksContextANGLE @765
- glGenVertexArraysContextANGLE @766
- glGenVertexArraysOESContextANGLE @767
- glGenerateMipmapContextANGLE @768
- glGenerateMipmapOESContextANGLE @769
- glGetActiveAttribContextANGLE @770
- glGetActiveUniformContextANGLE @771
- glGetActiveUniformBlockNameContextANGLE @772
- glGetActiveUniformBlockivContextANGLE @773
- glGetActiveUniformsivContextANGLE @774
- glGetAttachedShadersContextANGLE @775
- glGetAttribLocationContextANGLE @776
- glGetBooleani_vContextANGLE @777
- glGetBooleanvContextANGLE @778
- glGetBufferParameteri64vContextANGLE @779
- glGetBufferParameterivContextANGLE @780
- glGetBufferPointervContextANGLE @781
- glGetBufferPointervOESContextANGLE @782
- glGetClipPlanefContextANGLE @783
- glGetClipPlanexContextANGLE @784
- glGetDebugMessageLogKHRContextANGLE @785
- glGetErrorContextANGLE @786
- glGetFenceivNVContextANGLE @787
- glGetFixedvContextANGLE @788
- glGetFloatvContextANGLE @789
- glGetFragDataIndexEXTContextANGLE @790
- glGetFragDataLocationContextANGLE @791
- glGetFramebufferAttachmentParameterivContextANGLE @792
- glGetFramebufferAttachmentParameterivOESContextANGLE @793
- glGetFramebufferParameterivContextANGLE @794
- glGetGraphicsResetStatusEXTContextANGLE @795
- glGetInteger64i_vContextANGLE @796
- glGetInteger64vContextANGLE @797
- glGetIntegeri_vContextANGLE @798
- glGetIntegervContextANGLE @799
- glGetInternalformativContextANGLE @800
- glGetLightfvContextANGLE @801
- glGetLightxvContextANGLE @802
- glGetMaterialfvContextANGLE @803
- glGetMaterialxvContextANGLE @804
- glGetMultisamplefvContextANGLE @805
- glGetObjectLabelKHRContextANGLE @806
- glGetObjectPtrLabelKHRContextANGLE @807
- glGetPointervContextANGLE @808
- glGetPointervKHRContextANGLE @809
- glGetProgramBinaryContextANGLE @810
- glGetProgramBinaryOESContextANGLE @811
- glGetProgramInfoLogContextANGLE @812
- glGetProgramInterfaceivContextANGLE @813
- glGetProgramPipelineInfoLogContextANGLE @814
- glGetProgramPipelineivContextANGLE @815
- glGetProgramResourceIndexContextANGLE @816
- glGetProgramResourceLocationContextANGLE @817
- glGetProgramResourceLocationIndexEXTContextANGLE @818
- glGetProgramResourceNameContextANGLE @819
- glGetProgramResourceivContextANGLE @820
- glGetProgramivContextANGLE @821
- glGetQueryObjecti64vEXTContextANGLE @822
- glGetQueryObjectivEXTContextANGLE @823
- glGetQueryObjectui64vEXTContextANGLE @824
- glGetQueryObjectuivContextANGLE @825
- glGetQueryObjectuivEXTContextANGLE @826
- glGetQueryivContextANGLE @827
- glGetQueryivEXTContextANGLE @828
- glGetRenderbufferParameterivContextANGLE @829
- glGetRenderbufferParameterivOESContextANGLE @830
- glGetSamplerParameterfvContextANGLE @831
- glGetSamplerParameterivContextANGLE @832
- glGetShaderInfoLogContextANGLE @833
- glGetShaderPrecisionFormatContextANGLE @834
- glGetShaderSourceContextANGLE @835
- glGetShaderivContextANGLE @836
- glGetStringContextANGLE @837
- glGetStringiContextANGLE @838
- glGetSyncivContextANGLE @839
- glGetTexEnvfvContextANGLE @840
- glGetTexEnvivContextANGLE @841
- glGetTexEnvxvContextANGLE @842
- glGetTexGenfvOESContextANGLE @843
- glGetTexGenivOESContextANGLE @844
- glGetTexGenxvOESContextANGLE @845
- glGetTexLevelParameterfvContextANGLE @846
- glGetTexLevelParameterivContextANGLE @847
- glGetTexParameterfvContextANGLE @848
- glGetTexParameterivContextANGLE @849
- glGetTexParameterxvContextANGLE @850
- glGetTransformFeedbackVaryingContextANGLE @851
- glGetTranslatedShaderSourceANGLEContextANGLE @852
- glGetUniformBlockIndexContextANGLE @853
- glGetUniformIndicesContextANGLE @854
- glGetUniformLocationContextANGLE @855
- glGetUniformfvContextANGLE @856
- glGetUniformivContextANGLE @857
- glGetUniformuivContextANGLE @858
- glGetVertexAttribIivContextANGLE @859
- glGetVertexAttribIuivContextANGLE @860
- glGetVertexAttribPointervContextANGLE @861
- glGetVertexAttribfvContextANGLE @862
- glGetVertexAttribivContextANGLE @863
- glGetnUniformfvEXTContextANGLE @864
- glGetnUniformivEXTContextANGLE @865
- glHintContextANGLE @866
- glInsertEventMarkerEXTContextANGLE @867
- glInvalidateFramebufferContextANGLE @868
- glInvalidateSubFramebufferContextANGLE @869
- glIsBufferContextANGLE @870
- glIsEnabledContextANGLE @871
- glIsFenceNVContextANGLE @872
- glIsFramebufferContextANGLE @873
- glIsFramebufferOESContextANGLE @874
- glIsProgramContextANGLE @875
- glIsProgramPipelineContextANGLE @876
- glIsQueryContextANGLE @877
- glIsQueryEXTContextANGLE @878
- glIsRenderbufferContextANGLE @879
- glIsRenderbufferOESContextANGLE @880
- glIsSamplerContextANGLE @881
- glIsShaderContextANGLE @882
- glIsSyncContextANGLE @883
- glIsTextureContextANGLE @884
- glIsTransformFeedbackContextANGLE @885
- glIsVertexArrayContextANGLE @886
- glIsVertexArrayOESContextANGLE @887
- glLightModelfContextANGLE @888
- glLightModelfvContextANGLE @889
- glLightModelxContextANGLE @890
- glLightModelxvContextANGLE @891
- glLightfContextANGLE @892
- glLightfvContextANGLE @893
- glLightxContextANGLE @894
- glLightxvContextANGLE @895
- glLineWidthContextANGLE @896
- glLineWidthxContextANGLE @897
- glLinkProgramContextANGLE @898
- glLoadIdentityContextANGLE @899
- glLoadMatrixfContextANGLE @900
- glLoadMatrixxContextANGLE @901
- glLoadPaletteFromModelViewMatrixOESContextANGLE @902
- glLogicOpContextANGLE @903
- glMapBufferOESContextANGLE @904
- glMapBufferRangeContextANGLE @905
- glMapBufferRangeEXTContextANGLE @906
- glMaterialfContextANGLE @907
- glMaterialfvContextANGLE @908
- glMaterialxContextANGLE @909
- glMaterialxvContextANGLE @910
- glMatrixIndexPointerOESContextANGLE @911
- glMatrixModeContextANGLE @912
- glMaxShaderCompilerThreadsKHRContextANGLE @913
- glMemoryBarrierContextANGLE @914
- glMemoryBarrierByRegionContextANGLE @915
- glMultMatrixfContextANGLE @916
- glMultMatrixxContextANGLE @917
- glMultiTexCoord4fContextANGLE @918
- glMultiTexCoord4xContextANGLE @919
- glNormal3fContextANGLE @920
- glNormal3xContextANGLE @921
- glNormalPointerContextANGLE @922
- glObjectLabelKHRContextANGLE @923
- glObjectPtrLabelKHRContextANGLE @924
- glOrthofContextANGLE @925
- glOrthoxContextANGLE @926
- glPauseTransformFeedbackContextANGLE @927
- glPixelStoreiContextANGLE @928
- glPointParameterfContextANGLE @929
- glPointParameterfvContextANGLE @930
- glPointParameterxContextANGLE @931
- glPointParameterxvContextANGLE @932
- glPointSizeContextANGLE @933
- glPointSizePointerOESContextANGLE @934
- glPointSizexContextANGLE @935
- glPolygonOffsetContextANGLE @936
- glPolygonOffsetxContextANGLE @937
- glPopDebugGroupKHRContextANGLE @938
- glPopGroupMarkerEXTContextANGLE @939
- glPopMatrixContextANGLE @940
- glProgramBinaryContextANGLE @941
- glProgramBinaryOESContextANGLE @942
- glProgramParameteriContextANGLE @943
- glProgramUniform1fContextANGLE @944
- glProgramUniform1fvContextANGLE @945
- glProgramUniform1iContextANGLE @946
- glProgramUniform1ivContextANGLE @947
- glProgramUniform1uiContextANGLE @948
- glProgramUniform1uivContextANGLE @949
- glProgramUniform2fContextANGLE @950
- glProgramUniform2fvContextANGLE @951
- glProgramUniform2iContextANGLE @952
- glProgramUniform2ivContextANGLE @953
- glProgramUniform2uiContextANGLE @954
- glProgramUniform2uivContextANGLE @955
- glProgramUniform3fContextANGLE @956
- glProgramUniform3fvContextANGLE @957
- glProgramUniform3iContextANGLE @958
- glProgramUniform3ivContextANGLE @959
- glProgramUniform3uiContextANGLE @960
- glProgramUniform3uivContextANGLE @961
- glProgramUniform4fContextANGLE @962
- glProgramUniform4fvContextANGLE @963
- glProgramUniform4iContextANGLE @964
- glProgramUniform4ivContextANGLE @965
- glProgramUniform4uiContextANGLE @966
- glProgramUniform4uivContextANGLE @967
- glProgramUniformMatrix2fvContextANGLE @968
- glProgramUniformMatrix2x3fvContextANGLE @969
- glProgramUniformMatrix2x4fvContextANGLE @970
- glProgramUniformMatrix3fvContextANGLE @971
- glProgramUniformMatrix3x2fvContextANGLE @972
- glProgramUniformMatrix3x4fvContextANGLE @973
- glProgramUniformMatrix4fvContextANGLE @974
- glProgramUniformMatrix4x2fvContextANGLE @975
- glProgramUniformMatrix4x3fvContextANGLE @976
- glPushDebugGroupKHRContextANGLE @977
- glPushGroupMarkerEXTContextANGLE @978
- glPushMatrixContextANGLE @979
- glQueryCounterEXTContextANGLE @980
- glQueryMatrixxOESContextANGLE @981
- glReadBufferContextANGLE @982
- glReadPixelsContextANGLE @983
- glReadnPixelsEXTContextANGLE @984
- glReleaseShaderCompilerContextANGLE @985
- glRenderbufferStorageContextANGLE @986
- glRenderbufferStorageMultisampleContextANGLE @987
- glRenderbufferStorageMultisampleANGLEContextANGLE @988
- glRenderbufferStorageOESContextANGLE @989
- glResumeTransformFeedbackContextANGLE @990
- glRotatefContextANGLE @991
- glRotatexContextANGLE @992
- glSampleCoverageContextANGLE @993
- glSampleCoveragexContextANGLE @994
- glSampleMaskiContextANGLE @995
- glSamplerParameterfContextANGLE @996
- glSamplerParameterfvContextANGLE @997
- glSamplerParameteriContextANGLE @998
- glSamplerParameterivContextANGLE @999
- glScalefContextANGLE @1000
- glScalexContextANGLE @1001
- glScissorContextANGLE @1002
- glSetFenceNVContextANGLE @1003
- glShadeModelContextANGLE @1004
- glShaderBinaryContextANGLE @1005
- glShaderSourceContextANGLE @1006
- glStencilFuncContextANGLE @1007
- glStencilFuncSeparateContextANGLE @1008
- glStencilMaskContextANGLE @1009
- glStencilMaskSeparateContextANGLE @1010
- glStencilOpContextANGLE @1011
- glStencilOpSeparateContextANGLE @1012
- glTestFenceNVContextANGLE @1013
- glTexCoordPointerContextANGLE @1014
- glTexEnvfContextANGLE @1015
- glTexEnvfvContextANGLE @1016
- glTexEnviContextANGLE @1017
- glTexEnvivContextANGLE @1018
- glTexEnvxContextANGLE @1019
- glTexEnvxvContextANGLE @1020
- glTexGenfOESContextANGLE @1021
- glTexGenfvOESContextANGLE @1022
- glTexGeniOESContextANGLE @1023
- glTexGenivOESContextANGLE @1024
- glTexGenxOESContextANGLE @1025
- glTexGenxvOESContextANGLE @1026
- glTexImage2DContextANGLE @1027
- glTexImage3DContextANGLE @1028
- glTexParameterfContextANGLE @1029
- glTexParameterfvContextANGLE @1030
- glTexParameteriContextANGLE @1031
- glTexParameterivContextANGLE @1032
- glTexParameterxContextANGLE @1033
- glTexParameterxvContextANGLE @1034
- glTexStorage1DEXTContextANGLE @1035
- glTexStorage2DContextANGLE @1036
- glTexStorage2DEXTContextANGLE @1037
- glTexStorage2DMultisampleContextANGLE @1038
- glTexStorage3DContextANGLE @1039
- glTexStorage3DEXTContextANGLE @1040
- glTexStorage3DMultisampleOESContextANGLE @1041
- glTexSubImage2DContextANGLE @1042
- glTexSubImage3DContextANGLE @1043
- glTransformFeedbackVaryingsContextANGLE @1044
- glTranslatefContextANGLE @1045
- glTranslatexContextANGLE @1046
- glUniform1fContextANGLE @1047
- glUniform1fvContextANGLE @1048
- glUniform1iContextANGLE @1049
- glUniform1ivContextANGLE @1050
- glUniform1uiContextANGLE @1051
- glUniform1uivContextANGLE @1052
- glUniform2fContextANGLE @1053
- glUniform2fvContextANGLE @1054
- glUniform2iContextANGLE @1055
- glUniform2ivContextANGLE @1056
- glUniform2uiContextANGLE @1057
- glUniform2uivContextANGLE @1058
- glUniform3fContextANGLE @1059
- glUniform3fvContextANGLE @1060
- glUniform3iContextANGLE @1061
- glUniform3ivContextANGLE @1062
- glUniform3uiContextANGLE @1063
- glUniform3uivContextANGLE @1064
- glUniform4fContextANGLE @1065
- glUniform4fvContextANGLE @1066
- glUniform4iContextANGLE @1067
- glUniform4ivContextANGLE @1068
- glUniform4uiContextANGLE @1069
- glUniform4uivContextANGLE @1070
- glUniformBlockBindingContextANGLE @1071
- glUniformMatrix2fvContextANGLE @1072
- glUniformMatrix2x3fvContextANGLE @1073
- glUniformMatrix2x4fvContextANGLE @1074
- glUniformMatrix3fvContextANGLE @1075
- glUniformMatrix3x2fvContextANGLE @1076
- glUniformMatrix3x4fvContextANGLE @1077
- glUniformMatrix4fvContextANGLE @1078
- glUniformMatrix4x2fvContextANGLE @1079
- glUniformMatrix4x3fvContextANGLE @1080
- glUnmapBufferContextANGLE @1081
- glUnmapBufferOESContextANGLE @1082
- glUseProgramContextANGLE @1083
- glUseProgramStagesContextANGLE @1084
- glValidateProgramContextANGLE @1085
- glValidateProgramPipelineContextANGLE @1086
- glVertexAttrib1fContextANGLE @1087
- glVertexAttrib1fvContextANGLE @1088
- glVertexAttrib2fContextANGLE @1089
- glVertexAttrib2fvContextANGLE @1090
- glVertexAttrib3fContextANGLE @1091
- glVertexAttrib3fvContextANGLE @1092
- glVertexAttrib4fContextANGLE @1093
- glVertexAttrib4fvContextANGLE @1094
- glVertexAttribBindingContextANGLE @1095
- glVertexAttribDivisorContextANGLE @1096
- glVertexAttribDivisorANGLEContextANGLE @1097
- glVertexAttribFormatContextANGLE @1098
- glVertexAttribI4iContextANGLE @1099
- glVertexAttribI4ivContextANGLE @1100
- glVertexAttribI4uiContextANGLE @1101
- glVertexAttribI4uivContextANGLE @1102
- glVertexAttribIFormatContextANGLE @1103
- glVertexAttribIPointerContextANGLE @1104
- glVertexAttribPointerContextANGLE @1105
- glVertexBindingDivisorContextANGLE @1106
- glVertexPointerContextANGLE @1107
- glViewportContextANGLE @1108
- glWaitSyncContextANGLE @1109
- glWeightPointerOESContextANGLE @1110
- glBindUniformLocationCHROMIUMContextANGLE @1111
- glCoverageModulationCHROMIUMContextANGLE @1112
- glMatrixLoadfCHROMIUMContextANGLE @1113
- glMatrixLoadIdentityCHROMIUMContextANGLE @1114
- glGenPathsCHROMIUMContextANGLE @1115
- glDeletePathsCHROMIUMContextANGLE @1116
- glIsPathCHROMIUMContextANGLE @1117
- glPathCommandsCHROMIUMContextANGLE @1118
- glPathParameterfCHROMIUMContextANGLE @1119
- glPathParameteriCHROMIUMContextANGLE @1120
- glGetPathParameterfvCHROMIUMContextANGLE @1121
- glGetPathParameterivCHROMIUMContextANGLE @1122
- glPathStencilFuncCHROMIUMContextANGLE @1123
- glStencilFillPathCHROMIUMContextANGLE @1124
- glStencilStrokePathCHROMIUMContextANGLE @1125
- glCoverFillPathCHROMIUMContextANGLE @1126
- glCoverStrokePathCHROMIUMContextANGLE @1127
- glStencilThenCoverFillPathCHROMIUMContextANGLE @1128
- glStencilThenCoverStrokePathCHROMIUMContextANGLE @1129
- glCoverFillPathInstancedCHROMIUMContextANGLE @1130
- glCoverStrokePathInstancedCHROMIUMContextANGLE @1131
- glStencilStrokePathInstancedCHROMIUMContextANGLE @1132
- glStencilFillPathInstancedCHROMIUMContextANGLE @1133
- glStencilThenCoverFillPathInstancedCHROMIUMContextANGLE @1134
- glStencilThenCoverStrokePathInstancedCHROMIUMContextANGLE @1135
- glBindFragmentInputLocationCHROMIUMContextANGLE @1136
- glProgramPathFragmentInputGenCHROMIUMContextANGLE @1137
- glCopyTextureCHROMIUMContextANGLE @1138
- glCopySubTextureCHROMIUMContextANGLE @1139
- glCompressedCopyTextureCHROMIUMContextANGLE @1140
- glRequestExtensionANGLEContextANGLE @1141
- glGetBooleanvRobustANGLEContextANGLE @1142
- glGetBufferParameterivRobustANGLEContextANGLE @1143
- glGetFloatvRobustANGLEContextANGLE @1144
- glGetFramebufferAttachmentParameterivRobustANGLEContextANGLE @1145
- glGetIntegervRobustANGLEContextANGLE @1146
- glGetProgramivRobustANGLEContextANGLE @1147
- glGetRenderbufferParameterivRobustANGLEContextANGLE @1148
- glGetShaderivRobustANGLEContextANGLE @1149
- glGetTexParameterfvRobustANGLEContextANGLE @1150
- glGetTexParameterivRobustANGLEContextANGLE @1151
- glGetUniformfvRobustANGLEContextANGLE @1152
- glGetUniformivRobustANGLEContextANGLE @1153
- glGetVertexAttribfvRobustANGLEContextANGLE @1154
- glGetVertexAttribivRobustANGLEContextANGLE @1155
- glGetVertexAttribPointervRobustANGLEContextANGLE @1156
- glReadPixelsRobustANGLEContextANGLE @1157
- glTexImage2DRobustANGLEContextANGLE @1158
- glTexParameterfvRobustANGLEContextANGLE @1159
- glTexParameterivRobustANGLEContextANGLE @1160
- glTexSubImage2DRobustANGLEContextANGLE @1161
- glTexImage3DRobustANGLEContextANGLE @1162
- glTexSubImage3DRobustANGLEContextANGLE @1163
- glCompressedTexImage2DRobustANGLEContextANGLE @1164
- glCompressedTexSubImage2DRobustANGLEContextANGLE @1165
- glCompressedTexImage3DRobustANGLEContextANGLE @1166
- glCompressedTexSubImage3DRobustANGLEContextANGLE @1167
- glGetQueryivRobustANGLEContextANGLE @1168
- glGetQueryObjectuivRobustANGLEContextANGLE @1169
- glGetBufferPointervRobustANGLEContextANGLE @1170
- glGetIntegeri_vRobustANGLEContextANGLE @1171
- glGetInternalformativRobustANGLEContextANGLE @1172
- glGetVertexAttribIivRobustANGLEContextANGLE @1173
- glGetVertexAttribIuivRobustANGLEContextANGLE @1174
- glGetUniformuivRobustANGLEContextANGLE @1175
- glGetActiveUniformBlockivRobustANGLEContextANGLE @1176
- glGetInteger64vRobustANGLEContextANGLE @1177
- glGetInteger64i_vRobustANGLEContextANGLE @1178
- glGetBufferParameteri64vRobustANGLEContextANGLE @1179
- glSamplerParameterivRobustANGLEContextANGLE @1180
- glSamplerParameterfvRobustANGLEContextANGLE @1181
- glGetSamplerParameterivRobustANGLEContextANGLE @1182
- glGetSamplerParameterfvRobustANGLEContextANGLE @1183
- glGetFramebufferParameterivRobustANGLEContextANGLE @1184
- glGetProgramInterfaceivRobustANGLEContextANGLE @1185
- glGetBooleani_vRobustANGLEContextANGLE @1186
- glGetMultisamplefvRobustANGLEContextANGLE @1187
- glGetTexLevelParameterivRobustANGLEContextANGLE @1188
- glGetTexLevelParameterfvRobustANGLEContextANGLE @1189
- glGetPointervRobustANGLERobustANGLEContextANGLE @1190
- glReadnPixelsRobustANGLEContextANGLE @1191
- glGetnUniformfvRobustANGLEContextANGLE @1192
- glGetnUniformivRobustANGLEContextANGLE @1193
- glGetnUniformuivRobustANGLEContextANGLE @1194
- glTexParameterIivRobustANGLEContextANGLE @1195
- glTexParameterIuivRobustANGLEContextANGLE @1196
- glGetTexParameterIivRobustANGLEContextANGLE @1197
- glGetTexParameterIuivRobustANGLEContextANGLE @1198
- glSamplerParameterIivRobustANGLEContextANGLE @1199
- glSamplerParameterIuivRobustANGLEContextANGLE @1200
- glGetSamplerParameterIivRobustANGLEContextANGLE @1201
- glGetSamplerParameterIuivRobustANGLEContextANGLE @1202
- glGetQueryObjectivRobustANGLEContextANGLE @1203
- glGetQueryObjecti64vRobustANGLEContextANGLE @1204
- glGetQueryObjectui64vRobustANGLEContextANGLE @1205
- glFramebufferTextureMultiviewLayeredANGLEContextANGLE @1206
- glFramebufferTextureMultiviewSideBySideANGLEContextANGLE @1207
- glCopyTexture3DANGLEContextANGLE @1208
- glCopySubTexture3DANGLEContextANGLE @1209
- glTexStorage2DMultisampleANGLEContextANGLE @1210
+ glActiveShaderProgramContextANGLE @614
+ glActiveTextureContextANGLE @615
+ glAlphaFuncContextANGLE @616
+ glAlphaFuncxContextANGLE @617
+ glAttachShaderContextANGLE @618
+ glBeginQueryContextANGLE @619
+ glBeginQueryEXTContextANGLE @620
+ glBeginTransformFeedbackContextANGLE @621
+ glBindAttribLocationContextANGLE @622
+ glBindBufferContextANGLE @623
+ glBindBufferBaseContextANGLE @624
+ glBindBufferRangeContextANGLE @625
+ glBindFragDataLocationEXTContextANGLE @626
+ glBindFragDataLocationIndexedEXTContextANGLE @627
+ glBindFramebufferContextANGLE @628
+ glBindFramebufferOESContextANGLE @629
+ glBindImageTextureContextANGLE @630
+ glBindProgramPipelineContextANGLE @631
+ glBindRenderbufferContextANGLE @632
+ glBindRenderbufferOESContextANGLE @633
+ glBindSamplerContextANGLE @634
+ glBindTextureContextANGLE @635
+ glBindTransformFeedbackContextANGLE @636
+ glBindVertexArrayContextANGLE @637
+ glBindVertexArrayOESContextANGLE @638
+ glBindVertexBufferContextANGLE @639
+ glBlendColorContextANGLE @640
+ glBlendEquationContextANGLE @641
+ glBlendEquationSeparateContextANGLE @642
+ glBlendFuncContextANGLE @643
+ glBlendFuncSeparateContextANGLE @644
+ glBlitFramebufferContextANGLE @645
+ glBlitFramebufferANGLEContextANGLE @646
+ glBufferDataContextANGLE @647
+ glBufferSubDataContextANGLE @648
+ glCheckFramebufferStatusContextANGLE @649
+ glCheckFramebufferStatusOESContextANGLE @650
+ glClearContextANGLE @651
+ glClearBufferfiContextANGLE @652
+ glClearBufferfvContextANGLE @653
+ glClearBufferivContextANGLE @654
+ glClearBufferuivContextANGLE @655
+ glClearColorContextANGLE @656
+ glClearColorxContextANGLE @657
+ glClearDepthfContextANGLE @658
+ glClearDepthxContextANGLE @659
+ glClearStencilContextANGLE @660
+ glClientActiveTextureContextANGLE @661
+ glClientWaitSyncContextANGLE @662
+ glClipPlanefContextANGLE @663
+ glClipPlanexContextANGLE @664
+ glColor4fContextANGLE @665
+ glColor4ubContextANGLE @666
+ glColor4xContextANGLE @667
+ glColorMaskContextANGLE @668
+ glColorPointerContextANGLE @669
+ glCompileShaderContextANGLE @670
+ glCompressedTexImage2DContextANGLE @671
+ glCompressedTexImage3DContextANGLE @672
+ glCompressedTexSubImage2DContextANGLE @673
+ glCompressedTexSubImage3DContextANGLE @674
+ glCopyBufferSubDataContextANGLE @675
+ glCopyTexImage2DContextANGLE @676
+ glCopyTexSubImage2DContextANGLE @677
+ glCopyTexSubImage3DContextANGLE @678
+ glCreateProgramContextANGLE @679
+ glCreateShaderContextANGLE @680
+ glCreateShaderProgramvContextANGLE @681
+ glCullFaceContextANGLE @682
+ glCurrentPaletteMatrixOESContextANGLE @683
+ glDebugMessageCallbackKHRContextANGLE @684
+ glDebugMessageControlKHRContextANGLE @685
+ glDebugMessageInsertKHRContextANGLE @686
+ glDeleteBuffersContextANGLE @687
+ glDeleteFencesNVContextANGLE @688
+ glDeleteFramebuffersContextANGLE @689
+ glDeleteFramebuffersOESContextANGLE @690
+ glDeleteProgramContextANGLE @691
+ glDeleteProgramPipelinesContextANGLE @692
+ glDeleteQueriesContextANGLE @693
+ glDeleteQueriesEXTContextANGLE @694
+ glDeleteRenderbuffersContextANGLE @695
+ glDeleteRenderbuffersOESContextANGLE @696
+ glDeleteSamplersContextANGLE @697
+ glDeleteShaderContextANGLE @698
+ glDeleteSyncContextANGLE @699
+ glDeleteTexturesContextANGLE @700
+ glDeleteTransformFeedbacksContextANGLE @701
+ glDeleteVertexArraysContextANGLE @702
+ glDeleteVertexArraysOESContextANGLE @703
+ glDepthFuncContextANGLE @704
+ glDepthMaskContextANGLE @705
+ glDepthRangefContextANGLE @706
+ glDepthRangexContextANGLE @707
+ glDetachShaderContextANGLE @708
+ glDisableContextANGLE @709
+ glDisableClientStateContextANGLE @710
+ glDisableVertexAttribArrayContextANGLE @711
+ glDiscardFramebufferEXTContextANGLE @712
+ glDispatchComputeContextANGLE @713
+ glDispatchComputeIndirectContextANGLE @714
+ glDrawArraysContextANGLE @715
+ glDrawArraysIndirectContextANGLE @716
+ glDrawArraysInstancedContextANGLE @717
+ glDrawArraysInstancedANGLEContextANGLE @718
+ glDrawBuffersContextANGLE @719
+ glDrawBuffersEXTContextANGLE @720
+ glDrawElementsContextANGLE @721
+ glDrawElementsIndirectContextANGLE @722
+ glDrawElementsInstancedContextANGLE @723
+ glDrawElementsInstancedANGLEContextANGLE @724
+ glDrawRangeElementsContextANGLE @725
+ glDrawTexfOESContextANGLE @726
+ glDrawTexfvOESContextANGLE @727
+ glDrawTexiOESContextANGLE @728
+ glDrawTexivOESContextANGLE @729
+ glDrawTexsOESContextANGLE @730
+ glDrawTexsvOESContextANGLE @731
+ glDrawTexxOESContextANGLE @732
+ glDrawTexxvOESContextANGLE @733
+ glEGLImageTargetRenderbufferStorageOESContextANGLE @734
+ glEGLImageTargetTexture2DOESContextANGLE @735
+ glEnableContextANGLE @736
+ glEnableClientStateContextANGLE @737
+ glEnableVertexAttribArrayContextANGLE @738
+ glEndQueryContextANGLE @739
+ glEndQueryEXTContextANGLE @740
+ glEndTransformFeedbackContextANGLE @741
+ glFenceSyncContextANGLE @742
+ glFinishContextANGLE @743
+ glFinishFenceNVContextANGLE @744
+ glFlushContextANGLE @745
+ glFlushMappedBufferRangeContextANGLE @746
+ glFlushMappedBufferRangeEXTContextANGLE @747
+ glFogfContextANGLE @748
+ glFogfvContextANGLE @749
+ glFogxContextANGLE @750
+ glFogxvContextANGLE @751
+ glFramebufferParameteriContextANGLE @752
+ glFramebufferRenderbufferContextANGLE @753
+ glFramebufferRenderbufferOESContextANGLE @754
+ glFramebufferTexture2DContextANGLE @755
+ glFramebufferTexture2DOESContextANGLE @756
+ glFramebufferTextureEXTContextANGLE @757
+ glFramebufferTextureLayerContextANGLE @758
+ glFrontFaceContextANGLE @759
+ glFrustumfContextANGLE @760
+ glFrustumxContextANGLE @761
+ glGenBuffersContextANGLE @762
+ glGenFencesNVContextANGLE @763
+ glGenFramebuffersContextANGLE @764
+ glGenFramebuffersOESContextANGLE @765
+ glGenProgramPipelinesContextANGLE @766
+ glGenQueriesContextANGLE @767
+ glGenQueriesEXTContextANGLE @768
+ glGenRenderbuffersContextANGLE @769
+ glGenRenderbuffersOESContextANGLE @770
+ glGenSamplersContextANGLE @771
+ glGenTexturesContextANGLE @772
+ glGenTransformFeedbacksContextANGLE @773
+ glGenVertexArraysContextANGLE @774
+ glGenVertexArraysOESContextANGLE @775
+ glGenerateMipmapContextANGLE @776
+ glGenerateMipmapOESContextANGLE @777
+ glGetActiveAttribContextANGLE @778
+ glGetActiveUniformContextANGLE @779
+ glGetActiveUniformBlockNameContextANGLE @780
+ glGetActiveUniformBlockivContextANGLE @781
+ glGetActiveUniformsivContextANGLE @782
+ glGetAttachedShadersContextANGLE @783
+ glGetAttribLocationContextANGLE @784
+ glGetBooleani_vContextANGLE @785
+ glGetBooleanvContextANGLE @786
+ glGetBufferParameteri64vContextANGLE @787
+ glGetBufferParameterivContextANGLE @788
+ glGetBufferPointervContextANGLE @789
+ glGetBufferPointervOESContextANGLE @790
+ glGetClipPlanefContextANGLE @791
+ glGetClipPlanexContextANGLE @792
+ glGetDebugMessageLogKHRContextANGLE @793
+ glGetErrorContextANGLE @794
+ glGetFenceivNVContextANGLE @795
+ glGetFixedvContextANGLE @796
+ glGetFloatvContextANGLE @797
+ glGetFragDataIndexEXTContextANGLE @798
+ glGetFragDataLocationContextANGLE @799
+ glGetFramebufferAttachmentParameterivContextANGLE @800
+ glGetFramebufferAttachmentParameterivOESContextANGLE @801
+ glGetFramebufferParameterivContextANGLE @802
+ glGetGraphicsResetStatusEXTContextANGLE @803
+ glGetInteger64i_vContextANGLE @804
+ glGetInteger64vContextANGLE @805
+ glGetIntegeri_vContextANGLE @806
+ glGetIntegervContextANGLE @807
+ glGetInternalformativContextANGLE @808
+ glGetLightfvContextANGLE @809
+ glGetLightxvContextANGLE @810
+ glGetMaterialfvContextANGLE @811
+ glGetMaterialxvContextANGLE @812
+ glGetMultisamplefvContextANGLE @813
+ glGetObjectLabelKHRContextANGLE @814
+ glGetObjectPtrLabelKHRContextANGLE @815
+ glGetPointervContextANGLE @816
+ glGetPointervKHRContextANGLE @817
+ glGetProgramBinaryContextANGLE @818
+ glGetProgramBinaryOESContextANGLE @819
+ glGetProgramInfoLogContextANGLE @820
+ glGetProgramInterfaceivContextANGLE @821
+ glGetProgramPipelineInfoLogContextANGLE @822
+ glGetProgramPipelineivContextANGLE @823
+ glGetProgramResourceIndexContextANGLE @824
+ glGetProgramResourceLocationContextANGLE @825
+ glGetProgramResourceLocationIndexEXTContextANGLE @826
+ glGetProgramResourceNameContextANGLE @827
+ glGetProgramResourceivContextANGLE @828
+ glGetProgramivContextANGLE @829
+ glGetQueryObjecti64vEXTContextANGLE @830
+ glGetQueryObjectivEXTContextANGLE @831
+ glGetQueryObjectui64vEXTContextANGLE @832
+ glGetQueryObjectuivContextANGLE @833
+ glGetQueryObjectuivEXTContextANGLE @834
+ glGetQueryivContextANGLE @835
+ glGetQueryivEXTContextANGLE @836
+ glGetRenderbufferParameterivContextANGLE @837
+ glGetRenderbufferParameterivOESContextANGLE @838
+ glGetSamplerParameterIivOESContextANGLE @839
+ glGetSamplerParameterIuivOESContextANGLE @840
+ glGetSamplerParameterfvContextANGLE @841
+ glGetSamplerParameterivContextANGLE @842
+ glGetShaderInfoLogContextANGLE @843
+ glGetShaderPrecisionFormatContextANGLE @844
+ glGetShaderSourceContextANGLE @845
+ glGetShaderivContextANGLE @846
+ glGetStringContextANGLE @847
+ glGetStringiContextANGLE @848
+ glGetSyncivContextANGLE @849
+ glGetTexEnvfvContextANGLE @850
+ glGetTexEnvivContextANGLE @851
+ glGetTexEnvxvContextANGLE @852
+ glGetTexGenfvOESContextANGLE @853
+ glGetTexGenivOESContextANGLE @854
+ glGetTexGenxvOESContextANGLE @855
+ glGetTexLevelParameterfvContextANGLE @856
+ glGetTexLevelParameterivContextANGLE @857
+ glGetTexParameterIivOESContextANGLE @858
+ glGetTexParameterIuivOESContextANGLE @859
+ glGetTexParameterfvContextANGLE @860
+ glGetTexParameterivContextANGLE @861
+ glGetTexParameterxvContextANGLE @862
+ glGetTransformFeedbackVaryingContextANGLE @863
+ glGetTranslatedShaderSourceANGLEContextANGLE @864
+ glGetUniformBlockIndexContextANGLE @865
+ glGetUniformIndicesContextANGLE @866
+ glGetUniformLocationContextANGLE @867
+ glGetUniformfvContextANGLE @868
+ glGetUniformivContextANGLE @869
+ glGetUniformuivContextANGLE @870
+ glGetVertexAttribIivContextANGLE @871
+ glGetVertexAttribIuivContextANGLE @872
+ glGetVertexAttribPointervContextANGLE @873
+ glGetVertexAttribfvContextANGLE @874
+ glGetVertexAttribivContextANGLE @875
+ glGetnUniformfvEXTContextANGLE @876
+ glGetnUniformivEXTContextANGLE @877
+ glHintContextANGLE @878
+ glInsertEventMarkerEXTContextANGLE @879
+ glInvalidateFramebufferContextANGLE @880
+ glInvalidateSubFramebufferContextANGLE @881
+ glIsBufferContextANGLE @882
+ glIsEnabledContextANGLE @883
+ glIsFenceNVContextANGLE @884
+ glIsFramebufferContextANGLE @885
+ glIsFramebufferOESContextANGLE @886
+ glIsProgramContextANGLE @887
+ glIsProgramPipelineContextANGLE @888
+ glIsQueryContextANGLE @889
+ glIsQueryEXTContextANGLE @890
+ glIsRenderbufferContextANGLE @891
+ glIsRenderbufferOESContextANGLE @892
+ glIsSamplerContextANGLE @893
+ glIsShaderContextANGLE @894
+ glIsSyncContextANGLE @895
+ glIsTextureContextANGLE @896
+ glIsTransformFeedbackContextANGLE @897
+ glIsVertexArrayContextANGLE @898
+ glIsVertexArrayOESContextANGLE @899
+ glLightModelfContextANGLE @900
+ glLightModelfvContextANGLE @901
+ glLightModelxContextANGLE @902
+ glLightModelxvContextANGLE @903
+ glLightfContextANGLE @904
+ glLightfvContextANGLE @905
+ glLightxContextANGLE @906
+ glLightxvContextANGLE @907
+ glLineWidthContextANGLE @908
+ glLineWidthxContextANGLE @909
+ glLinkProgramContextANGLE @910
+ glLoadIdentityContextANGLE @911
+ glLoadMatrixfContextANGLE @912
+ glLoadMatrixxContextANGLE @913
+ glLoadPaletteFromModelViewMatrixOESContextANGLE @914
+ glLogicOpContextANGLE @915
+ glMapBufferOESContextANGLE @916
+ glMapBufferRangeContextANGLE @917
+ glMapBufferRangeEXTContextANGLE @918
+ glMaterialfContextANGLE @919
+ glMaterialfvContextANGLE @920
+ glMaterialxContextANGLE @921
+ glMaterialxvContextANGLE @922
+ glMatrixIndexPointerOESContextANGLE @923
+ glMatrixModeContextANGLE @924
+ glMaxShaderCompilerThreadsKHRContextANGLE @925
+ glMemoryBarrierContextANGLE @926
+ glMemoryBarrierByRegionContextANGLE @927
+ glMultMatrixfContextANGLE @928
+ glMultMatrixxContextANGLE @929
+ glMultiTexCoord4fContextANGLE @930
+ glMultiTexCoord4xContextANGLE @931
+ glNormal3fContextANGLE @932
+ glNormal3xContextANGLE @933
+ glNormalPointerContextANGLE @934
+ glObjectLabelKHRContextANGLE @935
+ glObjectPtrLabelKHRContextANGLE @936
+ glOrthofContextANGLE @937
+ glOrthoxContextANGLE @938
+ glPauseTransformFeedbackContextANGLE @939
+ glPixelStoreiContextANGLE @940
+ glPointParameterfContextANGLE @941
+ glPointParameterfvContextANGLE @942
+ glPointParameterxContextANGLE @943
+ glPointParameterxvContextANGLE @944
+ glPointSizeContextANGLE @945
+ glPointSizePointerOESContextANGLE @946
+ glPointSizexContextANGLE @947
+ glPolygonOffsetContextANGLE @948
+ glPolygonOffsetxContextANGLE @949
+ glPopDebugGroupKHRContextANGLE @950
+ glPopGroupMarkerEXTContextANGLE @951
+ glPopMatrixContextANGLE @952
+ glProgramBinaryContextANGLE @953
+ glProgramBinaryOESContextANGLE @954
+ glProgramParameteriContextANGLE @955
+ glProgramUniform1fContextANGLE @956
+ glProgramUniform1fvContextANGLE @957
+ glProgramUniform1iContextANGLE @958
+ glProgramUniform1ivContextANGLE @959
+ glProgramUniform1uiContextANGLE @960
+ glProgramUniform1uivContextANGLE @961
+ glProgramUniform2fContextANGLE @962
+ glProgramUniform2fvContextANGLE @963
+ glProgramUniform2iContextANGLE @964
+ glProgramUniform2ivContextANGLE @965
+ glProgramUniform2uiContextANGLE @966
+ glProgramUniform2uivContextANGLE @967
+ glProgramUniform3fContextANGLE @968
+ glProgramUniform3fvContextANGLE @969
+ glProgramUniform3iContextANGLE @970
+ glProgramUniform3ivContextANGLE @971
+ glProgramUniform3uiContextANGLE @972
+ glProgramUniform3uivContextANGLE @973
+ glProgramUniform4fContextANGLE @974
+ glProgramUniform4fvContextANGLE @975
+ glProgramUniform4iContextANGLE @976
+ glProgramUniform4ivContextANGLE @977
+ glProgramUniform4uiContextANGLE @978
+ glProgramUniform4uivContextANGLE @979
+ glProgramUniformMatrix2fvContextANGLE @980
+ glProgramUniformMatrix2x3fvContextANGLE @981
+ glProgramUniformMatrix2x4fvContextANGLE @982
+ glProgramUniformMatrix3fvContextANGLE @983
+ glProgramUniformMatrix3x2fvContextANGLE @984
+ glProgramUniformMatrix3x4fvContextANGLE @985
+ glProgramUniformMatrix4fvContextANGLE @986
+ glProgramUniformMatrix4x2fvContextANGLE @987
+ glProgramUniformMatrix4x3fvContextANGLE @988
+ glPushDebugGroupKHRContextANGLE @989
+ glPushGroupMarkerEXTContextANGLE @990
+ glPushMatrixContextANGLE @991
+ glQueryCounterEXTContextANGLE @992
+ glQueryMatrixxOESContextANGLE @993
+ glReadBufferContextANGLE @994
+ glReadPixelsContextANGLE @995
+ glReadnPixelsEXTContextANGLE @996
+ glReleaseShaderCompilerContextANGLE @997
+ glRenderbufferStorageContextANGLE @998
+ glRenderbufferStorageMultisampleContextANGLE @999
+ glRenderbufferStorageMultisampleANGLEContextANGLE @1000
+ glRenderbufferStorageOESContextANGLE @1001
+ glResumeTransformFeedbackContextANGLE @1002
+ glRotatefContextANGLE @1003
+ glRotatexContextANGLE @1004
+ glSampleCoverageContextANGLE @1005
+ glSampleCoveragexContextANGLE @1006
+ glSampleMaskiContextANGLE @1007
+ glSamplerParameterIivOESContextANGLE @1008
+ glSamplerParameterIuivOESContextANGLE @1009
+ glSamplerParameterfContextANGLE @1010
+ glSamplerParameterfvContextANGLE @1011
+ glSamplerParameteriContextANGLE @1012
+ glSamplerParameterivContextANGLE @1013
+ glScalefContextANGLE @1014
+ glScalexContextANGLE @1015
+ glScissorContextANGLE @1016
+ glSetFenceNVContextANGLE @1017
+ glShadeModelContextANGLE @1018
+ glShaderBinaryContextANGLE @1019
+ glShaderSourceContextANGLE @1020
+ glStencilFuncContextANGLE @1021
+ glStencilFuncSeparateContextANGLE @1022
+ glStencilMaskContextANGLE @1023
+ glStencilMaskSeparateContextANGLE @1024
+ glStencilOpContextANGLE @1025
+ glStencilOpSeparateContextANGLE @1026
+ glTestFenceNVContextANGLE @1027
+ glTexCoordPointerContextANGLE @1028
+ glTexEnvfContextANGLE @1029
+ glTexEnvfvContextANGLE @1030
+ glTexEnviContextANGLE @1031
+ glTexEnvivContextANGLE @1032
+ glTexEnvxContextANGLE @1033
+ glTexEnvxvContextANGLE @1034
+ glTexGenfOESContextANGLE @1035
+ glTexGenfvOESContextANGLE @1036
+ glTexGeniOESContextANGLE @1037
+ glTexGenivOESContextANGLE @1038
+ glTexGenxOESContextANGLE @1039
+ glTexGenxvOESContextANGLE @1040
+ glTexImage2DContextANGLE @1041
+ glTexImage3DContextANGLE @1042
+ glTexParameterIivOESContextANGLE @1043
+ glTexParameterIuivOESContextANGLE @1044
+ glTexParameterfContextANGLE @1045
+ glTexParameterfvContextANGLE @1046
+ glTexParameteriContextANGLE @1047
+ glTexParameterivContextANGLE @1048
+ glTexParameterxContextANGLE @1049
+ glTexParameterxvContextANGLE @1050
+ glTexStorage1DEXTContextANGLE @1051
+ glTexStorage2DContextANGLE @1052
+ glTexStorage2DEXTContextANGLE @1053
+ glTexStorage2DMultisampleContextANGLE @1054
+ glTexStorage3DContextANGLE @1055
+ glTexStorage3DEXTContextANGLE @1056
+ glTexStorage3DMultisampleOESContextANGLE @1057
+ glTexSubImage2DContextANGLE @1058
+ glTexSubImage3DContextANGLE @1059
+ glTransformFeedbackVaryingsContextANGLE @1060
+ glTranslatefContextANGLE @1061
+ glTranslatexContextANGLE @1062
+ glUniform1fContextANGLE @1063
+ glUniform1fvContextANGLE @1064
+ glUniform1iContextANGLE @1065
+ glUniform1ivContextANGLE @1066
+ glUniform1uiContextANGLE @1067
+ glUniform1uivContextANGLE @1068
+ glUniform2fContextANGLE @1069
+ glUniform2fvContextANGLE @1070
+ glUniform2iContextANGLE @1071
+ glUniform2ivContextANGLE @1072
+ glUniform2uiContextANGLE @1073
+ glUniform2uivContextANGLE @1074
+ glUniform3fContextANGLE @1075
+ glUniform3fvContextANGLE @1076
+ glUniform3iContextANGLE @1077
+ glUniform3ivContextANGLE @1078
+ glUniform3uiContextANGLE @1079
+ glUniform3uivContextANGLE @1080
+ glUniform4fContextANGLE @1081
+ glUniform4fvContextANGLE @1082
+ glUniform4iContextANGLE @1083
+ glUniform4ivContextANGLE @1084
+ glUniform4uiContextANGLE @1085
+ glUniform4uivContextANGLE @1086
+ glUniformBlockBindingContextANGLE @1087
+ glUniformMatrix2fvContextANGLE @1088
+ glUniformMatrix2x3fvContextANGLE @1089
+ glUniformMatrix2x4fvContextANGLE @1090
+ glUniformMatrix3fvContextANGLE @1091
+ glUniformMatrix3x2fvContextANGLE @1092
+ glUniformMatrix3x4fvContextANGLE @1093
+ glUniformMatrix4fvContextANGLE @1094
+ glUniformMatrix4x2fvContextANGLE @1095
+ glUniformMatrix4x3fvContextANGLE @1096
+ glUnmapBufferContextANGLE @1097
+ glUnmapBufferOESContextANGLE @1098
+ glUseProgramContextANGLE @1099
+ glUseProgramStagesContextANGLE @1100
+ glValidateProgramContextANGLE @1101
+ glValidateProgramPipelineContextANGLE @1102
+ glVertexAttrib1fContextANGLE @1103
+ glVertexAttrib1fvContextANGLE @1104
+ glVertexAttrib2fContextANGLE @1105
+ glVertexAttrib2fvContextANGLE @1106
+ glVertexAttrib3fContextANGLE @1107
+ glVertexAttrib3fvContextANGLE @1108
+ glVertexAttrib4fContextANGLE @1109
+ glVertexAttrib4fvContextANGLE @1110
+ glVertexAttribBindingContextANGLE @1111
+ glVertexAttribDivisorContextANGLE @1112
+ glVertexAttribDivisorANGLEContextANGLE @1113
+ glVertexAttribFormatContextANGLE @1114
+ glVertexAttribI4iContextANGLE @1115
+ glVertexAttribI4ivContextANGLE @1116
+ glVertexAttribI4uiContextANGLE @1117
+ glVertexAttribI4uivContextANGLE @1118
+ glVertexAttribIFormatContextANGLE @1119
+ glVertexAttribIPointerContextANGLE @1120
+ glVertexAttribPointerContextANGLE @1121
+ glVertexBindingDivisorContextANGLE @1122
+ glVertexPointerContextANGLE @1123
+ glViewportContextANGLE @1124
+ glWaitSyncContextANGLE @1125
+ glWeightPointerOESContextANGLE @1126
+ glBindUniformLocationCHROMIUMContextANGLE @1127
+ glCoverageModulationCHROMIUMContextANGLE @1128
+ glMatrixLoadfCHROMIUMContextANGLE @1129
+ glMatrixLoadIdentityCHROMIUMContextANGLE @1130
+ glGenPathsCHROMIUMContextANGLE @1131
+ glDeletePathsCHROMIUMContextANGLE @1132
+ glIsPathCHROMIUMContextANGLE @1133
+ glPathCommandsCHROMIUMContextANGLE @1134
+ glPathParameterfCHROMIUMContextANGLE @1135
+ glPathParameteriCHROMIUMContextANGLE @1136
+ glGetPathParameterfvCHROMIUMContextANGLE @1137
+ glGetPathParameterivCHROMIUMContextANGLE @1138
+ glPathStencilFuncCHROMIUMContextANGLE @1139
+ glStencilFillPathCHROMIUMContextANGLE @1140
+ glStencilStrokePathCHROMIUMContextANGLE @1141
+ glCoverFillPathCHROMIUMContextANGLE @1142
+ glCoverStrokePathCHROMIUMContextANGLE @1143
+ glStencilThenCoverFillPathCHROMIUMContextANGLE @1144
+ glStencilThenCoverStrokePathCHROMIUMContextANGLE @1145
+ glCoverFillPathInstancedCHROMIUMContextANGLE @1146
+ glCoverStrokePathInstancedCHROMIUMContextANGLE @1147
+ glStencilStrokePathInstancedCHROMIUMContextANGLE @1148
+ glStencilFillPathInstancedCHROMIUMContextANGLE @1149
+ glStencilThenCoverFillPathInstancedCHROMIUMContextANGLE @1150
+ glStencilThenCoverStrokePathInstancedCHROMIUMContextANGLE @1151
+ glBindFragmentInputLocationCHROMIUMContextANGLE @1152
+ glProgramPathFragmentInputGenCHROMIUMContextANGLE @1153
+ glCopyTextureCHROMIUMContextANGLE @1154
+ glCopySubTextureCHROMIUMContextANGLE @1155
+ glCompressedCopyTextureCHROMIUMContextANGLE @1156
+ glRequestExtensionANGLEContextANGLE @1157
+ glGetBooleanvRobustANGLEContextANGLE @1158
+ glGetBufferParameterivRobustANGLEContextANGLE @1159
+ glGetFloatvRobustANGLEContextANGLE @1160
+ glGetFramebufferAttachmentParameterivRobustANGLEContextANGLE @1161
+ glGetIntegervRobustANGLEContextANGLE @1162
+ glGetProgramivRobustANGLEContextANGLE @1163
+ glGetRenderbufferParameterivRobustANGLEContextANGLE @1164
+ glGetShaderivRobustANGLEContextANGLE @1165
+ glGetTexParameterfvRobustANGLEContextANGLE @1166
+ glGetTexParameterivRobustANGLEContextANGLE @1167
+ glGetUniformfvRobustANGLEContextANGLE @1168
+ glGetUniformivRobustANGLEContextANGLE @1169
+ glGetVertexAttribfvRobustANGLEContextANGLE @1170
+ glGetVertexAttribivRobustANGLEContextANGLE @1171
+ glGetVertexAttribPointervRobustANGLEContextANGLE @1172
+ glReadPixelsRobustANGLEContextANGLE @1173
+ glTexImage2DRobustANGLEContextANGLE @1174
+ glTexParameterfvRobustANGLEContextANGLE @1175
+ glTexParameterivRobustANGLEContextANGLE @1176
+ glTexSubImage2DRobustANGLEContextANGLE @1177
+ glTexImage3DRobustANGLEContextANGLE @1178
+ glTexSubImage3DRobustANGLEContextANGLE @1179
+ glCompressedTexImage2DRobustANGLEContextANGLE @1180
+ glCompressedTexSubImage2DRobustANGLEContextANGLE @1181
+ glCompressedTexImage3DRobustANGLEContextANGLE @1182
+ glCompressedTexSubImage3DRobustANGLEContextANGLE @1183
+ glGetQueryivRobustANGLEContextANGLE @1184
+ glGetQueryObjectuivRobustANGLEContextANGLE @1185
+ glGetBufferPointervRobustANGLEContextANGLE @1186
+ glGetIntegeri_vRobustANGLEContextANGLE @1187
+ glGetInternalformativRobustANGLEContextANGLE @1188
+ glGetVertexAttribIivRobustANGLEContextANGLE @1189
+ glGetVertexAttribIuivRobustANGLEContextANGLE @1190
+ glGetUniformuivRobustANGLEContextANGLE @1191
+ glGetActiveUniformBlockivRobustANGLEContextANGLE @1192
+ glGetInteger64vRobustANGLEContextANGLE @1193
+ glGetInteger64i_vRobustANGLEContextANGLE @1194
+ glGetBufferParameteri64vRobustANGLEContextANGLE @1195
+ glSamplerParameterivRobustANGLEContextANGLE @1196
+ glSamplerParameterfvRobustANGLEContextANGLE @1197
+ glGetSamplerParameterivRobustANGLEContextANGLE @1198
+ glGetSamplerParameterfvRobustANGLEContextANGLE @1199
+ glGetFramebufferParameterivRobustANGLEContextANGLE @1200
+ glGetProgramInterfaceivRobustANGLEContextANGLE @1201
+ glGetBooleani_vRobustANGLEContextANGLE @1202
+ glGetMultisamplefvRobustANGLEContextANGLE @1203
+ glGetTexLevelParameterivRobustANGLEContextANGLE @1204
+ glGetTexLevelParameterfvRobustANGLEContextANGLE @1205
+ glGetPointervRobustANGLERobustANGLEContextANGLE @1206
+ glReadnPixelsRobustANGLEContextANGLE @1207
+ glGetnUniformfvRobustANGLEContextANGLE @1208
+ glGetnUniformivRobustANGLEContextANGLE @1209
+ glGetnUniformuivRobustANGLEContextANGLE @1210
+ glTexParameterIivRobustANGLEContextANGLE @1211
+ glTexParameterIuivRobustANGLEContextANGLE @1212
+ glGetTexParameterIivRobustANGLEContextANGLE @1213
+ glGetTexParameterIuivRobustANGLEContextANGLE @1214
+ glSamplerParameterIivRobustANGLEContextANGLE @1215
+ glSamplerParameterIuivRobustANGLEContextANGLE @1216
+ glGetSamplerParameterIivRobustANGLEContextANGLE @1217
+ glGetSamplerParameterIuivRobustANGLEContextANGLE @1218
+ glGetQueryObjectivRobustANGLEContextANGLE @1219
+ glGetQueryObjecti64vRobustANGLEContextANGLE @1220
+ glGetQueryObjectui64vRobustANGLEContextANGLE @1221
+ glFramebufferTextureMultiviewLayeredANGLEContextANGLE @1222
+ glFramebufferTextureMultiviewSideBySideANGLEContextANGLE @1223
+ glCopyTexture3DANGLEContextANGLE @1224
+ glCopySubTexture3DANGLEContextANGLE @1225
+ glTexStorage2DMultisampleANGLEContextANGLE @1226
diff --git a/src/libGLESv2/proc_table_autogen.cpp b/src/libGLESv2/proc_table_autogen.cpp
index 30ee93d..d0b977a 100644
--- a/src/libGLESv2/proc_table_autogen.cpp
+++ b/src/libGLESv2/proc_table_autogen.cpp
@@ -618,9 +618,13 @@
{"glGetRenderbufferParameterivRobustANGLE", P(gl::GetRenderbufferParameterivRobustANGLE)},
{"glGetRenderbufferParameterivRobustANGLEContextANGLE",
P(gl::GetRenderbufferParameterivRobustANGLEContextANGLE)},
+ {"glGetSamplerParameterIivOES", P(gl::GetSamplerParameterIivOES)},
+ {"glGetSamplerParameterIivOESContextANGLE", P(gl::GetSamplerParameterIivOESContextANGLE)},
{"glGetSamplerParameterIivRobustANGLE", P(gl::GetSamplerParameterIivRobustANGLE)},
{"glGetSamplerParameterIivRobustANGLEContextANGLE",
P(gl::GetSamplerParameterIivRobustANGLEContextANGLE)},
+ {"glGetSamplerParameterIuivOES", P(gl::GetSamplerParameterIuivOES)},
+ {"glGetSamplerParameterIuivOESContextANGLE", P(gl::GetSamplerParameterIuivOESContextANGLE)},
{"glGetSamplerParameterIuivRobustANGLE", P(gl::GetSamplerParameterIuivRobustANGLE)},
{"glGetSamplerParameterIuivRobustANGLEContextANGLE",
P(gl::GetSamplerParameterIuivRobustANGLEContextANGLE)},
@@ -666,9 +670,13 @@
{"glGetTexLevelParameterivRobustANGLE", P(gl::GetTexLevelParameterivRobustANGLE)},
{"glGetTexLevelParameterivRobustANGLEContextANGLE",
P(gl::GetTexLevelParameterivRobustANGLEContextANGLE)},
+ {"glGetTexParameterIivOES", P(gl::GetTexParameterIivOES)},
+ {"glGetTexParameterIivOESContextANGLE", P(gl::GetTexParameterIivOESContextANGLE)},
{"glGetTexParameterIivRobustANGLE", P(gl::GetTexParameterIivRobustANGLE)},
{"glGetTexParameterIivRobustANGLEContextANGLE",
P(gl::GetTexParameterIivRobustANGLEContextANGLE)},
+ {"glGetTexParameterIuivOES", P(gl::GetTexParameterIuivOES)},
+ {"glGetTexParameterIuivOESContextANGLE", P(gl::GetTexParameterIuivOESContextANGLE)},
{"glGetTexParameterIuivRobustANGLE", P(gl::GetTexParameterIuivRobustANGLE)},
{"glGetTexParameterIuivRobustANGLEContextANGLE",
P(gl::GetTexParameterIuivRobustANGLEContextANGLE)},
@@ -1001,9 +1009,13 @@
{"glSampleCoveragexContextANGLE", P(gl::SampleCoveragexContextANGLE)},
{"glSampleMaski", P(gl::SampleMaski)},
{"glSampleMaskiContextANGLE", P(gl::SampleMaskiContextANGLE)},
+ {"glSamplerParameterIivOES", P(gl::SamplerParameterIivOES)},
+ {"glSamplerParameterIivOESContextANGLE", P(gl::SamplerParameterIivOESContextANGLE)},
{"glSamplerParameterIivRobustANGLE", P(gl::SamplerParameterIivRobustANGLE)},
{"glSamplerParameterIivRobustANGLEContextANGLE",
P(gl::SamplerParameterIivRobustANGLEContextANGLE)},
+ {"glSamplerParameterIuivOES", P(gl::SamplerParameterIuivOES)},
+ {"glSamplerParameterIuivOESContextANGLE", P(gl::SamplerParameterIuivOESContextANGLE)},
{"glSamplerParameterIuivRobustANGLE", P(gl::SamplerParameterIuivRobustANGLE)},
{"glSamplerParameterIuivRobustANGLEContextANGLE",
P(gl::SamplerParameterIuivRobustANGLEContextANGLE)},
@@ -1071,8 +1083,12 @@
{"glTexImage3DContextANGLE", P(gl::TexImage3DContextANGLE)},
{"glTexImage3DRobustANGLE", P(gl::TexImage3DRobustANGLE)},
{"glTexImage3DRobustANGLEContextANGLE", P(gl::TexImage3DRobustANGLEContextANGLE)},
+ {"glTexParameterIivOES", P(gl::TexParameterIivOES)},
+ {"glTexParameterIivOESContextANGLE", P(gl::TexParameterIivOESContextANGLE)},
{"glTexParameterIivRobustANGLE", P(gl::TexParameterIivRobustANGLE)},
{"glTexParameterIivRobustANGLEContextANGLE", P(gl::TexParameterIivRobustANGLEContextANGLE)},
+ {"glTexParameterIuivOES", P(gl::TexParameterIuivOES)},
+ {"glTexParameterIuivOESContextANGLE", P(gl::TexParameterIuivOESContextANGLE)},
{"glTexParameterIuivRobustANGLE", P(gl::TexParameterIuivRobustANGLE)},
{"glTexParameterIuivRobustANGLEContextANGLE", P(gl::TexParameterIuivRobustANGLEContextANGLE)},
{"glTexParameterf", P(gl::TexParameterf)},
@@ -1246,5 +1262,5 @@
{"glWeightPointerOES", P(gl::WeightPointerOES)},
{"glWeightPointerOESContextANGLE", P(gl::WeightPointerOESContextANGLE)}};
-size_t g_numProcs = 1178;
+size_t g_numProcs = 1194;
} // namespace egl
diff --git a/src/libGLESv2/proc_table_data.json b/src/libGLESv2/proc_table_data.json
index 2383dd5..49255c2 100644
--- a/src/libGLESv2/proc_table_data.json
+++ b/src/libGLESv2/proc_table_data.json
@@ -539,6 +539,17 @@
"glTexStorage3DMultisampleOES"
],
+ "GL_OES_texture_border_clamp": [
+ "glTexParameterIivOES",
+ "glTexParameterIuivOES",
+ "glGetTexParameterIivOES",
+ "glGetTexParameterIuivOES",
+ "glSamplerParameterIivOES",
+ "glSamplerParameterIuivOES",
+ "glGetSamplerParameterIivOES",
+ "glGetSamplerParameterIuivOES"
+ ],
+
"GLES3 core": [
"glReadBuffer",
"glDrawRangeElements",
diff --git a/src/tests/gl_tests/TextureTest.cpp b/src/tests/gl_tests/TextureTest.cpp
index 4ee8151..e6c94b5 100644
--- a/src/tests/gl_tests/TextureTest.cpp
+++ b/src/tests/gl_tests/TextureTest.cpp
@@ -2751,6 +2751,439 @@
runSamplerInStructTest();
}
+// GL_OES_texture_border_clamp
+class TextureBorderClampTest : public Texture2DTest
+{
+ protected:
+ TextureBorderClampTest() : Texture2DTest() {}
+
+ std::string getVertexShaderSource() override
+ {
+ return
+ R"(precision highp float;
+ attribute vec4 position;
+ varying vec2 texcoord;
+
+ void main()
+ {
+ gl_Position = vec4(position.xy, 0.0, 1.0);
+ // texcoords in [-0.5, 1.5]
+ texcoord = (position.xy) + 0.5;
+ })";
+ }
+
+ void uploadTexture()
+ {
+ glActiveTexture(GL_TEXTURE0);
+ glBindTexture(GL_TEXTURE_2D, mTexture2D);
+ std::vector<GLColor> texDataRed(1, GLColor::red);
+ glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, 1, 1, 0, GL_RGBA, GL_UNSIGNED_BYTE,
+ texDataRed.data());
+ EXPECT_GL_NO_ERROR();
+ }
+};
+
+// Test if the color set as GL_TEXTURE_BORDER_COLOR is used when sampling outside of the texture in
+// GL_CLAMP_TO_BORDER wrap mode (set with glTexParameter).
+TEST_P(TextureBorderClampTest, TextureBorderClampFunctional)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ setUpProgram();
+
+ uploadTexture();
+
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_BORDER);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_BORDER);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+ glTexParameterfv(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, &kFloatGreen.R);
+ EXPECT_GL_NO_ERROR();
+
+ drawQuad(mProgram, "position", 0.5f);
+
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() / 2, getWindowHeight() / 2, GLColor::red);
+ EXPECT_PIXEL_COLOR_EQ(0, 0, GLColor::green);
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() - 1, getWindowHeight() - 1, GLColor::green);
+}
+
+// Test reading back GL_TEXTURE_BORDER_COLOR by glGetTexParameter.
+TEST_P(TextureBorderClampTest, TextureBorderClampFunctional2)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ glActiveTexture(GL_TEXTURE0);
+ glBindTexture(GL_TEXTURE_2D, mTexture2D);
+
+ glTexParameterfv(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, &kFloatGreen.R);
+
+ GLint colorFixedPoint[4] = {0};
+ glGetTexParameteriv(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorFixedPoint);
+ constexpr GLint colorGreenFixedPoint[4] = {0, std::numeric_limits<GLint>::max(), 0,
+ std::numeric_limits<GLint>::max()};
+ EXPECT_EQ(colorFixedPoint[0], colorGreenFixedPoint[0]);
+ EXPECT_EQ(colorFixedPoint[1], colorGreenFixedPoint[1]);
+ EXPECT_EQ(colorFixedPoint[2], colorGreenFixedPoint[2]);
+ EXPECT_EQ(colorFixedPoint[3], colorGreenFixedPoint[3]);
+
+ constexpr GLint colorBlueFixedPoint[4] = {0, 0, std::numeric_limits<GLint>::max(),
+ std::numeric_limits<GLint>::max()};
+ glTexParameteriv(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorBlueFixedPoint);
+
+ GLfloat color[4] = {0.0f};
+ glGetTexParameterfv(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, color);
+ EXPECT_EQ(color[0], kFloatBlue.R);
+ EXPECT_EQ(color[1], kFloatBlue.G);
+ EXPECT_EQ(color[2], kFloatBlue.B);
+ EXPECT_EQ(color[3], kFloatBlue.A);
+}
+
+// Test GL_TEXTURE_BORDER_COLOR parameter validation at glTexParameter.
+TEST_P(TextureBorderClampTest, TextureBorderClampValidation)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ glActiveTexture(GL_TEXTURE0);
+ glBindTexture(GL_TEXTURE_2D, mTexture2D);
+
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, 1.0f);
+ EXPECT_GL_ERROR(GL_INVALID_ENUM);
+
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, std::numeric_limits<GLint>::max());
+ EXPECT_GL_ERROR(GL_INVALID_ENUM);
+
+ glTexParameterfv(GL_TEXTURE_2D_MULTISAMPLE, GL_TEXTURE_BORDER_COLOR, &kFloatGreen.R);
+ EXPECT_GL_ERROR(GL_INVALID_ENUM);
+
+ GLint colorInt[4] = {0};
+ glTexParameteriv(GL_TEXTURE_2D_MULTISAMPLE_ARRAY, GL_TEXTURE_BORDER_COLOR, colorInt);
+ EXPECT_GL_ERROR(GL_INVALID_ENUM);
+
+ if (getClientMajorVersion() < 3)
+ {
+ glTexParameterIivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorInt);
+ EXPECT_GL_ERROR(GL_INVALID_OPERATION);
+ glGetTexParameterIivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorInt);
+ EXPECT_GL_ERROR(GL_INVALID_OPERATION);
+
+ GLuint colorUInt[4] = {0};
+ glTexParameterIuivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorUInt);
+ EXPECT_GL_ERROR(GL_INVALID_OPERATION);
+ glGetTexParameterIuivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorUInt);
+ EXPECT_GL_ERROR(GL_INVALID_OPERATION);
+
+ GLSampler sampler;
+ glSamplerParameterIivOES(sampler, GL_TEXTURE_BORDER_COLOR, colorInt);
+ EXPECT_GL_ERROR(GL_INVALID_OPERATION);
+ glGetSamplerParameterIivOES(sampler, GL_TEXTURE_BORDER_COLOR, colorInt);
+ EXPECT_GL_ERROR(GL_INVALID_OPERATION);
+
+ glSamplerParameterIuivOES(sampler, GL_TEXTURE_BORDER_COLOR, colorUInt);
+ EXPECT_GL_ERROR(GL_INVALID_OPERATION);
+ glGetSamplerParameterIuivOES(sampler, GL_TEXTURE_BORDER_COLOR, colorUInt);
+ EXPECT_GL_ERROR(GL_INVALID_OPERATION);
+ }
+}
+
+class TextureBorderClampTestES3 : public TextureBorderClampTest
+{
+ protected:
+ TextureBorderClampTestES3() : TextureBorderClampTest() {}
+};
+
+// Test if the color set as GL_TEXTURE_BORDER_COLOR is used when sampling outside of the texture in
+// GL_CLAMP_TO_BORDER wrap mode (set with glSamplerParameter).
+TEST_P(TextureBorderClampTestES3, TextureBorderClampES3Functional)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ setUpProgram();
+
+ uploadTexture();
+
+ GLSampler sampler;
+ glBindSampler(0, sampler);
+ glSamplerParameteri(sampler, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_BORDER);
+ glSamplerParameteri(sampler, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_BORDER);
+ glSamplerParameteri(sampler, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+ glSamplerParameteri(sampler, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+ glSamplerParameterfv(sampler, GL_TEXTURE_BORDER_COLOR, &kFloatGreen.R);
+ EXPECT_GL_NO_ERROR();
+
+ drawQuad(mProgram, "position", 0.5f);
+
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() / 2, getWindowHeight() / 2, GLColor::red);
+ EXPECT_PIXEL_COLOR_EQ(0, 0, GLColor::green);
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() - 1, getWindowHeight() - 1, GLColor::green);
+}
+
+// Test reading back GL_TEXTURE_BORDER_COLOR by glGetSamplerParameter.
+TEST_P(TextureBorderClampTestES3, TextureBorderClampES3Functional2)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ glActiveTexture(GL_TEXTURE0);
+
+ GLSampler sampler;
+ glBindSampler(0, sampler);
+
+ glSamplerParameterfv(sampler, GL_TEXTURE_BORDER_COLOR, &kFloatGreen.R);
+
+ GLint colorFixedPoint[4] = {0};
+ glGetSamplerParameteriv(sampler, GL_TEXTURE_BORDER_COLOR, colorFixedPoint);
+ constexpr GLint colorGreenFixedPoint[4] = {0, std::numeric_limits<GLint>::max(), 0,
+ std::numeric_limits<GLint>::max()};
+ EXPECT_EQ(colorFixedPoint[0], colorGreenFixedPoint[0]);
+ EXPECT_EQ(colorFixedPoint[1], colorGreenFixedPoint[1]);
+ EXPECT_EQ(colorFixedPoint[2], colorGreenFixedPoint[2]);
+ EXPECT_EQ(colorFixedPoint[3], colorGreenFixedPoint[3]);
+
+ constexpr GLint colorBlueFixedPoint[4] = {0, 0, std::numeric_limits<GLint>::max(),
+ std::numeric_limits<GLint>::max()};
+ glSamplerParameteriv(sampler, GL_TEXTURE_BORDER_COLOR, colorBlueFixedPoint);
+
+ GLfloat color[4] = {0.0f};
+ glGetSamplerParameterfv(sampler, GL_TEXTURE_BORDER_COLOR, color);
+ EXPECT_EQ(color[0], kFloatBlue.R);
+ EXPECT_EQ(color[1], kFloatBlue.G);
+ EXPECT_EQ(color[2], kFloatBlue.B);
+ EXPECT_EQ(color[3], kFloatBlue.A);
+
+ constexpr GLint colorSomewhatRedInt[4] = {500000, 0, 0, std::numeric_limits<GLint>::max()};
+ glSamplerParameterIivOES(sampler, GL_TEXTURE_BORDER_COLOR, colorSomewhatRedInt);
+ GLint colorInt[4] = {0};
+ glGetSamplerParameterIivOES(sampler, GL_TEXTURE_BORDER_COLOR, colorInt);
+ EXPECT_EQ(colorInt[0], colorSomewhatRedInt[0]);
+ EXPECT_EQ(colorInt[1], colorSomewhatRedInt[1]);
+ EXPECT_EQ(colorInt[2], colorSomewhatRedInt[2]);
+ EXPECT_EQ(colorInt[3], colorSomewhatRedInt[3]);
+
+ constexpr GLuint colorSomewhatRedUInt[4] = {500000, 0, 0, std::numeric_limits<GLuint>::max()};
+ glSamplerParameterIuivOES(sampler, GL_TEXTURE_BORDER_COLOR, colorSomewhatRedUInt);
+ GLuint colorUInt[4] = {0};
+ glGetSamplerParameterIuivOES(sampler, GL_TEXTURE_BORDER_COLOR, colorUInt);
+ EXPECT_EQ(colorUInt[0], colorSomewhatRedUInt[0]);
+ EXPECT_EQ(colorUInt[1], colorSomewhatRedUInt[1]);
+ EXPECT_EQ(colorUInt[2], colorSomewhatRedUInt[2]);
+ EXPECT_EQ(colorUInt[3], colorSomewhatRedUInt[3]);
+
+ glBindTexture(GL_TEXTURE_2D, mTexture2D);
+
+ constexpr GLint colorSomewhatGreenInt[4] = {0, 500000, 0, std::numeric_limits<GLint>::max()};
+ glTexParameterIivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorSomewhatGreenInt);
+ glGetTexParameterIivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorInt);
+ EXPECT_EQ(colorInt[0], colorSomewhatGreenInt[0]);
+ EXPECT_EQ(colorInt[1], colorSomewhatGreenInt[1]);
+ EXPECT_EQ(colorInt[2], colorSomewhatGreenInt[2]);
+ EXPECT_EQ(colorInt[3], colorSomewhatGreenInt[3]);
+
+ constexpr GLuint colorSomewhatGreenUInt[4] = {0, 500000, 0, std::numeric_limits<GLuint>::max()};
+ glTexParameterIuivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorSomewhatGreenUInt);
+ glGetTexParameterIuivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, colorUInt);
+ EXPECT_EQ(colorUInt[0], colorSomewhatGreenUInt[0]);
+ EXPECT_EQ(colorUInt[1], colorSomewhatGreenUInt[1]);
+ EXPECT_EQ(colorUInt[2], colorSomewhatGreenUInt[2]);
+ EXPECT_EQ(colorUInt[3], colorSomewhatGreenUInt[3]);
+}
+
+// Test GL_TEXTURE_BORDER_COLOR parameter validation at glSamplerParameter.
+TEST_P(TextureBorderClampTestES3, TextureBorderClampES3Validation)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ glActiveTexture(GL_TEXTURE0);
+
+ GLSampler sampler;
+ glBindSampler(0, sampler);
+
+ glSamplerParameterf(sampler, GL_TEXTURE_BORDER_COLOR, 1.0f);
+ EXPECT_GL_ERROR(GL_INVALID_ENUM);
+
+ glSamplerParameteri(sampler, GL_TEXTURE_BORDER_COLOR, std::numeric_limits<GLint>::max());
+ EXPECT_GL_ERROR(GL_INVALID_ENUM);
+}
+
+class TextureBorderClampIntegerTestES3 : public Texture2DTest
+{
+ protected:
+ TextureBorderClampIntegerTestES3() : Texture2DTest(), isUnsignedIntTest(false) {}
+
+ std::string getVertexShaderSource() override
+ {
+ return
+ R"(#version 300 es
+ out vec2 texcoord;
+ in vec4 position;
+
+ void main()
+ {
+ gl_Position = vec4(position.xy, 0.0, 1.0);
+ // texcoords in [-0.5, 1.5]
+ texcoord = (position.xy) + 0.5;
+ })";
+ }
+
+ std::string getFragmentShaderSource()
+ {
+ // clang-format off
+ return std::string(
+ "#version 300 es\n"
+ "precision highp float;\n"
+ "uniform highp ") + (isUnsignedIntTest ? "usampler2D" : "isampler2D") + " tex;\n"
+ "in vec2 texcoord;\n"
+ "out vec4 fragColor;\n"
+
+ "void main()\n"
+ "{\n"
+ "vec4 red = vec4(1.0, 0.0, 0.0, 1.0);\n"
+ "vec4 green = vec4(0.0, 1.0, 0.0, 1.0);\n"
+ "fragColor = (texture(tex, texcoord).r == " + (isUnsignedIntTest ? "150u" : "-50") + ")"
+ " ? green : red;\n"
+ "}\n";
+ // clang-format on
+ }
+
+ void uploadTexture()
+ {
+ glActiveTexture(GL_TEXTURE0);
+ glBindTexture(GL_TEXTURE_2D, mTexture2D);
+ if (isUnsignedIntTest)
+ {
+ std::vector<GLubyte> texData(4, 100);
+ glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA8UI, 1, 1, 0, GL_RGBA_INTEGER, GL_UNSIGNED_BYTE,
+ texData.data());
+ }
+ else
+ {
+ std::vector<GLbyte> texData(4, 100);
+ glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA8I, 1, 1, 0, GL_RGBA_INTEGER, GL_BYTE,
+ texData.data());
+ }
+ EXPECT_GL_NO_ERROR();
+ }
+
+ bool isUnsignedIntTest;
+};
+
+// Test if the integer values set as GL_TEXTURE_BORDER_COLOR is used when sampling outside of the
+// integer texture in GL_CLAMP_TO_BORDER wrap mode (set with glTexParameterIivOES).
+TEST_P(TextureBorderClampIntegerTestES3, TextureBorderClampInteger)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ setUpProgram();
+
+ uploadTexture();
+
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_BORDER);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_BORDER);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+
+ constexpr GLint borderColor[4] = {-50, -50, -50, -50};
+ glTexParameterIivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, borderColor);
+
+ EXPECT_GL_NO_ERROR();
+
+ drawQuad(mProgram, "position", 0.5f);
+
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() / 2, getWindowHeight() / 2, GLColor::red);
+ EXPECT_PIXEL_COLOR_EQ(0, 0, GLColor::green);
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() - 1, getWindowHeight() - 1, GLColor::green);
+}
+
+// Test if the integer values set as GL_TEXTURE_BORDER_COLOR is used when sampling outside of the
+// integer texture in GL_CLAMP_TO_BORDER wrap mode (set with glTexParameterIivOES).
+TEST_P(TextureBorderClampIntegerTestES3, TextureBorderClampInteger2)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ setUpProgram();
+
+ uploadTexture();
+
+ GLSampler sampler;
+ glBindSampler(0, sampler);
+ glSamplerParameteri(sampler, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_BORDER);
+ glSamplerParameteri(sampler, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_BORDER);
+ glSamplerParameteri(sampler, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+ glSamplerParameteri(sampler, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+
+ constexpr GLint borderColor[4] = {-50, -50, -50, -50};
+ glSamplerParameterIivOES(sampler, GL_TEXTURE_BORDER_COLOR, borderColor);
+
+ EXPECT_GL_NO_ERROR();
+
+ drawQuad(mProgram, "position", 0.5f);
+
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() / 2, getWindowHeight() / 2, GLColor::red);
+ EXPECT_PIXEL_COLOR_EQ(0, 0, GLColor::green);
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() - 1, getWindowHeight() - 1, GLColor::green);
+}
+
+// Test if the unsigned integer values set as GL_TEXTURE_BORDER_COLOR is used when sampling outside
+// of the unsigned integer texture in GL_CLAMP_TO_BORDER wrap mode (set with glTexParameterIuivOES).
+TEST_P(TextureBorderClampIntegerTestES3, TextureBorderClampIntegerUnsigned)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ isUnsignedIntTest = true;
+
+ setUpProgram();
+
+ uploadTexture();
+
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_BORDER);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_BORDER);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+
+ constexpr GLuint borderColor[4] = {150, 150, 150, 150};
+ glTexParameterIuivOES(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, borderColor);
+
+ EXPECT_GL_NO_ERROR();
+
+ drawQuad(mProgram, "position", 0.5f);
+
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() / 2, getWindowHeight() / 2, GLColor::red);
+ EXPECT_PIXEL_COLOR_EQ(0, 0, GLColor::green);
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() - 1, getWindowHeight() - 1, GLColor::green);
+}
+
+// Test if the unsigned integer values set as GL_TEXTURE_BORDER_COLOR is used when sampling outside
+// of the unsigned integer texture in GL_CLAMP_TO_BORDER wrap mode (set with
+// glSamplerParameterIuivOES).
+TEST_P(TextureBorderClampIntegerTestES3, TextureBorderClampIntegerUnsigned2)
+{
+ ANGLE_SKIP_TEST_IF(!extensionEnabled("GL_OES_texture_border_clamp"));
+
+ isUnsignedIntTest = true;
+
+ setUpProgram();
+
+ uploadTexture();
+
+ GLSampler sampler;
+ glBindSampler(0, sampler);
+ glSamplerParameteri(sampler, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_BORDER);
+ glSamplerParameteri(sampler, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_BORDER);
+ glSamplerParameteri(sampler, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
+ glSamplerParameteri(sampler, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+
+ constexpr GLuint borderColor[4] = {150, 150, 150, 150};
+ glSamplerParameterIuivOES(sampler, GL_TEXTURE_BORDER_COLOR, borderColor);
+
+ EXPECT_GL_NO_ERROR();
+
+ drawQuad(mProgram, "position", 0.5f);
+
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() / 2, getWindowHeight() / 2, GLColor::red);
+ EXPECT_PIXEL_COLOR_EQ(0, 0, GLColor::green);
+ EXPECT_PIXEL_COLOR_EQ(getWindowWidth() - 1, getWindowHeight() - 1, GLColor::green);
+}
+
+// ~GL_OES_texture_border_clamp
+
class TextureLimitsTest : public ANGLETest
{
protected:
@@ -3932,6 +4365,13 @@
ES2_D3D9(),
ES2_OPENGL(),
ES2_OPENGLES());
+ANGLE_INSTANTIATE_TEST(TextureBorderClampTest,
+ ES2_D3D11(),
+ ES2_D3D9(),
+ ES2_OPENGL(),
+ ES2_OPENGLES());
+ANGLE_INSTANTIATE_TEST(TextureBorderClampTestES3, ES3_D3D11(), ES3_OPENGL(), ES3_OPENGLES());
+ANGLE_INSTANTIATE_TEST(TextureBorderClampIntegerTestES3, ES3_D3D11(), ES3_OPENGL(), ES3_OPENGLES());
ANGLE_INSTANTIATE_TEST(TextureLimitsTest, ES2_D3D11(), ES2_OPENGL(), ES2_OPENGLES(), ES2_VULKAN());
ANGLE_INSTANTIATE_TEST(Texture2DNorm16TestES3, ES3_D3D11(), ES3_OPENGL(), ES3_OPENGLES());
ANGLE_INSTANTIATE_TEST(TextureCubeTestES3, ES3_D3D11(), ES3_OPENGL(), ES3_OPENGLES());