Video-Encoder-Bot
a telegram bot for compressing/encoding videos in h264 format.
Configuration
Add values in environment variables or add them in config.env.example and rename file to config.env
.
Basics
API_ID
- Get it by creating an app on https://my.telegram.orgAPI_HASH
- Get it by creating an app on https://my.telegram.orgBOT_TOKEN
- Get it by creating a bot on https://t.me/BotFather
Authorization
SUDO_USERS
- Chat identifier of the sudo user. For multiple users use space as seperator.
Encode Settings
PRESET
- https://telegra.ph/Encode-Settings-Guide-11-22TUNE
- https://telegra.ph/Encode-Settings-Guide-11-22AUDIO
- https://telegra.ph/Encode-Settings-Guide-11-22
Optional
UPLOAD_AS_DOC
- (Optional) Uploads Video as doc ifTrue
elseFalse
.DOWNLOAD_DIR
- (Optional) Temporary download directory to keep downloaded files.ENCODE_DIR
-(Optional) Temporary encode directory to keep encoded files.
Configuring Encoding Format
To change the ffmpeg profile edit them in ffmpeg.py
Deployment
With python3.7 or later.
pip3 install --no-cache-dir -r requirements.txt
python3 -m VideoEncoder
Credits
- ShannonScott for transcode_h265.py
- viperadnan-git for queue etc.
Copyright & License
- Copyright © 2021 — WeebTime
- Licensed under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE