Charles
Charles

Reputation: 11758

nodejs read image data

Is there any library to read image data of a jpeg ?

I would like to get the pixel of a jpeg.

I only find library like node-jpeg or gm but they don't provide images data.

Upvotes: 9

Views: 28911

Answers (3)

caffeinum
caffeinum

Reputation: 431

There are also exifr and exiftool-vendored

https://www.npmjs.com/package/exifr

https://www.npmjs.com/package/exiftool-vendored

Upvotes: 0

junming zheng
junming zheng

Reputation: 71

npm got a package that can extract pixel data in rgba, maybe it could help: https://www.npmjs.com/package/get-image-pixels

Upvotes: -1

gherkins
gherkins

Reputation: 14973

You could do this with the node-imagemagick module. (see Opening images on NodeJS and finding out width/height).

Also, if you prefer accessing the EXIF metadata, there is node-exif.

Upvotes: 10

Related Questions