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

Blur Image On Desktop Chrome browsers #23

Closed
ocordova opened this issue Sep 23, 2016 · 10 comments
Closed

Blur Image On Desktop Chrome browsers #23

ocordova opened this issue Sep 23, 2016 · 10 comments
Assignees
Labels

Comments

@ocordova
Copy link

The zoomed image looks blurry on Chrome Desktop even when using a high quality image. No issue with Firefox or Edge.

@spinningarrow
Copy link
Owner

Thanks for opening this. I've heard mention of this bug before but had no luck reproducing it. Could you provide some more information (such as your platform/browser version) or even better - a CodePen example where you see this happening?

@ocordova
Copy link
Author

I realized that there are also some opened issues in fat's repo... You can reproduce it by opening your demo page (or fat's) with Chrome on a Desktop. I've tested it in Windows w/ Chrome 54.0.2840.34 (64-bit) and macOS Sierra v10.12 w/ Chrome 53.0.2785.116 (64-bit)

Perhaps it is imperceptible for photographs, but images with text make it difficult to read.
issue

@spinningarrow
Copy link
Owner

Thanks for the information! I'll reply here once I've looked more into it.

@spinningarrow
Copy link
Owner

Oddly enough, I'm still not seeing this (tried with a textual image). I don't doubt it's happening; I'd just like to reproduce it so I can be sure I've fixed it once I change the code.

@spinningarrow
Copy link
Owner

These are the images I tried - can you check if you see any blurriness with them?

Image 1

screen

Image 2

screen2

Image 3

texty

Also can I have the following information:

  1. What is your display size and resolution?
  2. Does changing your browser window's size have any effect on the blurriness?

@ocordova
Copy link
Author

ocordova commented Oct 7, 2016

If I use those images, there is slightly blurriness almost imperceptible 🤔

1

  1. The display sizes that I've tested are 1366x768 and 1600x900
  2. No, it does not have any effect on the blurriness.

Can you try with this image or this image?

@marathia
Copy link

marathia commented Feb 8, 2017

None of the CSS solutions suggested here and elsewhere worked for me, but this did: in zoom-vanilla.js (lines 189, 189) replace:

var translateY = viewportY - imageCenterY
var translateX = viewportX - imageCenterX

with:

var translateY = Math.round(viewportY - imageCenterY)
var translateX = Math.round(viewportX - imageCenterX)

(inspired on this PR for fat/zoom.js)

@spinningarrow
Copy link
Owner

@ocordova @marathia I've applied that change ^ in the latest commit. If you have the time, can you test if it fixes the issue? Thank you (and apologies for the long delay in getting this out)!

Uses the change from fat#52

@spinningarrow spinningarrow self-assigned this Mar 5, 2017
@marathia
Copy link

marathia commented Mar 6, 2017

@ spinning arrow This indeed fixes the blurriness, thanks!

@spinningarrow
Copy link
Owner

Awesome, closing this 💯

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

No branches or pull requests

3 participants