[FFmpeg-devel] [PATCH 7/9] avfilter/vf_subtitles: Remove obsolete LIBAVCODEC_VERSION_INT checks
Paul B Mahol
onemda at gmail.com
Fri Sep 11 12:18:49 EEST 2020
On Thu, Sep 10, 2020 at 11:48:59PM +0200, Andreas Rheinhardt wrote:
> libavcodec major version is already 58.
>
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at gmail.com>
> ---
> libavfilter/vf_subtitles.c | 10 +++-------
> 1 file changed, 3 insertions(+), 7 deletions(-)
>
ok
> diff --git a/libavfilter/vf_subtitles.c b/libavfilter/vf_subtitles.c
> index a045375b2d..08b4d4efca 100644
> --- a/libavfilter/vf_subtitles.c
> +++ b/libavfilter/vf_subtitles.c
> @@ -396,8 +396,7 @@ static av_cold int init_subtitles(AVFilterContext *ctx)
> }
> if (ass->charenc)
> av_dict_set(&codec_opts, "sub_charenc", ass->charenc, 0);
> - if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(57,26,100))
> - av_dict_set(&codec_opts, "sub_text_format", "ass", 0);
> + av_dict_set(&codec_opts, "sub_text_format", "ass", 0);
>
> dec_ctx = avcodec_alloc_context3(dec);
> if (!dec_ctx) {
> @@ -465,11 +464,8 @@ static av_cold int init_subtitles(AVFilterContext *ctx)
> char *ass_line = sub.rects[i]->ass;
> if (!ass_line)
> break;
> - if (LIBAVCODEC_VERSION_INT < AV_VERSION_INT(57,25,100))
> - ass_process_data(ass->track, ass_line, strlen(ass_line));
> - else
> - ass_process_chunk(ass->track, ass_line, strlen(ass_line),
> - start_time, duration);
> + ass_process_chunk(ass->track, ass_line, strlen(ass_line),
> + start_time, duration);
> }
> }
> }
> --
> 2.20.1
>
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request at ffmpeg.org with subject "unsubscribe".
More information about the ffmpeg-devel
mailing list