[wp-trac] [WordPress Trac] #36477: Responsive images (srcset) can include images larger than the full size

WordPress Trac noreply at wordpress.org
Fri May 10 17:57:14 UTC 2024


#36477: Responsive images (srcset) can include images larger than the full size
-------------------------------------------------+-------------------------
 Reporter:  peterdavehello                       |       Owner:  pbearne
     Type:  defect (bug)                         |      Status:  assigned
 Priority:  normal                               |   Milestone:  Future
                                                 |  Release
Component:  Media                                |     Version:  4.4.2
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch needs-testing dev-         |     Focuses:
  feedback has-unit-tests                        |  performance
-------------------------------------------------+-------------------------

Comment (by nosilver4u):

 Since I don't own some of these, I can't attach them directly. I've got
 one provided by a customer for testing, several from related tickets here
 on trac, and a couple free/public domain images:
 https://ewwwio-downloads.b-cdn.net/png-tests/17-c3-duplicate-entries.png
 https://ewwwio-downloads.b-cdn.net/png-tests/cloudflare-status.png
 https://ewwwio-downloads.b-cdn.net/png-tests/deskcat8.png
 https://ewwwio-downloads.b-cdn.net/png-tests/Palette_icon.png
 https://ewwwio-downloads.b-cdn.net/png-tests/rabbit-time-paletted.png
 https://ewwwio-downloads.b-cdn.net/png-tests/test8.png

 Out of all of these, only Palette_icon.png seems to be "fixed" by your
 patch. I haven't done any debugging to find out why, but I suspect it
 might be similar to this "fix":
 https://stackoverflow.com/a/26434303/2882573
 When I tried that, I got no thumbs at all because Imagemagick was throwing
 an error very similar to this:
 https://github.com/ImageMagick/ImageMagick/discussions/3269
 The quantizeImage() idea "works" but on deskcat8.png it introduces (lots
 of) black pixels around the edges, similar to observations here:
 https://stackoverflow.com/questions/14031965/convert-32-bit-png-to-8-bit-
 png-with-imagemagick-by-preserving-semi-transparent/14032098#14032098

 Unfortunately, as pngquant is a command line binary, I'm pretty sure
 that's a non-starter for core WP.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/36477#comment:51>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list