https://github.com/rendiffdev/ffmpeg-webgui
The goal of this project is to build a containerized web application that provides a graphical interface for FFmpeg. Users will be able to upload media files, configure advanced encoding/transcoding settings, launch jobs, and monitor their status.
https://github.com/rendiffdev/ffmpeg-webgui
ffmpeg ffmpeg-gui webui
Last synced: 12 months ago
JSON representation
The goal of this project is to build a containerized web application that provides a graphical interface for FFmpeg. Users will be able to upload media files, configure advanced encoding/transcoding settings, launch jobs, and monitor their status.
- Host: GitHub
- URL: https://github.com/rendiffdev/ffmpeg-webgui
- Owner: rendiffdev
- License: mit
- Created: 2025-02-24T10:41:58.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-17T09:56:41.000Z (12 months ago)
- Last Synced: 2025-03-17T10:43:56.495Z (12 months ago)
- Topics: ffmpeg, ffmpeg-gui, webui
- Homepage:
- Size: 16.6 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# FFmpeg Web GUI in Docker
A containerized web application that serves as a full-featured web GUI for FFmpeg.
This tool provides an intuitive interface for uploading media files, configuring advanced encoding/transcoding settings, and managing processing jobs.
It also integrates VMAF (Video Multi-Method Assessment Fusion) scoring to evaluate the quality of each transcoded file.
---
## FFmpeg WebGUI Screenshots
### HLS Example

### VP9 Example

## Table of Contents
- [Overview](#overview)
- [Objectives](#objectives)
- [Key Features](#key-features)
- [User Management](#user-management)
- [File Management](#file-management)
- [FFmpeg Job Configuration](#ffmpeg-job-configuration)
- [VMAF Integration](#vmaf-integration)
- [Job Management & Monitoring](#job-management--monitoring)
- [Administration & System Settings](#administration--system-settings)
- [Architecture](#architecture)
- [Implementation Details](#implementation-details)
- [Dockerfile Sample](#dockerfile-sample)
- [Job Management Module](#job-management-module)
- [VMAF Score Integration](#vmaf-score-integration)
- [Testing and Quality Assurance](#testing-and-quality-assurance)
- [Deployment and Maintenance](#deployment-and-maintenance)
- [License](#license)
---
## Overview
This project provides a web-based interface for FFmpeg, enabling users to perform advanced encoding and transcoding tasks with ease.
The application runs inside a Docker container, ensuring a consistent environment and simplified deployment.
Users can monitor job status, view detailed logs, and even assess quality with integrated VMAF scoring.
---
## Objectives
- **User-Friendly Web Interface:** Offer an intuitive GUI suitable for both novice and advanced users.
- **Advanced FFmpeg Integration:** Support a wide range of codecs, formats, filters, and custom parameters.
- **Job Management:** Enable users to queue, monitor, and control transcoding jobs with real-time updates.
- **Quality Assessment:** Automatically compute and display VMAF scores for each processed job.
- **Containerization:** Deploy the application within Docker to guarantee consistency and ease of deployment.
---
## Key Features
### User Management
- **Authentication & Authorization:** Secure login system with role-based access (admin vs. standard users).
- **Dashboard:** A summary view of recent jobs, system status, and resource usage.
### File Management
- **File Upload/Selection:** Options to upload local files or specify file paths accessible by the container.
- **Input Validation:** Checks for supported file formats and size limits before processing.
### FFmpeg Job Configuration
- **Preset Options:** Ready-to-use presets for common tasks (e.g., 1080p H.264, 4K HEVC).
- **Custom Command Builder:**
- Define advanced FFmpeg parameters including codecs (H.264, H.265, VP9, AV1) and formats (MP4, MKV, WebM, MOV).
- Utilize filters for scaling, deinterlacing, denoising, color correction, etc.
- Configure bitrate, CRF values, two-pass encoding, and other quality settings.
- **Advanced Options:**
- Integration with libraries like libx264, libx265, and libvmaf.
- Custom audio/video stream mapping, subtitle overlays, and more.
### VMAF Integration
- **Quality Analysis:** Automatically compute VMAF scores post-encoding by comparing the source and encoded files.
- **Reporting:** Detailed job reports with VMAF scores, quality graphs, and log data.
### Job Management & Monitoring
- **Job Queue:** Support for multiple concurrent or sequential encoding jobs.
- **Real-Time Status:** Live updates showing progress, estimated completion time, and command status.
- **Logging & History:** Detailed logs for each job, with error tracking and historical data.
- **Notifications:** Email or in-app alerts on job completion or failures.
### Administration & System Settings
- **Resource Management:** Monitor CPU, memory, and disk usage during transcoding jobs.
- **Configuration Panel:** Admin interface for system-wide FFmpeg defaults, Docker resource settings, and log management.
- **API Access:** RESTful endpoints for integration with external systems or automation workflows.
---
## Architecture
The application is built with a modern web stack:
- **Frontend:** Built using a JavaScript framework (React, Vue, or Angular) for a dynamic user experience.
- **Backend:** A RESTful API implemented in Python (Flask/Django) or Node.js (Express) to handle job submissions, process management, and integration with FFmpeg.
- **FFmpeg Integration:** The backend constructs and executes FFmpeg commands based on user input while monitoring subprocess outputs.
- **VMAF Processing:** Uses FFmpeg's built-in libvmaf filter or an external library for quality scoring.
- **Database:** A lightweight database (SQLite or PostgreSQL) to track user data, job metadata, and logs.
- **Containerization:** The entire application runs inside a Docker container, ensuring consistent deployment and operation.
**System Diagram:**
```
+------------------+ HTTP/HTTPS +--------------------+
| Web Browser | <-------------------> | Web Server (API) |
+------------------+ +---------+----------+
|
| Subprocess management
v
+--------------+
| FFmpeg |
| (with VMAF) |
+--------------+
|
| File I/O (volumes)
v
+--------------+
| Storage |
| (Docker Vol.)|
+--------------+
```
---
## Implementation Details
### Dockerfile Sample
```dockerfile
FROM ubuntu:22.04
# Install dependencies and FFmpeg with required libraries
RUN apt-get update && apt-get install -y \
ffmpeg \
python3 \
python3-pip \
nginx \
# (Include additional libraries such as libx264, libx265, libvmaf if not bundled with ffmpeg)
# Copy application code
COPY ./app /opt/app
# Install Python dependencies
RUN pip3 install -r /opt/app/requirements.txt
# Expose port 80 for web access
EXPOSE 80
# Start the web server (using gunicorn, for example)
CMD ["gunicorn", "--bind", "0.0.0.0:80", "app:app"]
```
### Job Management Module
- **Command Generation:** Dynamically construct FFmpeg commands based on user inputs.
- **Process Management:** Use a task queue (e.g., Celery for Python or Bull for Node.js) for managing long-running jobs.
- **Real-Time Updates:** Implement WebSocket or long polling to provide live updates on job status.
### VMAF Score Integration
Utilize FFmpeg’s libvmaf filter to compute quality scores:
```bash
ffmpeg -i input.mp4 -i encoded.mp4 -lavfi libvmaf="log_path=./vmaf_log.json" -f null -
```
Parse the resulting JSON output to display quality metrics in the job report.
---
## Testing and Quality Assurance
- **Unit & Integration Tests:** Test individual modules (job scheduler, command builder, VMAF integration).
- **User Acceptance Testing:** Conduct pilot tests with target users to refine UI/UX.
- **Performance Testing:** Benchmark under load to ensure robust concurrent job handling.
---
## Deployment and Maintenance
- **CI/CD:** Automate building, testing, and deployment using continuous integration pipelines.
- **Documentation:** Provide comprehensive user guides, API documentation, and developer setup instructions.
- **Monitoring:** Integrate logging and monitoring tools (e.g., Prometheus/Grafana) for ongoing system performance and resource usage tracking.
---
## License
Distributed under the MIT License. See `LICENSE` for more information.