当前位置:网站首页>Mutual conversion of pictures in fluent uint8list format and pictures in file format
Mutual conversion of pictures in fluent uint8list format and pictures in file format
2022-07-01 10:48:00 【Dense breath】
file Format picture into Uint8List Format picture
Uint8List imageByte;
imageByte = await widget.image.readAsBytes();
// Get the callback Uint8List Format picture to File Format
SaveImage(Uint8List imageByte) async {
// Get the temporary directory
var tempDir = await getTemporaryDirectory();
// Generate file File format
var file =
await File('${
tempDir.path}/image_${
DateTime.now().millisecond}.jpg')
.create();
// Turn into file file
file.writeAsBytesSync(imageByte);
print("${file.path}");
setState(() {
path = file.path;
// turn(file);
_imageUint8=imageByte;
});
}
边栏推荐
- PHP realizes lottery function
- 数据库的增删改查问题
- Huawei HMS core joins hands with hypergraph to inject new momentum into 3D GIS
- 零基础入门测试该学什么?最全整理,照着学就对了
- Half of 2022 has passed, isn't it sudden?
- 大佬们 有没有搞过sink分流写入clickhouse 或者其他数据库的操作。
- 【论文阅读】Trajectory-guided Control Prediction for End-to-end Autonomous Driving: A Simple yet Strong Ba
- Prism journal navigation button usability exploration record
- [.net6] use ml.net+onnx pre training model to liven the classic "Huaqiang buys melons" in station B
- Is it safe to open a stock account online in 2022? Is there any danger?
猜你喜欢

【MPC】①二次规划问题MATLAB求解器quadprog

IDEA运行报错Command line is too long. Shorten command line for...

移动硬盘驱动器读到,但不显示盘符

What a high commission! The new programmer's partner plan is coming. Everyone can participate!

《百年巨匠》数字藏品中奖名单公布

leetcode:111. Minimum depth of binary tree

华为HMS Core携手超图为三维GIS注入新动能

新品大揭秘!雅迪冠能 3 多元产品矩阵,满足全球用户出行需求

数字藏品市场新局面

云上“视界” 创新无限 | 2022阿里云直播峰会正式上线
随机推荐
. Net 5.0+ does not need to rely on third-party native implementation of scheduled tasks
Huawei HMS core joins hands with hypergraph to inject new momentum into 3D GIS
问下群里的各位,有使用flink oracle cdc的logminer方案,在生产上稳定运行的实际
I'd like to know where I can open an account in Guangzhou? Is it safe to open an account online now?
网站源码整站下载 网站模板源代码下载
Zero foundation software testing must see, 10 years of testing old bird's conscience suggestions (a total of 15)
prism journal导航按钮的可用性探索记录
关于#SQL#的问题,如何解决?
北汽蓝谷:业绩承压,极狐难期
678. Valid bracket string
程序员都想去国企?技术落后薪资低,躺平几年出来都找不到工作...
华为HMS Core携手超图为三维GIS注入新动能
[.net6] use ml.net+onnx pre training model to liven the classic "Huaqiang buys melons" in station B
大佬们,数据湖iceberg的数据,怎样导出到mysql? 有什么工具? sqoop,datax都没
Submission lottery - light application server essay solicitation activity (may) award announcement
Suggest collecting | what to do when encountering slow SQL on opengauss?
leetcode:111. Minimum depth of binary tree
[paper reading] trajectory guided control prediction for end to end autonomous driving: a simple yet strong Ba
内存泄漏定位工具之 valgrind 使用
Handling distributed transactions with powerful dbpack (PHP tutorial)