Skip to main content

Crate oximedia_cv

Crate oximedia_cv 

Source
Expand description

Computer vision module for OxiMedia.

oximedia-cv provides computer vision algorithms and image processing capabilities for the OxiMedia multimedia framework. This includes:

  • Image processing: Resize, color conversion, filtering, edge detection
  • Detection: Face detection, motion detection, object detection, corner detection
  • Transforms: Affine and perspective transformations
  • Enhancement: Super-resolution and denoising using AI models
  • Machine Learning: ONNX Runtime integration for ML model inference
  • Tracking: Optical flow, feature tracking, object tracking
  • Stabilization: Video stabilization with motion smoothing
  • Scene detection: Video scene changes and shot boundary detection
  • Quality: Video quality assessment metrics (PSNR, SSIM, VMAF)
  • Interpolation: Frame interpolation using optical flow for frame rate conversion
  • Chroma key: Green screen and blue screen processing with spill suppression
  • Content-aware scaling: Seam carving and intelligent resizing
  • Interlace detection: Interlacing and telecine detection with IVTC recommendations
  • Motion blur: Motion blur synthesis and removal with deconvolution algorithms
  • Fingerprinting: Perceptual content fingerprinting for video and audio

§Modules

  • image: Image processing operations (resize, filter, histogram, etc.)
  • detect: Detection algorithms (face, motion, object, corner)
  • transform: Geometric transformations (affine, perspective)
  • enhance: Image enhancement (super-resolution, denoising)
  • ml: Machine learning and ONNX Runtime integration
  • tracking: Video tracking and optical flow (incl. enhanced SORT with tracking::SortTrackerV2 / tracking::LkTracker)
  • stabilize: Video stabilization with motion smoothing
  • scene: Video scene detection and shot boundary detection
  • quality: Video quality metrics (PSNR, SSIM, VMAF, temporal)
  • interpolate: Frame interpolation using optical flow for smooth motion
  • chroma_key: Chroma keying (green screen) with spill suppression and compositing
  • scale: Content-aware scaling using seam carving and saliency detection
  • interlace: Interlacing and telecine detection for video content analysis
  • motion_blur: Motion blur synthesis and removal with deconvolution
  • fingerprint: Perceptual fingerprinting for content identification and matching

§Example

use oximedia_cv::image::{ResizeMethod, ColorSpace};
use oximedia_cv::detect::BoundingBox;
use oximedia_cv::transform::AffineTransform;

// Example usage
let bbox = BoundingBox::new(10.0, 20.0, 100.0, 150.0);
assert!(bbox.area() > 0.0);

Re-exports§

pub use error::CvError;
pub use error::CvResult;

Modules§

action_recognition
Action recognition using temporal feature analysis.
background_subtraction
Background subtraction via a per-pixel Mixture-of-Gaussians (MOG2-inspired) model.
blob_detector
Blob detection via connected-component labeling and morphological filtering.
bounding_box
Axis-aligned bounding-box utilities for computer-vision pipelines.
chroma_key
Chroma key (green screen) processing module.
color_cluster
Color clustering via K-Means for dominant color extraction.
contour
Contour finding and analysis for binary/edge images.
deep_sort
DeepSORT multi-object tracker combining Kalman filter motion prediction with deep appearance feature embeddings for robust re-identification.
depth_estimation
Stereo depth estimation from disparity maps.
detect
Detection algorithms.
enhance
Image enhancement module.
error
Error types for computer vision operations.
feature_extract
Feature extraction: SIFT-like keypoints, ORB-like descriptors, and BRIEF.
feature_match
Feature descriptor matching utilities for stereo vision, SLAM, and object tracking.
fingerprint
Content fingerprinting for video and audio.
histogram_backproject
Histogram back-projection for object localization in images.
hough_transform
Hough transform for detecting lines and circles in images.
image
Image processing operations.
instance_segmentation
Instance segmentation: connected-component labeling with per-object binary masks.
interlace
Interlacing and telecine detection for video content.
interpolate
Video frame interpolation using optical flow.
keypoint
Keypoint detection and matching for feature-based computer vision tasks.
lane_detect
Lane detection for video frames.
lens_distortion
Lens distortion correction (barrel, pincushion, fish-eye).
morphology
Mathematical morphology operations for binary and grayscale images.
motion_blur
Motion blur synthesis and removal.
motion_vector
Motion vector estimation between video frames.
obj_tracking
Object tracking: centroid tracking, IoU-based track association, and track lifecycle management.
optical_flow_field
Dense optical flow field representation and analysis.
panorama_stitch
Simple offset-based panorama stitching with linear alpha blending.
pose_estimation
Human pose estimation module.
quality
Video quality assessment metrics.
registration
Video alignment and registration tools.
scale
Content-aware video scaling for OxiMedia.
scene
Video scene detection and shot boundary detection.
segmentation
Image segmentation: connected components, region growing, and a watershed-like approximation.
stabilize
Video stabilization with motion smoothing.
style_transfer
CPU-based artistic style transfer using neural-style approximation.
superpixel
Superpixel segmentation using a simplified SLIC algorithm.
text_detect
Text detection and recognition (OCR) for extracting burned-in subtitles.
texture_analysis
Image texture analysis using Gray-Level Co-occurrence Matrices (GLCM).
tracking
Video tracking and motion estimation.
transform
Geometric transformation module.
video_matting
Video matting — alpha matte extraction without a chroma key.