Message ID | GV1P250MB073730C38ACEF9DD78C806178F012@GV1P250MB0737.EURP250.PROD.OUTLOOK.COM |
---|---|
State | Accepted |
Commit | 8261d5d38c93419535dbd81116fc1d065716e039 |
Headers | show
Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:24a8:b0:1a3:b6bb:3029 with SMTP id m40csp2146916pzd; Sun, 7 Apr 2024 14:09:55 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCVoEbwN63+HKe7q7gH4d8ljRhwRA2u0L8PEhTtJrPKSnZwKo+QmKMnMadQDfUX3CZbK9bd3HkwaFdH/Uo7NrC3gt6iE8w0LM/iwgg== X-Google-Smtp-Source: AGHT+IFLQj5U0081BGqlVND78k0tShwhd8L5MQXoqFGlQ0APuk3IqWP2MTrliwjchPCphnhr+iJq X-Received: by 2002:a17:907:72c2:b0:a4e:4ed4:5efb with SMTP id du2-20020a17090772c200b00a4e4ed45efbmr5790930ejc.3.1712524194956; Sun, 07 Apr 2024 14:09:54 -0700 (PDT) Return-Path: <ffmpeg-devel-bounces@ffmpeg.org> Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id gb40-20020a170907962800b00a51c45d1273si1443485ejc.890.2024.04.07.14.09.54; Sun, 07 Apr 2024 14:09:54 -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=GMs545qV; 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 3C84F68D1C4; Mon, 8 Apr 2024 00:09:47 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01olkn2043.outbound.protection.outlook.com [40.92.64.43]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 3238D68D14C for <ffmpeg-devel@ffmpeg.org>; Mon, 8 Apr 2024 00:09:40 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=gRapEH2PODIO/NN5M0iYfOI9Qtak7K4jKgiutloMKPr+e60KThU0XCHyb0ZA/1R0K+T2JHE+roxXHnV/uDrvWuntzStRoBzDf2K6zLXcipsUJmMI02zlxuMIjDCUNVBzUflJbj9IbivAqE1+IognY56cwwTY2hsweY4JZ4F3E1zjW1duqtLYM2LDdsbiSIy4YHsanifQfel15Bu5R9F0ysoYC2rt9o9fT9WBo7HU5ZNtuYSwPoRixAj7dn09CG2xD2w1+Gu2opft7fFDhJbWNUho2bBAOdqQ4uFNhrPRN0A3iUxlXMSnOMY2L1vq7xfNAWqGRkNKQ+kJELFFRQjRSA== 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:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=JrAWIpK+Xvx+SRayBmMokI1Hh9Qov2BEG5mz8rMAs4I=; b=Rxq16FNZcwWYo2UF9Q1rnxwzQ17nAvq+czBixGnVUkUhHwHT2i2KjBBt2kevYsbT2dhrNeAx+vebbSctyarwmMCqGal8WT29MscloUxR1LxAYhIOMCEduEq0YUowia6F+XSkVoKy2ylxkY/7/86vaxml9Pku1zRm2PdI5wbcZQT77ja8lTIviS8HVG3itWrNBw/XFoZTEiYYmg57F2Y8uJCbDyvWC0STYi7PU7gvv4DWNdHqJFWZ19hyIpqFSkQDeJFBxnIZ8F8AueEakuEkuKOjrJxrfh1vLM2Kh6cNw1RWnI0N4QwXZWmwZ079L4pc/b03V+G8WhOOWCAgMfieLg== 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=JrAWIpK+Xvx+SRayBmMokI1Hh9Qov2BEG5mz8rMAs4I=; b=GMs545qVPq6yyMluB5VNwjKoij5BCpIA8LF9K9Z3IO2RuZ5CdNxhO89wDnfME0KNlbmbEMsltPxMsKBM3jso8/TtgO0+Ou2sW174mcey/FlDRPanDzyy/eMm9+ngs4cIMvcJfCe6aL8wnRhCPFnsl+/fO1pdeLurCi7PG2GBKel7Tql/L7FMNANXZTl7FIpfbM8PC4b9qeuEo11GexUZggkaQ5ZtF01TAsXSWv9MOJBHkd/nzkE7ppIGLkIR/3iA/XVt837sbtOuD72x0LHsaLobRWeJY4IyqaX1m71elmoMtTxCMfEUreeXIoFckd2g2j2SPyOo0RxFiV8DRbR8LA== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AS8P250MB0234.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:379::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.55; Sun, 7 Apr 2024 21:09:34 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7409.042; Sun, 7 Apr 2024 21:09:34 +0000 From: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> To: ffmpeg-devel@ffmpeg.org Date: Sun, 7 Apr 2024 23:09:02 +0200 Message-ID: <GV1P250MB073730C38ACEF9DD78C806178F012@GV1P250MB0737.EURP250.PROD.OUTLOOK.COM> X-Mailer: git-send-email 2.40.1 In-Reply-To: <GV1P250MB073758D71A50C11C0A3C26CE8F012@GV1P250MB0737.EURP250.PROD.OUTLOOK.COM> References: <GV1P250MB073758D71A50C11C0A3C26CE8F012@GV1P250MB0737.EURP250.PROD.OUTLOOK.COM> X-TMN: [2mBluIW1Qn1yCl8KJ6moi1/lKuARjmar] X-ClientProxiedBy: ZR0P278CA0038.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:1d::7) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240407210915.895619-3-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AS8P250MB0234:EE_ X-MS-Office365-Filtering-Correlation-Id: 4a8fb6ce-58f6-40cf-d915-08dc5747065d X-MS-Exchange-SLBlob-MailProps: quCBMN2EvO+2u7sZ7OSLhMIkTSfckR5Uyku0MLan1FsCZgvY8Qx2X6bnK/25h/N+I97GZvPwmbslPlx8CJOYkG128KktNJzdh3mAiiYxR6pOfeIy+1SPV4JluDHxBLKapg4scSkaPSFJzQGmKuH73+GVBGpjHsqB9oOzwY6ov5JPgawjbapAx7I3tCElicRntym2d+62pG9eHmbfmNxtCTS9lWL2pL1nFWH2LSKjBwVW2of2HTg1B6I0z6xCwucz4hMVhxvCjpi6XeYhOG2okqebZJKQ8RhrJVSkOwx61qQtVWqLWQBzakHGfroyu+PCxX3yEG1jE/Q7zYFwvhDj9x7zRcvdnEOZ0EkZSDBMZABwKi/JKfKyXxaR/AfajpvrZzlQRCTi1ytfTeIl53YzpjuwM9RplrmIo1N6yvOpSMv+OR2kam9+sGXGqsLyWcEaI0HCoTnKrA+2j0nAFvYnuFT1r+0ajiZmbJ+zsRX2GFEeESCSpzEMNC3kaTc/WGH+A27qPbAcT/tdWTW85RykWkgCg/F02oJualksA/yO5paUYC31z+nBVfMIOpLRyk+vlRMajFy3/naVu9Ki0zJ07rm4m3NgzHYQQS7QgomWRGOQtKBZgBUHBaLHFxBXLEg3Rdq95hGUSe/Fo3wU39XhLvvjdjaoK7IRnG/p+bhQrdupiROY70pGElwoeVd5OYduLX7nyRLl/dCgJxtM004Ijw== X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 9AMBJC8Pnz9W+9WVYSk645Ay7p7zTKycvSTPZUuIcqOhVOdf4SD9F9NUrFxM+W74faFzFtGshC24rTyMLAPM/XFbFUrneQNCzljCbBCWxOgqAOa5q1knxF7fB9ECnd5JVu3miEy/22IUD1Qh24Ivkhg2d2OSnmpVRCW2zdnPePkHVWWtcOJMXafh6TXBX35sjVY3ZEltgM+qHYVMqfRr4rgTVeMMwFYNVziCORh50lQh0Z1BW9DMjcKCfxlxs/V94d6AeDDtIY5uUTWBw6VlqB7iP/vQo+w1gbSW99x7kd2bRJBiOaRLLr/iNFrQK84OcRhw5KpUv7k33I3DYuHPpYZI6q2jH/qvASQ2i1/n+MiDu4I72K0K7P/KWPkrr5d1IT6alxMIsfXCaMAJsBv2IB1GR01va/dnxzsTI2rpFcufllFjHaNf+JbT+y+//l5o0WfkYPf+H0fnA6jJ5YrdKoJRpI+ln3picEjT75Bw7ztJzMsEOoPLP1KcaeoYAoaeQ44dwyKWOGNdTwlexpRqswSjDc5L1XtaoZRHB2QBSYQez3dYV5qZaDXZY1frj5W5lmIjCyCRYH6BUGFOeKP/CnWOiaSH/Jf6ZVOGxbc6LYVfABq9aVxWZRp06z1+SXLC X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 5YAH9GIoQQ95X1JbfAYxVeHLDEf0FNhlTeZLZB5MD0NL72RcdDm3QOHbqtzJ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jLqyRbECOKGHhr+NN7JXeisvW6g/idtRAU65kccIojnURMK4stQdoFm58Om4z07Y+olp8ZlABChkM+CbVijPFr3lFMrK5ezqa+DO9dkezSOeMWPi5825ew3IQk97GyW+N586Ymj4mo0anM015cMms9l0wnVm/7iHA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4a8fb6ce-58f6-40cf-d915-08dc5747065d X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Apr 2024 21:09:34.3106 (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: AS8P250MB0234 Subject: [FFmpeg-devel] [PATCH 04/17] avcodec/ac3enc: Use bit-operations for bit-mask X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches <ffmpeg-devel.ffmpeg.org> List-Unsubscribe: <https://ffmpeg.org/mailman/options/ffmpeg-devel>, <mailto:ffmpeg-devel-request@ffmpeg.org?subject=unsubscribe> List-Archive: <https://ffmpeg.org/pipermail/ffmpeg-devel> List-Post: <mailto:ffmpeg-devel@ffmpeg.org> List-Help: <mailto:ffmpeg-devel-request@ffmpeg.org?subject=help> List-Subscribe: <https://ffmpeg.org/mailman/listinfo/ffmpeg-devel>, <mailto:ffmpeg-devel-request@ffmpeg.org?subject=subscribe> Reply-To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org> Cc: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" <ffmpeg-devel-bounces@ffmpeg.org> X-TUID: Hwm6c9RoHMxD |
Series |
[FFmpeg-devel,01/17] avcodec/ac3enc: Don't presume ch_layout to be AV_CHANNEL_ORDER_NATIVE
|
expand
|
Context | Check | Description |
---|---|---|
yinshiyou/make_loongarch64 | success | Make finished |
yinshiyou/make_fate_loongarch64 | success | Make fate finished |
andriy/make_x86 | success | Make finished |
andriy/make_fate_x86 | success | Make fate finished |
diff --git a/libavcodec/ac3enc.c b/libavcodec/ac3enc.c index 1a65e35161..31b9474822 100644 --- a/libavcodec/ac3enc.c +++ b/libavcodec/ac3enc.c @@ -2199,10 +2199,8 @@ static av_cold void set_channel_info(AVCodecContext *avctx) s->channels = channels; s->fbw_channels = channels - s->lfe_on; s->lfe_channel = s->lfe_on ? s->fbw_channels + 1 : -1; - if (s->lfe_on) - mask -= AV_CH_LOW_FREQUENCY; - switch (mask) { + switch (mask & ~AV_CH_LOW_FREQUENCY) { case AV_CH_LAYOUT_MONO: s->channel_mode = AC3_CHMODE_MONO; break; case AV_CH_LAYOUT_STEREO: s->channel_mode = AC3_CHMODE_STEREO; break; case AV_CH_LAYOUT_SURROUND: s->channel_mode = AC3_CHMODE_3F; break;
Simply masking the LFE bit is more natural than subtracting if set. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> --- libavcodec/ac3enc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)