2005.04.06 12:19 "[Tiff] PB with TIFFWriteScanline, writing after data", by Samuel

2005.04.06 12:19 "[Tiff] PB with TIFFWriteScanline, writing after data", by Samuel

Hi!

I've made a function called createEmptyFile(TIFF* file, uint32 width, uint32 height) wich create an empty file opened with TIFFOpen(".","r").

This function set different TAGS like:

TIFFTAG_IMAGEWIDTH
TIFFTAG_IMAGELENGTH
TIFFTAG_SAMPLESPERPIXEL
TIFFTAG_BITSPERSAMPLE
TIFFTAG_PLANARCONFIG
TIFFTAG_PHOTOMETRIC
TIFFTAG_ROWSPERSTRIP

Then with a FOR loop, it fills the raster data with 0xFF and thanks to the TIFFWriteScanline function.

This work perfectly!

But then when a want to alter one row by calling TIFFWriteScanline again, raster data are written after the existing raster data and before the ending directory (the different tags). So it doesn't overwrite the row I want to!

Is it normal?

Thank you very much if you can help me!

And sorry my English is not so good..

sam