I correctly executed the result of this answer , but I get the following error:
ReferenceError: BinaryFile not defined
Here is the code where it is used:
fr.onloadend = function() { console.log(this); exif = EXIF.readFromBinaryFile(new BinaryFile(this.result)); }
console.log shows that there is data, I just do not understand this error that I get.
console.log
Thank you for your help.
I used the following which worked very well
EXIF.getData(img, function() { orientation = EXIF.getTag(this, "Orientation"); });
where img is my image object.
img
Also EXIF.pretty(this) was useful to see what data is in each image.
EXIF.pretty(this)
Removing the BinaryFile and changing the way the FileReader ( readAsArrayBuffer ) is readAsArrayBuffer for me.
BinaryFile
readAsArrayBuffer
fileReader.onload = function (event) { var exif = EXIF.readFromBinaryFile(this.result); console.log(exif); }; fileReader.readAsArrayBuffer(file);
Source: https://habr.com/ru/post/1236647/More articles:Swift: How can I get a listener that tells me when the connection is lost and when it will return? - iosWhat is dnu for? - .netGroovy: getClass method on map literal returns null - dictionaryThe effect of md-ink-ripples for a specific row in a table - angular-materialPHP behavior when interacting with Shell - linuxHow to set counter color on TextInputLayout? - androidIs this the right behavior? std :: map iterator invalidity - c ++Toolbar overlaps below status bar - androidSpring Oauth2 Client Credential Flow Example - javaHow can I use the d3 library (e.g. c3.js) on the server side to create diagrams in nodejs? - javascriptAll Articles