[gthumb/gthumb-3-10] image viewer: fixed bright line visual artifacts
- From: Paolo Bacchilega <paobac src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gthumb/gthumb-3-10] image viewer: fixed bright line visual artifacts
- Date: Sun, 13 Dec 2020 15:06:32 +0000 (UTC)
commit a0e318b146026b74a263f2c126c21a501128c2a6
Author: Paolo Bacchilega <paobac src gnome org>
Date: Sun Nov 29 16:12:08 2020 +0100
image viewer: fixed bright line visual artifacts
Fixes https://gitlab.gnome.org/GNOME/gthumb/-/issues/118
gthumb/gth-image-dragger.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gthumb/gth-image-dragger.c b/gthumb/gth-image-dragger.c
index 9eadbbfd..547958b6 100644
--- a/gthumb/gth-image-dragger.c
+++ b/gthumb/gth-image-dragger.c
@@ -588,8 +588,8 @@ _gth_image_dragger_update_scaled_image (GthImageDragger *self)
zoom_from_original = gth_image_viewer_get_zoom (self->priv->viewer);
gth_image_viewer_get_original_size (self->priv->viewer, &original_width, &original_height);
- new_width = zoom_from_original * original_width * screen_scale_factor;
- new_height = zoom_from_original * original_height * screen_scale_factor;
+ new_width = zoom_from_original * original_width * screen_scale_factor + 0.5;
+ new_height = zoom_from_original * original_height * screen_scale_factor + 0.5;
image_width = cairo_image_surface_get_width (image);
image_height = cairo_image_surface_get_height (image);
zoom_from_image = (double) new_width / image_width;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]