y4mcolorbars(1)
β¨ y4mcolorbars β the MJPEG tools manual β¨
okay so bestie, welcome to the y4mcolorbars(1) page π this one lives in the MJPEG tools manual and it's genuinely so fun, no cap.
π NAME
y4mcolorbars β make a YUV4MPEG2 stream that's literally just a colorbar test pattern, over and over π
πΌ SYNOPSIS
y4mcolorbars [options]
π DESCRIPTION
y4mcolorbars creates a YUV4MPEG2 stream where every single frame is a colorbar test pattern. Nothing else, just vibes and bars π¦
The pattern is out here trying to reproduce the standard SMPTE EG-1-1990 colorbar test signal as faithfully as it possibly can, given the constraints of the Y'CbCr colorspace. It's giving "doing my best under capitalism," honestly.
Output goes to stdout, specifically so you can pipe it into other MJPEG tools. Pipeline main character energy, periodt.
β¨ OPTIONS β¨
y4mcolorbars accepts the following options, and yes, we're going through all of them:
-nnum β Output a total of num output frames. [default:1]-Fn:d β Set the framerate encoded in the output stream, as an exact integer ratio. The common rates are:24000:1001β NTSC 3:2 pulldown converted film24:1β native film25:1β PAL/SECAM30000:1001β NTSC video [default]50:1β PAL field rate60000:1001β NTSC field rate
-Ww β Set frame width. [default:720]-Hh β Set frame height. [default:480]-An:d β Set the pixel aspect ratio encoded in the output stream, as an exact integer ratio. The common ratios are:1:1β square pixels (e.g. computer graphics)10:11β CCIR-601 NTSC [default]59:54β CCIR-601 PAL
-Ix β Set the interlacing mode, which is used to interpret the PPM image(s) and is also encoded in the output stream.pβ progressive, non-interlaced [default]tβ top/upper-field-first interlacedbβ bottom/lower-field-first interlaced
-Qn β The data to place in the-I/+Qpatches in the bottom row of the pattern:0β-Iand+Qat 20% (20IRE) [default]1β-Iand+Qat 50% (50IRE)2β+Cband+Crat 100%
-Smode β Set the chroma subsampling mode.444β 4:4:4 (no subsampling) [default]420jpegβ 4:2:0 JPEG/MPEG-1, interstitial cositing420mpeg2β 4:2:0 MPEG-2, horizontal cositing
ngl the supported subsampled modes use a lousy subsampling filter π better results will be achieved by passing the default 4:4:4 output to a scaler which supports subsampling, such as y4mscaler(1). that's the move.
-v[0,1,2]β Set the verbosity level.0β warnings and errors only.1β add informative messages, too. [default]2β add chatty debugging message, too.
π EXAMPLES
Wanna create and display 200 frames of colorbars that match a top-field-first interlaced 4:3 NTSC source? Say less:
y4mcolorbars -n 200 -It -S 420jpeg | yuvplay
And for 200 frames of colorbars matching a bottom-field-first interlaced 4:3 PAL source:
y4mcolorbars -n 200 -H 576 -F 25:1 -A 59:54 -Ib | yuvplay
ate. no crumbs. π₯
π BUGS
okay so, first thing: it's genuinely not clear to the author (who has, and I cannot stress this enough, never actually seen the SMPTE EG-1-1990 document itself π) what the absolute excursion of the -I and +Q regions is supposed to be. However, the phase is correct, and that should be the critical feature. so like, we ball.
Second thing: the PLUGE bars, of -4 and +4 IRE, can never be precisely synthesized. Why? Because the Y' digital space maps [16,235] over the full luma excursion, but the full luma excursion in analog space depends on whether or not 7.5 IRE NTSC setup is being used by whatever device eventually produces the analog output. π The good news though: the difference is within 1-bit of Y' accuracy anyway, so it's lowkey fine.
π AUTHOR
This man page was written by Matt Marjanovic.
If you have questions, remarks, problems, or you just want to contact the developers, the main mailing list for the MJPEG-tools is:
mjpeg-users@lists.sourceforge.net
For more info, see our website at:
http://mjpeg.sourceforge.net
π«Ά SEE ALSO
mjpegtools(1), mpeg2enc(1), y4mscaler(1), yuv2lav(1), yuvplay(1)
and that's the whole page bestie π huge thanks to the MJPEG Tools Team for this one, dated 28 April 2004 β iconic behavior from start to finish, and y4mcolorbars(1) will always be that girl πΈβ¨
π¦ where this page comes from
- arch rolling: mjpegtools 2.2.1-4 Β· GPL-2.0-or-later
- debian bookworm: mjpegtools 1:2.1.0+debian-7
- debian trixie: mjpegtools 1:2.1.0+debian-8.1+b1
- fedora 43: mjpegtools 2.2.1-11.fc43 Β· GPL-2.0-or-later AND GPL-2.0-only AND GPL-1.0-or-later
- fedora 44: mjpegtools 2.2.1-12.fc44 Β· GPL-2.0-or-later AND GPL-2.0-only AND GPL-1.0-or-later
- nixos 26.05: mjpegtools 2.2.1
- nixpkgs unstable: mjpegtools 2.2.1
- opensuse-leap 16.0: mjpegtools 2.2.1-160000.2.2 Β· GPL-2.0-only
- opensuse-leap 16.0: mjpegtools 2.2.1-160000.2.2 Β· GPL-2.0-only
- opensuse-leap 16.0: mjpegtools 2.2.1-160000.2.2 Β· GPL-2.0-only
- opensuse-leap 16.0: mjpegtools 2.2.1-160000.2.2 Β· GPL-2.0-only
- ubuntu jammy: mjpegtools 1:2.1.0+debian-6build1
- ubuntu noble: mjpegtools 1:2.1.0+debian-8.1build1
- ubuntu questing: mjpegtools 1:2.1.0+debian-8.1build1
- ubuntu resolute: mjpegtools 1:2.2.1-3
- ubuntu stonking: mjpegtools 1:2.2.1-3
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms