Page 1 of 1
How to "edit" Multipage Tiff's?
Posted: Thu Sep 25, 2014 10:39 am
by Co1m
Hello
i have a colored Multipage Tiff and i want to greyscale the Multipage Tiff and do some optimazations. Im trying commands like this:
Code: Select all
nconvert.exe -multi -ctype grey -dpi 100 -autocontrast C:\D3\TEMP\TEST1\Original_16MB.tif
But the only thing i get is the first Page of my Multipage Tiff. How to use the commands that alle "Settings" are done for all sites of the Multipage Tiff?
regards
Co1m
Re: How to "edit" Multipage Tiff's?
Posted: Thu Sep 25, 2014 11:59 am
by cday
Co1m wrote:i have a colored Multipage Tiff and i want to greyscale the Multipage Tiff and do some optimazations...
From memory, I think the only way to do that is to first extract the images from the multi-page TIFF to a folder, then perform the operations you wish to perform on the images in the folder, and then create a new multi-page TIFF...
That would require three command lines performed successively, but you could put them all in a .bat batch file.
Re: How to "edit" Multipage Tiff's?
Posted: Thu Sep 25, 2014 12:14 pm
by Co1m
Hi
i found a solution by brute forcing
Code: Select all
nconvert.exe -o result.tif -out tiff -multi -autocontrast -grey 16 -c 4 C:\D3\TEMP\TEST1\Original_16MB.tif
With this command you can edit all pages within the tiff.
regards
Co1m
Re: How to "edit" Multipage Tiff's?
Posted: Thu Sep 25, 2014 12:25 pm
by cday
Co1m wrote:Hi
i found a solution by brute forcing
Code: Select all
nconvert.exe -o result.tif -out tiff -multi -autocontrast -grey 16 -c 4 C:\D3\TEMP\TEST1\Original_16MB.tif
With this command you can edit all pages within the tiff.
Thanks for posting that, I'll have a look at it in case I've missed something myself

Re: How to "edit" Multipage Tiff's?
Posted: Thu Sep 25, 2014 1:36 pm
by Co1m
Hi Again
i found out, that this solution doesn't work in all cases. I have a folder with x Multipage Tiffs. I want that they become "greyscale" and small. But i want still x Multipage tiffs, not just one.
This command edits and resizes all MultiPage-Tiff-Files into ONE big Multipage Tiff-File:
Code: Select all
nconvert.exe -o % -out tiff -multi -autocontrast -grey 16 -resize 40% 40% -c 2 C:\D3\TEMP\TEST1\*.tif
If there is just one File everything is fine. BUT, i have more than one file. Any idea how to implement this?
regards
Co1m
Re: How to "edit" Multipage Tiff's?
Posted: Thu Sep 25, 2014 2:33 pm
by cday
Co1m wrote:I have a folder with x Multipage Tiffs. I want that they become "greyscale" and small. But i want still x Multipage tiffs, not just one.
I think -- and I was wrong last time from memory -- you probably need to use a 'DOS' FOR loop in a batch file...
Re: How to "edit" Multipage Tiff's?
Posted: Thu Sep 25, 2014 3:37 pm
by Co1m
Hi
right, same conclusion here. Here is what i did:
1. create a Batch-File with this content:
Code: Select all
SET INPUT_PATH=C:\Users\kga\Desktop\SCANNER-INPUT
SET PATTERN=*.tif
SET COMMAND=cmd /c C:\D3\xnView\nconvert.exe -quiet -o C:\Users\kga\Desktop\IRFAN-OUTPUT\%% -out tiff -multi -autocontrast -grey 16 -resize 50%% 50%% -c 2
forfiles /p "%INPUT_PATH%" /m %PATTERN% /c "%COMMAND% @file"
move C:\Users\kga\Desktop\IRFAN-OUTPUT\* V:\
del /f/s/q C:\Users\kga\Desktop\SCANNER-INPUT\*
The last two lines arent necessary. I'm just moving the output to another folder and deleting the files from the input folder. I know there is the option
-D but there is a Bug with it. If you use -D NConvert deletes the original-Multipage-Tif-File after processing the first Page.
This batch-file takes all TIF-files from the input directory and process them one after another (for-loop for every tiff file) and output it to the output directory. After this he takes the hole bunch of files and moves the files to a new directory.
regards
Co1m
Re: How to "edit" Multipage Tiff's?
Posted: Thu Sep 25, 2014 7:24 pm
by cday
Thanks for posting your solution: forfiles looks an interesting option for running NConvert repetitively on a series of files when that is necessary, and looks to have simpler syntax than the 'DOS' FOR loop.
Re: How to "edit" Multipage Tiff's?
Posted: Wed Apr 22, 2015 11:46 am
by se.semagin
Hello. I'm trying to change compression in multipage TIFF-file. Now it is LZW, but I want JPG.
Code: Select all
nconvert.exe -multi -c 8 -out tiff -o "out.tiff" "in.tiff"
After conversion the TIFF-file is WITHOUT jpeg compression. Works only for -c (1-4). Any idea?
Re: How to "edit" Multipage Tiff's?
Posted: Wed Apr 22, 2015 12:00 pm
by cday
Are the TIFF images 24/32 bit, not 1-bit (black and white) or 8-bit (grayscale)?
Re: How to "edit" Multipage Tiff's?
Posted: Wed Apr 22, 2015 12:11 pm
by se.semagin
Are the TIFF images 24/32 bit, not 1-bit (black and white) or 8-bit (grayscale)?
8-bit
Re: How to "edit" Multipage Tiff's?
Posted: Wed Apr 22, 2015 12:19 pm
by cday
se.semagin wrote:Are the TIFF images 24/32 bit, not 1-bit (black and white) or 8-bit (grayscale)?
8-bit
Although the JPG format supports 8-bit images, JPG compression for TIFF files is only supported in NConvert for 24/32 bit depths, as stated in the Help file.
You could possibly convert your TIFF files to 24-bit depth images and then save them with JPEG compression, adding a
-q term to set the compression level...
Re: How to "edit" Multipage Tiff's?
Posted: Fri Apr 24, 2015 5:41 am
by se.semagin
Although the JPG format supports 8-bit images, JPG compression for TIFF files is only supported in NConvert for 24/32 bit depths, as stated in the Help file.
You could possibly convert your TIFF files to 24-bit depth images and then save them with JPEG compression, adding a -q term to set the compression level..
Thank you for help.
I've tried to convert my TIFF to 32-bit depth using
, as I can't find NConvert parameter to convert to 24 bit. Then I've tried to compress 32-bit TIFF with
- but no compression was added.
Got no idea what is wrong

JPEG compression is supported in NConvert for 24/
32 bit depths in the TIFF files , as stated in the Help file.

Re: How to "edit" Multipage Tiff's?
Posted: Fri Apr 24, 2015 6:35 am
by cday
You have a multi-page TIFF file containing grayscale images that you wish to compress using JPG compression, so you need to convert to 24 or 32-bit colour depth...
se.semagin wrote:I can't find NConvert parameter to convert to 24 bit.
You could try:
I'm not an expert on NConvert but no-one else replies ...

Re: How to "edit" Multipage Tiff's?
Posted: Fri Apr 24, 2015 6:50 am
by se.semagin
With -truecolors work well. Thank you!