hls-converter-cli
General-purpose HLS media converter built on FFmpeg, by @devdasher.
Install
pip install hls-converter-cli
You also need ffmpeg and ffprobe on your PATH, or pass their locations via --ffmpeg / --ffprobe.
CLI usage
hls-converter "movie.mkv"
hls-converter "movie.mkv" --video-mode encode --video-profiles 720,1080
hls-converter "subs.srt" --add-to-stream "/path/to/stream" --language fa
Run hls-converter --about for author, license, and project links.
Library usage
from pathlib import Path
from hls_converter_cli import (
HLSConverter, AppConfig, CancellationToken,
)
config = AppConfig(...) # build with build_parser()/build_config()
converter = HLSConverter(config)
result = converter.convert(
input_file=Path("movie.mkv"),
output_dir=Path("movie-stream"),
on_progress=lambda ev: print(ev.stage, ev.percent),
cancel_token=CancellationToken(),
)
Features
- Copy or re-encode video to multiple resolutions
- Per-track audio bitrate and channel overrides
- Subtitle extraction to WebVTT with offset and time-scale correction
- Add audio/subtitle tracks to an existing stream folder
- Dry-run mode, progress events, cooperative cancellation
License
MIT
Release files for hls-converter-cli 0.9.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| hls_converter_cli-0.9.0.tar.gz | 32.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| hls_converter_cli-0.9.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 64.8 kB
Release files / hls_converter_cli-0.9.0.tar.gz
| Download URL | hls_converter_cli-0.9.0.tar.gz |
|---|---|
| Size | 32.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3db88f1a0dc216037c98b6afa77989ee99116589a0f3ecae4ef5a623f8a7f218
|
|
BLAKE2b-256 checksum How to use checksums |
933e2502e10dd697e7ca881173f66cafd0492f960fcc80477e7821ed292d3d2e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.11
|
Release files / hls_converter_cli-0.9.0-py3-none-any.whl
| Download URL | hls_converter_cli-0.9.0-py3-none-any.whl |
|---|---|
| Size | 32.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7bb8d8fa1f14d351e3af0b7d1d07de4639d45ab27a677247c94fff8cbf88b28d
|
|
BLAKE2b-256 checksum How to use checksums |
a3364ba63a4be638dd8f7ae356beb0aba8c416e8665a82e97c686d2b940625bf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.11
|