From patchwork Sat Sep 11 23:40:42 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 30157 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6602:2a4a:0:0:0:0 with SMTP id k10csp2757663iov; Sat, 11 Sep 2021 16:43:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzWuTRAFut24WTn2Px4uTQbXjeSiA4jc/3bdpKPbjt19G2/WQPOVIn32uiO9/s2cXQdUrPi X-Received: by 2002:aa7:c7c2:: with SMTP id o2mr5348871eds.166.1631403821953; Sat, 11 Sep 2021 16:43:41 -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 a3si3202131edn.396.2021.09.11.16.43.41; Sat, 11 Sep 2021 16:43:41 -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=a9S4cVDl; 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 8EAB268812E; Sun, 12 Sep 2021 02:41:55 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05olkn2068.outbound.protection.outlook.com [40.92.91.68]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 8AABA68A8B1 for ; Sun, 12 Sep 2021 02:41:42 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AEEo3jGbQ4QDuFSCSR9tBC4OwUklWhYQNJ0/h8jYeyi/Dgy8qI2AeaqeWHaiQ1owsR9Y7OltYEebtX26bpPuiCoP8jGBvdnludEequT7Ap1EdUeI/PkUO6bNyR/YfbVwVvtt4MwbUkq3xdOAEgL7ilW3Hq9VV++g64OJSt2dz/rNEnczbZylCf8SlqfJRZzrDMhvP6OzBVDWUhD+7964QDU117UOtxCzshSBDSkbyZdCP2LMET6EltuR91u/i+4OzugKYbIkKPxbqEqptGVYiajNpqu+n9ZUap11vhFSohngk1ycc/pkIumhBwirE5YafK8hCz20MUYPXJN/fno2Pg== 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=s+f8Lctp0hirB387MLMZmdYWBuGn0vDUFWXbNs0zoGw=; b=Z6HmZozm4NB3zmpDNWUG9Sh+dyQeLnV+Ta95pr2MGp30lckMKuXzOsmblx9bxE+Yh00OiJpVSMQLj7LUtoRcA/jZj1EsjMKXZwAqaXG+1+/PP74GBxnbD/T2BhiU7VL7HhnDpZy5s8rkVHDiTexxCSo4LR5H9vyOpJEwM59TeVAiLeZWFazEEiqLFbX3RhJkCu7tPmRREwGmMhmlwBvQPB5yXfBrxzwUgp4DHVmLTUuGQusF6fpZWGuoYPqCf3u0+UsgMumxdF5zIqOLw2nQRDkMAzp5iQdctMcq0dF5o4EaRCeuVPx4EKJ+TtxGbQZQhx1wRFWFuO0SWBd3Rq5OBg== 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=s+f8Lctp0hirB387MLMZmdYWBuGn0vDUFWXbNs0zoGw=; b=a9S4cVDl+8GkLQrKxw9CwQ/HS/jjEDIY2Gti7gG2vsmwfbRobK7/ADoM8OC+SKTzfOuh8Dl7MTtP++SxlwSCBAjVvocZQjutRPYH3j9ZaffPQ5RXe84uQKeofFdE7SR0L+4qD5M+mZNIuoSj0wyMD+2sxRklNgcjTBdu5QzXVcEGh3IAWmpfxjJK3z1j4v7+BeZhnmzPw7H/EhLRxoP1In4FlC0j6+WUZAAx00Ss/uIiUaLUyKkgDB2PhllIgOAfJ///RlfYS7FDsmYJIBJvUMWCT/tby5cShQhc1nfT1yM9iuquVhr58a9MH52rHt3lOZBijoF+XRVUHL9FMraEmA== Received: from AM7PR03MB6660.eurprd03.prod.outlook.com (2603:10a6:20b:1c1::22) by AM6PR03MB5047.eurprd03.prod.outlook.com (2603:10a6:20b:89::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4500.16; Sat, 11 Sep 2021 23:41:34 +0000 Received: from AM7PR03MB6660.eurprd03.prod.outlook.com ([fe80::787b:2156:ca99:fe00]) by AM7PR03MB6660.eurprd03.prod.outlook.com ([fe80::787b:2156:ca99:fe00%4]) with mapi id 15.20.4500.018; Sat, 11 Sep 2021 23:41:34 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sun, 12 Sep 2021 01:40:42 +0200 Message-ID: X-Mailer: git-send-email 2.30.2 In-Reply-To: References: X-TMN: [VxrhkgAP0FbsyvgWV9NEZ7SfadimszGA] X-ClientProxiedBy: AM0PR05CA0088.eurprd05.prod.outlook.com (2603:10a6:208:136::28) To AM7PR03MB6660.eurprd03.prod.outlook.com (2603:10a6:20b:1c1::22) X-Microsoft-Original-Message-ID: <20210911234109.2246196-11-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from sblaptop.fritz.box (188.192.142.38) by AM0PR05CA0088.eurprd05.prod.outlook.com (2603:10a6:208:136::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4500.14 via Frontend Transport; Sat, 11 Sep 2021 23:41:33 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 8567db5d-904a-42ea-a5b0-08d9757db044 X-MS-Exchange-SLBlob-MailProps: gjx25WM8ZNVv/2++Uk5pM+AmDHCluBYMksTRFWjkHU2ce/cyBvv6mOmmQQZy/u/7qw84/9E1NEbzCGw3fGfqW8kPQkCKELOQ4tpWH0WjXw/JKhKF6+w65rWqiGhkZSCpuKPUAt2JgeMMJF8n8RN8FmkSN7ymPfPI+CmBpLjMQhgapkYf+nbt75QJkKcAZd3ckSsaPh8Hdw2HXas5DFnrYnhRx/z2z6hGKMW9LNWFO+JToannOOiR8cZ1AzI7P8y2uJf6h1iNX3xaE3YhO4rWl+VxtXCkcmGEzV9j6xQz3HzI0sVOlt4W8w2CuqhsV6yLq/2RkYN6XB+mXUb5FPlgviS+j95B//rq9hY7UuF/AS6+/900B4JUE8ltMIhtINKQMjUpbmpYNjNcCkei4VBwSQHVIgTHUhYdEaP8IAemxqtAHdfdCrli0Bqhk3Llh2+44VrYhQBCSNSuQ4GY2G6FjNpfNQm4AtsDK/6nGNOz8WwppZCWxqAuR1kKA9bMSPNG/6JbWkqLd1mwd6JcIMJbf2qL8EIXIJjJL9OnRR/qV6v6r2bo2ibTEVfU0VP6rrwK/4N2jco3n2nDJTZs8dZ0N9LlZ3/b7ZVW3CWIQvUP2klzn9gqHUffCROFZD04qyKeQ/h0ewlc1BxCnKms5uRM7ijwKN+Z5X+33X2L/UOLdsohJdWELAE16SecaITwBjS0rqmxZlEeQ8Y6Q8eeLkm39IUBTQbcyXx1VZRPKx5oZqo= X-MS-TrafficTypeDiagnostic: AM6PR03MB5047: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 3EM1AOWguhvTQW6OohwxkYMfK90naDmG70uQz+Hmjg9ErposdeBZfAimqPT7szOpGHAC6VQUhN61yni+k28sEKYMW1vzZQhSUtFdp1xXrqEIgvRZQuDJHvxF0DBjOMuvsTTe0xahAb+5V3JsotxjpZOeK1IX6Vliq3ZKGTJtKTGF4DTFGbOd9QK2yG0BPF4j223o7SbNo5cbv4lDsRkP9HY8QWfNb3vlNrQ8WOk9vnEX0MwxU36ktZAYH8YW7V1WT2zqBaGogb0CliiAGgGvQyIeRfXFvToKUOtPi823ALJDKqf8tpftvngvkzYm4wMEHUNXx/rkgVoPtuPKSc8Whqy+uPIptTULS73c6OW3EIKG/Hykq3WpEuZSeh5EvTnoofUBk0TTBxllqvwUX6eLoE7eTBKoZ5Yb41ceB2exb40Qr5Sst4Pd0TqTB8dawE3g X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 1o16BdBiirq9stN9yM1WCLB/cRPNzcQtvALWAf0MjG+hyNyfbRSY1Wy+TWLH7OHXHNjgne72wFxCxevFz51WL2fmEDzMvteu4J0OreT/WbAPUh1rtgBQBCzPtBXsVbOIsd+wUdcg2oJj9W41T7D0Lg== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8567db5d-904a-42ea-a5b0-08d9757db044 X-MS-Exchange-CrossTenant-AuthSource: AM7PR03MB6660.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Sep 2021 23:41:34.2856 (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: AM6PR03MB5047 Subject: [FFmpeg-devel] [PATCH 12/39] avfilter/f_perms: Deduplicate AVClasses 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: gkZGroyB2NFa Signed-off-by: Andreas Rheinhardt --- libavfilter/f_perms.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/libavfilter/f_perms.c b/libavfilter/f_perms.c index 8c449fbdfc..470db45bee 100644 --- a/libavfilter/f_perms.c +++ b/libavfilter/f_perms.c @@ -111,10 +111,9 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *frame) return ret; } -#if CONFIG_APERMS_FILTER +AVFILTER_DEFINE_CLASS_EXT(perms, "(a)perms", options); -#define aperms_options options -AVFILTER_DEFINE_CLASS(aperms); +#if CONFIG_APERMS_FILTER static const AVFilterPad aperms_inputs[] = { { @@ -134,20 +133,17 @@ static const AVFilterPad aperms_outputs[] = { const AVFilter ff_af_aperms = { .name = "aperms", .description = NULL_IF_CONFIG_SMALL("Set permissions for the output audio frame."), + .priv_class = &perms_class, .init = init, .priv_size = sizeof(PermsContext), FILTER_INPUTS(aperms_inputs), FILTER_OUTPUTS(aperms_outputs), - .priv_class = &aperms_class, .flags = AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC, }; #endif /* CONFIG_APERMS_FILTER */ #if CONFIG_PERMS_FILTER -#define perms_options options -AVFILTER_DEFINE_CLASS(perms); - static const AVFilterPad perms_inputs[] = { { .name = "default",