From patchwork Thu Jul 21 12:36:34 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: alexandros.frantzis@linaro.org X-Patchwork-Id: 2959 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 2EF3E23F4D for ; Thu, 21 Jul 2011 12:42:58 +0000 (UTC) Received: from mail-qy0-f180.google.com (mail-qy0-f180.google.com [209.85.216.180]) by fiordland.canonical.com (Postfix) with ESMTP id F2626A184BF for ; Thu, 21 Jul 2011 12:42:57 +0000 (UTC) Received: by mail-qy0-f180.google.com with SMTP id 30so845420qyk.11 for ; Thu, 21 Jul 2011 05:42:57 -0700 (PDT) Received: by 10.229.217.3 with SMTP id hk3mr209067qcb.38.1311252177763; Thu, 21 Jul 2011 05:42:57 -0700 (PDT) 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.229.217.78 with SMTP id hl14cs139520qcb; Thu, 21 Jul 2011 05:42:57 -0700 (PDT) Received: by 10.227.201.144 with SMTP id fa16mr174964wbb.71.1311251796640; Thu, 21 Jul 2011 05:36:36 -0700 (PDT) Received: from adelie.canonical.com (adelie.canonical.com [91.189.90.139]) by mx.google.com with ESMTP id ft20si2369051wbb.131.2011.07.21.05.36.36; Thu, 21 Jul 2011 05:36:36 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.139 as permitted sender) client-ip=91.189.90.139; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.139 as permitted sender) smtp.mail=bounces@canonical.com Received: from loganberry.canonical.com ([91.189.90.37]) by adelie.canonical.com with esmtp (Exim 4.71 #1 (Debian)) id 1QjsUU-0000D9-U6 for ; Thu, 21 Jul 2011 12:36:34 +0000 Received: from loganberry.canonical.com (localhost [127.0.0.1]) by loganberry.canonical.com (Postfix) with ESMTP id 5124C2EA002 for ; Thu, 21 Jul 2011 12:36:34 +0000 (UTC) MIME-Version: 1.0 X-Launchpad-Project: glmark2 X-Launchpad-Branch: ~glmark2-dev/glmark2/trunk X-Launchpad-Message-Rationale: Subscriber X-Launchpad-Branch-Revision-Number: 61 X-Launchpad-Notification-Type: branch-revision To: Linaro Patch Tracker From: noreply@launchpad.net Subject: [Branch ~glmark2-dev/glmark2/trunk] Rev 61: Request non-zero sizes for the rgb components of the color buffer and the depth buffer when creat... Message-Id: <20110721123634.17019.73189.launchpad@loganberry.canonical.com> Date: Thu, 21 Jul 2011 12:36:34 -0000 Reply-To: noreply@launchpad.net Sender: bounces@canonical.com Errors-To: bounces@canonical.com Precedence: bulk X-Generated-By: Launchpad (canonical.com); Revision="13475"; Instance="initZopeless config overlay" X-Launchpad-Hash: c8eb95e29603f4b72e070df9f5aa6a3ff341aa65 ------------------------------------------------------------ revno: 61 committer: Alexandros Frantzis timestamp: Fri 2010-11-19 13:54:36 +0200 message: Request non-zero sizes for the rgb components of the color buffer and the depth buffer when creating the EGL context. This makes sure we get sane values for them (eg that we actually get a depth buffer!). modified: src/screen-sdl-glesv2.cpp src/sdlgles/attribs.inc --- lp:glmark2 https://code.launchpad.net/~glmark2-dev/glmark2/trunk You are subscribed to branch lp:glmark2. To unsubscribe from this branch go to https://code.launchpad.net/~glmark2-dev/glmark2/trunk/+edit-subscription === modified file 'src/screen-sdl-glesv2.cpp' --- src/screen-sdl-glesv2.cpp 2010-07-13 10:22:05 +0000 +++ src/screen-sdl-glesv2.cpp 2010-11-19 11:54:36 +0000 @@ -44,6 +44,26 @@ return; } +#ifdef _DEBUG + { + int buf, red, green, blue, alpha, depth; + SDL_GLES_GetAttribute(SDL_GLES_BUFFER_SIZE, &buf); + SDL_GLES_GetAttribute(SDL_GLES_RED_SIZE, &red); + SDL_GLES_GetAttribute(SDL_GLES_GREEN_SIZE, &green); + SDL_GLES_GetAttribute(SDL_GLES_BLUE_SIZE, &blue); + SDL_GLES_GetAttribute(SDL_GLES_ALPHA_SIZE, &alpha); + SDL_GLES_GetAttribute(SDL_GLES_DEPTH_SIZE, &depth); + printf("EGL chosen config:\n" + " Buffer: %d bits\n" + " Red: %d bits\n" + " Green: %d bits\n" + " Blue: %d bits\n" + " Alpha: %d bits\n" + " Depth: %d bits\n", + buf, red, green, blue, alpha, depth); + } +#endif + glClearColor(0.0f, 0.0f, 0.0f, 0.5f); glEnable(GL_DEPTH_TEST); glDepthFunc(GL_LEQUAL); === modified file 'src/sdlgles/attribs.inc' --- src/sdlgles/attribs.inc 2010-07-12 13:37:04 +0000 +++ src/sdlgles/attribs.inc 2010-11-19 11:54:36 +0000 @@ -1,13 +1,13 @@ /* List of EGL attributes we care about */ -A(0, EGL_BUFFER_SIZE, 0) -A(1, EGL_RED_SIZE, 0) -A(2, EGL_GREEN_SIZE, 0) -A(3, EGL_BLUE_SIZE, 0) +A(0, EGL_BUFFER_SIZE, 1) +A(1, EGL_RED_SIZE, 1) +A(2, EGL_GREEN_SIZE, 1) +A(3, EGL_BLUE_SIZE, 1) A(4, EGL_LUMINANCE_SIZE, 0) A(5, EGL_ALPHA_SIZE, 0) A(6, EGL_CONFIG_CAVEAT, EGL_DONT_CARE) A(7, EGL_CONFIG_ID, EGL_DONT_CARE) -A(8, EGL_DEPTH_SIZE, 0) +A(8, EGL_DEPTH_SIZE, 1) A(9, EGL_LEVEL, 0) A(10, EGL_NATIVE_RENDERABLE, EGL_DONT_CARE) A(11, EGL_NATIVE_VISUAL_TYPE, EGL_DONT_CARE)