This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Examples taken from https://opensource.com/article/17/6/ffmpeg-convert-media-file-formats | |
| # Convert a webm file to a matroska format with a vp9 encoding and keeping the same audio encoding. | |
| # Also changes the bitrate to 1Mb/s | |
| ffmpeg -i input.webm -c:a copy -c:v vp9 -b:v 1M output.mkv | |
| # Same but change the frame rate to 30 FPS and dropping the bitrate conversion | |
| ffmpeg -i input.webm -c:a copy -c:v vp9 -r 30 output.mkv | |
| # Same but only setting the video size to a predetermined format HD 720 in this case |