Blame toonz/sources/image/tzp/tiff_dir.c
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#include <stdio.h></stdio.h>
|
|
Toshihiro Shimizu |
890ddd |
#include <stdlib.h></stdlib.h>
|
|
Toshihiro Shimizu |
890ddd |
#include <string.h></string.h>
|
|
Toshihiro Shimizu |
890ddd |
#include <unistd.h></unistd.h>
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#define _TOONZ_PROTOTYPES_
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#include "toonz.h"
|
|
Toshihiro Shimizu |
890ddd |
#include "tiff.h"
|
|
Toshihiro Shimizu |
890ddd |
#include "tiffio.h"
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
void main(int argc, char *argv[])
|
|
Toshihiro Shimizu |
890ddd |
{
|
|
Toshihiro Shimizu |
890ddd |
TIFF *tfp = NIL;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
if (argc != 2) {
|
|
Toshihiro Shimizu |
890ddd |
printf("tiff_dir error: missing parameters\n");
|
|
Toshihiro Shimizu |
890ddd |
exit(0);
|
|
Toshihiro Shimizu |
890ddd |
}
|
|
Toshihiro Shimizu |
890ddd |
Tiff_ignore_missing_internal_colormap = 1;
|
|
Toshihiro Shimizu |
890ddd |
Silent_tiff_print_error = 1;
|
|
Toshihiro Shimizu |
890ddd |
tfp = TIFFOpen(argv[1], "r");
|
|
Toshihiro Shimizu |
890ddd |
if (!tfp) {
|
|
Toshihiro Shimizu |
890ddd |
printf("unable to open %s\n", argv[1]);
|
|
Toshihiro Shimizu |
890ddd |
exit(0);
|
|
Toshihiro Shimizu |
890ddd |
}
|
|
Toshihiro Shimizu |
890ddd |
TIFFPrintDirectory(tfp, stderr, TRUE);
|
|
Toshihiro Shimizu |
890ddd |
while (TIFFReadDirectory(tfp))
|
|
Toshihiro Shimizu |
890ddd |
TIFFPrintDirectory(tfp, stderr, TRUE);
|
|
Toshihiro Shimizu |
890ddd |
TIFFClose(tfp);
|
|
Toshihiro Shimizu |
890ddd |
}
|