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

outputting into jpg format fails if processed image is a gif or png

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 3.0
    • 3.0
    • image operations
    • None

    Description

      The method ImageUtil.flattenTransparentImageForOpaqueFormat(BufferedImage, OutputFormat) fails for the following cenario
      1) input is png and output jpg
      2) input is gif and output jpg

      the exceptions are not the same

      1) java.lang.ClassCastException: java.awt.image.ComponentColorModel cannot be cast to java.awt.image.DirectColorModel

      2) java.lang.ArrayIndexOutOfBoundsException: 1
      at java.awt.image.PixelInterleavedSampleModel.createSubsetSampleModel(PixelInterleavedSampleModel.java:142)
      at sun.awt.image.ByteInterleavedRaster.createWritableChild(ByteInterleavedRaster.java:1279)
      at info.magnolia.imaging.util.ImageUtil.flattenTransparentImageForOpaqueFormat(ImageUtil.java:3

      Checklists

        Acceptance criteria

        Attachments

          Issue Links

            Activity

              People

                gjoseph Magnolia International
                pbaerfuss Philipp Bärfuss
                Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  Checklists

                    Bug DoR
                    Task DoD