Page 1 of 2 1 2 LastLast
Results 1 to 10 of 15

Thread: Convert multiple TIFF files to a single multi-page file

  1. #1
    IV Newbie
    Join Date
    Jul 2007
    Posts
    7
    OS
    Win Vista Home Basic

    Cool Convert multiple TIFF files to a single multi-page file

    Is there a way to convert a whole folder of single-page TIFF files to one multi-page TIFF file from the command line?

    I'm trying to set-up a batch file to do this.

    Wildcards are not allowed in the "/multitif=" function

    Thanks for any help with this one.

  2. #2
    Moderator Bhikkhu Pesala's Avatar
    Join Date
    May 2007
    Location
    East London
    Posts
    4,265
    Version
    IrfanView 4.38
    OS
    64-bit Win 7 Home Basic
    CPU Cores
    1

    Default

    It is pretty straightforward to do from the GUI. Is there any special reason you want to use a command line?

  3. #3
    IV Newbie
    Join Date
    Jul 2007
    Posts
    7
    OS
    Win Vista Home Basic

    Default

    I'm trying to have this done automatically without having to open the program.

  4. #4
    IV Newbie
    Join Date
    Jul 2007
    Posts
    7
    OS
    Win Vista Home Basic

    Default

    How do I do it in the GUI?

  5. #5
    Moderator Bhikkhu Pesala's Avatar
    Join Date
    May 2007
    Location
    East London
    Posts
    4,265
    Version
    IrfanView 4.38
    OS
    64-bit Win 7 Home Basic
    CPU Cores
    1

    Default

    From the View menu, select Multipage images, create multipage tiff.

    Add images by browsing and selecting multiple images.

    Set compression if you want, and save the file.

  6. #6
    IV Newbie
    Join Date
    Jul 2007
    Posts
    7
    OS
    Win Vista Home Basic

    Default

    That's exactly what I want to do but I want to be able to do it without opening the program and clicking on everything.

    Is there no way to do the same function from the command prompt?

  7. #7
    Moderator Laurent's Avatar
    Join Date
    May 2007
    Location
    Brussels, Belgium
    Posts
    882
    Version
    IrfanView 4.25
    OS
    32-bit Win XP Pro SP3
    CPU Cores
    2

    Default

    Hi shoehn,

    Here is a copy/paste from IrfanView's help about command line:

    Example for /multitif:
    Syntax: /multitif=(tifname,file1,...,fileN)
    First file is the name of the result TIF file.
    i_view32.exe /multitif=(c:\test.tif,c:\test1.bmp,c:\dummy.jpg)
    Create multipage TIF ('c:\test.tif') from 2 other images.
    Does this help?

    Laurent

  8. #8
    IV Newbie
    Join Date
    Jul 2007
    Posts
    7
    OS
    Win Vista Home Basic

    Default

    I've looked at that but it doesn't allow wildcards so creating a single multi-page tiff of say 50 single-page tiff's in a folder would be difficult.
    Thanks for the input though... I'm still working on a solution.

  9. #9
    IV Newbie
    Join Date
    Jul 2007
    Posts
    7
    OS
    Win Vista Home Basic

    Thumbs up

    Okay, I figured a way to do it using the /append option in a batch file:

    for %%a in (*.*) do "c:\program files\irfanview\i_view32.exe" %%a /append=temp\final.tif /killmesoftly /silent

    Thanks for the help.

  10. #10
    IV Newbie
    Join Date
    Aug 2006
    Location
    Chapel Hill NC, USA
    Posts
    2

    Default

    shoehn,

    I had to combine hundreds of single page PCX files into multi-page files and had similar difficulties getting it to work from the cmdline as documented. Laurent's post of the instructions is correct:

    i_view32.exe /multitif=(c:\test.tif,c:\test1.bmp,c:\dummy.jpg)

    This syntax is correct, however it will fail if any of the file names in parentheses have quotations (which of course are required with filespecs contain spaces. That is, the above syntax will ONLY work if the filenames do not contain spaces (and therefore do not require quoting).

    I see this as a bug since, in general, quoting filenames is the normal method of dealing with filenames containing spaces from the cmdline.

    Note that you can (and must) quote the path to IV.exe if not submitting the cmdline from IV's directory (if it contains spaces), for example:

    "c:\Program Files\IrfanView\i_view32.exe /multitif=(c:\test.tif,c:\test1.bmp,c:\dummy.jpg)

    shoehn, your /append solution using a the DOS 'for' command works, but requires working knowledge of this command. I wrote myself a README file in the folder I typically use when setting up these conversions to remind me of this bug so I don't have to go through the frustration of figuring out why it doesn't work as expected when I need to do this again. My README is below (I will add your for ... /append method for future reference).

    Chris

    ----------------------
    README.txt re: /multitif
    ----------------------

    Syntax for combining single-page files into a multi-page TIFF:

    "EXEPATH" /tifc=4 /multitif=(OUTFILE,File1,File2,...FileN) /killmesoftly

    where
    EXEPATH = path to IrfanView
    OUTFILE = filespec of TIF file to create
    File1... = comma-separated list of source files to be combined

    NOTE: The /killmesoftly option terminates IrfanView after the conversion, otherwise it stays open. This option is NOT needed fot the /convert option, just the /multitif option.

    Notice there are NO QUOTES in the multitif part of the cmdline. This is VERY IMPORTANT when using /multitif=() to combine files, DO NOT USE QUOTES FOR ANY OF THE FILENAMES IN THE PARENTHESES (output file or input files). This is a bug in IrfanView, it will not work if there are quotes inside the parentheses. Therefore, if either the OUTFLIE or any input files have spaces in the pathspecs, when using the /multitif option, they MUST to be copied to a path without spaces OR IT WILL FAIL. Alternatively, you can change to the folder containing the input files before calling IrfanView (assuming the base filenames do not have spaces), in which case the filenames do not need folders/paths.

    Thus, if the source files are in "My Documents\Images", then:

    cd "c:\My documents\images"
    "EXEPATH" /tifc=4 /multitif=(NewTif.tif,Page1.pcx,Page2.pcx) /killmesoftly

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •