From patchwork Thu Sep 10 21:48:59 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 22269 Return-Path: X-Original-To: patchwork@ffaux-bg.ffmpeg.org Delivered-To: patchwork@ffaux-bg.ffmpeg.org Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by ffaux.localdomain (Postfix) with ESMTP id 220BE44B1C3 for ; Fri, 11 Sep 2020 00:52:01 +0300 (EEST) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 12F5B68BA04; Fri, 11 Sep 2020 00:52:01 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-wr1-f65.google.com (mail-wr1-f65.google.com [209.85.221.65]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 8864268B9F3 for ; Fri, 11 Sep 2020 00:51:58 +0300 (EEST) Received: by mail-wr1-f65.google.com with SMTP id o5so8876044wrn.13 for ; Thu, 10 Sep 2020 14:51:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=7xtSx6YDHBbC6JiyqqWI22xbD9c/AUnu8JniQLhTYVg=; b=i/eCf2LuOw2RTDLFz2WQn5m6WuEPlCwJgPP0/5VDCx18QZasuqCt/j7ChxvN4Sw2RO hau/OkCRMcH7S2FIC4AzyJlv/1ysaIHWuoAZcZRe77y+fDwa7UHtVbD7mkWMURc+y/Vs xWp3XXzlr+vAHKtLNpBjweciLHY4PjRFoNlUMIvuWnfOnAoVnAFQ/srXyzOrj9bk5Kdh f0NZLzPZWX74lA91gjmlw5vlwKIZOZTQw4LxQj+R9fu1FznzNmb531Txz999y1sDMT4/ x1AiE7W+GY+TuEMfNUnJYsZgZH1P43I94wSEULw7lVuuCoFp2XVH/9Tm/rxAi1Ow8XlE IeQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=7xtSx6YDHBbC6JiyqqWI22xbD9c/AUnu8JniQLhTYVg=; b=O1SwqaBEQ5FN/3NS7R3g4WinaP6kY6JpSZyw+EhpENukDOUkMYO9vQghIDb9pkhOxe JAHzXxRXZBr2J5HwzQ+pwHJGcXC+JngRLBzrwwwt6McIuFEGNhGrxVtU3+5LFF6TObRu dYgXolrY/wSJnU/eCsfy7/XkX195IXWn7+tAU3GL6+hyFuP1bqjgc0ITrdjtc7c5cv+M kl4P3G7Q6+0RjjhIfNwMdYa5nWwI+zk7Dmej6xv0cEGvptZvoA2RARVjkKSQScqZDNDE POw5bowCA3+NqpfUQk+4Nky1QaNCu07s5VPNMelnoKMAYpxLk5ZWG/bFK92ZMMimpvgo R9Jw== X-Gm-Message-State: AOAM5303ajZRcf/F6nxoT+6qgtZhiSwCzL+437oLkLMCHzx7o1HeUzhG CCUQ5ey7ccBQsjLBoQ5KMr7yqX92wqc= X-Google-Smtp-Source: ABdhPJwUQ3Gms/GTJzoI0ZFNHYI91YiitX56WtW9H/m0QKIiKNkkXhnVhnr9GEqupb4T6V+2QTl9oA== X-Received: by 2002:a5d:4645:: with SMTP id j5mr10003610wrs.388.1599774717809; Thu, 10 Sep 2020 14:51:57 -0700 (PDT) Received: from sblaptop.fritz.box (ipbcc1fb0f.dynamic.kabel-deutschland.de. [188.193.251.15]) by smtp.gmail.com with ESMTPSA id z203sm59232wmc.31.2020.09.10.14.51.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Sep 2020 14:51:57 -0700 (PDT) From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Thu, 10 Sep 2020 23:48:59 +0200 Message-Id: <20200910214901.25401-7-andreas.rheinhardt@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200910214901.25401-1-andreas.rheinhardt@gmail.com> References: <20200910214901.25401-1-andreas.rheinhardt@gmail.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 7/9] avfilter/vf_subtitles: Remove obsolete LIBAVCODEC_VERSION_INT checks X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" libavcodec major version is already 58. Signed-off-by: Andreas Rheinhardt --- libavfilter/vf_subtitles.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) 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); } } }