From patchwork Thu Sep 30 13:39:09 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 30700 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a6b:6506:0:0:0:0:0 with SMTP id z6csp685061iob; Thu, 30 Sep 2021 06:44:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxj3nXxSYi3JUp7AtXUNxwy7WqHw4D3ZZHHfuH7HI+Mh2IfSTLmb4yhQY9OG9giEuosxbv0 X-Received: by 2002:a17:906:e118:: with SMTP id gj24mr3475569ejb.439.1633009460660; Thu, 30 Sep 2021 06:44:20 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id ia22si3337538ejc.629.2021.09.30.06.44.20; Thu, 30 Sep 2021 06:44:20 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=GcuB3kXU; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id E298D68A852; Thu, 30 Sep 2021 16:43:28 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR02-VE1-obe.outbound.protection.outlook.com (mail-oln040092069099.outbound.protection.outlook.com [40.92.69.99]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 95BEE68A894 for ; Thu, 30 Sep 2021 16:43:27 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kHJwQatpPyTr6Kfn6V3hsmrN9WsL2WFAbJzCTLNAcayCIoFlGp68FsV8D9wj88aeoXs8q/hLBm7adkXbWu1D9v7F/JJF77A4lIy8ElRmruDcbCAIXlydQf9F+w4qZNiDDbZZfpo4lQbZMorzi7QxhVBU36rvbrLKGLDEjNZ4+n4FGiASrkw8etmK83snIhgj0LqjQlPj6riiVnEmexk+QxpzU9jSCJedIl2CTRQs87XA5owG9cwRRKqNESjN/18UCB6oMIdTm1U9FKULfqrb+eXH/bQcSdkZWU/CeuXiWqyTin108OoopMsP3etFOkrbacsbGwITMfEkX8zIx4zwBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=YRGwdGVRomK3nX25LkEGlXRLrYQ5NQslYiwlZVj7Gf8=; b=JJOAZmFCH3nMArzKKC/fdg8SwDO2L17+K03s9W5LsV8LdO5d7qZO2UYP0uPxi4lFFfxeXO4P2CCdB5ecpqp1+IwyI8B2djB36KgYn7oapLc4osKnWvcygFDtgK9uJ7zMmA4Qzvt313R0rs4GV4dturMKyEYqGyfgaOpoZwE/hNqwD4p7kEUjyxYmxzOuXNrwvxAFzgiPdaSszhs1aMAp1Fd0+GEMGztNl3ijvhTydo4fFV0pgVSxvz5YvES9QRP55kBiWIX4XDfsTHhlTNz2j2Kpxe2TxtdDGj8F7C5xPQMkK5bGmYQA0nhadzSsjVOv5yHETV8lX2uGZwcioXX3lg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YRGwdGVRomK3nX25LkEGlXRLrYQ5NQslYiwlZVj7Gf8=; b=GcuB3kXUwDdrKeQx6G2/GeLLGAI0w/l0Z0ii/JXOZZM2AMUrg0OVSD9w0NheQXv1lNgZ2ePcNBEqjg/YrxZZgKp34VD4BrRsVn3HUP1MI/S41NlG9k96nb6xhHcrOkbzoU3rktlfl0UhTc97rFoojNk3YWmm7TlkUzTO+fXhxgm7KFU0jS54HBSIIgx9IPIY3QmX37FoZ+irgm9V+PdIhF8bjw7CWoJu1S8HiRY/aFLC8QpMTgWaW3K1pg6OnBy9J6H7thT3hQQtoJGrlU4I0n8Q3tuE5VOfRM2YwXwTDCSwhiWxBPYkFFcCU2Yz40O9MfATj7v8CxMX9Zt5xhRW4Q== Received: from PR3PR03MB6665.eurprd03.prod.outlook.com (2603:10a6:102:7d::6) by PA4PR03MB6847.eurprd03.prod.outlook.com (2603:10a6:102:eb::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4566.15; Thu, 30 Sep 2021 13:43:26 +0000 Received: from PR3PR03MB6665.eurprd03.prod.outlook.com ([fe80::15d4:ff2d:e607:cf68]) by PR3PR03MB6665.eurprd03.prod.outlook.com ([fe80::15d4:ff2d:e607:cf68%3]) with mapi id 15.20.4566.015; Thu, 30 Sep 2021 13:43:26 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Thu, 30 Sep 2021 15:39:09 +0200 Message-ID: X-Mailer: git-send-email 2.30.2 In-Reply-To: References: X-TMN: [WyN5qmx1JiNpVMib4CXDE4aajMWS7p6K] X-ClientProxiedBy: AS9PR06CA0306.eurprd06.prod.outlook.com (2603:10a6:20b:45b::15) To PR3PR03MB6665.eurprd03.prod.outlook.com (2603:10a6:102:7d::6) X-Microsoft-Original-Message-ID: <20210930134239.2672698-7-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from sblaptop.fritz.box (188.192.142.38) by AS9PR06CA0306.eurprd06.prod.outlook.com (2603:10a6:20b:45b::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4566.15 via Frontend Transport; Thu, 30 Sep 2021 13:43:25 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 9face8ea-1063-4e1f-880f-08d984184758 X-MS-Exchange-SLBlob-MailProps: gjx25WM8ZNVNZLmtPNeeDNv1jHth/FTeFbSiUZn3s0ZJTXVNLfSoV2DbeCHtoNfXRt9yL9wC4+hV4TRsMdcKKesgN6/ilw/9aTHOANfIcV0R/5ddNkxXTfo8yhAofGEo4otM3eQAcPmgwQNgSc8BJL8VOayuXJZ9VhRakAUJEZb/SQEbnNt0202qXwoXuqayJj2nneZUeZLCEujm/5bLPm5TuBhSjVep0GCF+sDqmbvL5xzjz41gjYLpeywmjvouk1yEYUH+7JkG+bjRXLd9dgHm/GtQijdW0EcHH9fqPrG4b7xvCtDGBvBqk0ygoDEiT0t0nPfi+YzyLp/H1MSWpF05IoYiAc2Xyj91oYoEX7c+tDVBulKlmTEKkYcHotEq9xK2YReVnm6/1XM5eOTzLtj17oiJ2h/A+cPGQQ0PWUbgM0LkJwSpUnbzngSQyhyd0ykCS1hi5iRPWu3sjWYRajc3rq5GnAxcQKygGnADZyxJAzTQRd4mROulNnmT/wT3kxoTv1L+vRx34DwzDrNxJVRSvveyj9GFWEVP4EZDdtFoojONMpoId01EtoAgnlpbxrDO0wnakYOPCQhXHxwqUk/Q/R+DaPfLkkzTibrz5E5yevKd2sFZFyIKTFpLlcImwVL9zoIPcC7gaPJzRKVPBehb8Gz79RQeqETvzo7e3ux9ODZl8MF8lTFB9w2QGxMll3mI12zzp4bGJJbeDd8suHg0HapuI6N7o2vtMveSHVg= X-MS-TrafficTypeDiagnostic: PA4PR03MB6847: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: zWdKm3vRgJNFWL2Ui6BGWMZwoUadzj0ENAxRYZ/UUg2/ycjlAxuPJ2n5JvRO68AJyfMRluQo8XdKqvP+ZtjPyWvKzKSZPj9v/1MyWjgJd9vlvHjWI1dBHSi6MeFyUxgugJnMP757OPBWECjIztf4Q3UQrLxw91S19pXBbK82/LUOCa69aT9jIrU7wJphUM1+ilwsTKRz1NFBHDvJCEFYWWvV4MbvFwEHNnw1CYScQk3yZy602o3GfNHlsmCaLR3uXaWqRJWHSAgTle+l5nYMeHZgoKvbwLrwZNmzB4qg70tnCGPVCQK7wjrRhaBN8Q7DRdVB3aR9ITFQ1o/ZUbSaT/bK10MuJ0tn7QceRkbh3J66Zgx42qOyUm7TSG927dPeb4/hB8BODk1uP88AjTs9Y7Tp7BYlFHLYWD91OnBI6+2XSi6lXH3GVYQQ5nGfIaYL X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: XbBwsS/H5XheiRg8qIfupO/Fry/L6YQwbQMSriECP6vYNtJLyfGoKp15K7sxhoso0oITJjjC0VZQ7EX7Rd4lsYgAgmLvhK5XmPoLyk+tg59wT6dUftoTgIc89/HKGdbEbZVrpLtgzrb85iZ9jtw/IQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9face8ea-1063-4e1f-880f-08d984184758 X-MS-Exchange-CrossTenant-AuthSource: PR3PR03MB6665.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Sep 2021 13:43:26.2832 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: PA4PR03MB6847 Subject: [FFmpeg-devel] [PATCH 008/218] avfilter/af_adeclick: Store format in filter, remove query function X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 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" X-TUID: 9DIuC6CQpfF3 Signed-off-by: Andreas Rheinhardt --- libavfilter/af_adeclick.c | 23 ++--------------------- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git a/libavfilter/af_adeclick.c b/libavfilter/af_adeclick.c index f9404b2a4a..77336e50bb 100644 --- a/libavfilter/af_adeclick.c +++ b/libavfilter/af_adeclick.c @@ -113,25 +113,6 @@ static const AVOption adeclick_options[] = { AVFILTER_DEFINE_CLASS(adeclick); -static int query_formats(AVFilterContext *ctx) -{ - static const enum AVSampleFormat sample_fmts[] = { - AV_SAMPLE_FMT_DBLP, - AV_SAMPLE_FMT_NONE - }; - int ret; - - ret = ff_set_common_formats_from_list(ctx, sample_fmts); - if (ret < 0) - return ret; - - ret = ff_set_common_all_channel_counts(ctx); - if (ret < 0) - return ret; - - return ff_set_common_all_samplerates(ctx); -} - static int config_input(AVFilterLink *inlink) { AVFilterContext *ctx = inlink->dst; @@ -760,7 +741,7 @@ const AVFilter ff_af_adeclick = { .uninit = uninit, FILTER_INPUTS(inputs), FILTER_OUTPUTS(outputs), - FILTER_QUERY_FUNC(query_formats), + FILTER_SINGLE_SAMPLEFMT(AV_SAMPLE_FMT_DBLP), .flags = AVFILTER_FLAG_SLICE_THREADS | AVFILTER_FLAG_SUPPORT_TIMELINE_INTERNAL, }; @@ -796,6 +777,6 @@ const AVFilter ff_af_adeclip = { .uninit = uninit, FILTER_INPUTS(inputs), FILTER_OUTPUTS(outputs), - FILTER_QUERY_FUNC(query_formats), + FILTER_SINGLE_SAMPLEFMT(AV_SAMPLE_FMT_DBLP), .flags = AVFILTER_FLAG_SLICE_THREADS | AVFILTER_FLAG_SUPPORT_TIMELINE_INTERNAL, };