Confused by an explanation of. Tiff file

Started by Skids, March 17, 2022, 12:57:07 PM

Previous topic - Next topic

Skids

Hi,

I am posting here in the hope of gaining a greater understanding of the Tiff file format.  An internet search led me to one explanation here : https://www.fileformat.info/format/tiff/egff.htm

the following copied from the website has confused me :

"Tags may be added and deleted from an IFD much the same way that notebook paper may be added to or removed from a three-ring binder."

The author makes the process seem simple but is it?  I have the impression that if I add a new tag to an IFD that is anywhere in the body of the tiff file then the file will grow by 12 bytes and that every pointer pointing to data after the IFD has to be located and modified to account for the extra 12 bytes, all data having been shunted along by 12 bytes.  Am I wrong as this does not seem as simple as adding a page into a three-ring binder although the following pages would have to be renumbered and any contents pages updated.

best wishes
Simon

greybeard

You wouldn't update the TIFF file in place and shunt tags around - you would create a new file and automatically recalculate the location of each field - the analogy doesn't really work - but it does make it simple.

Skids

Thanks. I wanted to confirm that I had not misunderstood how the tiff file format works and therefore by association how many RAW files are written.  I shall also go no further than reading data from the files.