Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore zoom quality after viewing a GIF #1067

Closed
khumba opened this issue Mar 11, 2023 · 3 comments
Closed

Restore zoom quality after viewing a GIF #1067

khumba opened this issue Mar 11, 2023 · 3 comments

Comments

@khumba
Copy link

khumba commented Mar 11, 2023

ISSUE TYPE

  • Bug Report

GEEQIE VERSION

Geeqie 2.0.1 GTK3
GTK+ 3.24.37

OS / DISTRIBUTION

Gentoo amd64

SUMMARY

Geeqie downgrades the image rendering quality when displaying GIFs:

static void image_change_complete(ImageWindow *imd, gdouble zoom)
{
  ...

      /* Disable 2-pass for GIFs. Animated GIFs can flicker when enabled
       * Reduce quality to worst but fastest to avoid dropped frames */
      if (g_ascii_strcasecmp(imd->image_fd->extension, ".GIF") == 0)
        {
        g_object_set(G_OBJECT(imd->pr), "zoom_2pass", FALSE, NULL);
        g_object_set(G_OBJECT(imd->pr), "zoom_quality", GDK_INTERP_NEAREST, NULL);
        }

It doesn't seem to switch back to a higher-quality render after switching away from the GIF to some other image. Could Geeqie please restore these two options? Maybe they could just be reset on each image change?

Workaround: Open the preferences window and click Ok.

Thanks for maintaining Geeqie, it's a great program.

STEPS TO REPRODUCE

  1. Open Geeqie.
  2. Set the zoom quality to Bilinear in preferences.
  3. Navigate from a non-GIF to a GIF image.
  4. Navigate to a non-GIF image that is larger than the Geeqie window, and see that Nearest rendering is still active.
@khumba
Copy link
Author

khumba commented Mar 12, 2023

Also it might be nice to downgrade the quality only if the GIF is animated.

@mowgli mowgli closed this as completed in 94afaee Mar 13, 2023
@caclark
Copy link
Collaborator

caclark commented Mar 13, 2023

Also it might be nice to downgrade the quality only if the GIF is animated.

Changes are required to handle webp animation correctly - this point might be fixed at the same time.

@khumba
Copy link
Author

khumba commented Mar 14, 2023

Fantastic, thanks for the quick fix. The patch works for me.

Changes are required to handle webp animation correctly - this point might be fixed at the same time.

Sounds good!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants