Open Bug 1307813 Opened 8 years ago Updated 4 months ago

Viewing images on nondefault monitor DPI uses too big scaling (zoom)

Categories

(Core :: Layout: Images, Video, and HTML Frames, defect, P3)

49 Branch
defect

Tracking

()

People

(Reporter: david.balazic, Unassigned)

Details

(Whiteboard: tpi:+)

User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:49.0) Gecko/20100101 Firefox/49.0
Build ID: 20160922113459

Steps to reproduce:

Open http://htse.kapilarya.com/FIX-COM-Surrogate-Has-Stopped-Working-In-Windows-8.1.png on a system with 125% DPI setting.


Actual results:

Image is displayed zoomed in (enlarged), using a scaling algorithm that gives a blurry image.


Expected results:

Image should be displayed 1:1, not scaled. (as Chrome v53 does)
A few more notes:
 - this issue also result in this: if one takes a screenshot of Firefox (displaying some image for example), saves the file, opens it in Firefox, it is displayed enlarged. (taking another screenshot of it enlarges it again, and again...)
 - related question: "Image viewer doesn't offer a native zoom level unless layout.css.devPixelsPerPx is set to 1.0, which makes the entire interface tiny." <https://support.mozilla.org/en-US/questions/1081171>

PS: Is the often mentioned (also in the linked document) layout.css.devPixelsPerPx documented anywhere? (maybe respond out of band for this)
Component: Untriaged → Widget: Win32
Product: Firefox → Core
Priority: -- → P3
Whiteboard: tpi:+

Me and Viewhance extension’s author solved this in Viewhance https://github.com/Deathamns/Viewhance/issues/46
But it should be the default built-in behavior - Firefox must not apply DPI scaling to any media (images and videos) opened in separate tabs

So, in the meantime, you can acheive 100% zoom for images on separate tabs with any windows scaling by installing Viewhance. Then you should paste in Viewhance settings "{"scaling": "*"}" into "Export/import settings" field and then hit "Import" button).

But, again, this certainly needs to be the default behavior. It makes 0 sense to zoom images on separate tabs. Zooming in damages quality (image becomes blurry), it makes screenshots look bad and it does not use full pixel density of display.

I use 150% system DPI and get this issue. Setting layout.css.devPixelsPerPx to 1 does indeed make images scale correctly at 100% zoom (at the expense of all other page and UI elements).

Could this PLEASE get fixed? There are countless reports for it and they all just seem to go ignored. It's been a reported issue since 2013!!! High DPI monitors are only getting more and more common. As someone using a 4k monitor with 200% scaling, every single image I open in the standalone viewer looks absolutely hideous. It only shows at the correct size if I manually zoom out to 50% (200% x 50% = 100%).

Even worse, as an artist it's not sufficient to set up a workaround on my end only. When I'm linking my artwork to other people for viewing in their web browser, I want to be sure they'll actually see it in the correct dimensions rather than a horribly blurry mess. A lot of the people I'm sending artwork to are using 200-300% scaling, so they don't see it as it's supposed to look.

This is marked as a Win32 issue but it affects Linux as well. Specifically tested on GNOME with Wayland.

This has been a reported issue for almost a decade. Looking through other reports it seems they mostly just go completely ignored. Can this please, please be fixed, or at least get some actual response from a human being? Is there anything I can do to get this moving? Any possibility of a bug bounty or something?

Flags: needinfo?(jmathies)
Severity: normal → S4
Status: UNCONFIRMED → NEW
Component: Widget: Win32 → Layout: Images, Video, and HTML Frames
Ever confirmed: true
Flags: needinfo?(jmathies)

FWIW, this seems an issue in other browsers as well, right? I'm not sure the proposed behavior is necessarily better. Fwiw, it is the difference between:

data:text/html,<img srcset="https://htse.kapilarya.com/FIX-COM-Surrogate-Has-Stopped-Working-In-Windows-8.1.png 1x">

and:

data:text/html,<img srcset="https://htse.kapilarya.com/FIX-COM-Surrogate-Has-Stopped-Working-In-Windows-8.1.png 2x">
You need to log in before you can comment on or make changes to this bug.