Giter Club home page Giter Club logo

Comments (4)

lovell avatar lovell commented on August 18, 2024 3

This PNG image appears to store its EXIF data in the relatively new eXIf PNG chunk rather than the historic iTXt chunk.

http://www.simplesystems.org/png-group/proposals/eXIf/history/png-proposed-eXIf-chunk-2017-06-08a.html

The eXIf chunk doesn't include the Exif\0 prefix whereas the iTXt chunk does.

(libpng v1.6.32+ supports the eXIf chunk. sharp recently started providing libspng to parse PNG images, which also supports it.)

Are you able to create a PR that updates the following logic to skip ahead 5 bytes when the Exif\0 prefix is found rather than throw when it's not? The image attached to this issue would make a great test case too.

exif-reader/index.js

Lines 4 to 5 in 2b040eb

if (buffer.toString('ascii', 0, 5) !== 'Exif\0')
throw new Error('Invalid EXIF data: buffer should start with "Exif".');

from exif-reader.

lovell avatar lovell commented on August 18, 2024 2

v1.1.0 now available with support for this - please see #21

from exif-reader.

rijkvanzanten avatar rijkvanzanten commented on August 18, 2024

Screenshots taken on a mac seem to "trigger" sharp to think there's exif data, but subsequently fail in exif-reader

Screenshot.2021-01-12.at.19.32.29.zip

from exif-reader.

kapouer avatar kapouer commented on August 18, 2024

Hi, I came across this
sanity-io@6ee2ee2
which is precisely what is asked ?

from exif-reader.

Related Issues (13)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.