feat(video): Implement MP4 format support across frontend and backend

- Updated VideoModal to display web compatibility status for video formats.
- Enhanced VideoPlayer to dynamically fetch video MIME types and handle MP4 streaming.
- Introduced video file utilities for better handling of video formats and MIME types.
- Modified CameraConfig interface to include new video recording settings (format, codec, quality).
- Created comprehensive documentation for MP4 format integration and frontend implementation.
- Ensured backward compatibility with existing AVI files while promoting MP4 as the preferred format.
- Added validation and error handling for video format configurations.
This commit is contained in:
Alireza Vaezi
2025-08-04 16:21:22 -04:00
parent 551e5dc2e3
commit 1aaac68edd
36 changed files with 1446 additions and 4578 deletions

View File

@@ -5,7 +5,7 @@ The USDA Vision Camera System now includes a modular video streaming system that
## 🌟 Features
- **HTTP Range Request Support** - Enables seeking and progressive download
- **Web-Compatible Formats** - Automatic conversion from AVI to MP4/WebM
- **Native MP4 Support** - Direct streaming of MP4 files with automatic AVI conversion
- **Intelligent Caching** - Optimized streaming performance
- **Thumbnail Generation** - Extract preview images from videos
- **Modular Architecture** - Clean separation of concerns
@@ -41,11 +41,11 @@ GET /videos/
{
"videos": [
{
"file_id": "camera1_recording_20250804_143022.avi",
"file_id": "camera1_recording_20250804_143022.mp4",
"camera_name": "camera1",
"filename": "camera1_recording_20250804_143022.avi",
"file_size_bytes": 52428800,
"format": "avi",
"filename": "camera1_recording_20250804_143022.mp4",
"file_size_bytes": 31457280,
"format": "mp4",
"status": "completed",
"created_at": "2025-08-04T14:30:22",
"is_streamable": true,