Expand description
§exiftool
A Rust reimplementation of ExifTool for reading, writing, and editing metadata in image, audio, video, and document files.
§Quick Start
use exiftool_rs::ExifTool;
let et = ExifTool::new();
let tags = et.extract_info("photo.jpg").unwrap();
for tag in &tags {
println!("{}: {}", tag.name, tag.print_value);
}§One-liner
let info = exiftool_rs::image_info("photo.jpg").unwrap();
println!("Camera: {}", info.get("Model").unwrap_or(&String::new()));§Writing Tags
use exiftool_rs::ExifTool;
let mut et = ExifTool::new();
et.set_new_value("Artist", Some("John Doe"));
et.write_info("photo.jpg", "photo_out.jpg").unwrap();§Supported Formats (30+ readers, 15 writers)
Images: JPEG, TIFF, PNG, WebP, PSD, BMP, GIF, HEIF/AVIF, ICO Raw: CR2, NEF, DNG, ARW, ORF, RAF, RW2, PEF, SR2, X3F, 3FR, ERF Video: MP4/MOV, AVI, MKV Audio: MP3, FLAC, WAV, OGG Documents: PDF
Re-exports§
pub use crate::error::Error;pub use crate::error::Result;pub use crate::exiftool::ExifTool;pub use crate::exiftool::ImageInfo;pub use crate::exiftool::Options;pub use crate::file_type::FileType;pub use crate::tag::Tag;pub use crate::tag::TagGroup;pub use crate::tag::TagId;pub use crate::value::Value;
Modules§
- composite
- Composite (derived/calculated) tags.
- config
- ExifTool configuration file parser (.ExifTool_config).
- error
- exiftool
- Core ExifTool struct and public API.
- file_
type - formats
- geolocation
- Geolocation reverse geocoding using ExifTool’s Geolocation.dat.
- md5
- Minimal MD5 implementation (RFC 1321) for CurrentIPTCDigest.
- metadata
- tag
- tags
- value
- writer
Constants§
- VERSION
- Library version.
Functions§
- get_
file_ type - Detect the file type of the given file.
- image_
info - Convenience function: extract metadata from a file in one call.