[mutter/gnome-3-14] MetaBackgroundActor: glsl: do not mix int and float.
- From: Adel Gadllah <agadllah src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/gnome-3-14] MetaBackgroundActor: glsl: do not mix int and float.
- Date: Tue, 3 Mar 2015 21:10:53 +0000 (UTC)
commit 8dd7102909ea56de6e9cbb01ee133a40961ac650
Author: Alban Browaeys <prahal yahoo com>
Date: Mon Mar 2 11:34:40 2015 +0100
MetaBackgroundActor: glsl: do not mix int and float.
Implicit conversion from int to float is not supported by
GLSL ES.
Fixes:
(gnome-shell:8954): Cogl-WARNING **: Shader compilation failed:
1:2: P0004: High precision not supported, instead compiling high precision as medium precision
4:17: S0001: Type mismatch in arithmetic operation between 'int' and 'float'
when one trigger the overview mode on Mali 400 r1p1 GPU.
https://bugzilla.gnome.org/show_bug.cgi?id=745442
src/compositor/meta-background-actor.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/compositor/meta-background-actor.c b/src/compositor/meta-background-actor.c
index abc6fda..132494d 100644
--- a/src/compositor/meta-background-actor.c
+++ b/src/compositor/meta-background-actor.c
@@ -115,7 +115,7 @@ typedef enum {
#define FRAGMENT_SHADER_CODE \
"float t = 2.0 * length(position);\n" \
"t = min(t, 1.0);\n" \
-"float pixel_brightness = 1 - t * vignette_sharpness;\n" \
+"float pixel_brightness = 1.0 - t * vignette_sharpness;\n" \
"cogl_color_out.rgb = cogl_color_out.rgb * pixel_brightness;\n" \
typedef struct _MetaBackgroundLayer MetaBackgroundLayer;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]