Czechball / discord-video

Simple bash and batch scripts that use ffmpeg to compress videos to fit under 25 MB (Discord free upload limit)
MIT License
52 stars 11 forks source link

Should %VIDEO_BITRATE% be in a bash script? #6

Closed ZacharyTalis closed 2 years ago

ZacharyTalis commented 2 years ago

Neato script!

This line uses %VIDEO_BITRATE% (towards the end). Should it be $VIDEO_BITRATE?

Script failed on my Linux machine until tweaking this. Error message:

[libvpx-vp9 @ 0x55961f169840] [Eval @ 0x7fff73449e70] Undefined constant or missing '(' in '%VIDEO_BITRATE%'
[libvpx-vp9 @ 0x55961f169840] Unable to parse option value "%VIDEO_BITRATE%"
[libvpx-vp9 @ 0x55961f169840] Error setting option b to value %VIDEO_BITRATE%.
Error initializing output stream 0:0 -- Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height
Czechball commented 2 years ago

Seems like @RealOfficialTurf broke it here: https://github.com/Czechball/discord-video/commit/fcfe83e90d5bfc5df99db2a9172690bfc29da074 Will fix..

Czechball commented 2 years ago

https://github.com/Czechball/discord-video/commit/3d4010bc6d1aac853837ab322f044377e664947c