Function photon_rs::native::save_image
source · pub fn save_image(img: PhotonImage, img_path: &str) -> Result<(), Error>
Expand description
Save the image to the filesystem at a given path.
Arguments
- img: The PhotonImage you wish to save.
img_path
- Path for the outputted image.
Example
use photon_rs::native::{open_image, save_image};
let img = open_image("img.jpg").expect("File should open");
// Save the image at the given path.
save_image(img,"manipulated_image.jpg").expect("Save failed");