[cogl] Fix the alpha value in the default texture data
- From: Neil Roberts <nroberts src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [cogl] Fix the alpha value in the default texture data
- Date: Mon, 1 Jul 2013 12:34:43 +0000 (UTC)
commit 2ffc77565fb6395b986d3274f8bdb6eee6addbf9
Author: Neil Roberts <neil linux intel com>
Date: Fri Jun 21 17:46:19 2013 +0100
Fix the alpha value in the default texture data
When a layer is added to a pipeline without setting a texture it ends
up sampling from a default 1x1 texture which is meant to be solid
white. However for some reason we were creating the texture with 0
opacity which is effectively an invalid premultiplied colour. This
would make the blending behave oddly if it was used.
https://bugzilla.gnome.org/show_bug.cgi?id=702570
Reviewed-by: Robert Bragg <robert linux intel com>
cogl/cogl-context.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/cogl/cogl-context.c b/cogl/cogl-context.c
index c2ad0a2..9b650bb 100644
--- a/cogl/cogl-context.c
+++ b/cogl/cogl-context.c
@@ -126,7 +126,7 @@ cogl_context_new (CoglDisplay *display,
CoglError **error)
{
CoglContext *context;
- GLubyte default_texture_data[] = { 0xff, 0xff, 0xff, 0x0 };
+ uint8_t default_texture_data[] = { 0xff, 0xff, 0xff, 0xff };
CoglBitmap *default_texture_bitmap;
const CoglWinsysVtable *winsys;
int i;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]