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

With version 9.0 the PNG image is blurry #1716

Closed
worldsdream opened this issue Nov 25, 2023 · 16 comments
Closed

With version 9.0 the PNG image is blurry #1716

worldsdream opened this issue Nov 25, 2023 · 16 comments
Assignees
Milestone

Comments

@worldsdream
Copy link

System information:

  • Windows OS version: Version 23H2 (Windows 11)
  • ImageGlass version: 9.0.7.1125 (stable)

To Reproduce

Steps to reproduce the behavior:

  1. Install 9.0.7.1125
  2. Open a PNG file
  3. It's blurry
  4. Remove 9.0.7.1125
  5. Install 8.10.9.27 (stable)
  6. Open a PNG file
  7. Everything looks sharp

I will update with a PNG image or screenshots so you can check.

@siblount
Copy link
Contributor

siblount commented Nov 25, 2023

@worldsdream
Is the image in question smaller or larger than your current screen resolution? It's most likely because of the default Image interpolation, since it's default to use a faster, but lower res method of upscaling/downscaling an image.

Try going into your settings, Layout -> Viewer -> Zooming, and set "When zoom <= 100%" and "When zoom > 100%" to High quality bicubic and see if it is sharper for you.

@siblount
Copy link
Contributor

For your reference,

Ranked from fastest & low-res method to slowest & high-res method:

  • Nearest Neighbor - fastest but produces a low-quality image (blurry or blocky image)
  • Linear - slightly slower than nearest neighbor but better image quality
  • Multi-sample linear - slower than linear but better image quality
  • Cubic - slower than multi-sample but better image quality
  • Anisotropic - slower than cubic but better image quality
  • High quality bicubic - slowest method but produces the best image quality.

Because ImageGlass now uses GPU instead of CPU, the speed shouldn't be an issue. But there could be some scenarios where you need to change this setting, especially if you have an older laptop/desktop with only an iGPU (think older than 2016).

For images that are upscaled (aka images that are zoomed in/bigger), my suggestion is to set When zoom > 100% to High quality bicubic.

For images that are downscaled (aka images that are zoomed out/smaller), my suggestion is to set When zoom <= 100% to Linear.

@d2phap Maybe this calls for a feature improvement...I'm debating whether to create a feature request issue.

@siblount
Copy link
Contributor

@d2phap The default settings for the zoom options are inversed. To be clear, the default settings for the zoom options should be as described above:

When zoom > 100% = High quality bicubic.
When zoom <= 100% = Linear.

@andrei2987
Copy link

@worldsdream Is the image in question smaller or larger than your current screen resolution? It's most likely because of the default Image interpolation, since it's default to use a faster, but lower res method of upscaling/downscaling an image.

Try going into your settings, Layout -> Viewer -> Zooming, and set "When zoom <= 100%" and "When zoom > 100%" to High quality bicubic and see if it is sharper for you.

It worked for me. Thank you.

siblount added a commit to siblount/ImageGlass that referenced this issue Nov 28, 2023
siblount added a commit to siblount/ImageGlass that referenced this issue Nov 28, 2023
@d2phap d2phap added this to the v9.1 milestone Nov 28, 2023
@d2phap d2phap pinned this issue Nov 29, 2023
@d2phap
Copy link
Owner

d2phap commented Dec 5, 2023

Fixed in ImageGlass 9.0.8.1208

@d2phap d2phap closed this as completed Dec 5, 2023
@vivadavid
Copy link

Hi,

I have a similar problem, even in version 9.0.8.1208, but it only affects, so far, a particular PNG. This PNG is a screenshot (taken a long time ago probably with Greenshot).

I've tried different interpolation methods, but nothing changed. (By the way, I couldn't find an interpolation method for those cases when zoom is 100%, but I read in a message above that zoom=100% is included in zoom<100%, so maybe When zoom < 100% could be replaced, in the settings, with When zoom <= 100%.).

This is the original screenshot:

original_screenshot

This is the screenshot image viewed in ImageGlass:

screenshot_ImageGlass

This is the screenshot image viewed in Honeyview:

screenshot_Honeyview

@d2phap
Copy link
Owner

d2phap commented Dec 5, 2023

@vivadavid
I just tried with IG 8, IG 9 and MS Photos. They all look the same:

image

@vivadavid
Copy link

Thank you for your reply, @d2phap ! I've just checked that the original screenshot was taken with Greenshot, like the rest of my screenshots, and when I look at the information displayed by ExifTool (see below), I can't find anything different from the information displayed for other screenshots. Maybe there's some kind of rare internal corruption in the PNG due to a bug in Screenshot.

ExifTool Version Number : 12.70
File Name : PEN DRIVE - DUO.png
Directory : C:/Users/vivad/Downloads
File Size : 16 kB
File Modification Date/Time : 2023:08:10 11:15:00+02:00
File Access Date/Time : 2023:12:05 12:49:22+01:00
File Creation Date/Time : 2023:08:10 11:15:00+02:00
File Permissions : -rw-rw-rw-
File Type : PNG
File Type Extension : png
MIME Type : image/png
Image Width : 359
Image Height : 750
Bit Depth : 8
Color Type : RGB
Compression : Deflate/Inflate
Filter : Adaptive
Interlace : Noninterlaced
SRGB Rendering : Perceptual
Gamma : 2.2
Pixels Per Unit X : 4724
Pixels Per Unit Y : 4724
Pixel Units : meters
Software : Greenshot
Image Size : 359x750
Megapixels : 0.269

@d2phap d2phap unpinned this issue Dec 5, 2023
@vivadavid
Copy link

Hi,

I've checked my problematic PNG on other image viewers and only ImageGlass shows a problem.

My screen scale is at 125%, and I've switched to 100% just to give it a try, but the result was the same.

I've viewed a few more images on ImageGlass, but they are all fine, so I really don't know what makes this PNG special.

@Opicka879
Copy link

Opicka879 commented Dec 7, 2023

@vivadavid Try to zoom-out one step and go back to 100% and image should looks fine. I wonder if it behaves the same for you as it does for me. I did report it before the last update and this issue is still same.

Edit: fix works only if i zooming by mouse scroll, not when using auto zoom. And only when zooming out first, not zooming in.

@vivadavid
Copy link

Thanks for your observations, @Opicka879,

With my image at 100%, and using the mouse (with CTRL pressed on):

  • Switching to 124% and back to 100% produces a blurry image.
  • Switching to 81% and back to 100% produces a fine image. After that, if I go in and out alternatively several times, the image is still fine.

@Opicka879
Copy link

@vivadavid Ok, so it is same like me.

@d2phap Can you look at this again please? :)

@vivadavid
Copy link

The funny thing, @Opicka879, is that I've only detected this behaviour with one image in particular, which was generated by Greenshot, like the rest of my screenshots.

@d2phap
Copy link
Owner

d2phap commented Dec 23, 2023

@Opicka879 @vivadavid Please help to test the new build: #1762 (comment)

@vivadavid
Copy link

Hi, @d2phap , after your message, you uploaded another build, which is the one I've tested. The file is IG9_net8.0-windows-17763-x64.zip, and it contains build 9.0.8.1223.

The problem seems to be fixed: thanks!

As a separate issue, what I've noticed is that, the first time you run this build, the window appears on the right bottom corner:

image1

@d2phap
Copy link
Owner

d2phap commented Dec 23, 2023

Thanks @vivadavid for confirming the issue is fixed in build 9.0.8.1223.

As a separate issue, what I've noticed is that, the first time you run this build, the window appears on the right bottom corner:

I forgot to exclude the igconfig.json file when zipping the files.

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

No branches or pull requests

6 participants