summaryrefslogtreecommitdiff
path: root/tests/spec/arb_es2_compatibility
AgeCommit message (Collapse)AuthorFilesLines
2021-10-07Add missing max draw buffers checks to various tests.Emma Anholt1-12/+17
Acked-by: Adam Jackson <ajax@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/piglit/-/merge_requests/586>
2021-01-23arb_es2_compatibility: Check return value.Vinson Lee1-4/+7
Calling piglit_link_check_status without checking return value Reported-by: Coverity Scan Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/piglit/-/merge_requests/251>
2017-05-18tests: mark KHR_no_error incompatible testsTimothy Arceri1-0/+1
There is still a huge number of tests to classify but this gives us a good number of tests to start testing with.
2016-07-22arb_es2_compatibility: remove '#ifdef GL_EXTENSION' guardsEmil Velikov5-25/+0
Analogous to previous commit(s). With this commit no GL test in piglit (barring glean) relies on this broken behaviour. Checked with the following: $ git grep "defined.*\<GL_" $ git grep "ifdef.*\<GL_" Only local definitions can be seen with the inverse query $ git grep "ifndef.*\<GL_" Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-02-07es2_compat: run glReleaseShaderCompiler before link and use a builtinIlia Mirkin1-5/+10
All that mesa does when releasing the shader compiler is clear its builtins list. So make sure to use a builtin, and release the compiler sooner, to trigger a bug in mesa. This code sequence is hit by some core Android component. Reported-by: Rob Herring <robh@kernel.org> Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Timothy Arceri <timothy.arceri@collabora.com>
2015-09-29Remove unnecessary linking with libGLUIan Romanick1-1/+0
This patch was created by: sed -i -e '/[{]OPENGL_glu_LIBRARY[}]/d' $(grep -lr OPENGL_glu_LIBRARY) git checkout tests/glean/CMakeLists.gl.txt git checkout tests/spec/gl-1.4/CMakeLists.gl.txt git checkout tests/fbo/CMakeLists.gl.txt So, there are three places out of all of piglit that actually need this library. Signed-off-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Matt Turner <mattst88@gmail.com> Thanked-by: Kristian Høgsberg <krh@bitplanet.net>
2014-10-21Replaced assert(glGetError()) with gl_check_gl_error()Juliet fru1-2/+4
Report PIGLIT_FAIL if there's an unexpected error. Reviewed-by: Brian Paul <brianp@vmware.com>
2014-09-23fbo-missing-attachment-clear: probe correct buffer sizeBrian Paul1-3/+5
The piglit_probe_rect_depth() was invalid because it was using the piglit window size rather than the FBO size. Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
2014-07-15util/gl: Rename piglit-util-gl-common.hChad Versace9-9/+9
There are no longer any source files in tests/util that are specific to a particular OpenGL API. In other words, all OpenGL utility sources in tests/util are now "common" and shared by all OpenGL APIs. So remove the 'common' in filename 'piglit-util-gl-common.h'. Signed-off-by: Chad Versace <chad.versace@linux.intel.com> Reviewed-by: Brian Paul <brianp@vmware.com>
2014-05-13arb_es2_compatibility: use default window sizeBrian Paul2-4/+0
Reviewed-by: José Fonseca <jfonseca@vmware.com>
2013-12-02Always bind piglit_winsys_fbo instead of 0Marek Olšák1-2/+2
Tested-by: Dylan Baker <baker.dylan.c@gmail.com>
2013-06-04piglit: Switch a bunch of tests over to piglit_build_simple_program.Eric Anholt2-10/+4
Since I was about to clean up some piglit_compile_shader_text calls, I was looking at all these anyway. Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2013-04-16Rework the PIGLIT_GL_VISUAL flags, fix RGB vs RGBA vs ALPHA confusionMarek Olšák2-2/+2
Changes: - SINGLE is removed, because its value was 0 - ALPHA is removed, because it becomes redundant with this change - RGB asks for an RGB visual - RGBA asks for an RGBA visual - if RGB and RGBA are unset, it asks for a visual without RGB(A) Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Chris Forbes <chrisf@ijw.co.nz> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> v2: fix glut
2013-01-14arb_es2_compatibility: remove explicit 100x100 window sizeBrian Paul3-6/+0
Reviewed-by: José Fonseca <jfonseca@vmware.com>
2012-10-09util: Add fields to piglit_gl_test_config for listing supported GL flavors (v2)Chad Versace9-0/+18
This patch has 3 interrelated components. 1) Add the following fields to piglit_gl_test_config: supports_gl_core_version supports_gl_compat_version supports_gl_es1 supports_gl_es2 These allow a test to specify what GL flavors under which it can run. For details, see the documentation for struct piglit_gl_test_config. 2. In tests/util/piglit-framework-gl, implement support for the new fields. 3. In each GL test source, add one of the new fields to the PIGLIT_GL_TEST_CONFIG_BEGIN/END block. For GLES1 tests, add `supports_gl_es1 = true`. For GLES2 tests, add `supports_gl_es2 = true`. For desktop GL tests, add `supports_gl_compat_version = 10`. For an explanation of why version 1.0 is used for desktop GL tests, see the documentation for supports_gl_compat_version. No tests yet require a GL core context. v2: Replace silly sum of booleans with a logical conjuction. For Anholt. Reviewed-and-tested-by: Jordan Justen <jordan.l.justen@intel.com> Tested-by: Paul Berry <stereotype441@gmail.com> Acked-by: Eric Anholt <eric@anholt.net> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-10-09util: Convert GL tests to use PIGLIT_GL_CONFIG_BEGIN/ENDChad Versace9-36/+63
This patch has two components. 1. In tests/util/piglit-framework-gl.h, replace the definition of PIGLIT_GL_TEST_MAIN with the macro block PIGLIT_GL_CONFIG_BEGIN/END. The macro PIGLIT_GL_TEST_MAIN was very restrictive. It was a fixed-arity macro function that allowed a test to set only set 3 values: window width, height, and visual. It would have been difficult to shoehorn optional test attributes into such a fixed-arity macro function. Allowing optional attributes is an essential feature because a following commit adds optional fields to struct piglit_gl_test_config. The macro block PIGLIT_GL_TEST_CONFIG_BEGIN/END is more flexible. Within it the test is allowed to arbitrarilty modify the piglit_gl_test_config structure. 2. In each GL test source, replace PIGLIT_GL_TEST_MAIN with a PIGLIT_GL_TEST_CONFIG_BEGIN/END block. Reviewed-and-tested-by: Jordan Justen <jordan.l.justen@intel.com> Tested-by: Paul Berry <stereotype441@gmail.com> Acked-by: Eric Anholt <eric@anholt.net> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-10-09util,tests: Replace GLUT visual enums with PIGLTI_GL_VISUAL enums (v2)Chad Versace9-9/+9
I'm trying to transition Piglit from using GLUT to using Waffle. That requires either killing or wrapping all GLUT code. Define enum piglit_gl_visual in piglit-framework.h, of which each value matches its corresponding GLUT visual enum. Do the following substitution in all util and test sources: GLUT_RGB -> PIGLIT_GL_VISUAL_RGB GLUT_RGBA -> PIGLIT_GL_VISUAL_RGBA GLUT_DOUBLE -> PIGLIT_GL_VISUAL_DOUBLE GLUT_ACCUM -> PIGLIT_GL_VISUAL_ACCUM GLUT_ALPHA -> PIGLIT_GL_VISUAL_ALPHA GLUT_DEPTH -> PIGLIT_GL_VISUAL_DEPTH GLUT_STENCIL -> PIGLIT_GL_VISUAL_STENCIL v2: Remove GLUT_INDEX, for Ken. Reviewed-and-tested-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Tested-by: Paul Berry <stereotype441@gmail.com> Acked-by: Eric Anholt <eric@anholt.net> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-10-08fbo-missing-attachment-clear: remove unused err varBrian Paul1-1/+0
2012-10-07Use piglit_check_gl_error() instead of block with [f]printf.Chris Forbes1-8/+2
Generated from the following semantic patch. @@ expression RET, MSG; @@ - RET = glGetError(); - if (RET != 0) { + if (!piglit_check_gl_error(GL_NO_ERROR)) ( - printf(MSG,RET); | - fprintf(stderr,MSG,RET); ) piglit_report_result(PIGLIT_FAIL); - } Signed-off-by: Chris Forbes <chrisf@ijw.co.nz> Reviewed-by: Brian Paul <brianp@vmware.com>
2012-09-10Convert simple if(piglit_get_gl_version() < N) { SKIP } to requireChris Forbes5-20/+5
Generated from the following semantic patch: @@ expression VER; expression MSG; @@ - if (piglit_get_gl_version() < VER) { - printf(MSG); - piglit_report_result(PIGLIT_SKIP); ( - exit(1); | ) - } + piglit_require_gl_version(VER); Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
2012-09-04Convert all glutSwapBuffers to piglit_present_resultsChris Forbes3-3/+3
V2: Don't break tests/general/read-front Reviewed-by: Paul Berry <stereotype441@gmail.com> Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
2012-06-28cmake: Move piglitutil library to piglitutil_glBlaž Tomažič1-1/+1
Build gl utilities to piglitutil_gl library insted of piglitutil. As a result all executables linking to piglitutil library now link to piglitutil_gl. Signed-off-by: Blaž Tomažič <blaz.tomazic@gmail.com> Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
2012-06-28util: Move piglit-util to piglit-util-gl-commonBlaž Tomažič9-9/+9
Move piglit-util.* to piglit-util-gl-common.* Signed-off-by: Blaž Tomažič <blaz.tomazic@gmail.com> Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
2012-06-20tests: Let each test define main()Chad Versace9-21/+36
Each test that did not define main() now does so using PIGLIT_GL_TEST_MAIN(). Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-05-23cmake: Relocate all GLUT directives into single locationChad Versace1-2/+0
Nearly all CMakeLists.gl.txt contained the following: include_directories(${GLUT_INCLUDE_DIR}) link_libraries(${GLUT_glut_LIBRARY}) This patch relocates them to cmake/target_api/gl/CMakeLists.txt. Reviewed-by: Pauli Nieminen <pauli.nieminen@intel.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com> Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-03-23cmake: Replace calls to add_{executable,library} with wrappersChad Versace1-9/+9
Replace add_executable -> piglit_add_executable add_library -> piglit_add_library For now, each wrapper function trivially wraps the function it replaces, and so this patch changes no behavior. This commit was created using the command: sed -i -e "s/add_executable/piglit_add_executable/" -e "s/add_library/piglit_add_library/" $(find src/ tests/ -name "*CMakeLists*") Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
2012-03-07Stop using GLEW extension macrosPaul Berry4-4/+4
Several tests were checking for the presence of GL extensions using GLEW macros. This patch changes the tests to use piglit_is_extension_supported(), which provides the same functionality in a way that is not dependent on GLEW. v2: Follow piglit convention of including "GL_" in the string passed to piglit_is_extension_supported(). Reviewed-by: Chad Versace <chad.versace@linux.intel.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2012-03-07Stop using GLEW_VERSION_* macrosPaul Berry5-5/+5
Several tests were checking the GL version using GLEW's GLEW_VERSION_* macros. This patch changes the tests to use piglit_get_gl_version(), which provides the same functionality in a way that is not dependent on GLEW. Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
2012-03-03don't write generated header to the source directoryDylan Noblesmith1-1/+0
It was impossible to have the source directory read-only. Also add the include_directories() directive for tests/util in just one place, under tests/, so that all subdirectories inherit it. A bunch of CMakeLists.txt files duplicate it, so delete those redundant include flags: sed -i -e "/^\t\${piglit_SOURCE_DIR}\/tests\/util/ d" \ `grep piglit_SOURCE_DIR -rl tests/ | grep "CMakeLists\.gl"`
2011-07-25Fix several "set-but-not-used" gcc warnings.Eric Anholt1-0/+2
2011-06-06arb_es2_compatibility: Verify FBO blits with missing color doesn't crashIan Romanick2-0/+217
There are four ways this test can be run. - Color/depth blit to an FBO w/o color with draw buffer = NONE - Color/depth blit to an FBO w/o color with draw buffer != NONE (ES2 FBO completeness rules). - Color/depth blit from an FBO w/o color with draw buffer = NONE - Color/depth blit from an FBO w/o color with draw buffer != NONE (ES2 FBO completeness rules). In addition, after the blit the values in the depth buffer are probed to make sure that part of the blit happened. Reviewed-by: Eric Anholt <eric@anholt.net>
2011-06-06arb_es2_compatibility: Verify clearing FBO with missing color doesn't crashIan Romanick2-1/+116
The relaxed completeness rules in ARB_ES2_compatibility allow clearing the color buffer of an FBO that lacks a color attachment and has the draw buffer set to non-GL_NONE. Reproduces Mesa bugzilla #37739. Reviewed-by: Eric Anholt <eric@anholt.net>
2011-05-13Make TIFF an optional dependency.José Fonseca1-1/+0
It's only used by glean, so no need to force linking against it everywhere.
2011-04-29Rename PIGLIT_SUCCESS and PIGLIT_FAILURE to PIGLIT_PASS and PIGLIT_FAIL, resp.Marek Olšák5-12/+12
2011-04-29arb_es2_compatibility-fixed-type: new test for GL_FIXED vertex typeMarek Olšák2-0/+143
2011-03-07cmake: Allow GL/glext.h to be specified separately.José Fonseca1-0/+1
glext.h is not bundled on MSVC, so its path needs to be included separately. It might be also useful on other platforms to override the system's glext.h with a more recent one.
2011-02-25cmake: Each CMakeLists.txt that produces a target, rename to CMakeLists.gl.txtChad Versace2-22/+25
In preparation for adding GLES2 targets to Piglit, it is necessary to compartmentalize the GL targets and the GLES2 targets (of which none yet exist) in API-specific CMake files. Since all CMake targets currently use the OpenGL API, achieving compartmentalization is as simple as renaming each CMakeLists.txt. Note: This belongs to a series that adds GLES2 support to Piglit. Signed-off-by: Chad Versace <chad.versace@intel.com>
2011-02-25cmake: Don't add source dirs as link dirsChad Versace1-5/+0
This fixes out-of-source builds, and does not harm in-source builds. CMake is intelligent enough to add the appropriate link directories itself. Signed-off-by: Chad Versace <chad.versace@intel.com>
2011-02-17Import GLEWMarek Olšák1-2/+0
Discussed on IRC. Finally we have headers for OpenGL 4.1 and all the extensions released to this day.
2011-02-04Modify arb_es2_compatibility-releaseshadercompiler to only use ES2 interfacesIan Romanick1-30/+59
Use #version 100 shaders. Use generic attribute 0 instead of gl_Vertex. Don't use gl_ModelViewProjectionMatrix. Use GL_TRIANGLE_STRIP instead of GL_QUADS. Make sure all the shaders need are actually included. Previously glsl-uniform-color.frag was not in the GIT repo.
2011-01-15add compile-time checks for GL_ARB_ES2_compatibilityBrian Paul5-0/+23
In case glew.h isn't up to date.
2011-01-14arb_es2_compatibility: New test for glGetShaderPrecisionFormatIan Romanick2-0/+128
2011-01-14arb_es2_compatibility: Add missing CMakeLists.txtIan Romanick1-0/+28
2011-01-14arb_es2_compatibility: New test for fbo completeness ignoring glDrawBuffers().Eric Anholt1-0/+106
2011-01-14arb_es2_compatibility: New test for SHADER_COMPILER always being set.Eric Anholt1-0/+62
2011-01-14arb_es2_compatibility: New test for MAX_*_COMPONENTS / 4 = MAX_*_VECTORSEric Anholt1-0/+88
2011-01-14arb_es2_compatibility: New test for glDepthRangef.Eric Anholt1-0/+83
2011-01-14arb_es2_compability: Add a test for glReleaseShaderCompilerEric Anholt1-0/+103