[FFmpeg-devel] [PATCH v8 07/13] fftools/ffmpeg: Replace sub2video with subtitle frame filtering

Andreas Rheinhardt andreas.rheinhardt at outlook.com
Wed Sep 22 07:07:14 EEST 2021


Soft Works:
> This commit actually enables subtitle filtering in ffmpeg by
> sending and receiving subtitle frames to and from a filtergraph.
> 
> The heartbeat functionality from the previous sub2video implementation
> is retained and applied to all subtitle frames (bitmap, text, ..).
> 
> The other part of sub2video functionality is retained by
> auto-insertion of the new graphicsub2video filter.
> 
> Signed-off-by: softworkz <softworkz at hotmail.com>
> ---
>  fftools/ffmpeg.c                          | 460 ++++++++++------------
>  fftools/ffmpeg.h                          |  14 +-
>  fftools/ffmpeg_filter.c                   | 200 +++++++---
>  fftools/ffmpeg_hw.c                       |   2 +-
>  fftools/ffmpeg_opt.c                      |   3 +-
>  tests/ref/fate/filter-overlay-dvdsub-2397 | 181 +++++----
>  tests/ref/fate/sub-dvb                    | 162 ++++----
>  tests/ref/fate/sub2video                  |  44 ---
>  tests/ref/fate/sub2video_basic            |  93 +++--
>  tests/ref/fate/sub2video_time_limited     |   4 +-
>  10 files changed, 575 insertions(+), 588 deletions(-)
> 

> diff --git a/fftools/ffmpeg_filter.c b/fftools/ffmpeg_filter.c
> index b798459946..a97fca6521 100644
> --- a/fftools/ffmpeg_filter.c
> +++ b/fftools/ffmpeg_filter.c
> @@ -22,6 +22,9 @@
>  
>  #include "ffmpeg.h"
>  
> +#include <libavcodec/ass_split.h>
> +#include <libavfilter/internal.h>
> +
>  #include "libavfilter/avfilter.h"
>  #include "libavfilter/buffersink.h"
>  #include "libavfilter/buffersrc.h"
> @@ -221,9 +224,8 @@ static void init_input_filter(FilterGraph *fg, AVFilterInOut *in)
>      enum AVMediaType type = avfilter_pad_get_type(in->filter_ctx->input_pads, in->pad_idx);
>      int i;
>  
> -    // TODO: support other filter types
> -    if (type != AVMEDIA_TYPE_VIDEO && type != AVMEDIA_TYPE_AUDIO) {
> -        av_log(NULL, AV_LOG_FATAL, "Only video and audio filters supported "
> +    if (type != AVMEDIA_TYPE_VIDEO && type != AVMEDIA_TYPE_AUDIO && type != AVMEDIA_TYPE_SUBTITLE) {
> +        av_log(NULL, AV_LOG_FATAL, "Only video, audio and subtitle filters supported "
>                 "currently.\n");
>          exit_program(1);
>      }
> @@ -244,8 +246,9 @@ static void init_input_filter(FilterGraph *fg, AVFilterInOut *in)
>          for (i = 0; i < s->nb_streams; i++) {
>              enum AVMediaType stream_type = s->streams[i]->codecpar->codec_type;
>              if (stream_type != type &&
> -                !(stream_type == AVMEDIA_TYPE_SUBTITLE &&
> -                  type == AVMEDIA_TYPE_VIDEO /* sub2video hack */))
> +                // in the followng case we auto-insert the graphicsub2video conversion filter 
> +                // for retaining compatibility with the previous sub2video hack
> +                !(stream_type == AVMEDIA_TYPE_SUBTITLE && type == AVMEDIA_TYPE_VIDEO))
>                  continue;
>              if (check_stream_specifier(s, s->streams[i], *p == ':' ? p + 1 : p) == 1) {
>                  st = s->streams[i];
> @@ -416,6 +419,39 @@ static int insert_filter(AVFilterContext **last_filter, int *pad_idx,
>      return 0;
>  }
>  
> +static int configure_output_subtitle_filter(FilterGraph *fg, OutputFilter *ofilter, AVFilterInOut *out)
> +{
> +    OutputStream *ost = ofilter->ost;
> +    AVFilterContext *last_filter = out->filter_ctx;
> +    int pad_idx = out->pad_idx;
> +    int ret;
> +    char name[255];
> +
> +    snprintf(name, sizeof(name), "out_%d_%d", ost->file_index, ost->index);
> +    ret = avfilter_graph_create_filter(&ofilter->filter,
> +                                       avfilter_get_by_name("sbuffersink"),
> +                                       name, NULL, NULL, fg->graph);
> +
> +    if (ret < 0) {
> +        av_log(NULL, AV_LOG_ERROR, "Unable to create filter sbuffersink\n");
> +        return ret;
> +    }
> +
> +    ////snprintf(name, sizeof(name), "trim_out_%d_%d",
> +    ////         ost->file_index, ost->index);
> +    ////ret = insert_trim(of->start_time, of->recording_time,
> +    ////                  &last_filter, &pad_idx, name);
> +    ////if (ret < 0)
> +    ////    return ret;
> +
> +    ////ost->st->codecpar->codec_tag = MKTAG('a', 's', 's', 's');
> +
> +    if ((ret = avfilter_link(last_filter, pad_idx, ofilter->filter, 0)) < 0)
> +        return ret;
> +
> +    return 0;
> +}
> +
>  static int configure_output_video_filter(FilterGraph *fg, OutputFilter *ofilter, AVFilterInOut *out)
>  {
>      char *pix_fmts;
> @@ -594,7 +630,8 @@ static int configure_output_audio_filter(FilterGraph *fg, OutputFilter *ofilter,
>          int i;
>  
>          for (i=0; i<of->ctx->nb_streams; i++)
> -            if (of->ctx->streams[i]->codecpar->codec_type == AVMEDIA_TYPE_VIDEO)
> +            if (of->ctx->streams[i]->codecpar->codec_type == AVMEDIA_TYPE_VIDEO ||
> +                of->ctx->streams[i]->codecpar->codec_type == AVMEDIA_TYPE_SUBTITLE)
>                  break;
>  
>          if (i<of->ctx->nb_streams) {
> @@ -628,6 +665,7 @@ static int configure_output_filter(FilterGraph *fg, OutputFilter *ofilter,
>      switch (avfilter_pad_get_type(out->filter_ctx->output_pads, out->pad_idx)) {
>      case AVMEDIA_TYPE_VIDEO: return configure_output_video_filter(fg, ofilter, out);
>      case AVMEDIA_TYPE_AUDIO: return configure_output_audio_filter(fg, ofilter, out);
> +    case AVMEDIA_TYPE_SUBTITLE: return configure_output_subtitle_filter(fg, ofilter, out);
>      default: av_assert0(0); return 0;
>      }
>  }
> @@ -647,51 +685,103 @@ void check_filter_outputs(void)
>      }
>  }
>  
> -static int sub2video_prepare(InputStream *ist, InputFilter *ifilter)
> +static int configure_input_subtitle_filter(FilterGraph *fg, InputFilter *ifilter,
> +                                        AVFilterInOut *in)
>  {
> -    AVFormatContext *avf = input_files[ist->file_index]->ctx;
> -    int i, w, h;
> +    AVFilterContext *last_filter;
> +    const AVFilter *buffer_filt = avfilter_get_by_name("sbuffer");
> +    InputStream *ist = ifilter->ist;
> +    AVBPrint args;
> +    char name[255];
> +    int ret, pad_idx = 0;
> +    int w, h;
> +    AVBufferSrcParameters *par = av_buffersrc_parameters_alloc();
> +
> +    if (!par)
> +        return AVERROR(ENOMEM);
> +    memset(par, 0, sizeof(*par));
> +    par->format = AV_PIX_FMT_NONE;
> +
> +    if (ist->dec_ctx->codec_type == AVMEDIA_TYPE_AUDIO) {
> +        av_log(NULL, AV_LOG_ERROR, "Cannot connect subtitle filter to audio input\n");
> +        ret = AVERROR(EINVAL);
> +        goto fail;
> +    }
> +
> +    if (ist->dec_ctx->codec_type == AVMEDIA_TYPE_VIDEO) {
> +        av_log(NULL, AV_LOG_ERROR, "Cannot connect subtitle filter to video input\n");
> +        ret = AVERROR(EINVAL);
> +        goto fail;
> +    }
> +
> +    if (!ist->subtitle_heartbeat.header && ist->dec_ctx->subtitle_header)
> +        ist->subtitle_heartbeat.header = av_strdup((char *)ist->dec_ctx->subtitle_header);
> +
> +    ist->subtitle_heartbeat.is_active = 1;
>  
> -    /* Compute the size of the canvas for the subtitles stream.
> -       If the subtitles codecpar has set a size, use it. Otherwise use the
> -       maximum dimensions of the video streams in the same file. */
>      w = ifilter->width;
>      h = ifilter->height;
> +
>      if (!(w && h)) {
> -        for (i = 0; i < avf->nb_streams; i++) {
> -            if (avf->streams[i]->codecpar->codec_type == AVMEDIA_TYPE_VIDEO) {
> -                w = FFMAX(w, avf->streams[i]->codecpar->width);
> -                h = FFMAX(h, avf->streams[i]->codecpar->height);
> -            }
> -        }
> -        if (!(w && h)) {
> -            w = FFMAX(w, 720);
> -            h = FFMAX(h, 576);
> -        }
> -        av_log(avf, AV_LOG_INFO, "sub2video: using %dx%d canvas\n", w, h);
> +        w = ist->dec_ctx->width;
> +        h = ist->dec_ctx->height;
>      }
> -    ist->sub2video.w = ifilter->width  = w;
> -    ist->sub2video.h = ifilter->height = h;
>  
> -    ifilter->width  = ist->dec_ctx->width  ? ist->dec_ctx->width  : ist->sub2video.w;
> -    ifilter->height = ist->dec_ctx->height ? ist->dec_ctx->height : ist->sub2video.h;
> +    if (!(w && h) && ist->dec_ctx->subtitle_header) {
> +        ASSSplitContext *ass_ctx = ff_ass_split((char *)ist->dec_ctx->subtitle_header);
> +        ASS *ass = (ASS *)ass_ctx;
> +        w = ass->script_info.play_res_x;
> +        h = ass->script_info.play_res_y;
> +        ff_ass_split_free(ass_ctx);

This would only work if these functions were made public.

> +    }
>  
> -    /* rectangles are AV_PIX_FMT_PAL8, but we have no guarantee that the
> -       palettes for all rectangles are identical or compatible */
> -    ifilter->format = AV_PIX_FMT_RGB32;
> +    ist->subtitle_heartbeat.w = w;
> +    ist->subtitle_heartbeat.h = h;
> +    av_log(ifilter, AV_LOG_INFO, "subtitle input filter: decoding size %dx%d\n", ist->subtitle_heartbeat.w, ist->subtitle_heartbeat.h);
>  
> -    ist->sub2video.frame = av_frame_alloc();
> -    if (!ist->sub2video.frame)
> -        return AVERROR(ENOMEM);
> -    ist->sub2video.last_pts = INT64_MIN;
> -    ist->sub2video.end_pts  = INT64_MIN;
> +    ifilter->width = w;
> +    ifilter->height = h;
> +
> +    ist->subtitle_heartbeat.last_pts = INT64_MIN;
> +
> +    snprintf(name, sizeof(name), "graph %d subtitle input from stream %d:%d", fg->index,
> +             ist->file_index, ist->st->index);
> +
> +
> +    av_bprint_init(&args, 0, AV_BPRINT_SIZE_AUTOMATIC);
> +    av_bprintf(&args,
> +             "subtitle_type=%d:time_base=%d/%d:",
> +             ifilter->format,
> +             ist->st->time_base.num, ist->st->time_base.den);
> +    if ((ret = avfilter_graph_create_filter(&ifilter->filter, buffer_filt, name,
> +                                            args.str, NULL, fg->graph)) < 0)
> +        goto fail;
>  
> -    /* sub2video structure has been (re-)initialized.
> -       Mark it as such so that the system will be
> -       initialized with the first received heartbeat. */
> -    ist->sub2video.initialize = 1;
> +    par->hw_frames_ctx = ifilter->hw_frames_ctx;
> +    par->format = ifilter->format;
> +    par->width = ifilter->width;
> +    par->height = ifilter->height;
> +
> +    ret = av_buffersrc_parameters_set(ifilter->filter, par);
> +    if (ret < 0)
> +        goto fail;
> +    av_freep(&par);
> +    last_filter = ifilter->filter;
> +
> +    if (in->filter_ctx->input_pads[in->pad_idx].type == AVMEDIA_TYPE_VIDEO) {

AVFilterPad is a type internal to libavfilter; it must not be used
directly outside of libavfilter. Use avfilter_pad_get_type() instead.

> +        ret = insert_filter(&last_filter, &pad_idx, "graphicsub2video", NULL);
> +        if (ret < 0)
> +            return ret;
> +    }
> +
> +    if ((ret = avfilter_link(last_filter, 0, in->filter_ctx, in->pad_idx)) < 0)
> +        return ret;
>  
>      return 0;
> +fail:
> +    av_freep(&par);
> +
> +    return ret;
>  }
>  
>  static int configure_input_video_filter(FilterGraph *fg, InputFilter *ifilter,
> @@ -710,8 +800,15 @@ static int configure_input_video_filter(FilterGraph *fg, InputFilter *ifilter,
>      char name[255];
>      int ret, pad_idx = 0;
>      int64_t tsoffset = 0;
> -    AVBufferSrcParameters *par = av_buffersrc_parameters_alloc();
> +    AVBufferSrcParameters *par;
>  
> +    if (ist->dec_ctx->codec_type == AVMEDIA_TYPE_SUBTITLE) {
> +        // Automatically insert conversion filter to retain compatibility
> +        // with sub2video command lines
> +        return configure_input_subtitle_filter(fg, ifilter, in);
> +    }
> +
> +    par = av_buffersrc_parameters_alloc();
>      if (!par)
>          return AVERROR(ENOMEM);
>      memset(par, 0, sizeof(*par));
> @@ -726,12 +823,6 @@ static int configure_input_video_filter(FilterGraph *fg, InputFilter *ifilter,
>      if (!fr.num)
>          fr = av_guess_frame_rate(input_files[ist->file_index]->ctx, ist->st, NULL);
>  
> -    if (ist->dec_ctx->codec_type == AVMEDIA_TYPE_SUBTITLE) {
> -        ret = sub2video_prepare(ist, ifilter);
> -        if (ret < 0)
> -            goto fail;
> -    }
> -
>      sar = ifilter->sample_aspect_ratio;
>      if(!sar.den)
>          sar = (AVRational){0,1};
> @@ -743,7 +834,7 @@ static int configure_input_video_filter(FilterGraph *fg, InputFilter *ifilter,
>               tb.num, tb.den, sar.num, sar.den);
>      if (fr.num && fr.den)
>          av_bprintf(&args, ":frame_rate=%d/%d", fr.num, fr.den);
> -    snprintf(name, sizeof(name), "graph %d input from stream %d:%d", fg->index,
> +    snprintf(name, sizeof(name), "graph %d video input from stream %d:%d", fg->index,
>               ist->file_index, ist->st->index);
>  
>  
> @@ -966,6 +1057,7 @@ static int configure_input_filter(FilterGraph *fg, InputFilter *ifilter,
>      switch (avfilter_pad_get_type(in->filter_ctx->input_pads, in->pad_idx)) {
>      case AVMEDIA_TYPE_VIDEO: return configure_input_video_filter(fg, ifilter, in);
>      case AVMEDIA_TYPE_AUDIO: return configure_input_audio_filter(fg, ifilter, in);
> +    case AVMEDIA_TYPE_SUBTITLE: return configure_input_subtitle_filter(fg, ifilter, in);
>      default: av_assert0(0); return 0;
>      }
>  }
> @@ -1133,19 +1225,6 @@ int configure_filtergraph(FilterGraph *fg)
>          }
>      }
>  
> -    /* process queued up subtitle packets */
> -    for (i = 0; i < fg->nb_inputs; i++) {
> -        InputStream *ist = fg->inputs[i]->ist;
> -        if (ist->sub2video.sub_queue && ist->sub2video.frame) {
> -            while (av_fifo_size(ist->sub2video.sub_queue)) {
> -                AVSubtitle tmp;
> -                av_fifo_generic_read(ist->sub2video.sub_queue, &tmp, sizeof(tmp), NULL);
> -                sub2video_update(ist, INT64_MIN, &tmp);
> -                avsubtitle_free(&tmp);
> -            }
> -        }
> -    }
> -
>      return 0;
>  
>  fail:
> @@ -1168,6 +1247,7 @@ int ifilter_parameters_from_frame(InputFilter *ifilter, const AVFrame *frame)
>      ifilter->sample_rate         = frame->sample_rate;
>      ifilter->channels            = frame->channels;
>      ifilter->channel_layout      = frame->channel_layout;
> +    ifilter->type                = frame->type;
>  
>      av_freep(&ifilter->displaymatrix);
>      sd = av_frame_get_side_data(frame, AV_FRAME_DATA_DISPLAYMATRIX);
> diff --git a/fftools/ffmpeg_hw.c b/fftools/ffmpeg_hw.c
> index 14e702bd92..be69d54aaf 100644
> --- a/fftools/ffmpeg_hw.c
> +++ b/fftools/ffmpeg_hw.c
> @@ -449,7 +449,7 @@ int hw_device_setup_for_encode(OutputStream *ost)
>      AVBufferRef *frames_ref = NULL;
>      int i;
>  
> -    if (ost->filter) {
> +    if (ost->filter && ost->filter->filter) {
>          frames_ref = av_buffersink_get_hw_frames_ctx(ost->filter->filter);
>          if (frames_ref &&
>              ((AVHWFramesContext*)frames_ref->data)->format ==
> diff --git a/fftools/ffmpeg_opt.c b/fftools/ffmpeg_opt.c
> index 1d6d29cfc9..5a290c946f 100644
> --- a/fftools/ffmpeg_opt.c
> +++ b/fftools/ffmpeg_opt.c
> @@ -2150,8 +2150,9 @@ static void init_output_filter(OutputFilter *ofilter, OptionsContext *o,
>      switch (ofilter->type) {
>      case AVMEDIA_TYPE_VIDEO: ost = new_video_stream(o, oc, -1); break;
>      case AVMEDIA_TYPE_AUDIO: ost = new_audio_stream(o, oc, -1); break;
> +    case AVMEDIA_TYPE_SUBTITLE: ost = new_subtitle_stream(o, oc, -1); break;
>      default:
> -        av_log(NULL, AV_LOG_FATAL, "Only video and audio filters are supported "
> +        av_log(NULL, AV_LOG_FATAL, "Only video, audio and subtitle filters are supported "
>                 "currently.\n");
>          exit_program(1);
>      }
> diff --git a/tests/ref/fate/sub2video b/tests/ref/fate/sub2video
> index 80abe9c905..b53c3d95ad 100644
> --- a/tests/ref/fate/sub2video
> +++ b/tests/ref/fate/sub2video
> @@ -10,7 +10,6 @@
>  0,          0,          0,        1,   518400, 0x83c27b82
>  0,          1,          1,        1,   518400, 0x4051c7f9
>  0,          2,          2,        1,   518400, 0xfb00e17e
> -1,     499000,     499000,  4960000,     1015, 0x19e092d2
>  0,          3,          3,        1,   518400, 0x192abb74
>  0,          4,          4,        1,   518400, 0x4669a88b
>  0,          5,          5,        1,   518400, 0xaababe00
> @@ -58,129 +57,86 @@
>  0,         47,         47,        1,   518400, 0xde69683f
>  0,         48,         48,        1,   518400, 0x7df08fba
>  0,         49,         49,        1,   518400, 0xbab197ea
> -1,   15355000,   15355000,  4733000,     2094, 0x3c171425
>  0,         77,         77,        1,   518400, 0x902285d9
>  0,        100,        100,        1,   518400, 0xbab197ea
> -1,   48797000,   48797000,  2560000,     2480, 0x7c0edf21
>  0,        244,        244,        1,   518400, 0x7a11c812
>  0,        257,        257,        1,   518400, 0xbab197ea
> -1,   51433000,   51433000,  2366000,     3059, 0xc95b8a05
>  0,        258,        258,        1,   518400, 0x34cdddee
>  0,        269,        269,        1,   518400, 0xbab197ea
> -1,   53910000,   53910000,  2696000,     2095, 0x61bb15ed
>  0,        270,        270,        1,   518400, 0x4db4ce51
>  0,        283,        283,        1,   518400, 0xbab197ea
> -1,   56663000,   56663000,  1262000,     1013, 0xc9ae89b7
>  0,        284,        284,        1,   518400, 0xe6bc0ea9
>  0,        290,        290,        1,   518400, 0xbab197ea
> -1,   58014000,   58014000,  1661000,      969, 0xe01878f0
>  0,        291,        291,        1,   518400, 0xa8643af7
>  0,        298,        298,        1,   518400, 0xbab197ea
> -1,   67724000,   67724000,  1365000,      844, 0xe7db4fc1
>  0,        339,        339,        1,   518400, 0xb1885c67
>  0,        345,        345,        1,   518400, 0xbab197ea
> -1,   69175000,   69175000,  1558000,      802, 0xf48531ba
>  0,        346,        346,        1,   518400, 0x378e3fd0
>  0,        354,        354,        1,   518400, 0xbab197ea
> -1,   70819000,   70819000,  1865000,     1709, 0xb4d5a1bd
>  0,        355,        355,        1,   518400, 0xa3782469
>  0,        363,        363,        1,   518400, 0xbab197ea
> -1,   72762000,   72762000,  1968000,     2438, 0x99d7bc82
>  0,        364,        364,        1,   518400, 0xba23a0d5
>  0,        374,        374,        1,   518400, 0xbab197ea
> -1,   74806000,   74806000,  1831000,     2116, 0x96514097
>  0,        375,        375,        1,   518400, 0x129de2f8
>  0,        383,        383,        1,   518400, 0xbab197ea
> -1,   76716000,   76716000,  1262000,     1822, 0xefccc72e
>  0,        384,        384,        1,   518400, 0x19772f0f
>  0,        390,        390,        1,   518400, 0xbab197ea
> -1,   78051000,   78051000,  1524000,      987, 0x7b927a27
>  0,        391,        391,        1,   518400, 0x56f54e73
>  0,        398,        398,        1,   518400, 0xbab197ea
> -1,   79644000,   79644000,  2662000,     2956, 0x190778f7
>  0,        399,        399,        1,   518400, 0x300b5247
> -1,   82380000,   82380000,  2764000,     3094, 0xc021b7d3
>  0,        412,        412,        1,   518400, 0xbab197ea
>  0,        413,        413,        1,   518400, 0x6fd028fa
>  0,        426,        426,        1,   518400, 0xbab197ea
> -1,   85225000,   85225000,  2366000,     2585, 0x74d0048f
>  0,        427,        427,        1,   518400, 0x01f80e9d
>  0,        438,        438,        1,   518400, 0xbab197ea
> -1,   87652000,   87652000,  1831000,      634, 0x8832fda1
>  0,        439,        439,        1,   518400, 0xb48d90c0
>  0,        447,        447,        1,   518400, 0xbab197ea
> -1,   91531000,   91531000,  2332000,     2080, 0x97a1146f
>  0,        458,        458,        1,   518400, 0xcb5a0173
>  0,        469,        469,        1,   518400, 0xbab197ea
> -1,   95510000,   95510000,  3299000,     2964, 0x8b8f6684
>  0,        478,        478,        1,   518400, 0xb8a323e4
>  0,        494,        494,        1,   518400, 0xbab197ea
> -1,   98872000,   98872000,  2161000,     1875, 0x9002ef71
>  0,        495,        495,        1,   518400, 0xc43518ba
>  0,        505,        505,        1,   518400, 0xbab197ea
> -1,  101124000,  101124000,  4096000,     3872, 0x20c6ed9c
>  0,        506,        506,        1,   518400, 0x04e38692
>  0,        526,        526,        1,   518400, 0xbab197ea
> -1,  105303000,  105303000,  2730000,     3094, 0xf203a663
>  0,        527,        527,        1,   518400, 0x856b0ee5
>  0,        540,        540,        1,   518400, 0xbab197ea
> -1,  108106000,  108106000,  2059000,     2404, 0x41a7b429
>  0,        541,        541,        1,   518400, 0x3e5beee2
>  0,        551,        551,        1,   518400, 0xbab197ea
> -1,  141556000,  141556000,  1661000,     1088, 0xde20aa20
>  0,        708,        708,        1,   518400, 0xb8bc1365
>  0,        716,        716,        1,   518400, 0xbab197ea
>  0,        817,        817,        1,   518400, 0x83efa32d
> -1,  163445000,  163445000,  1331000,      339, 0x8bd186ef
>  0,        824,        824,        1,   518400, 0xbab197ea
>  0,        840,        840,        1,   518400, 0x03ea0e90
> -1,  168049000,  168049000,  1900000,     1312, 0x0bf20e8d
>  0,        850,        850,        1,   518400, 0xbab197ea
> -1,  170035000,  170035000,  1524000,     1279, 0xb6c2dafe
>  0,        851,        851,        1,   518400, 0x8780239e
>  0,        858,        858,        1,   518400, 0xbab197ea
>  0,        861,        861,        1,   518400, 0x6eb72347
> -1,  172203000,  172203000,  1695000,     1826, 0x9a1ac769
>  0,        869,        869,        1,   518400, 0xbab197ea
> -1,  173947000,  173947000,  1934000,     1474, 0xa9b03cdc
>  0,        870,        870,        1,   518400, 0x9c4a3a3d
>  0,        879,        879,        1,   518400, 0xbab197ea
> -1,  175957000,  175957000,  1763000,     1019, 0x20409355
>  0,        880,        880,        1,   518400, 0xc9ebfa89
>  0,        889,        889,        1,   518400, 0xbab197ea
>  0,        946,        946,        1,   518400, 0xbaf801ef
> -1,  189295000,  189295000,  1968000,     1596, 0x408c726e
>  0,        956,        956,        1,   518400, 0xbab197ea
> -1,  191356000,  191356000,  1228000,     1517, 0xae8c5c2b
>  0,        957,        957,        1,   518400, 0x59f4e72f
>  0,        963,        963,        1,   518400, 0xbab197ea
> -1,  192640000,  192640000,  1763000,     2506, 0xa458d6d4
>  0,        964,        964,        1,   518400, 0x9d5b9d69
>  0,        972,        972,        1,   518400, 0xbab197ea
> -1,  195193000,  195193000,  1092000,     1074, 0x397ba9a8
>  0,        976,        976,        1,   518400, 0x923d1ce7
>  0,        981,        981,        1,   518400, 0xbab197ea
> -1,  196361000,  196361000,  1524000,     1715, 0x695ca41e
>  0,        982,        982,        1,   518400, 0x6e652cd2
>  0,        989,        989,        1,   518400, 0xbab197ea
> -1,  197946000,  197946000,  1160000,      789, 0xc63a189e
>  0,        990,        990,        1,   518400, 0x25113966
>  0,        996,        996,        1,   518400, 0xbab197ea
> -1,  199230000,  199230000,  1627000,     1846, 0xeea8c599
>  0,        997,        997,        1,   518400, 0x2dc83609
>  0,       1004,       1004,        1,   518400, 0xbab197ea
> -1,  200924000,  200924000,  1763000,      922, 0xd4a87222
>  0,       1005,       1005,        1,   518400, 0x90483bc6
>  0,       1013,       1013,        1,   518400, 0xbab197ea
>  0,       1053,       1053,        1,   518400, 0x3de86ab7
> -1,  210600000,  210600000,  1831000,      665, 0x55580135
>  0,       1062,       1062,        1,   518400, 0xbab197ea
> -1,  214771000,  214771000,  1558000,     1216, 0x50d1f6c5
>  0,       1074,       1074,        1,   518400, 0x8c320e68
>  0,       1082,       1082,        1,   518400, 0xbab197ea
>  0,       1128,       1128,        1,   518400, 0x81e977b2
> -1,  225640000,  225640000,  2127000,     2133, 0x670c11a5
>  0,       1139,       1139,        1,   518400, 0xbab197ea
> -1,  227834000,  227834000,  1262000,     1264, 0xc1d9fc57
>  0,       1140,       1140,        1,   518400, 0xb046dd30
> -0,       1145,       1145,        1,   518400, 0xbab197ea

There is something wrong with this test. All the subtitles are just gone.

- Andreas


More information about the ffmpeg-devel mailing list