Message ID | GV1P250MB0737B6D1211B7DECE35094508F499@GV1P250MB0737.EURP250.PROD.OUTLOOK.COM |
---|---|
State | Accepted |
Commit | e6bfb14223e44b4110c1d171d1ecffe9c80302a8 |
Headers | show
Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:3b1c:b0:96:9ee8:5cfd with SMTP id c28csp521169pzh; Thu, 15 Sep 2022 12:28:57 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7RZ9HYPK76HjQKPI5DFp5rEUzJR8g5omaTlQuiOzuIQHL0ze1CN+g+r45TWPSuhJBP4L8t X-Received: by 2002:a17:907:1dd9:b0:77a:341b:88cb with SMTP id og25-20020a1709071dd900b0077a341b88cbmr994716ejc.753.1663270137747; Thu, 15 Sep 2022 12:28:57 -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 hr7-20020a1709073f8700b0077c951af30dsi13270739ejc.235.2022.09.15.12.28.57; Thu, 15 Sep 2022 12:28:57 -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=NzburluX; 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 2435068BBDA; Thu, 15 Sep 2022 22:28:42 +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-oln040092069055.outbound.protection.outlook.com [40.92.69.55]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 7E54668BBCE for <ffmpeg-devel@ffmpeg.org>; Thu, 15 Sep 2022 22:28:39 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ERM6xY8EKMilN2gATFluAmHrrQRT/em7IQng9jihXgZ3snSmhNAVPvEOAyacu59sxnp6BlhCmxOv29hOCiQfCjsNOx7c2e3v418HPhtrdvtWMDvFXlj7sOUkZeNDmbHoP0Xe4a4bN0NF+H9gDtU66LYOqpbm/x5IrA1irLpcJbrO3/tyija4FNU1uSvU5jDKgHfepF7ArvWj8F8MJwjUR8pTjgZZG/Kk3dzhBDJGJVqWA24P4XRQkK6jjLr5CAa4fuuPnnFQr8Keol/q8jP/YDfIanSoy9/qY/k9auT9SeOhx+zOcZ0W0IubkqaB1eHvhIOQkI/1069SewkY+ibwNg== 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=uW6h+Zc1S1dFZoLM3tQLB5MQEqfAwNAz6jxugpjaWYc=; b=JfD0Hm5E84ez69YVaN0No1JmB9Ri1N96AEuykVAnshnveubIw9OotTY2OjoGDiHyAbihY01ahXhe+mYwButHADLlDJl1XVsYjOiND4IbatdsdqoVo3Gev0Q1I1rwjMAJ97em30W9pWtx5+XHIcwDWHTJkiFTKWUm+BrwCTmj/7OT1nJ8iTDsQ/bna8vAZnRiY1IutrbvgEVzzjV5rl60cWE8vTvCinGJBO1eNotq8Z9PZODDn5eR7Z0K8gsLh4u9MChUKd/FaUToY9rVXs9eJvzn35v2kcUHTpOnGBK4/ZUHkOiYkhBEz0qdAzn7Y59FsGtvLU3Hf0dyt0Vet26iwQ== 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=uW6h+Zc1S1dFZoLM3tQLB5MQEqfAwNAz6jxugpjaWYc=; b=NzburluXwMAZo0KQayKBmDUZAHPiCXN3ddMtW5sAhHAvZCnwX0AV0p5xScbyqBz3/5yLWkQ5UO54SpAKaUl7DCJxtvMb0tDoFleSY9IWbqfBiK6ARUrPWv9ciOxiVZqxcaRwwFlMh8Hw7953vweeSOu4nWf9ImnMQXFOy8q237w0cJc/m+qu2ccJQwYmUZaGu15/2suXkXPPnTHt/oJKewEuL41ufJO0/sKJNhtl/yLJ/PIsytUZYTzxCRzyyzasmJPpHFFSVB64hCF0rTU551ZtPD/6i3QDQzM09ftnlhLxeUNJmHuiQeqs1rpXF9PcT/gY4IB2vnT8kP0ZZTBCyg== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by DU2P250MB0014.EURP250.PROD.OUTLOOK.COM (2603:10a6:10:2b7::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5632.15; Thu, 15 Sep 2022 19:28:31 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::51a4:ed23:ea45:dfeb]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::51a4:ed23:ea45:dfeb%8]) with mapi id 15.20.5612.022; Thu, 15 Sep 2022 19:28:31 +0000 From: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> To: ffmpeg-devel@ffmpeg.org Date: Thu, 15 Sep 2022 21:28:06 +0200 Message-ID: <GV1P250MB0737B6D1211B7DECE35094508F499@GV1P250MB0737.EURP250.PROD.OUTLOOK.COM> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220915192809.2761301-1-andreas.rheinhardt@outlook.com> References: <GV1P250MB07379524B6965693D412DE238F499@GV1P250MB0737.EURP250.PROD.OUTLOOK.COM> <20220915192809.2761301-1-andreas.rheinhardt@outlook.com> X-TMN: [qx9hRJqoyp9O+G8kAZqGnLCNACrY5MbDXOw4+33yHFs=] X-ClientProxiedBy: ZR0P278CA0117.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:20::14) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20220915192809.2761301-5-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|DU2P250MB0014:EE_ X-MS-Office365-Filtering-Correlation-Id: 9591265c-45b8-42f0-573a-08da97507909 X-MS-Exchange-SLBlob-MailProps: EgT5Wr3QDKwiAlKx4YLPXfs4dEXJm5ZiKk1hfDeE+x8NuKxjWrqBoxp5gyYz3ALMCuFBfpZHgh9qKqqBPOulNwtxSkF5NakkjXfF0H5F98KO5BoUcJAHlpczS13m393V8hmyKdRDW9DkdgiYWwHXGedAjnMOzywCUY1aXbAWGFwvOXRon9u0bBKT4yN3TGvGc0ZlJRIItwmRpR9S2c61eZk+4muJGqFYPL8S+9Q8MZXtY6BlKmX9XXhIC1w8uRTgOcioc4/7CN7VKtkf0Q/OpNefSL/0jT8eGgzq9WtD3rhke4QjdohQvO4mFefXbAXBiC76DtdNNOkkrJ7w1fa8lMImHtDxBtRC79MnKxb+kZwS6WEbVTTZtHnkdqxj26rfNkqyBjpmrS88v+gB6Dr9Hi/1gM87wOyGIL4EKfcScLeSPtaJ6TalsH97KrHUQApZS4h7LfNgfKhfw2764FB+AyZAd7lxOSxDHJL/7Q1QGz91c0t1S0MjboScAwS3ojqEIoTaDd60uXfZbOGSeZRm3B/26GeG2n6mihBY5QdQFGHTTqp757XEFLnIosLT7fZg/aidhmlw9cerVyZ4ezCSHhHmD5D2VFtzknIEfp1xioEIyQUNMO33SkT7GipaMXrmP6jsjTSq0PLoGVpdGxvTVw/vn6vLKniH3rrQ9bHhflEZadDeMzl8tIRaqtyADmyVVHaEIHtxaZuE17u69usDGKh5wah6lbsleJI5jALL/8M= X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: oagByH/BOuhRZjLrIrYaxdSCMAjal6i3c7w09RAurIGZHspMSd6tP2wFQ2jafVTNp+RpfZnPzDj+W56wPl10xFYLF/tdgV3frf1XaIih4037ap55pYuNxzrtSUyAeQ7SRclBSztcGn3dGcyA7dszodbmI1RV36fXpfJv17sO67Od5MILoXu3opo8ILsH+EiIGUIVWthmw/ooEGNMICfkrP4VNYsj0xYe7R+N64iReTQ7mfsXU0r4SOjjhmO4C9nGn5E/7XbzD5EzSGJc1WcTUEJK8dAiFnafCZZJl2UqkL3lgsx2ZVo9WuXIhcQ3rBOsE1e1FiQLRxCoZfB0DYDGrdwD/6PlAgHwNDkue56nJ5wqZfm575THpZEQitI6hgQ3u5D1I61AZCSE/wucfE+8zss3Tpk8HNCTBDb+3Ro5yr4wgeGJbdZ8ENBJuR2F+X6GVEftq2r2VsciXdQIgPxqTI5meSRuB8bC6Ymar5/vN+Va+PwTLd/xJV3RjDq8kzlJCdkESHDtrsfe+sm3q/xr8HY8ZHq4ZcF3T08O7UPN28gWJ0yI5lQLtbNW8IaeGX2NC3oOLpURaoogP6aQhPvUSHq8jJW2KEBgYpdwfALzUqm0RvDiEeJWHl7v463+KOF+hr9X1uE9uqRgcRGfewiuAw== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: JLyWbnmzJE6Pt8nmuWjNF0ieob60ocW+aQjc/L6IrIBgSTd+sn1dweuGWYq/rHnKaKI5YCO9LnkrhYZUl/kmwGlS04r6pEMKg0BqGJhdC+rzlKSAEns770QJAqcC7LjZKGTNKE++q1D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w8fCU/OuGb3WyLW9Zc0oREkfZaLAmkuobhQaQ6CLBexbof6FEVNULmxDiSycA7e8Zn4qnY14lh5iqbklzSIu/3hv+bHeHx/TEYy7pbDWasXv0PFxa8RGU= X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9591265c-45b8-42f0-573a-08da97507909 X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 15 Sep 2022 19:28:31.2210 (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: DU2P250MB0014 Subject: [FFmpeg-devel] [PATCH 6/9] avcodec/aptxdec: Process data in complete blocks only 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: JSt7Q0+K3byf |
Series |
[FFmpeg-devel,1/9] fate/audio: Add tests for APTX (HD)
|
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/aptxdec.c b/libavcodec/aptxdec.c index 878c9ffe1b..d254b3026b 100644 --- a/libavcodec/aptxdec.c +++ b/libavcodec/aptxdec.c @@ -151,7 +151,7 @@ static int aptx_decode_frame(AVCodecContext *avctx, AVFrame *frame, /* get output buffer */ frame->ch_layout.nb_channels = NB_CHANNELS; frame->format = AV_SAMPLE_FMT_S32P; - frame->nb_samples = 4 * avpkt->size / s->block_size; + frame->nb_samples = 4 * (avpkt->size / s->block_size); if ((ret = ff_get_buffer(avctx, frame, 0)) < 0) return ret;
The APTX (HD) decoder decodes blocks of four (six) bytes to four output samples. It makes no sense to handle incomplete blocks: They would just lead to synchronization errors, in which case the complete frame is discarded. So only handle complete blocks. This also avoids reading from the packet's padding and writing into the frame's padding. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> --- libavcodec/aptxdec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)