Announcement

Collapse
No announcement yet.

v4.23: Some GIF images are decoded improperly

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Pending v4.23: Some GIF images are decoded improperly

    During some research into the LZW compression scheme I discovered that IrfanView seems to decode some GIF images improperly. It seems to be related to the situation where the LZW dictionary gets filled, but is not immediately followed by a CLR code.

    I've included an example image. While Irfanview shows the image with several "cuts", all other programs I've tested (Firefox, Opera, The GIMP, Imagemagick, MSPaint) decode and show the image properly.

    Last edited by ymgve; 24.05.2009, 08:29 PM.

    #2
    I can confirm the problem.

    In IV 3.97 to lower sections of the image are just black.

    I have forwarded the image to Irfan with your report.
    Before you post ... Edit your profile • IrfanView 4.67 • Windows 10 Home 19045.2486

    Irfan PaintIrfan View HelpIrfanPaint HelpMore SkinsFastStone CaptureUploads

    Comment


      #3
      Confirmed with 4.23
      Lower sections not black, but there are shifts to the left in the Y-coordinate at e.g. X = 400 and at X = 604 and X = 638
      0.6180339887
      Rest In Peace, Sam!

      Comment


        #4
        I got a reply from Irfan:
        IrfanView has some very strict checks for overflow, not all compression bugs will be tolerated

        Now, the user knows, the GIF is saved as buggy and it should save it again, properly.

        => I can't make a promise to "fix" bugs from other people/programs, maybe later, it should be better to save it properly
        Do you know the source of this GIF image? If so, contact the author of the program and ask them to fix the bug.
        Before you post ... Edit your profile • IrfanView 4.67 • Windows 10 Home 19045.2486

        Irfan PaintIrfan View HelpIrfanPaint HelpMore SkinsFastStone CaptureUploads

        Comment


          #5
          The image is made with my self-created GIF optimizer. If there actually is something in the image that is out of spec, I would like to know exactly what it is.

          Comment


            #6
            my self-created GIF optimizer
            The better I think. So you don't depend on other people/programs, you can check for yourself.

            As said, it could be a bug in the addressing of the pixel-lines, or indeed in the saving procedure, as Irfan indicates.

            Report :
            1 - While the pictury is obviously B/W, the resolution is 4BPP instead of a possible 1BPP.
            2 - Distortions are taking place at the transition from one horizontal line to the lower next.
            3 - A snapshot of a region (IV 4.23) :



            If saving is concerned, it might be a prob of a wrong addressing of the video memory temp.
            Last edited by Sam_Zen; 27.05.2009, 12:46 AM. Reason: PS
            0.6180339887
            Rest In Peace, Sam!

            Comment


              #7
              Other picture viewers show it properly, so it's not so easy. Also, GIF is not line-oriented, it's a single compressed stream of pixels for each subimage, so it's not related to line changes.

              Comment

              Working...
              X