brave / brave-browser

Brave browser for Android, iOS, Linux, macOS, Windows.
https://brave.com
Mozilla Public License 2.0
17.95k stars 2.35k forks source link

Images are extremely blurry #5405

Open adamreisnz opened 5 years ago

adamreisnz commented 5 years ago

Description

Images in Brave are extremely blurry in some cases.

Steps to Reproduce

Compare this Github page in Firefox (left) and Brave (right) and look at the avatars:

image

Actual result:

Avatar is so blurry I almost don't recognise myself.

Expected result:

For the avatar to be sharp, as I uploaded it and as other browsers display it.

Reproduces how often:

100%

Brave version (brave://version info)

Brave 0.66.100 Chromium: 75.0.3770.142 (Official Build) (64-bit)
Revision 8d93477bd18154c67a70a67019cb8032382c55dd-refs/branch-heads/3770@{#1160}
OS Mac OS X

Version/Channel Information:

Chrome also seems to be affected.

Other Additional Information:

Miscellaneous Information:

I note that when creating a new issue, the avatar there looks sharp (both screenshots from Brave):

image

Upon inspecting the code, it seems the difference is that the blurry image is originally larger. So it seems the algorithm to downsize images is broken, as images which are larger should, when downsize, be sharper not blurrier.

The sharp images is downsized from 88px to 44px, whereas the blurry image is downsized from 180px to 44px.

kjozwiak commented 5 years ago

@adamreisnz can you try and see if you get the same results on Chrome? I went through a few images on GH and it seems like Firefox renders them more clearly compared to Chromium browsers. Would be interesting to see if Chrome/Opera and other Chromium based browsers are having the same issue compared to Firefox.

adamreisnz commented 5 years ago

Yes, Chrome has the same problem as I mentioned also in the original issue.

I don't think Firefox renders them more clearly necessarily, because Brave does render the image that is downsized from 88px to 44px with the same clarity.

It's when Brave/Chrome scale the 180px image down to 44px when the algorithms seem to fail and render blurry images instead.

I've noticed this started to happen a few months ago.