max-texture-size: Really test GL_PROXY_TEXTURE_RECTANGLE

Fix a typo so that GL_PROXY_TEXTURE_RECTANGLE test actually tests that.

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
arb_gpu_shader_fp64: add initial generated tests (v5)

This creates a bunch of built-in tests for GLSL 4.00,
corresponding to the builtin uniform and constant array size tests.

I copied the test generators into new files, as I wasn't really sure how
to separate the float and double generation, maybe some sort of force double
mode to generate the correct code, would need advice of original author.

v2: fix dmat issue

v3: emit glsl-4.00 and ARB_gpu_shader_fp64 tests,
    use a double precision value
    fix double precision emitting bugs
    fix generated constant test to work.

v4: fix emitting extensions names so piglit can skip instead of fail

v5: generate tests into a lowercase subdir.

Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
arb_gpu_shader_fp64: add packDouble2x32 and unpackDouble2x32 tests

Simple tests to make sure the packing is correct, along with constant
tests.

also check corner case with writemasks we ran into while developing

Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
arb_gpu_shader_fp64: add a truncate DBL_MAX test

This just tests that trunc doesn't go via a float conversion
like I was doing when I wrote it originally.

Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
arb_gpu_shader_fp64: add frexp/ldexp tests (v2)

These are special cases the generator can't handle,
ported from the float equivalents with DBL special cases.

v2: add const ldexp test.

Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
arb_gpu_shader_fp64: add double modf test.

This tests modf with doubles.

Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
arb_gpu_shader_fp64: add fma tests

Add constant and non-constant fma double test.

Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
arb_gpu_shader_fp64: add a double vertex output, fs input test

This is to verify we pass 64-bit values from shader stage to shader stage,
correctly.

This just passes vs->fs.

Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
arb_gpu_shader_fp64: test intra-shader stage doubles.

This passes vs->gs->fs.

Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
all.tests: add arb_gpu_shader_fp64 dir

Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Add a test case for all of the modes of RGBA_UNORM BPTC texture

This creates a compressed texture with a block for each of 8 modes of
RGBA_UNORM BPTC compression. The texture is then both rendered and
read back via glGetTexImage and compared with the expected values.
util/gl: Add the BPTC-compressed formats to piglit-util-gl

piglit_rgbw_image has a special override for compressed formats to
ensure that when the size of the image is less than the size of a
block then it picks a solid color instead of using four colors. This
patch adds the BPTC formats to this list.

It also modifies piglit_get_compressed_block_size to handle the
formats.
Add the bptc formats to fbo-formats.h
bptc: Add tests using fbo-generatemipmap-formats

The unsigned half float format needs special handling because the
texture that the test uploads tries to use negative values.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
texwrap: Add the BPTC formats

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
compressedteximage: Add tests for the four BPTC formats

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Add a test for all of the modes of the two half-float formats of BPTC

The test creates a texture with a block for each of the possible modes
of the half-float formats of BPTC and then retrieves it as a
half-float texture via glGetTexImage. This should test that the
decompressor works correctly with all possible code paths. It doesn't
test rendering the texture because that is a bit more tricky to do
accurately as it is not possible to create a half-float render target.

The data is generated randomly with an external program which also
generated the expected results. There are expected results for both
the signed and unsigned formats.