Re: CFD: eXIf 2017-06-09a
Glenn Randers-Pehrson <[email protected]> Fri, 9 Jun 2017 08:40:36 -0400
| Newsgroups | gmane.comp.graphics.png.general |
|---|---|
| Message-ID | <CA+PdXcsOvjcGOZ1o+AqKFyXhHo_+ySCYZkAVJu-ZxVQz7OyTLw@mail.gmail.com> |
On Fri, Jun 9, 2017 at 8:27 AM, Phil Harvey <phil-CIeU6mJ2MbMd166Dz3SrqbDks+cytr/[email protected]> wrote: > This version mentions 2^16-2 as the maximum size that will fit in > a JPEG APP1 segment. The exact number is 2^16-9 as I mentioned > previously. This version says (correctly, I believe): While the PNG specification allows the chunk size to be as large as 2^31-1 bytes, decoders should be aware that, if the Exif profile is written to a JPEG datastream, the total length of the Exif data (the sum of the lengths of the Exif attributes IFD, the GPS IFD, the thumbnail IFD, and the TIFF header) may need to be adjusted to not exceed 2^16-2 bytes, so it can fit into a JPEG APP1 marker. That works out to be 2^16-9 when you take 2^16-1 and subtract 2-byte length and 6-byte "Exif\0\0". I guess we could still debate about the word "decoders". Maybe "application authors" would be better. The restriction is really on JPEG encoders, and we're just mentioning it as something for authors to think about. Glenn ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot