diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2014-09-01 13:56:46 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2014-09-01 13:56:46 +0200 |
commit | 22f703cab05b7cd368f4de9e03991b7664dc5022 (patch) | |
tree | 6f4d50beaa42328e24b1c6b56b6ec059e4ef21a5 /tiff/contrib/tags/listtif.c |
Initial import of argyll version 1.5.1-8debian/1.5.1-8
Diffstat (limited to 'tiff/contrib/tags/listtif.c')
-rw-r--r-- | tiff/contrib/tags/listtif.c | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/tiff/contrib/tags/listtif.c b/tiff/contrib/tags/listtif.c new file mode 100644 index 0000000..605de84 --- /dev/null +++ b/tiff/contrib/tags/listtif.c @@ -0,0 +1,39 @@ +/* + * listtif.c -- lists a tiff file. + */ + +#include "xtiffio.h" +#include <stdlib.h> + +void main(int argc,char *argv[]) +{ + char *fname="newtif.tif"; + int flags; + + TIFF *tif=(TIFF*)0; /* TIFF-level descriptor */ + + if (argc>1) fname=argv[1]; + + tif=XTIFFOpen(fname,"r"); + if (!tif) goto failure; + + /* We want the double array listed */ + flags = TIFFPRINT_MYMULTIDOUBLES; + + TIFFPrintDirectory(tif,stdout,flags); + XTIFFClose(tif); + exit (0); + +failure: + printf("failure in listtif\n"); + if (tif) XTIFFClose(tif); + exit (-1); +} + +/* + * Local Variables: + * mode: c + * c-basic-offset: 8 + * fill-column: 78 + * End: + */ |