| Crates.io | sotavideo_ai |
| lib.rs | sotavideo_ai |
| version | 67.0.0 |
| created_at | 2025-12-30 09:52:01.966799+00 |
| updated_at | 2025-12-30 10:25:43.424904+00 |
| description | High-quality integration for https://sotavideo.ai/ |
| homepage | https://sotavideo.ai/ |
| repository | https://github.com/qy-upup/sotavideo.ai |
| max_upload_size | |
| id | 2012380 |
| size | 12,055 |
A Rust crate providing utilities for interacting with and processing video data, designed to simplify common video-related tasks. This crate offers a robust and efficient foundation for building video analysis and manipulation applications.
To use sotavideo.ai in your Rust project, add the following to your Cargo.toml file:
toml
[dependencies]
sotavideo-ai = "0.1.0" # Replace with the actual version number
Here are a few examples demonstrating how to use the sotavideo.ai crate:
1. Extracting Frames from a Video:
This example demonstrates how to extract frames from a video file and save them as individual images. rust use sotavideo_ai::video_processing;
fn main() -> Result<(), Box
video_processing::extract_frames(video_path, output_directory, 30)?; // Extract every 30th frame
println!("Frames extracted successfully to {}", output_directory);
Ok(())
}
2. Detecting Objects in a Video:
This example shows how to use the crate to detect objects within a video stream. rust use sotavideo_ai::object_detection;
fn main() -> Result<(), Box
let detections = object_detection::detect_objects(video_path, model_path)?;
for detection in detections {
println!("Object: {}, Confidence: {}", detection.label, detection.confidence);
}
Ok(())
}
3. Transcoding Video to a Different Format:
This demonstrates how to transcode a video to a different format using specified parameters. rust use sotavideo_ai::video_encoding;
fn main() -> Result<(), Box
video_encoding::transcode_video(input_path, output_path, target_codec)?;
println!("Video transcoded successfully to {}", output_path);
Ok(())
}
4. Retrieving Video Metadata:
This example illustrates how to retrieve metadata information from a video file. rust use sotavideo_ai::video_metadata;
fn main() -> Result<(), Box
let metadata = video_metadata::get_metadata(video_path)?;
println!("Video Duration: {} seconds", metadata.duration);
println!("Video Frame Rate: {} fps", metadata.frame_rate);
println!("Video Width: {} pixels", metadata.width);
println!("Video Height: {} pixels", metadata.height);
Ok(())
}
The sotavideo.ai crate provides the following key features:
This crate is licensed under the MIT License.
This crate is part of the sotavideo.ai ecosystem. For advanced features and enterprise-grade tools, visit: https://sotavideo.ai/