From patchwork Fri Jan 11 19:46:06 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Gall X-Patchwork-Id: 13997 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 394FC23E27 for ; Fri, 11 Jan 2013 19:46:22 +0000 (UTC) Received: from mail-vb0-f50.google.com (mail-vb0-f50.google.com [209.85.212.50]) by fiordland.canonical.com (Postfix) with ESMTP id E2416A1970C for ; Fri, 11 Jan 2013 19:46:21 +0000 (UTC) Received: by mail-vb0-f50.google.com with SMTP id ft2so1785097vbb.23 for ; Fri, 11 Jan 2013 11:46:21 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:x-forwarded-to:x-forwarded-for:delivered-to:x-received :received-spf:x-received:from:to:cc:subject:date:message-id:x-mailer :x-gm-message-state; bh=rzU26+ajuppRGvWjT1v4avxqwTjn3CyaqSLlWeTJDbg=; b=LTLrBosBAL5oeeKFGPGP8zhYdEAGTGDirMr+pczY2a3dPIpxu3gzqjV3Cn8xcLtxlN 555s8BOHGLIWKiXFT0JJF3U4nMM7eCajNN6PPKS2huOl0uXDlf3DJfk5S3eJg9vQuhwR PHp8ZxbRLVewTNvabBcV2KLBNisBix7aC0Gkwk1Vj6cOY+F8Qusl2IOpk3xypAtWuQJT 3IoLmnwNwW7zIZ1GxPU4VdsjaKQZzey6aSDhefPCvxJpwz/IecVA2Mw2Q16kWVs4Bhol s27D7EvLarhgiMbyYka9t5CzilezHnt1hinm4W2+tSFdGn7X9agUVfWRLNW23PfSoMLo KR0A== X-Received: by 10.58.196.196 with SMTP id io4mr97964957vec.22.1357933581349; Fri, 11 Jan 2013 11:46:21 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.58.145.101 with SMTP id st5csp128964veb; Fri, 11 Jan 2013 11:46:20 -0800 (PST) X-Received: by 10.50.51.231 with SMTP id n7mr227049igo.85.1357933580371; Fri, 11 Jan 2013 11:46:20 -0800 (PST) Received: from mail-ia0-f169.google.com (mail-ia0-f169.google.com [209.85.210.169]) by mx.google.com with ESMTPS id bq4si2017423icc.41.2013.01.11.11.46.20 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 11 Jan 2013 11:46:20 -0800 (PST) Received-SPF: neutral (google.com: 209.85.210.169 is neither permitted nor denied by best guess record for domain of tom.gall@linaro.org) client-ip=209.85.210.169; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.210.169 is neither permitted nor denied by best guess record for domain of tom.gall@linaro.org) smtp.mail=tom.gall@linaro.org Received: by mail-ia0-f169.google.com with SMTP id r4so1880046iaj.14 for ; Fri, 11 Jan 2013 11:46:20 -0800 (PST) X-Received: by 10.50.33.173 with SMTP id s13mr309887igi.23.1357933579951; Fri, 11 Jan 2013 11:46:19 -0800 (PST) Received: from localhost.localdomain ([70.35.96.184]) by mx.google.com with ESMTPS id ee8sm251414igc.13.2013.01.11.11.46.17 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 11 Jan 2013 11:46:18 -0800 (PST) From: Tom Gall To: patches@linaro.org Cc: Tom Gall Subject: [PATCH 1/1] gles2: squash warning Date: Fri, 11 Jan 2013 13:46:06 -0600 Message-Id: <1357933566-23290-1-git-send-email-tom.gall@linaro.org> X-Mailer: git-send-email 1.7.10.4 X-Gm-Message-State: ALoCoQm63r9TPgQx9iaOlzORjxkbp/RtOV5dcr+ahKWS8n8MjhQi6h/WfQDWhaqVl7/gWhbM1U0/ In the newly added piglit_gen_ortho_uniform it introduced a warning due to float *[4] being passed instead of the expected const GLfloat * as the type of the 4th param. Change the array of floats to const GLfloat [4][4] and provide the cast. Signed-off-by: Tom Gall --- tests/util/piglit-util-gl-common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/util/piglit-util-gl-common.c b/tests/util/piglit-util-gl-common.c index 92a0a4d..7674d4e 100644 --- a/tests/util/piglit-util-gl-common.c +++ b/tests/util/piglit-util-gl-common.c @@ -538,13 +538,13 @@ void piglit_gen_ortho_uniform(GLint location, double l, double r, double b, double t, double n, double f) { - float values[4][4] = { + const GLfloat values[4][4] = { { 2/(r-l), 0, 0, -(r+l)/(r-l) }, { 0, 2/(t-b), 0, -(t+b)/(t-b) }, { 0, 0, -2/(f-n), -(f+n)/(f-n) }, { 0, 0, 0, 1 } }; - glUniformMatrix4fv(location, 1, GL_TRUE, values); + glUniformMatrix4fv(location, 1, GL_TRUE, (const GLfloat *)values); }