From patchwork Sat Jun 20 12:14:35 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: 'Timothy Arceri' via Patchwork Forward X-Patchwork-Id: 50129 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f198.google.com (mail-wi0-f198.google.com [209.85.212.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id A8F0A21594 for ; Sat, 20 Jun 2015 12:15:21 +0000 (UTC) Received: by wibdt2 with SMTP id dt2sf11373732wib.3 for ; Sat, 20 Jun 2015 05:15:20 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:delivered-to:from:to:date :message-id:in-reply-to:references:subject:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :mime-version:content-type:content-transfer-encoding:errors-to :sender:x-original-sender:x-original-authentication-results :mailing-list:reply-to; bh=xsgkNsJrzyABSBAsmI3aUsZ5rbQ7M8GEDYcyOsU7hRM=; b=RLT0xvmfO+1u+1IErd9ol7OL0kw6NE8BbWZmTJd3stPoHKi/vkGCIFaiolGm3xeFbv t6QNSUaYu/8LSGv8AN7mMT0aMC/8kNxlDk0CFaZCeYbB93Mdb8no+dZ7LUDdxkVw1nvP imA1u99sRTcoh9SEM9+9uf97cx2/tfJm5GBrqGOXSRcKxF7Fne3UAyFodLfQjhwA7yJA RXalKXSvvSh9yzDuzngXBWX//7lT6mhxsm8mlnDPx8ioHdljA5Wn5DHOyJDO/r62eQee NQmrreghiQIlI9cQke7RNyNaJL426NPsBKJZxviR+hM1wfApOhnG0WCjA/9FntAguFUI H8Ag== X-Gm-Message-State: ALoCoQkMIWd/sC7aqFfoHL1mEy6v1tNk3yD6cj6loVGRMplW3nXJDCU7GG3vMegZlrYsO5jltadt X-Received: by 10.152.37.101 with SMTP id x5mr19546153laj.5.1434802520909; Sat, 20 Jun 2015 05:15:20 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.8.1 with SMTP id n1ls621056laa.87.gmail; Sat, 20 Jun 2015 05:15:20 -0700 (PDT) X-Received: by 10.152.27.197 with SMTP id v5mr21789655lag.23.1434802520794; Sat, 20 Jun 2015 05:15:20 -0700 (PDT) Received: from mail-la0-x22c.google.com (mail-la0-x22c.google.com. [2a00:1450:4010:c03::22c]) by mx.google.com with ESMTPS id lj10si11650240lbc.100.2015.06.20.05.15.20 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 20 Jun 2015 05:15:20 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 2a00:1450:4010:c03::22c as permitted sender) client-ip=2a00:1450:4010:c03::22c; Received: by labbc20 with SMTP id bc20so87514401lab.1 for ; Sat, 20 Jun 2015 05:15:20 -0700 (PDT) X-Received: by 10.152.7.7 with SMTP id f7mr22276132laa.106.1434802520371; Sat, 20 Jun 2015 05:15:20 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.108.230 with SMTP id hn6csp1209550lbb; Sat, 20 Jun 2015 05:15:19 -0700 (PDT) X-Received: by 10.66.90.137 with SMTP id bw9mr41259902pab.52.1434802517041; Sat, 20 Jun 2015 05:15:17 -0700 (PDT) Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTP id wt10si20929693pab.236.2015.06.20.05.15.16; Sat, 20 Jun 2015 05:15:17 -0700 (PDT) Received-SPF: pass (google.com: domain of piglit-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) client-ip=131.252.210.177; Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 02C256E70D; Sat, 20 Jun 2015 05:15:16 -0700 (PDT) X-Original-To: piglit@lists.freedesktop.org Delivered-To: piglit@lists.freedesktop.org Received: from nm28-vm10.bullet.mail.gq1.yahoo.com (nm28-vm10.bullet.mail.gq1.yahoo.com [98.136.216.169]) by gabe.freedesktop.org (Postfix) with ESMTP id 449AD6E70D for ; Sat, 20 Jun 2015 05:15:14 -0700 (PDT) Received: from [98.137.12.55] by nm28.bullet.mail.gq1.yahoo.com with NNFMP; 20 Jun 2015 12:15:13 -0000 Received: from [208.71.42.199] by tm15.bullet.mail.gq1.yahoo.com with NNFMP; 20 Jun 2015 12:15:13 -0000 Received: from [127.0.0.1] by smtp210.mail.gq1.yahoo.com with NNFMP; 20 Jun 2015 12:15:13 -0000 X-Yahoo-Newman-Id: 820636.61572.bm@smtp210.mail.gq1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: dxlwzRMVM1kNhHIypVDfxOwH8Mfw8Mlf8pwv2Eoufbg8hES RiUeFRLpysp6mD0PGi.y76OQAxhuiU1jIk..Z7eOgds.o27U36XgPbrIkW41 TnYQo9neH8U7FKmAcGv8o9u8vcG9v0UR6cZJGJeHLXx._S0ndMfpZ8MAj1Ny kV.QMqWPZVN8h3BrDqarvA1hAtdmeUgRQO54nI0nyVdDuKrvgnaS5FMwIBWZ E6ILZoIPhQgsTPle4zjDhDBkCnCnUHOxtOfsVkmav1vNyOPFK3H8gUs2I.Dj I.gfhK3mNvF7EKiqHtTUpinNCwF_Zs1f1GLu6kwzsqUx106QH8eX3M0lumMN 1SGAZ6LY4s5JMOXmWLN0ha3k9fWEj67bgbl93kk5AoRbU4RGiuGyIVBCOWW3 MrFopebWC9D.mxMVfd_tk.ux0uW7jQ8utQtNfqxa3.ad.kFQsSxgn3j55crF pPCTm7W0F9gbZUy3yjrqDeLmQGuU3ilVmEBVaODzs0YKA5Zh2ZDU_D63QewH RzoGVSJcdIn7U_WyQTemp4VrIscuU4Nfz4PA- X-Yahoo-SMTP: 9BNlx.aswBAkr0D8mG_whiOP1dyU From: "'Timothy Arceri' via Patchwork Forward" To: piglit@lists.freedesktop.org Date: Sat, 20 Jun 2015 22:14:35 +1000 Message-Id: <1434802475-4020-8-git-send-email-t_arceri@yahoo.com.au> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1434802475-4020-1-git-send-email-t_arceri@yahoo.com.au> References: <1434802475-4020-1-git-send-email-t_arceri@yahoo.com.au> Subject: [Piglit] [PATCH 8/8] arb_arrays_of_arrays: basic image store execution tests X-BeenThere: piglit@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Errors-To: piglit-bounces@lists.freedesktop.org Sender: "Piglit" X-Original-Sender: patch@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 2a00:1450:4010:c03::22c as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org; dkim=neutral (body hash did not verify) header.i=@yahoo.com.au; dmarc=fail (p=NONE dis=NONE) header.from=yahoo.com.au Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 X-Original-From: Timothy Arceri Reply-To: Timothy Arceri Test results: Nvidia GeForce 840M - NVIDIA 346.47 basic-imageStore-const-uniform-index.shader_test - pass basic-imageStore-non-const-uniform-index.shader_test - pass --- ...asic-imageStore-const-uniform-index.shader_test | 58 ++++++++++++ ...-imageStore-non-const-uniform-index.shader_test | 101 +++++++++++++++++++++ 2 files changed, 159 insertions(+) create mode 100644 tests/spec/arb_arrays_of_arrays/execution/image_store/basic-imageStore-const-uniform-index.shader_test create mode 100644 tests/spec/arb_arrays_of_arrays/execution/image_store/basic-imageStore-non-const-uniform-index.shader_test diff --git a/tests/spec/arb_arrays_of_arrays/execution/image_store/basic-imageStore-const-uniform-index.shader_test b/tests/spec/arb_arrays_of_arrays/execution/image_store/basic-imageStore-const-uniform-index.shader_test new file mode 100644 index 0000000..0009f86 --- /dev/null +++ b/tests/spec/arb_arrays_of_arrays/execution/image_store/basic-imageStore-const-uniform-index.shader_test @@ -0,0 +1,58 @@ +# Verify simple reading of a uniform and output to an image + +[require] +GL >= 3.3 +GLSL >= 3.30 +GL_ARB_shader_image_load_store +GL_ARB_arrays_of_arrays + +[vertex shader] +#version 130 +in vec4 piglit_vertex; + +void main() +{ + gl_Position = piglit_vertex; +} + +[fragment shader] +#version 330 +#extension GL_ARB_shader_image_load_store: enable +#extension GL_ARB_arrays_of_arrays: require + +uniform vec4 color; +writeonly uniform image2D tex[2][2]; +out vec4 outcolor; + +void main() +{ + imageStore(tex[1][0], ivec2(gl_FragCoord.xy), color); + outcolor = vec4(0.0, 0.0, 0.0, 1.0); +} + +[test] +# Texture 0 is the imageStore output. +uniform int tex[1][0] 0 +texture rgbw 0 (16, 16) +image texture 0 + +# Texture 1 is the rendering output. We don't care about this. +texture rgbw 1 (16, 16) + +# Store red using imageStore +uniform vec4 color 1.0 0.0 0.0 1.0 +fb tex 2d 1 +draw rect -1 -1 2 2 + +# Test the result of imageStore +fb tex 2d 0 +probe all rgba 1.0 0.0 0.0 1.0 + +# Store green using imageStore +uniform vec4 color 0.0 1.0 0.0 1.0 +fb tex 2d 1 +draw rect -1 -1 2 2 + +# Test the result of imageStore +fb tex 2d 0 +probe all rgba 0.0 1.0 0.0 1.0 diff --git a/tests/spec/arb_arrays_of_arrays/execution/image_store/basic-imageStore-non-const-uniform-index.shader_test b/tests/spec/arb_arrays_of_arrays/execution/image_store/basic-imageStore-non-const-uniform-index.shader_test new file mode 100644 index 0000000..f5271e6 --- /dev/null +++ b/tests/spec/arb_arrays_of_arrays/execution/image_store/basic-imageStore-non-const-uniform-index.shader_test @@ -0,0 +1,101 @@ +# Verify simple reading of a uniform and output to an image + +[require] +GL >= 3.3 +GLSL >= 3.30 +GL_ARB_shader_image_load_store +GL_ARB_arrays_of_arrays + +[vertex shader] +#version 130 +in vec4 piglit_vertex; + +void main() +{ + gl_Position = piglit_vertex; +} + +[fragment shader] +#version 330 +#extension GL_ARB_shader_image_load_store: enable +#extension GL_ARB_arrays_of_arrays: require + +uniform vec4 color; +uniform int n; +uniform int m; +writeonly uniform image2D tex[2][2]; +out vec4 outcolor; + +void main() +{ + imageStore(tex[n][m], ivec2(gl_FragCoord.xy), color); + outcolor = vec4(0.0, 0.0, 0.0, 1.0); +} + +[test] +# Texture 0 is the imageStore output. +uniform int tex[0][0] 0 +texture rgbw 0 (16, 16) +image texture 0 + +# Texture 1 is the imageStore output. +uniform int tex[0][1] 1 +texture rgbw 1 (16, 16) +image texture 1 + +# Texture 2 is the imageStore output. +uniform int tex[1][0] 2 +texture rgbw 2 (16, 16) +image texture 2 + +# Texture 3 is the imageStore output. +uniform int tex[1][1] 3 +texture rgbw 3 (16, 16) +image texture 3 + +# Texture 4 is the rendering output. We don't care about this. +texture rgbw 4 (16, 16) + +# Store red using imageStore +uniform int n 0 +uniform int m 0 +uniform vec4 color 1.0 0.0 0.0 1.0 +fb tex 2d 4 +draw rect -1 -1 2 2 + +# Test the result of imageStore 0 +fb tex 2d 0 +probe all rgba 1.0 0.0 0.0 1.0 + +# Store green using imageStore +uniform int n 0 +uniform int m 1 +uniform vec4 color 0.0 1.0 0.0 1.0 +fb tex 2d 4 +draw rect -1 -1 2 2 + +# Test the result of imageStore 1 +fb tex 2d 1 +probe all rgba 0.0 1.0 0.0 1.0 + +# Store blue using imageStore +uniform int n 1 +uniform int m 0 +uniform vec4 color 0.0 0.0 1.0 1.0 +fb tex 2d 4 +draw rect -1 -1 2 2 + +# Test the result of imageStore 2 +fb tex 2d 2 +probe all rgba 0.0 0.0 1.0 1.0 + +# Store cyan using imageStore +uniform int n 1 +uniform int m 1 +uniform vec4 color 0.0 1.0 1.0 1.0 +fb tex 2d 4 +draw rect -1 -1 2 2 + +# Test the result of imageStore 3 +fb tex 2d 3 +probe all rgba 0.0 1.0 1.0 1.0