diff options
Diffstat (limited to 'src/qcam/dng_writer.cpp')
-rw-r--r-- | src/qcam/dng_writer.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/qcam/dng_writer.cpp b/src/qcam/dng_writer.cpp index b4362537..6dd7d0f4 100644 --- a/src/qcam/dng_writer.cpp +++ b/src/qcam/dng_writer.cpp @@ -507,7 +507,10 @@ int DNGWriter::write(const char *filename, const Camera *camera, TIFFSetField(tif, TIFFTAG_PLANARCONFIG, PLANARCONFIG_CONTIG); TIFFSetField(tif, TIFFTAG_SAMPLEFORMAT, SAMPLEFORMAT_UINT); TIFFSetField(tif, TIFFTAG_CFAREPEATPATTERNDIM, cfaRepeatPatternDim); - TIFFSetField(tif, TIFFTAG_CFAPATTERN, info->pattern); + if (TIFFLIB_VERSION < 20201219) + TIFFSetField(tif, TIFFTAG_CFAPATTERN, info->pattern); + else + TIFFSetField(tif, TIFFTAG_CFAPATTERN, 4, info->pattern); TIFFSetField(tif, TIFFTAG_CFAPLANECOLOR, 3, cfaPlaneColor); TIFFSetField(tif, TIFFTAG_CFALAYOUT, 1); |