Video Transcoding – scripts @ Github

  • transcode-video
  • detect-crop
  • convert-video
  • query-handbrake-log

1
2
3
4
5
6
7
8
9
10
11
brew install ruby
gem install video_transcoding

# ** THE FOLLOWING ARE REQUIRED **
brew install handbrake
brew install ffmpeg
brew install mkvtoolnix
brew install mp4v2

# ** OPTIONAL **
brew install mpv

eg:

1
transcode-video --mp4 --simple --veryquick --crop detect --constrain-crop --fallback-crop handbrake --720p --add-subtitle all --output ~ -v "FIRST.mkv"
This will:
convert FIRST.mkv, output to ~
save conversion in mp4, 720p size
simple : read the instructions regarding optimization algorithm
crop : detect optimal crop, if there is a diff between handbrake & ffmpeg, choose handbrake as default
subtitles : add all subtitles from source to destination
-v : verbose output

SOURCE: Video-Transcoding scripts (ruby) by Don Melton

Most of the tools in this package are essentially intelligent wrappers around Open Source software like HandBrake, FFmpeg, MKVToolNix, and MP4v2. And they’re all designed to be executed from the command line shell:

  • 1
    transcode-video

    Transcode video file or disc image directory into format and size similar to popular online downloads.

  • 1
    detect-crop

    Detect crop values for video file or disc image directory.

  • 1
    convert-video

    Convert video file from Matroska to MP4 format or from MP4 to Matroksa format without transcoding video.

  • 1
    query-handbrake-log

    Report information from HandBrake-generated

    1
    .log

    files.