Announcement

Collapse
No announcement yet.

Irfanview hangs when trying to print an oversized PNG

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Confirmed Irfanview hangs when trying to print an oversized PNG

    I was trying to print a QR code that was 1600x2078 and when I click on the print dialog it hangs. I keeps trying to do something but the window is non responsive, after about 20 seconds it refresh itself and then hangs again. Basically when the picture is too large it just takes up a lot of CPU and hangs when using the Keep original size option.
    However I "somehow" manage to click on the Fit to page or custom size and reduce the size, then works fine.

    I've tried this on 5 different printers from laserjets to adobe and fax, same results, it isn't printer dependent but some bug with irfanview

    Steps to replicate
    1. Windows 10 64bit with Irfanview 64 bit (4.51)
    2. Use attached PNG file
    3. Print, select Original size
    4. Hang....

    Screenshot with settings and hang showing attached
    Attached Files

    #2
    Oh forgot to mention apart from CPU it keeps taking up tons of memory, after about a minute it had taken up 500MB of memory and still growing. Some kind of a memory leak happening here.

    Comment


      #3
      Originally posted by hunnypuppy View Post
      Oh forgot to mention apart from CPU it keeps taking up tons of memory, after about a minute it had taken up 500MB of memory and still growing. Some kind of a memory leak happening here.
      Okay it even hangs on the thumbnails page when trying to read this PNG file

      Comment


        #4
        The attached image is a JPG, not a PNG, and it is not 600 dpi. No image resolution is set. See the image information.

        Try setting it to 600 dpi, then print based on original size.
        Before you post ... Edit your profile • IrfanView 4.62 • Windows 10 Home 19045.2486

        Irfan PaintIrfan View HelpIrfanPaint HelpRiot.dllMore SkinsFastStone CaptureUploads

        Comment


          #5
          Originally posted by Bhikkhu Pesala View Post
          The attached image is a JPG, not a PNG, and it is not 600 dpi. No image resolution is set. See the image information.

          Try setting it to 600 dpi, then print based on original size.
          Huh, it was downloaded from https://www.qr-code-generator.com/ (with an active account) and it downloaded as a PNG. Are you saying the extension is incorrect and is that why it's causing an issue?

          Comment


            #6
            I tried to rename it to .JPG and open it with Irfanview and it said that the file extension was incorrect, it was actually a PNG and it asked me if I wanted to correct the extension.
            So it apparently is a PNG.

            Comment


              #7
              Okay I see what happened, when I tried to upload the file to this forum, it automatically converted it from PNG to JPG.
              So I've shared the original PNG file here which you can download and check:

              Comment


                #8
                The PNG image also has no DPI set. Change it to 600 dpi in the Image Information dialogue and its print size will change to just 3.2 x 2.2 cms. I had no problem uploading a PNG file without it converting to JPG.


                I also printed your original PNG image to a PDF driver without any freezing.
                Attached Files
                Last edited by Bhikkhu Pesala; 07.06.2018, 12:11 AM.
                Before you post ... Edit your profile • IrfanView 4.62 • Windows 10 Home 19045.2486

                Irfan PaintIrfan View HelpIrfanPaint HelpRiot.dllMore SkinsFastStone CaptureUploads

                Comment


                  #9
                  The PNG file is incorrectly generated. A user of QR Generator should file a bug. The specification says that the resolution unit shall be "meter". PNG is unique this way. This also leads to rounding of PNG resolution 599.99 occasionally...

                  The pHYs chunk in this file contains values 72, 72, and 0. Or pixel aspect ratio of 72:72 = 1:1.

                  I can confirm bad behavior from IrfanView 4.51, which should be improved. Technically it should treat this file as having no DPI, and assume a reasonable default. Instead it assumes that it has 72 pixels per meter or approximately 2 dpi. It then tries to upsample the image to printer's resolution, consuming large amount of memory.

                  An image is very unlikely to have 2 dpi. Maybe a sanity check should be done, and the default radio button switched to best fit, or a warning box presented if original is selected and dpi is very low.

                  Paint Shop Pro 7 and 9 treat this image as having no resolution (assume 72 dpi). FastStone Viewer assumes 300 dpi. Photoshop assumes 72 dpi.

                  Comment


                    #10
                    Originally posted by j7n View Post
                    I can confirm bad behavior from IrfanView 4.51, which should be improved.
                    I am reluctant to submit a bug-report to Irfan Skiljan as I suspect he will just say that people should fix their own bugs and produce valid PNG images.

                    Feel free to submit a report if you think this should be improved.
                    Before you post ... Edit your profile • IrfanView 4.62 • Windows 10 Home 19045.2486

                    Irfan PaintIrfan View HelpIrfanPaint HelpRiot.dllMore SkinsFastStone CaptureUploads

                    Comment


                      #11
                      Originally posted by Bhikkhu Pesala View Post
                      I am reluctant to submit a bug-report to Irfan Skiljan as I suspect he will just say that people should fix their own bugs and produce valid PNG images.

                      Feel free to submit a report if you think this should be improved.
                      In the real world (like this), nothing's perfect and the better applications can handle errors gracefully. Ifran view shouldn't "hang" because of bad metadata or a format, it should ignore it and move on.

                      Comment


                        #12
                        IrfanView should be more robust, and allow to press Cancel in a timely fashion and correct the error, without killing the program in Task Manager or checking Image Properties before every print. The GUI is unresponsive, just like in the batch converter, which is unfortunate. The preview and printing could possibly be optimized: when asked to fit 20 by 26 meter image onto an A4 page, the program could crop a portion of it, and only deal with that, and maybe warn so we don't waste a page full of ink.

                        I've asked Irfan about a problem a few times, and I feel like I shouldn't bother him too much with problems that haven't concerned me personally... Any reason why Irfan doesn't read this forum? I understand that he may not want to reply and be dragged into conversations that take time. But with all the password prompts, this forum is still much better than any modern social medium.

                        Comment


                          #13
                          I can only imagine how many emails Irfan Skiljan gets, and how many are bogus "bug reports" or impractical feature requests. Even on this little forum, we see our fair share. I am not surprised that he has no time to participate here.

                          With millions of users around the globe, and many of them not contributing financially or in any other way to IrfanView's development, I am amazed at how quickly he responds to my emails, often with a fix.

                          I can only point others to the Bug Report Sticky Thread and the Feature Request Sticky Thread.

                          I try to filter out the noise and forward what is likely to be acted upon. Even if an issue does not affect me personally, I will forward it if I think it will affect others.
                          Before you post ... Edit your profile • IrfanView 4.62 • Windows 10 Home 19045.2486

                          Irfan PaintIrfan View HelpIrfanPaint HelpRiot.dllMore SkinsFastStone CaptureUploads

                          Comment


                            #14
                            So you don't think that this is a genuine BUG?
                            You think it's acceptable for a program to hang and take 1GB of RAM?

                            Comment


                              #15
                              Originally posted by hunnypuppy View Post
                              So you don't think that this is a genuine BUG?
                              You think it's acceptable for a program to hang and take 1GB of RAM?
                              If I thought it was not a bug, I would have resolved the thread as No Bug

                              Please read the sticky thread as advised. Thread closed.
                              Before you post ... Edit your profile • IrfanView 4.62 • Windows 10 Home 19045.2486

                              Irfan PaintIrfan View HelpIrfanPaint HelpRiot.dllMore SkinsFastStone CaptureUploads

                              Comment

                              Working...
                              X