cloudacy / native_exif

A simple EXIF metadata reader/writer for Flutter.
MIT License
16 stars 14 forks source link

Video compatibility #18

Closed brianp closed 1 year ago

brianp commented 1 year ago

Hey! I've been trying to use the exif reader with video but having no luck. I've tried with multiple mp4 files, and some mov files.

It works fine with images I've tested with. Is it for images only?

The error I get is:

[VERBOSE-2:dart_vm_initializer.cc(41)] Unhandled Exception: PlatformException(READ_ERROR, Error while reading metadata from source, null, null)
#0      StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:652:7)
#1      MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:310:18)
<asynchronous suspension>
#2      Exif.getAttributes (package:native_exif/native_exif.dart:54:20)
p-kuen commented 1 year ago

Good point, thanks for the issue. Currently, this package was only used and tested with images, especially JPEG images as they are the only known images with EXIF metadata. Videos use other metadata which have to be parsed differently.

We should add that to the package README.

brianp commented 1 year ago

Makes sense. Thanks for the confirmation. I was trying to get access to apples "created at" metadata. I don't know how they store it. But yeah a note in the readme that it's for images only would probably be good :D

Cheers!