vidscroll0.3.3

CLI

The vidscroll encode command, every option and exactly what it runs.

For a walkthrough, see Pre-encoding with the CLI. This page is the reference.

Usage

Terminal
npx vidscroll encode <input> [output] [options]
npx vidscroll help

Arguments and options

ArgumentDefaultMeaning
<input>requiredThe video to prepare. Any format ffmpeg reads.
[output]input name with .scroll.mp4Where to write the result. Must differ from the input. An existing file is overwritten.
–resolution <px>720Short side of the output. Never enlarges.
–gop <frames>10Frames between keyframes. Rounded to a whole number.
–crf <n>22Quality, lower is better and bigger.
–fps <n>source rateFrame rate cap. Faster sources are reduced; slower ones keep their rate.
-h, –helpShow the help text.

All values must be positive numbers, written after a space (--crf 24, not --crf=24). Unknown options are ignored.

What it runs

The command calls ffmpeg with these settings:

SettingValue
Video codecH.264 (libx264), preset slow, yuv420p
KeyframesExactly every –gop frames, scene-cut keyframes off
Quality–crf
SizeShort side scaled to –resolution or less
Frame rateCapped at –fps when given
AudioRemoved
StreamingMetadata at the start of the file (+faststart)

When it finishes, it prints the output path, its size, the input’s size and the keyframe interval.

Finding ffmpeg

The first one that exists is used:

  1. the FFMPEG_PATH environment variable,
  2. the ffmpeg-static package, if installed,
  3. ffmpeg on your PATH.

If none is found, the command stops with instructions.