Nodes/MKRShift_Nodes/Proxy Transcode
ComfyUI Node

Proxy Transcode

Make a tiny proxy of a huge video and stop waiting on previews

By criskb·Created 7 months ago·Updated 5 months ago· 0
Proxy Transcode
  • video
  • video
  • output_path
  • summary
scale_percent50
target_fps0.0
output_formatmp4
video_bitrate_kbps3000
keep_audiotrue
filename_prefixMKR_proxy
subfolder
overwritefalse
filename_label

"Proxy" is a word editors know and most ComfyUI users have never needed: a low-resolution, low-bitrate copy of a clip that exists purely so you can scrub and preview it fast, while the original stays the master. MKRProxyTranscode brings that workflow into the graph. Feed it a big render, get back a small file that plays instantly - and can feed the rest of your MKRShift media pipeline without dragging around full-size frames.

What it's for

Two distinct jobs. First, the obvious one: your export is 4K and 200MB and you're tired of ComfyUI choking on it in preview. Crank scale_percent down to 50 (or 25), drop the bitrate, and get a file you can actually work with. Second, and sneakier: the returned video output is an MKR_VIDEO payload, which means you can wire the proxy into other MKRShift media nodes - scene detection, reverse, color match - and run all your analysis on a small file, then apply results to the master.

How it works

With a file source and ffmpeg available, it builds an ffmpeg command: scale to a percentage (rounded to even dimensions so encoders are happy), an optional fps filter when target_fps is set, then re-encodes - libx264 at veryfast preset for mp4/mov, libvpx-vp9 for webm - at video_bitrate_kbps, with audio (aac/opus at 128k) kept only if keep_audio is on. If ffmpeg is missing, it falls back to decoding frames in PIL, resizing, and re-encoding as best it can (containers get downgraded toward gif). Note that target_fps = 0 (the default) means "keep the source frame rate."

Inputs that matter

  • video - any file, tensor, or MKR_VIDEO payload.
  • scale_percent (default 50) - the whole point. 50 = half resolution, 25 = tiny.
  • target_fps (default 0 = keep source) - cap the frame rate to shrink the file further.
  • video_bitrate_kbps (default 3000) - your size/quality lever.
  • keep_audio (default true) - keep or drop the soundtrack. gif/webp get no audio either way.
  • output_format - mp4 (default), mov, webm, gif, webp.

Outputs: video (MKR_VIDEO payload to feed downstream), output_path (the file on disk), summary (mode, scale, fps, warnings).

Installing it

Pack install as usual:

cd ComfyUI/custom_nodes
git clone https://github.com/criskb/MKRShift_Nodes

restart ComfyUI (or Manager → MKRShift_Nodes). This node is the poster child for the README's ffmpeg requirement - without the binary you get the PIL fallback, and real mp4 proxies need the real thing.

Common issues

Forgetting ffmpeg is issue number one; the summary will tell you ("ffmpeg is not available"), so read it. Watch the even-dimension rounding - a 333px-wide clip becomes 332px, which matters only if you're overlaying exact coordinates. And a word on expectations: a proxy is a working copy, not a deliverable. Don't ship the output_path as your final render - that's what the original is for.

CategoryMKRShift Nodes/Media/IO

Inputs (10)

NameTypeDefaultDescription
video*
scale_percentINT505–100
target_fpsFLOAT0.00–240
output_formatCOMBOmp45 options: mp4, mov, webm, gif, webp
video_bitrate_kbpsINT3000200–50000
keep_audioBOOLEANtrue
filename_prefixSTRINGMKR_proxy
subfolderSTRING
overwriteBOOLEANfalse
filename_labeloptSTRING

Outputs (3)

NameTypeDescription
videoMKR_VIDEO
output_pathSTRING
summarySTRING