• Laser@feddit.org
    link
    fedilink
    arrow-up
    52
    arrow-down
    1
    ·
    23 hours ago

    How would a new format be backwards-compatible? At least JPEG-XL can losslessly compress standard jpg for a bit of space savings, and servers can choose to deliver the decompressed jpg to clients that don’t support JPEG-XL.

    Also from Wikipedia:

    Computationally efficient encoding and decoding without requiring specialized hardware: JPEG XL is about as fast to encode and decode as old JPEG using libjpeg-turbo

    Being a JPEG superset, JXL provides efficient lossless recompression options for images in the traditional/legacy JPEG format that can represent JPEG data in a more space-efficient way (~20% size reduction due to the better entropy coder) and can easily be reversed, e.g. on the fly. Wrapped inside a JPEG XL file/stream, it can be combined with additional elements, e.g. an alpha channel.

    • reddig33@lemmy.world
      link
      fedilink
      English
      arrow-up
      6
      arrow-down
      31
      ·
      23 hours ago

      All you have to do is add a small traditional JPEG image at the start of the file. It doesn’t have to be high resolution or more than a couple of kb. The new format decoder would know this, and skip the traditional jpeg “header”, rendering the newer file format embedded in the image.

      • wischi@programming.dev
        link
        fedilink
        arrow-up
        46
        arrow-down
        2
        ·
        23 hours ago

        Would completely defeat the purpose of making a new smaller file format if we prefix if with the old format.

        • reddig33@lemmy.world
          link
          fedilink
          English
          arrow-up
          4
          arrow-down
          19
          ·
          22 hours ago

          If you’re really saving 20% in file size with XL, adding back a very compressed preview image that takes up one or two percent isn’t going to cost you much.