[Webkit-unassigned] [Bug 149899] New: Responsive images (srcset, sizes, w) don't load higher resolution when viewport is enlarged.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Oct 7 14:46:22 PDT 2015


https://bugs.webkit.org/show_bug.cgi?id=149899

            Bug ID: 149899
           Summary: Responsive images (srcset, sizes, w) don't load higher
                    resolution when viewport is enlarged.
    Classification: Unclassified
           Product: WebKit
           Version: Safari 9
          Hardware: Macintosh
                OS: Mac OS X 10.11
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: Images
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: duncan at mclink.it

Created attachment 262646
  --> https://bugs.webkit.org/attachment.cgi?id=262646&action=review
testcase

The attached test case defines a 100% size image. The srcset attribute indicates different resolution images to be loaded. The sizes attribute indicates the image is going to be 100% of the viewport size.

The test case file should be opened after the browser window has been made as narrow as possible, or reloading the page after having made the browser window as narrow as possible. This ensures the browser starts with the smallest size image it needs. The placeholder images (sourced from placehold.it) show the image size. The initial image is typically 800 pixels on a retina Mac, with the Safari window as narrow as possible, as indicated by the "800w" text in the image.

The expected behavior is for the image to be reloaded when the viewport size changes, so making the browser window wider should show a new text, such as 1000w or 1200w, and so on.

The actual behavior in Safari 9 is no new image is ever loaded, until the whole page is reloaded. The current version of Chrome (45....) properly loads larger images.

While this is under- or un-specified in the relevant spec (https://html.spec.whatwg.org/multipage/embedded-content.html) the sensible approach is to load proper assets for the current viewport. Otherwise images will appear fuzzy or pixellated. On the desktop the switch can be dramatic (perhaps 400 to 1200+), but even on mobile a portrait/landscape rotation can almost double the required image size, and a split screen 320 pixel wide mobile safari can become a 1000+ pixel wide full screen browser.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20151007/a5939ccd/attachment-0001.html>


More information about the webkit-unassigned mailing list