From patchwork Sun Jul 5 07:18:16 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: 50667 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f72.google.com (mail-wg0-f72.google.com [74.125.82.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 8B1B3229FC for ; Sun, 5 Jul 2015 07:19:10 +0000 (UTC) Received: by wgjx7 with SMTP id x7sf40555570wgj.3 for ; Sun, 05 Jul 2015 00:19:09 -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=eoNMLRiP5fMjjiR/YVWdKUnCKSvPdDLsdAbvSip4l8k=; b=M0KBtNqGdW0hNgNltnMNPvEY6/oVrRRpcHxwDK5V80yuDrmtqXmcZWDs6YagC3/G17 LEq7a2DAiVyeLC/lUyRjyaFNo8vOMfV8FgvlZBk9h16vyGlS99JRcCYLiHELXzeK4vUg C0+QCV904+aMOQv2n3fw+GwrqGxWG15Ojn6fw5luIUqMWGQQKWYutdfht/QfTOnP4kxL mGaForO0BguV5Nn08HnAaf/OUY56xoJJHtq94FWEFqTjjbWtBmcIsRdD1OWIuRCArBEj eh6yAKi3D0l2SCUtbrRzGkq6EYQ3xz9eFYGGG4HzeghFRMLDx2qI/Q0Jeq3RMcQdKYAf 5ylQ== X-Gm-Message-State: ALoCoQk6hD2SC62UYrGDFKjTJ5rEeAUqNZL49fTuuqBjVbN7uBTcIDkNISnQLOlxOoi7gvFruAFC X-Received: by 10.180.90.106 with SMTP id bv10mr12057976wib.6.1436080749791; Sun, 05 Jul 2015 00:19:09 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.7.71 with SMTP id h7ls74460laa.55.gmail; Sun, 05 Jul 2015 00:19:09 -0700 (PDT) X-Received: by 10.112.92.99 with SMTP id cl3mr44080854lbb.34.1436080749389; Sun, 05 Jul 2015 00:19:09 -0700 (PDT) Received: from mail-la0-x235.google.com (mail-la0-x235.google.com. [2a00:1450:4010:c03::235]) by mx.google.com with ESMTPS id t2si11935573lbj.163.2015.07.05.00.19.09 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 05 Jul 2015 00:19:09 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 2a00:1450:4010:c03::235 as permitted sender) client-ip=2a00:1450:4010:c03::235; Received: by lagh6 with SMTP id h6so122764440lag.2 for ; Sun, 05 Jul 2015 00:19:09 -0700 (PDT) X-Received: by 10.112.199.133 with SMTP id jk5mr44342507lbc.32.1436080748945; Sun, 05 Jul 2015 00:19:08 -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 hn6csp991945lbb; Sun, 5 Jul 2015 00:19:07 -0700 (PDT) X-Received: by 10.70.88.80 with SMTP id be16mr72545923pdb.37.1436080746916; Sun, 05 Jul 2015 00:19:06 -0700 (PDT) Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTP id gv11si22841052pbd.79.2015.07.05.00.19.06; Sun, 05 Jul 2015 00:19:06 -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 D88AA6E3B6; Sun, 5 Jul 2015 00:19:05 -0700 (PDT) X-Original-To: piglit@lists.freedesktop.org Delivered-To: piglit@lists.freedesktop.org Received: from nm21-vm7.bullet.mail.gq1.yahoo.com (nm21-vm7.bullet.mail.gq1.yahoo.com [98.136.217.54]) by gabe.freedesktop.org (Postfix) with ESMTPS id E43506E357 for ; Sun, 5 Jul 2015 00:19:03 -0700 (PDT) Received: from [216.39.60.181] by nm21.bullet.mail.gq1.yahoo.com with NNFMP; 05 Jul 2015 07:19:03 -0000 Received: from [208.71.42.198] by tm17.bullet.mail.gq1.yahoo.com with NNFMP; 05 Jul 2015 07:19:03 -0000 Received: from [127.0.0.1] by smtp209.mail.gq1.yahoo.com with NNFMP; 05 Jul 2015 07:19:03 -0000 X-Yahoo-Newman-Id: 416765.47191.bm@smtp209.mail.gq1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: _HFwzzAVM1la4RTQHaH5wN9gZhsSn371A3w7_hyTVYX9eve t7BHgDL0N445haHUch89n7ngIIsZ3V9ckQBDsPJU3RVTtEg1ZTlisZehUyY. uFnlVW6akCMhXaockrhGPXSKSqyIlz4dLqwXqxkLdArnkWDBNFG6ItRdsXsV rcdosOihg41dkrJ8FhRir2sD4bsVVcr73uSnCxW1aW8OqbWCzpUSbn_f0_jL xRytj5.gvSje7rWYUxB_4PSXdAGhzbEe6irUywXWsTjycDQS6BG55sRsAMNS Kuqf5D1jBGObW7wxyQy4eATnDYG46_UfP6SymTcWS5rAXc0dAIG_3B5DICHA A6gPwDGHvm_3PPCxq3DhNUytqNSl3z_xYr6udiJM4Isp.9Y9_3pEApkv37El exgezZUKPuth6HRbH2xv5zs9skcL9ncqDK5v177AXqYuWqjQHkJcciO.N2gL YAffGoVR5M_lFpmkNwSI04BNaijjfX9W8drCu2HDnVRqpyvJWi.sJnal0.f4 CmqVKW_p7mI2olq0lGWX.KrqmTqoi.pu3zXw- X-Yahoo-SMTP: 9BNlx.aswBAkr0D8mG_whiOP1dyU From: "'Timothy Arceri' via Patchwork Forward" To: piglit@lists.freedesktop.org Date: Sun, 5 Jul 2015 17:18:16 +1000 Message-Id: <1436080696-9702-6-git-send-email-t_arceri@yahoo.com.au> X-Mailer: git-send-email 2.4.3 In-Reply-To: <1436080696-9702-1-git-send-email-t_arceri@yahoo.com.au> References: <1436080696-9702-1-git-send-email-t_arceri@yahoo.com.au> Subject: [Piglit] [PATCH V3 6/6] 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::235 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