diff options
author | Xabier Rodriguez Calvar <xrcalvar@igalia.com> | 2012-07-30 18:45:03 +0200 |
---|---|---|
committer | Xabier Rodriguez Calvar <xrcalvar@igalia.com> | 2012-07-30 18:45:03 +0200 |
commit | cd2ec42d55abd5b47a32564528dee453b9ab59fd (patch) | |
tree | bdd19fb2dd52907f733f0fc6c2da17d71e2ec33f | |
parent | 51435b782f80abd0aecae3443c739b09113f5e06 (diff) | |
download | gdk-pixbuf-cd2ec42d55abd5b47a32564528dee453b9ab59fd.tar.gz |
Too much rounding when scaling the pixbufs.
The former code was causing that some frames where 1 pixel bigger than
the animation.
-rw-r--r-- | gdk-pixbuf/gdk-pixbuf-scaled-anim.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gdk-pixbuf/gdk-pixbuf-scaled-anim.c b/gdk-pixbuf/gdk-pixbuf-scaled-anim.c index 9fbe5a2d8..da7e7a2c2 100644 --- a/gdk-pixbuf/gdk-pixbuf-scaled-anim.c +++ b/gdk-pixbuf/gdk-pixbuf-scaled-anim.c @@ -138,8 +138,8 @@ get_scaled_pixbuf (GdkPixbufScaledAnim *scaled, /* Get a new scaled pixbuf */ scaled->current = gdk_pixbuf_scale_simple (pixbuf, - MAX((int) (round((gdouble) gdk_pixbuf_get_width (pixbuf) * scaled->xscale + .5)), 1), - MAX((int) (round((gdouble) gdk_pixbuf_get_height (pixbuf) * scaled->yscale + .5)), 1), + MAX((int) ((gdouble) gdk_pixbuf_get_width (pixbuf) * scaled->xscale + .5), 1), + MAX((int) ((gdouble) gdk_pixbuf_get_height (pixbuf) * scaled->yscale + .5), 1), GDK_INTERP_BILINEAR); /* Copy the original pixbuf options to the scaled pixbuf */ |