Uploaded image for project: 'Imaging'
  1. Imaging
  2. MGNLIMG-281

WebP images/renditions broken on ARM/Apple M1

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • None
    • None
    • None
    • None

    Description

      Steps to reproduce

      1. Bring up Magnolia on a Mac with M1 CPU ( e.g. MacBook Air M1 )
      2. To your custom magnolia theme "mytheme", add WebP imaging variation 'my-rendition-webp' (see json below)
      3. Upload an image asset to Assets app ( -> /path/to/myImage.jpg )
      4. Try to show the image in your Browser <magnolia-server>/.imaging/mte/mytheme/my-rendition-webp/dam/path/to/myImage.jpg/jcr:content/myImage.jpg

      Expected results

      The "myImage" image shows delivered in expected 700*840 rendition in WebP format

      Actual results

      No image show but redirected to error page (Note: on a Notebook with x86_64 CPU everything works fine, image is delivered in WebP format)

      Workaround

      No workaround ( not using webp is not really an option, firing all developers with M1 Macs neighter )

      Development notes

      WebP imaging variation:

      imaging:
        variations:
          my-rendition-webp: !include:/ekzweb/theme-fragments/webp-variation.yaml
            class: info.magnolia.templating.imaging.variation.ImageOperationProvidingVariation
            imageOperation:
              class: info.magnolia.imaging.operations.ImageOperationChain
              outputFormat:
                quality: 80
                formatName: webp
              operations:
                load:
                  class: info.magnolia.imaging.operations.load.FromBinaryNode
                resize:
                  class: info.magnolia.imaging.operations.cropresize.AutoCropAndResize
                  crop: true
                  targetWidth: 700
                  targetHeight: 840

      Exception in info.magnolia.imaging.DefaultImageStreamer (Note that the exception does not end up in Magnolia Logs, something you probably want to fix as well):

      Pointers showing that WebP rendering does Native Java:

      https://github.com/nintha/webp-imageio-core/blob/master/src/main/java/com/luciad/imageio/webp/WebPEncoderOptions.java

      Checklists

        Acceptance criteria

        Attachments

          Activity

            People

              Unassigned Unassigned
              quatico Daniel Schneeberger
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:

                Checklists

                  Bug DoR
                  Task DoD