ICEpdf
  1. ICEpdf
  2. PDF-284

Image colors are inverted (white <-> black)

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 4.2
    • Fix Version/s: 4.3.4
    • Component/s: Core/Parsing
    • Labels:
      None
    • Environment:
      -

      Description

      The attached PDF displays white as black and black as white. The user mentions that the following exception is thrown but it looks to be EJB related:

      javax.ejb.EJBException: Unexpected Error
      java.lang.AbstractMethodError: org.icepdf.core.pobjects.fonts.nfont.NFontTrueType.toUnicode(C)C
      at org.icepdf.core.util.ContentParser.drawString(ContentParser.java:2180)

      1. 9952.pdf
        823 kB
        Tyler Johnson

        Issue Links

          Activity

          Tyler Johnson created issue -
          Tyler Johnson made changes -
          Field Original Value New Value
          Salesforce Case [5007000000G41bK]
          Tyler Johnson made changes -
          Attachment 9952.pdf [ 13004 ]
          Hide
          Patrick Corless added a comment -

          JFIF colour issue or indexed colour issue

          Show
          Patrick Corless added a comment - JFIF colour issue or indexed colour issue
          Patrick Corless made changes -
          Link This issue depends on PDF-270 [ PDF-270 ]
          Hide
          Patrick Corless added a comment -

          Looks like another JFIF colour issue or possibly an index colour issue, either way need a a closer look.

          As for the toUnicode error there might be a class path issue with an older version of ICEpdf. In ICEpdf 4.2 the toUnicode() method signature changed slightly which might be causing the error if there is a jar misalignment.

          Show
          Patrick Corless added a comment - Looks like another JFIF colour issue or possibly an index colour issue, either way need a a closer look. As for the toUnicode error there might be a class path issue with an older version of ICEpdf. In ICEpdf 4.2 the toUnicode() method signature changed slightly which might be causing the error if there is a jar misalignment.
          Patrick Corless made changes -
          Fix Version/s 4.3 [ 10266 ]
          Hide
          Patrick Corless added a comment -

          Pushing out to 5.0, still no hints as to what is going wrong with the decode.

          Show
          Patrick Corless added a comment - Pushing out to 5.0, still no hints as to what is going wrong with the decode.
          Patrick Corless made changes -
          Fix Version/s 5.0 [ 10314 ]
          Fix Version/s 4.3 [ 10266 ]
          Patrick Corless made changes -
          Fix Version/s 4.3.4 [ 10341 ]
          Fix Version/s 5.0 [ 10314 ]
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #30750 Fri Sep 07 15:58:05 MDT 2012 patrick.corless PDF-284 update jpg hanlding to avoid converting indexed colour models to gray which is causing an inverted colour issue.
          Files Changed
          Commit graph MODIFY /icepdf/trunk/icepdf/core/src/org/icepdf/core/pobjects/Stream.java
          Hide
          Patrick Corless added a comment -

          Interestingly enough this is a jpeg that has an indexed colour model that we are trying to convert to grey colour model. I'm pretty sure we can assume that index is grey and new need to do the extra work. I've updated the code accordingly and the image renders fine but I'll still have to run the change through QA as it is high risk.

          Show
          Patrick Corless added a comment - Interestingly enough this is a jpeg that has an indexed colour model that we are trying to convert to grey colour model. I'm pretty sure we can assume that index is grey and new need to do the extra work. I've updated the code accordingly and the image renders fine but I'll still have to run the change through QA as it is high risk.
          Patrick Corless made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #30775 Mon Sep 10 10:46:11 MDT 2012 patrick.corless PDF-284 update jpg hanlding to avoid converting indexed colour models to gray which is causing an inverted colour issue.
          Files Changed
          Commit graph MODIFY /icepdf/branches/icepdf-4.3.3/icepdf
          Commit graph MODIFY /icepdf/branches/icepdf-4.3.3/icepdf/core/src/org/icepdf/core/pobjects/Stream.java
          Patrick Corless made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

            People

            • Assignee:
              Patrick Corless
              Reporter:
              Tyler Johnson
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: