<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Apr 6, 2015 at 8:39 PM, Dave Airlie <span dir="ltr"><<a href="mailto:airlied@gmail.com" target="_blank">airlied@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">From: Dave Airlie <<a href="mailto:airlied@redhat.com">airlied@redhat.com</a>><br>
<br>
Add tests for interaction with ARB_texture_stencil8.<br>
<br>
Signed-off-by: Dave Airlie <<a href="mailto:airlied@redhat.com">airlied@redhat.com</a>><br>
---<br>
 tests/spec/arb_clear_texture/CMakeLists.gl.txt |  1 +<br>
 tests/spec/arb_clear_texture/stencil.c         | 60 ++++++++++++++++++++++++++<br>
 2 files changed, 61 insertions(+)<br>
 create mode 100644 tests/spec/arb_clear_texture/stencil.c<br>
<br>
diff --git a/tests/spec/arb_clear_texture/CMakeLists.gl.txt b/tests/spec/arb_clear_texture/CMakeLists.gl.txt<br>
index 726d5d8..f46e213 100644<br>
--- a/tests/spec/arb_clear_texture/CMakeLists.gl.txt<br>
+++ b/tests/spec/arb_clear_texture/CMakeLists.gl.txt<br>
@@ -20,5 +20,6 @@ piglit_add_executable (arb_clear_texture-float float.c common.c)<br>
 piglit_add_executable (arb_clear_texture-rg rg.c rg.c common.c)<br>
 piglit_add_executable (arb_clear_texture-depth-stencil depth-stencil.c common.c)<br>
 piglit_add_executable (arb_clear_texture-srgb srgb.c common.c)<br>
+piglit_add_executable (arb_clear_texture-stencil stencil.c common.c)<br>
<br>
 # vim: ft=cmake:<br>
diff --git a/tests/spec/arb_clear_texture/stencil.c b/tests/spec/arb_clear_texture/stencil.c<br>
new file mode 100644<br>
index 0000000..629a37c<br>
--- /dev/null<br>
+++ b/tests/spec/arb_clear_texture/stencil.c<br>
@@ -0,0 +1,60 @@<br>
+/*<br>
+ * Copyright (c) 2014 Intel Corporation<br>
+ *<br>
+ * Permission is hereby granted, free of charge, to any person obtaining a<br>
+ * copy of this software and associated documentation files (the "Software"),<br>
+ * to deal in the Software without restriction, including without limitation<br>
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,<br>
+ * and/or sell copies of the Software, and to permit persons to whom the<br>
+ * Software is furnished to do so, subject to the following conditions:<br>
+ *<br>
+ * The above copyright notice and this permission notice (including the next<br>
+ * paragraph) shall be included in all copies or substantial portions of the<br>
+ * Software.<br>
+ *<br>
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR<br>
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,<br>
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL<br>
+ * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER<br>
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING<br>
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS<br>
+ * IN THE SOFTWARE.<br>
+ */<br>
+<br>
+/** @file depth-stencil.c<br></blockquote><div>file stencil.c </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
+ *<br>
+ * A test of using glClearTexSubImage to clear a depth-stencil<br></blockquote><div> clear a stencil</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
+ * texture.<br>
+ */<br>
+<br>
+#include "common.h"<br>
+<br>
+PIGLIT_GL_TEST_CONFIG_BEGIN<br>
+<br>
+       config.supports_gl_compat_version = 13;<br>
+<br>
+       config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE;<br>
+<br>
+PIGLIT_GL_TEST_CONFIG_END<br>
+<br>
+void<br>
+piglit_init(int argc, char **argv)<br>
+{<br>
+       bool pass;<br>
+<br>
+       piglit_require_extension("GL_ARB_texture_stencil8");<br>
+<br>
+       pass = test_format(GL_STENCIL_INDEX8,<br>
+                          GL_STENCIL_INDEX,<br>
+                          GL_UNSIGNED_BYTE,<br>
+                          1);<br>
+<br>
+       piglit_report_result(pass ? PIGLIT_PASS : PIGLIT_FAIL);<br>
+}<br>
+<br>
+enum piglit_result<br>
+piglit_display(void)<br>
+{<br>
+       /* unused */<br>
+       return PIGLIT_FAIL;<br>
+}<br>
<span class=""><font color="#888888">--<br>
2.1.0<br>
<br>
_______________________________________________<br>
Piglit mailing list<br>
<a href="mailto:Piglit@lists.freedesktop.org">Piglit@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/piglit" target="_blank">http://lists.freedesktop.org/mailman/listinfo/piglit</a><br>
</font></span></blockquote></div><br></div><div class="gmail_extra">With above comments fixed, patch is:</div><div class="gmail_extra">Reviewed-by: Anuj Phogat <<a href="mailto:anuj.phogat@gmail.com">anuj.phogat@gmail.com</a>></div></div>