summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel van Vugt <daniel.van.vugt@canonical.com>2019-03-25 11:27:38 +0800
committerDaniel van Vugt <daniel.van.vugt@canonical.com>2019-03-26 11:38:52 +0800
commitd15e11bfe74c773f313be6b69f2d692077ff8be2 (patch)
tree1f7ebd4f4fecbfaa482889b06bca5555c38936d5
parent1eabaf12da4346d9b08a9e4c236255dc1dd076ec (diff)
downloadmutter-d15e11bfe74c773f313be6b69f2d692077ff8be2.tar.gz
background: Shrink wallpaper using LINEAR_MIPMAP_LINEAR
Commit 8e9184b6 added filtering to avoid image jaggies when downscaling but used `LINEAR_MIPMAP_NEAREST`. In some situations this could lead to GL choosing a single lower resolution mipmap and then upscaling it, hence slightly blurry. We don't want to revert that change since it avoids aliasing jaggies, so let's use `LINEAR_MIPMAP_LINEAR` instead. This provides the highest quality filtering that GL can do and avoids the situation of GL using a single mipmap that's lower resolution than the screen. Now it will blend that one with the next mipmap which is higher resolution than the screen. This still avoids jaggies but also maintains 1px resolution. Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/1105 https://gitlab.gnome.org/GNOME/mutter/merge_requests/505
-rw-r--r--src/compositor/meta-background.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/compositor/meta-background.c b/src/compositor/meta-background.c
index 6dd4242d2..c033395fe 100644
--- a/src/compositor/meta-background.c
+++ b/src/compositor/meta-background.c
@@ -615,7 +615,7 @@ create_pipeline (PipelineType type)
cogl_pipeline_set_layer_filters (templates[type],
0,
- COGL_PIPELINE_FILTER_LINEAR_MIPMAP_NEAREST,
+ COGL_PIPELINE_FILTER_LINEAR_MIPMAP_LINEAR,
COGL_PIPELINE_FILTER_LINEAR);
return cogl_pipeline_copy (templates[type]);