Closed ZhouZhiMin1 closed 5 years ago
print("图片原始大小:${image.length()}"); print("图片输出路径:$outPath"); CompressObject object = CompressObject( imageFile: image, path: outPath, quality: 85, step: 9, mode: CompressMode.LARGE2SMALL ); String path = await Luban.compressImage(object);
我找到原因了 我的输出路径搞错了
[ERROR:flutter/lib/ui/ui_dart_state.cc(148)] Unhandled Exception: Exception: FileSystemException: Cannot open file, path = '/data/user/0/com.example.im_flutter/cache/Android.jpg/img_1571561019173.jpg' (OS Error: No such file or directory, errno = 2)