diff options
Diffstat (limited to 'meta-extras/packages/clutter/moblin-proto/fix-shader-and-callbacks.patch')
-rw-r--r-- | meta-extras/packages/clutter/moblin-proto/fix-shader-and-callbacks.patch | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/meta-extras/packages/clutter/moblin-proto/fix-shader-and-callbacks.patch b/meta-extras/packages/clutter/moblin-proto/fix-shader-and-callbacks.patch new file mode 100644 index 0000000000..4a3eddb8cd --- /dev/null +++ b/meta-extras/packages/clutter/moblin-proto/fix-shader-and-callbacks.patch | |||
@@ -0,0 +1,44 @@ | |||
1 | diff --git a/Makefile b/Makefile | ||
2 | index e05b5b7..c348a1e 100644 | ||
3 | --- a/Makefile | ||
4 | +++ b/Makefile | ||
5 | @@ -64,7 +64,7 @@ HFILES = $(wildcard *.h) | ||
6 | %.o: %.c $(HFILES) | ||
7 | $(CC) -g $(CFLAGS) $(INCS) -c $< -o$@ | ||
8 | $(BINARY): $(OBJECTS) | ||
9 | - $(CXX) -o $@ $(OBJECTS) $(LIBS) | ||
10 | + $(CXX) -rdynamic -o $@ $(OBJECTS) $(LIBS) | ||
11 | |||
12 | #$(BINARY): $(CFILES) | ||
13 | # $(LD) $(CFLAGS) $(INCS) $(CFILES) $(LIBS) -o $@ | ||
14 | diff --git a/moblin-desktop.c b/moblin-desktop.c | ||
15 | index 6dd4f2c..fb9d231 100644 | ||
16 | --- a/moblin-desktop.c | ||
17 | +++ b/moblin-desktop.c | ||
18 | @@ -103,6 +103,8 @@ void moblin_blur (void) | ||
19 | if (desktop->maincopy) | ||
20 | return; | ||
21 | |||
22 | + if (clutter_feature_available (CLUTTER_FEATURE_SHADERS_GLSL)) | ||
23 | + { | ||
24 | #if 0 | ||
25 | desktop->maincopy = clutter_texture_new_from_actor (desktop->mainstuff); | ||
26 | #else | ||
27 | @@ -158,6 +160,17 @@ void moblin_blur (void) | ||
28 | 1.0f / moblin_desktop_width ()); | ||
29 | } | ||
30 | clutter_actor_set_shader_param (desktop->maincopy, "radius", 3.0); | ||
31 | + } | ||
32 | + else | ||
33 | + { | ||
34 | + ClutterColor clr= { 0x44, 0x44, 0x44, 0x77 }; | ||
35 | + guint w, h; | ||
36 | + | ||
37 | + desktop->maincopy = clutter_rectangle_new_with_color (&clr); | ||
38 | + clutter_actor_get_size (desktop->mainstuff, &w, &h); | ||
39 | + clutter_actor_set_size (desktop->maincopy, w, h); | ||
40 | + clutter_group_add (desktop->copyholder, desktop->maincopy); | ||
41 | + } | ||
42 | } | ||
43 | |||
44 | void moblin_unblur (void) | ||