TIF merge program

Associate
Joined
25 Feb 2007
Posts
905
Location
Midlands
I am after a something that will read a list of TIF file locations from a CSV file and merge those with the same ID number in a column next to it, ending up with multipage TIF files.

For example:

File Path | ID
/path/to/tif/file1.tif | 0001
/path/to/tif/file2.tif | 0001
/path/to/tif/file3.tif | 0001
/path/to/tif/file4.tif | 0002
/path/to/tif/file5.tif | 0002
/path/to/tif/file6.tif | 0003

I want to end up with 3 multipage tif files - 0001.tif (3 files merged), 0002.tif (2 files merged), 0003.tif (1 file)

Quite specific I know.

Any ideas on how this could be done?

Cheers,
 
you would probably be best to write a console app to parse the file and plug into a tif making dll to create on singular Tif
 
Any ideas on where I would start? I've got a bit of programming experience but no idea on how to go about this one.

Cheers,
 
what language?


but basically
i would start by creating an entity based on the available fields in the CSV file

i would then create something that can read the csv (stream reader?) and for each line in the csv create a new entity
and add that to a List<entity>

then create a method which takes the List<entity> and fires through it grouping each item by id then

passes the group to a Tif file creator

well thats the basic idea
 
Last edited:
You can do this with a fairly simple batch file and a copy of Irfanview.

I think this is what you need...

Code:
for /F "tokens=1,2 delims=|" %i in (file.csv) do i_view32.exe %i /append=path\to\output\%j.tiff /killmesoftly

It's untested so you'll need to play about with it. Run it from the same directory as i_view32.exe.
 
Back
Top Bottom