在 Flutter 中为图像编写元数据

BaD*_*aDo 7 metadata image flutter

我正在开发一个应用程序,允许用户将元数据从 UI 填充到图像中,例如:

  • 姓名
  • 地点
  • 创客笔记
  • ....

有没有办法在 Flutter 中做到这一点?

您可以通过http://metapicz.com/#landing使用任何图片 URL 进行检查

tri*_*le7 0

如果您只需要移动支持,有一个新的软件包可以为您做到这一点。

您将其添加为依赖项,然后...

final exif = await Exif.fromPath(file.path);
final attributes = await exif!.getAttributes();
attributes['UserComment'] = "This file was edited by FlutterApp!";
final result = await exif.writeAttributes(attributes);
Run Code Online (Sandbox Code Playgroud)