From 99c2a8b362add1750ecba9f9c3f98abb01824c9b Mon Sep 17 00:00:00 2001 From: "senorblanco@chromium.org" Date: Wed, 4 May 2011 20:12:01 +0000 Subject: [PATCH] SampleApp builds skia on Linux with BGRA pixel order, but Ganesh's SampleApp assumes GL_RGBA texture format on all platforms except Windows (where it uses GL_BGRA), so texture colours come out wrong. As a temporary fix, do on Linux what we do on Windows, and assume GL_BGRA. (This should be made more general later, and the assumption of matching formats between Skia and Ganesh removed.) Review URL: http://codereview.appspot.com/4474046/ git-svn-id: http://skia.googlecode.com/svn/trunk@1247 2bbb7eff-a529-9590-31e7-b0007b416f81 --- gpu/include/GrGLConfig.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gpu/include/GrGLConfig.h b/gpu/include/GrGLConfig.h index 18cc04901..b4ca78cee 100644 --- a/gpu/include/GrGLConfig.h +++ b/gpu/include/GrGLConfig.h @@ -133,7 +133,7 @@ // Pick a pixel config for 32bit bitmaps. Our default is GL_RGBA (except on // Windows where we match GDI's order). #ifndef GR_GL_32BPP_COLOR_FORMAT - #if GR_WIN32_BUILD + #if GR_WIN32_BUILD || GR_LINUX_BUILD #define GR_GL_32BPP_COLOR_FORMAT GR_GL_BGRA #else #define GR_GL_32BPP_COLOR_FORMAT GR_GL_RGBA