Mux 20-second keyframe interval vs Sume Video Trim keyframe precision

Mux wants a keyframe at least every 20 seconds on 1080p input. Sume Video Trim has an exact re-encode and a keyframe copy that may start early. Which to use.

4 min readSume
All posts

Short answer

Mux's input page says 1080p standard inputs need a maximum 20-second keyframe interval (10 seconds for HEVC), and that every group of pictures should be closed so it plays independently. Sume Video Trim offers two precision modes: exact (default), a frame-accurate libx264 re-encode at yuv420p, and keyframe, a stream copy where the cut may start a GOP early. If you trim for a Mux upload, exact re-encodes and writes its own keyframes; keyframe preserves the source's.

So the rule is simple: exact when you need a precise cut point, keyframe when speed and bit-for-bit quality matter and a little extra at the start is acceptable.

Choosing a precision mode

The table compares what each mode does, from the Video Trim doc, with the Mux requirement it touches.

Trim precision vs the Mux keyframe rule (read 2026-10-03)
ModeWhat happensEffect on keyframes
exact (default)Frame-accurate re-encode, libx264 yuv420pThe encoder places keyframes; check the result
keyframeStream copy, no re-encodeSource keyframes preserved; cut may start a GOP early
Output conformOnly with exact; width, height, fpsRe-encode at the new size

The GOP-early catch

A stream copy can only cut on a keyframe, so the clip may begin before the start you asked for. Video Trim reports actual_start_seconds, which is the real in-point; use it when you re-base subtitles or timeline offsets. If your source has a 20-second keyframe interval, the early start can be several seconds, which is a visible difference on a short clip.

If the source already satisfies Mux (a keyframe at least every 20 seconds) and you only want to drop the beginning, keyframe mode is fast and lossless. If the source has sparse keyframes and you need both a precise cut and Mux compatibility, exact is the safer path because the re-encode does not depend on the source's keyframe layout.

  • Output size and fps conforming works only with exact; combining output with keyframe is rejected with video_trim_output_requires_exact.
  • A trim costs $0.02 per job; the source can be up to 1800 seconds and the output 0.2 to 900 seconds.
  • Audio is kept by default and remuxed as AAC in exact mode; set audio to drop for a silent clip.

Checking the output

After the job, read the returned duration and actual_start_seconds, then run a quick keyframe probe on the file. If you use keyframe mode, compare actual_start_seconds with your requested start and decide whether the difference matters for the edit.

For loop checks on Reels, see the first-and-last-frame loop check, which relies on exact cuts.

A decision rule

Use exact when the trimmed clip will be uploaded to a service with an input envelope, when you will place cuts against audio or captions, or when you plan to conform size and frame rate in the same job. Use keyframe when you are making a rough preview, when the source is already compliant and you only need a head start trimmed, or when you cannot afford a generation loss.

Either way, record the requested start, the returned actual_start_seconds and the duration you asked for. That small log explains most future mismatches between a transcript timestamp and a clip.

Sources

Related posts

More in Developers

All Developers posts

Written by Sume