This valid JPEG2000 file does not decode in Safari 16 running on macOS Ventura 13.0.1, MacOS Monterey 12.6, or iOS 16.1.1. https://assets.meinauto.de/image/upload/f_jp2,w_3249/v1668594966/website/pics/landingpages/black-deals/red Note: - Changing the image slightly (resizing by one pixel) causes it to work: https://assets.meinauto.de/image/upload/f_jp2,w_3248/v1668594966/website/pics/landingpages/black-deals/red - This bug seems *very* related to FB9671920 / https://bugs.webkit.org/show_bug.cgi?id=219977 I have cross-filed this as FB11815925, and fully expect this WebKit bug to be closed as RESOLVED INVALID, because the bug is in the media handling layers in the OS. However previous experience has shown it is valuable to have a public URL to reference and share resources/workarounds when others run into this bug in Safari.
I should also note it seems extremely related to https://bugs.webkit.org/show_bug.cgi?id=219977 & FB9671920, which seems to have been recently fully fixed? Just as with that bug, the issue only seems to affect very "simple" images (for example, but not limited to: single-color images). I will update both this and the feedback as I find more examples of failing JP2s.
The JP2s seem to fail consistently when they are over a certain size. Setting the "width" parameter in this URL to anything over 3248 generates a failing image: https://assets.meinauto.de/image/upload/f_jp2,w_3250/v1668594966/website/pics/landingpages/black-deals/red Anything under 3248 succeeds: https://assets.meinauto.de/image/upload/f_jp2,w_325/v1668594966/website/pics/landingpages/black-deals/red Changing the color space to CMYK seems to change this boundary to 3260 https://assets.meinauto.de/image/upload/f_jp2,w_3260,cs_cmyk/website/pics/landingpages/black-deals/red (WORKS) https://assets.meinauto.de/image/upload/f_jp2,w_3261,cs_cmyk/website/pics/landingpages/black-deals/red (FAILS)
<rdar://problem/102617161>
> I have cross-filed this as FB11815925 rdar://102613994
Karl: not sure how this is BrowserCompat? failing to decode JPEG2000 arguably just makes us behave the same as everyone else (who don't support JPEG2000); I guess it could lead to site compat problems with usage of content negotiation or similar, as we'll get served a JPEG2000 image and then fail to render it.
Hmm Indeed. Sorry about that.