Skip to main content

Crate oximedia_repair

Crate oximedia_repair 

Source
Expand description

Media file repair and recovery tools for OxiMedia.

This crate provides comprehensive tools for detecting and repairing corrupted media files, including:

  • Corruption detection and analysis
  • Header repair for various container formats
  • Index rebuilding and seek table reconstruction
  • Timestamp validation and correction
  • Packet recovery and interpolation
  • Audio/video synchronization fixes
  • Truncation recovery and file finalization
  • Metadata repair and reconstruction
  • Partial file recovery
  • Frame reordering
  • Error concealment

§Example

use oximedia_repair::{RepairEngine, RepairMode, RepairOptions};
use std::path::Path;

let engine = RepairEngine::new();
let options = RepairOptions {
    mode: RepairMode::Balanced,
    create_backup: true,
    verify_after_repair: true,
    ..Default::default()
};

let result = engine.repair_file(Path::new("corrupted.mp4"), &options)?;
println!("Repaired: {}", result.success);
println!("Issues fixed: {}", result.issues_fixed);

Modules§

audio_repair
Audio artifact detection and repair.
audio_restore
Audio restoration: click removal, dropout recovery, and level restoration.
bitstream_repair
Bitstream-level error detection and repair for media streams.
checksum_repair
Checksum detection and repair for media files.
codec_probe
Codec parameter identification from raw bitstreams.
color_repair
Color repair: desaturation fix, color cast removal, and tone restoration.
conceal
Error concealment.
container_migrate
Re-muxing repaired streams into a clean container without re-encoding.
container_repair
Container-level structure repair for media files.
conversion
Format conversion error repair.
corruption_map
Media corruption mapping.
corruption_simulator
Controlled corruption injection for testing repair algorithms.
detect
Media corruption detection and analysis.
dropout_concealment
Dropout detection and concealment for video and audio streams.
error_correction
Error correction for corrupted media frames.
frame_concealment
Frame concealment strategies.
frame_repair
Frame-level damage detection and repair for video media.
gap_fill
Gap filling and interpolation for corrupted or missing media segments.
header
Header repair for various container formats.
index
Index rebuilding for seekable media files.
integrity
File integrity checking.
level_repair
Audio level repair and correction utilities.
metadata
Metadata repair and reconstruction.
metadata_repair
Metadata repair and reconstruction for media files.
packet
Packet recovery and repair.
packet_recovery
RTP/UDP packet-loss detection and recovery using Forward Error Correction.
packet_repair
Packet-level repair and loss recovery for media streams.
parallel_repair
Parallel batch repair of independent media files using rayon.
partial
Partial file recovery.
reorder
Frame reordering.
repair_log
Structured logging of repair actions taken on a media file.
repair_profile
Repair configuration presets per container format.
report
Repair report generation.
scratch
Scratch and artifact repair: detection, inpainting approximation, and temporal consistency.
stream_recovery
Elementary stream recovery from damaged container files.
stream_splice
Extract playable segments from partially corrupt files.
sync
Audio/video synchronization.
sync_repair
Audio/video synchronization analysis and repair.
timestamp
Timestamp validation and correction.
truncation
Truncation detection and recovery.
verify
Verification of repaired files.

Structs§

CustomRepairConfig
Repair mode determines the aggressiveness of repair operations. Per-issue aggressiveness configuration for RepairMode::Custom.
Issue
Detected issue in a media file.
RepairEngine
Main repair engine.
RepairOptions
Options for repair operations.
RepairResult
Result of a repair operation.

Enums§

IssueType
Types of issues that can be detected and repaired.
RepairError
Errors that can occur during media repair operations.
RepairMode
Repair aggressiveness mode controlling the tradeoff between data preservation and recovery completeness.
Severity
Issue severity level.

Type Aliases§

ProgressCallback
Progress callback type: called after each issue is processed. Arguments: (issues_done, issues_total, current_issue_description).
Result
Result type for repair operations.