FFmpeg 4.1.11
Since* 3.3
#

Read closed captioning (EIA-608) information from the top lines of a video frame.

This filter adds frame metadata for lavfi.readeia608.X.cc and lavfi.readeia608.X.line, where X is the number of the identified line with EIA-608 data (starting from 0). A description of each metadata value follows:

lavfi.readeia608.X.cc

The two bytes stored as EIA-608 data (printed in hexadecimal).

lavfi.readeia608.X.line

The number of the line on which the EIA-608 data was identified and read.

This filter accepts the following options:

scan_min

Set the line to start scanning for EIA-608 data. Default is 0.

scan_max

Set the line to end scanning for EIA-608 data. Default is 29.

mac

Set minimal acceptable amplitude change for sync codes detection. Default is 0.2. Allowed range is [0.001 - 1].

spw

Set the ratio of width reserved for sync code detection. Default is 0.27. Allowed range is [0.01 - 0.7].

mhd

Set the max peaks height difference for sync code detection. Default is 0.1. Allowed range is [0.0 - 0.5].

mpd

Set max peaks period difference for sync code detection. Default is 0.1. Allowed range is [0.0 - 0.5].

msd

Set the first two max start code bits differences. Default is 0.02. Allowed range is [0.0 - 0.5].

bhd

Set the minimum ratio of bits height compared to 3rd start code bit. Default is 0.75. Allowed range is [0.01 - 1].

th_w

Set the white color threshold. Default is 0.35. Allowed range is [0.1 - 1].

th_b

Set the black color threshold. Default is 0.15. Allowed range is [0.0 - 0.5].

chp

Enable checking the parity bit. In the event of a parity error, the filter will output 0x00 for that character. Default is false.

#

Examples

  • Output a csv with presentation time and the first two lines of identified EIA-608 captioning data.

    ffprobe -f lavfi -i movie=captioned_video.mov,readeia608 -show_entries frame=pkt_pts_time:frame_tags=lavfi.readeia608.0.cc,lavfi.readeia608.1.cc -of csv