ESFILTER(1)

✨ ESFILTER(1) ✨

okay bestie, welcome to the esfilter page from the General Commands Manual, section 1. this one's giving "output a filtered or truncated version of an elementary stream" and honestly? it ate. let's get into it πŸ’…


🌸 NAME 🌸

esfilter β€” output a filtered or truncated version of an elementary stream πŸ¦‹


🌈 SYNOPSIS 🌈

esfilter -copy | -filter | -strip [-err stdout] [-err stderr]
         [-verbose | -v] [-quiet | -q] [-host dest_ip[:port]]
         [-max max_frames | -m max_frames] [-freq keep_frequency]
         [-allref] [-tsout] [-pes | -ts] [-h264 | -avc | -h262] in_file
         | -stdin out_file | -stdout

πŸ’œ DESCRIPTION πŸ’œ

so what this does is: it outputs a filtered or truncated version of an elementary stream. that's the whole vibe. the input is either H.264 (MPEG-4/AVC) or H.262 (MPEG-2), and the output is either an elementary stream, or an H.222 transport stream.

heads up bestie: if the output is going to an H.222 Transport Stream, then fixed values get used for the PMT PID (0x66) and the video PID (0x68). no cap. πŸ”₯

πŸ“ Files πŸ“

  • in_file β€” this is your input elementary stream (but peek at -stdin below, okay?).
  • out_file β€” this is your output stream, either an equivalent elementary stream, or an H.222 Transport Stream (but see -stdout and -host below).

🎬 Actions 🎬

  • -copy β€” copies the input data straight to the output file. it's mostly useful as a way of truncating data with -max. lowkey just a lil photocopier.
  • -filter β€” filters data from input to output, aiming to keep every keep_frequencyth frame (where keep_frequency is specified by -freq). the way it's out here cherry-picking frames... iconic.
  • -strip β€” for H.264, outputs just the IDR and I pictures; for H.262, outputs just the I pictures β€” but bestie, check -allref below first, fr fr.

πŸŽ€ Switches πŸŽ€

  • -err stdout β€” write error messages to standard output (this is the default).
  • -err stderr β€” write error messages to standard error (Unix traditional, very old money of it).
  • -stdin β€” input from standard input, instead of from a file.
  • -v, -verbose β€” output extra information about packets. nosy girlie behavior and I respect it.
  • -q, -quiet β€” only output error messages. silent but deadly.
  • -host dest_ip[:port] β€” writes output (over TCP/IP) to the named host, instead of to a named file. if port isn't specified, it defaults to 88. implies -tsout. it's networking, periodt.
  • -max max_frames, -m max_frames β€” maximum number of frames to read (for -filter and -strip), or ES units/NAL units (for -copy). that's your cap, bestie.
  • -freq keep_frequency β€” specify the frequency of frames to try to keep with -filter. defaults to 8.
  • -allref β€” with -strip, keep all reference pictures (H.264) or all I and P pictures (H.262). greedy in the best way πŸ’–
  • -tsout β€” output data as Transport Stream PES packets (the default is as Elementary Stream).
  • -pes, -ts β€” the input file is TS or PS, to be read via the PES->ES reading mechanisms. not allowed with -stdin. 🚫

🧚 Stream type: 🧚

if input is from a file, then the program will look at the start of the file to determine if the stream is H.264 or H.262 data. this process may occasionally come to the wrong conclusion 😭, in which case the user can override the choice using the switches below.

if input is from standard input (via -stdin), then it is not possible for the program to make its own decision on the input stream type. instead, it defaults to H.262, and relies on the user indicating if this is wrong. main character energy: you have to tell it what's up.

  • -h264, -avc β€” force the program to treat the input as MPEG-4/AVC.
  • -h262 β€” force the program to treat the input as MPEG-2.

πŸ‘€ SEE ALSO πŸ‘€

esdots(1),


and that's the whole page bestie!! this cutie came from Debian and it's dated October 28, 2015 β€” so yes, it's a vintage, and yes, it still slays. go filter something, mwah πŸ«ΆπŸ’…βœ¨