summaryrefslogtreecommitdiff
path: root/tests/spec/arb_internalformat_query2/common.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/spec/arb_internalformat_query2/common.h')
-rw-r--r--tests/spec/arb_internalformat_query2/common.h31
1 files changed, 29 insertions, 2 deletions
diff --git a/tests/spec/arb_internalformat_query2/common.h b/tests/spec/arb_internalformat_query2/common.h
index df6858101..86aa4c729 100644
--- a/tests/spec/arb_internalformat_query2/common.h
+++ b/tests/spec/arb_internalformat_query2/common.h
@@ -168,7 +168,11 @@ static const GLenum invalid_pnames[] = {
GL_TEXTURE_COMPONENTS,
};
-/* From spec:
+/*
+ * The following are the valid internalformats defined when the spec
+ * was written (at 4.2).
+ *
+ * From spec:
*
* "INTERNALFORMAT_SUPPORTED:
* <skip>
@@ -184,7 +188,7 @@ static const GLenum invalid_pnames[] = {
* - unsized or base internal format, if the implementation accepts
* it for texture or image specification."
*/
-static const GLenum valid_internalformats[] = {
+static const GLenum base_valid_internalformats[] = {
/* Base/unsized internal format (from Table 3.11) */
GL_DEPTH_COMPONENT,
GL_DEPTH_STENCIL,
@@ -279,6 +283,27 @@ static const GLenum valid_internalformats[] = {
GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT,
};
+/*
+ * Below the new internalformats added by ARB_ES3_compatibility, core
+ * since 4.3. You can find those internalformats at Spec 4.3 Table
+ * 8.14
+ */
+static const GLenum arb_es3_compatibility_valid_internalformats[] = {
+ GL_COMPRESSED_RGB8_ETC2,
+ GL_COMPRESSED_SRGB8_ETC2,
+ GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2,
+ GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2,
+ GL_COMPRESSED_RGBA8_ETC2_EAC,
+ GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC,
+ GL_COMPRESSED_R11_EAC,
+ GL_COMPRESSED_SIGNED_R11_EAC,
+ GL_COMPRESSED_RG11_EAC,
+ GL_COMPRESSED_SIGNED_RG11_EAC,
+};
+
+GLenum *valid_internalformats;
+unsigned num_valid_internalformats;
+
typedef struct _test_data test_data;
test_data* test_data_new(int testing64,
@@ -360,3 +385,5 @@ bool create_texture(const GLenum target,
const GLenum internalformat,
GLuint *tex_out,
GLuint *buffer_out);
+
+void initialize_valid_internalformats();