My flutter app uses the camera
package to take a photo, which I save to the application's data directory (obtained from path_provider
and the getApplicationDocumentsDirectory()
function).
How can I save this image file into the phone photo gallery? I've noticed the image_picker
package allows reading from the gallery, but how can I write to it?
Control-click the illustration that you want to save as a separate image file, and then click Save as Picture.
Gallery Saver for FlutterSaves images and videos from network or temporary file to external storage. Both images and videos will be visible in Android Gallery and iOS Photos. NOTE: If you want to save network image or video link, it has to contain 'http/https' prefix.
https://pub.dev/packages/gallery_saver
this plugin saves images and video to gallery/photos.
You just need to provide it with path to temp file that you got from Camera(or even network url, it also works):
GallerySaver.saveVideo(recordedVideo.path);
GallerySaver.saveImage(recordedImage.path);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With