On 10/28/2013 12:16 PM, Jon Ashburn wrote:
Tests GL_ARB_texture_view rendering with various texture targets.
Creates texture maps with different solid colors for each level or layer
reads the framebuffer to ensure the rendered color is correct.

Tested on Nvidia  Quadro 600, all subtests pass.

Signed-off-by: Jon Ashburn <j...@lunarg.com>
---
  tests/all.tests                                |   1 +
  tests/spec/arb_texture_view/CMakeLists.gl.txt  |   1 +
  tests/spec/arb_texture_view/common.c           |  78 ++++++-
  tests/spec/arb_texture_view/common.h           |  16 +-
  tests/spec/arb_texture_view/rendering_target.c | 270 +++++++++++++++++++++++++
  5 files changed, 364 insertions(+), 2 deletions(-)
  create mode 100644 tests/spec/arb_texture_view/rendering_target.c

diff --git a/tests/all.tests b/tests/all.tests
index 8784e24..5941eb2 100644
--- a/tests/all.tests
+++ b/tests/all.tests
@@ -1476,6 +1476,7 @@ arb_texture_view['params'] = 
concurrent_test('arb_texture_view-params')
  arb_texture_view['formats'] = concurrent_test('arb_texture_view-formats')
  arb_texture_view['targets'] = concurrent_test('arb_texture_view-targets')
  arb_texture_view['queries'] = concurrent_test('arb_texture_view-queries')
+arb_texture_view['rendering-target'] = 
concurrent_test('arb_texture_view-rendering-target')

  tdfx_texture_compression_fxt1 = Group()
  spec['3DFX_texture_compression_FXT1'] = tdfx_texture_compression_fxt1
diff --git a/tests/spec/arb_texture_view/CMakeLists.gl.txt 
b/tests/spec/arb_texture_view/CMakeLists.gl.txt
index 6945a05..6b69bb1 100644
--- a/tests/spec/arb_texture_view/CMakeLists.gl.txt
+++ b/tests/spec/arb_texture_view/CMakeLists.gl.txt
@@ -14,5 +14,6 @@ piglit_add_executable(arb_texture_view-params params.c)
  piglit_add_executable(arb_texture_view-formats formats.c common.c)
  piglit_add_executable(arb_texture_view-targets targets.c common.c)
  piglit_add_executable(arb_texture_view-queries queries.c)
+piglit_add_executable(arb_texture_view-rendering-target rendering_target.c 
common.c)

  # vim: ft=cmake:
diff --git a/tests/spec/arb_texture_view/common.c 
b/tests/spec/arb_texture_view/common.c
index 5d7b6b9..2453847 100644
--- a/tests/spec/arb_texture_view/common.c
+++ b/tests/spec/arb_texture_view/common.c
@@ -26,6 +26,44 @@
  #include "piglit-util-gl-common.h"
  #include <stdarg.h>

+GLubyte Colors[][8] = {

const qualifier?


+               {127,   0,   0, 255,  0, 10, 20,  0},
+               {  0, 127,   0, 255,  0,  0, 80, 90},
+               {  0,   0, 127, 255, 25,  0,  0, 60},
+               {  0, 127, 127, 255, 15, 15,  0,  0},
+               {127,   0, 127, 255,  0,  2, 50,  0},
+               {127, 127,   0, 255, 80, 10, 70, 20},
+               {255,   0,   0, 255, 60,  0, 40, 30},
+               {  0, 255,   0, 255, 50, 20,  2, 40},
+               {  0,   0, 255, 255, 40,  0,  1,  0},
+               {  0, 255, 255, 255, 30,  5,  3,  8},
+               {255,   0, 255, 255, 20, 18,  4,  7},
+               {255, 255,   0, 255,  10, 24, 77, 67},
+               {255, 255, 255, 255,  5,  33, 88, 44}
+};
+

-Brian


_______________________________________________
Piglit mailing list
Piglit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to