如何将图像文件存储到 Dart 中的列表

How to Store Image File to List in Dart

如何将 ImageData 存储到 dart 中的列表??

所以我想将图像存储到我的列表,但我不知道要放什么类型的数据

我知道有不同的文件和文件图像吗?我想在我的 flutter 应用程序中使用它

  1. 您可以使用 File as your dataType and for the list of files you can use something like List 这个 List imageListInFile = []
  2. 您也可以使用 Uint8(但在您有字节图像的地方使用它)List imageListInBytes = []
  3. 您还可以使用 List,因为您可以存储从网络或设备获取的图像路径列表