Announcement

Collapse
No announcement yet.

batch DPI changing (e.g. fit all images to A4 or 20x30 cm)

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

    Requested batch DPI changing (e.g. fit all images to A4 or 20x30 cm)

    feature request: DPI changing in batch mode

    current implementation: currently it is only possible to set the DPI to the same value for all images in the batch job

    field of application: e.g. fitting all images to a given size (A4, 20x30cm, etc.), for instance prior to converting them into a multi-page .pdf document, etc.

    suggested solution: in file > batch conversion/rename > advanced > resize:
    1) remove the technically/terminologically erroneous* checkbox use resample function (better quality)
    2) add checkbox resample image. When deselected, the radio button pixels must be grayed out.
    3) add drop-down list box next to or below checkbox 2), enumerating the filters from the image > resize/resample dialogue box (Lanczos, etc.) and being grayed out when checkbox 2) is deselected.
    4) The set DPI value text field to value "variable", but still permit user input

    ((As an alternative solution, checkbox 2) can be named don't resample image (change DPI only), while drop-down list 3) and the radio button pixels would be grayed out accordingly, i.e. when checkbox 2) is selected.))

    If the user changes the DPI field "variable" to a specified number, then width and height should either be grayed out or changed to "variable".

    To simplify the GUI, I would also suggest the whole section set new size as percentage of original and add a single radio button percentage instead.


    All in all this would result in the following dialogue box (changes were only made to the bottom half of the 1st out of the 3 columns):



    Note that the abovementioned changes are based on IrfanView 4.20.

    * the "use resample function (better quality)" checkbox is technically erroneous, since a change in an image's pixel dimensions ALWAYS involves resampling. The distinction IrfanView draws between resizing and resampling throughout the whole program interface is simply wrong. What Irfanview refers to as "resizing" is in reality ALSO "image resampling", in particular using the "nearest neighbour" resampling algorithm (or the "bilinear" resampling algorithm).

    The correct terminological use of resizing vs. resampling is explained here:


    Attached Files
    Last edited by boarder's paradise; 16.10.2010, 08:54 PM.

    #2
    Just for info.

    The ImPDF multipage settings allow to stretch the images to your preferred format.
    So there is not really a need to convert images in this case.

    If you need more than the standard formats:
    There is also an ini variable in the ImPDF section called "DocAddFormats"
    DocAddFormats={<name>'['<width>'x'<height>']'}
    width and height must be in tenth of millimeters

    Comment


      #3
      * ImPDF is a plugin. Resampling / DPI changing is such a basic function that it should of course be available in the main program.
      My proposed changes concern the batch processing dialogue.
      * note that pdf conversion was just ONE example for in-the-field-use for "fitting all images to a given size" which ITSELF is just ONE example for in-the-field-use of batch conversions. There are lots of others.
      * your term "stretch" is quite vague (define please!), and I don't think it accounts for all suggestions made in my OP

      thanks for the info though!
      Last edited by boarder's paradise; 16.10.2010, 08:58 PM.

      Comment


        #4
        That's why I said JFI. But everything about PDFs sets a trigger to ImPDF ;-)

        Stretch in ImPDF means that you are not touching the original image data.
        You just tell the PDF viewer application to scale the image on the page.
        If you preselect a format like A4 you can decide if the image should keep its original size, or if it should fill the whole page (respecting aspect ratio or not). Additionally you can add borders.

        Comment


          #5
          okay, many thanks for your info. That sounds really promising, I'll look into this plugin very soon. Are you the author?
          In case you used "stretching" in the plugin GUI, be advised that it's not a correct term in this case, as "stretching" is commonly accepted as meaning "resizing (particularly enlarging) an image disregarding the original aspect ratio". The term "scaling" which you also used, is much better (and IMO perfect) as it implies that no resampling occurs and it does not say anything about whether or not the aspect ratio is preserved.

          (Just for the record: the plugin functionality does not render the requested feature obsolete in any way IMO.)
          But it is surely much appreciated!!

          Comment


            #6
            DPI target values via Batch conversion

            Hi boarder's paradise and impdf,

            In my opinion: Good idea from boarder's paradise and until now a good discussion!

            But I think, it's difficult to handle DPI target values via Batch conversion, because a final printing size must be valid for all selected pictures and you need a certain number of pixels to realize a certain value of DPI! And if you have a lot of different pictures (from very lower to very high picture resolution and/or number of pixels) then it is not very realistic to guarantee a certain DPI value! Then it will give always some exceptions under certain conditions! And it could be only possible with a format like the pdf format, where the final printing size can be already specified! That are the problems!

            But maybe with options like "Output format = PDF format" and "Don't use smaller images" it could be possible!


            regards
            Frank
            Last edited by Frank; 16.10.2010, 08:45 PM.

            Comment


              #7
              Originally posted by Frank
              Good idea [...]

              But I think, it's difficult to handle DPI target values via Batch conversion, because you need a certain number of pixels [...] it is not very realistic to guarantee a certain DPI value!
              Thank you for the flowers, Frank.

              As far as the feasibility is concerned, there is no problem whatsoever. You can set ANY dpi value for ANY picture you like! This is especially obvious if the image is not resampled (i.e. keeping the current resolution), but also if resampling is involved.

              Not only isn't there any technical difficulty, it's even easy to implement in the GUI (see suggested screenshot above).

              If you can think of technical issues, it would be best if you could come up with a concrete example (at least a single one), with concrete numbers, where you think a DPI change would be problematic.

              But I doubt you can find such an example, as it is standard procedure in almost any professional imaging software, including Photoshop (since the very beginning).

              (PS: The only issue I can think of is that x/y resolution in pixels has to be an integer value, so rounding is obviously involved, but that's rather a non-issue, no?)

              Originally posted by Frank
              "Don't use smaller images"
              something like "Don't enlarge smaller images" as can be seen in the screenshot above?

              Comment


                #8
                concrete example:

                you want:
                • a final printing size = DIN A4 (21,0 x 29,7 cm)
                • a printing resolution = 300 DPI


                you have (for instance) ten different source images:
                • picture number 1 = 40 x 30 pixel
                • picture number 2 = 100 x 75 pixel
                • picture number 3 = 200 x 150 pixel
                • picture number 4 = 300 x 225 pixel
                • picture number 5 = 400 x 300 pixel
                • picture number 6 = 1000 x 750 pixel
                • picture number 7 = 2000 x 1500 pixel
                • picture number 8 = 3000 x 2250 pixel
                • picture number 9 = 4000 x 3000 pixel
                • picture number 10 = 5000 x 3750 pixel


                then you can guarantee following DPI values for printing size = DIN A4:
                • picture number 1 = 40 x 30 pixel = 3 DPI
                • picture number 2 = 100 x 75 pixel = 9 DPI
                • picture number 3 = 200 x 150 pixel = 17 DPI
                • picture number 4 = 300 x 225 pixel = 26 DPI
                • picture number 5 = 400 x 300 pixel = 34 DPI
                • picture number 6 = 1000 x 750 pixel = 86 DPI
                • picture number 7 = 2000 x 1500 pixel = 171 DPI
                • picture number 8 = 3000 x 2250 pixel = 257 DPI
                • picture number 9 = 4000 x 3000 pixel = 342 DPI
                • picture number 10 = 5000 x 3750 pixel = 428 DPI


                That means: Only for two of these ten pictures you can guarantee a value at least = 300 DPI!

                Comment

                Working...
                X