From patchwork Sat Sep 10 01:07:26 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 37819 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:139a:b0:8f:1db5:eae2 with SMTP id w26csp1246004pzh; Fri, 9 Sep 2022 18:09:41 -0700 (PDT) X-Google-Smtp-Source: AA6agR7eWfIFhsXS9IPKEk4ZLDpraNNRbHxc1gr5GqJg8srYKxGf+y4xKLtE6sV0CNdHOE7MJ17e X-Received: by 2002:a17:907:9717:b0:77b:6f08:9872 with SMTP id jg23-20020a170907971700b0077b6f089872mr60530ejc.629.1662772181179; Fri, 09 Sep 2022 18:09: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 dr11-20020a170907720b00b0073d5b609447si1724198ejc.324.2022.09.09.18.09.40; Fri, 09 Sep 2022 18:09: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=gdtUoJ+6; 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 EB15368BB61; Sat, 10 Sep 2022 04:08:15 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR02-HE1-obe.outbound.protection.outlook.com (mail-oln040092068061.outbound.protection.outlook.com [40.92.68.61]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 9629468B980 for ; Sat, 10 Sep 2022 04:08:08 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=NDNclFuB5p0XfhDUH/704Nq4F69QbQ1twKpDSKtZ5Sgoufb8GxjmV4IKCxx+HgpwsfcmnGwkau+EEoUpXxSOE1EwpP85P9U8QFEWxalSR4nr85iup6DH1mfNBWdf5E5dUm0II8uncmejjLQ4+rsRdXbsaI0pQvHhthaWPfZCTWDotYdFJmpkLA4rGdoWMXifLTqHXdA/YnrF7ysG9Ex80Y+m7mk/AlA5PYavXitXhXSUUb6dmHHqX0SiFyLtMPzWc2wFCXdLMhsGSQyrJArijar090Sl9vjsT2PsxeaWSbWfSvewEsqlyAmcBQuWteWbGELMOEvaK1KXvPO5+PDBaA== 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=I+B2tf81xZv186pCTM9vNW4cmokMUTI42aGprtf01bw=; b=QZEUYbkV+KT3xAZD0vkowc+dRLfL8FENSB1vgrM+Ewt98qdoWKuyWVAPgUxjc936C/vIeVIzVQxhLCwkLvkvpYmtTcgKOUvHOTyQbHAQptLsyWQsqxpuJgY85qAfRFNnxpEouHeI4GGUv0pUnqITveIF7lULbiVw6Xw+VpatRTGrWzFUis3quIEpuLwejpUhGtPnKZcTV76FS+9uwTjtmT+eKxa4FlChcWHnY4J1f+xgbtuakp+jyFLN/5ZJANWp/5moH4lF0acv2D84awt9XWl/3zKwik5kQEJNf7hDQ+v7vsr2ZdOTb4WfCZ9//+U+DgRNsqp52PMGYYt18qb9UA== 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=I+B2tf81xZv186pCTM9vNW4cmokMUTI42aGprtf01bw=; b=gdtUoJ+6wTbW3EX7NqH+w6dtOqMIEnL3OhXvMICQryoCcmJy2Cp7YoHd6qBNHoNrsxU76aZ3M/fRKua68GfZ/0FCXRufSCHhqcgRWnNBIk2+NeXCo6mPSkecZth92hYHHOop94R0kQNsif0Rdp/ts8zFsfu2L7B0tbEyhBChhIk85rysFozX0Kakcc7BN0H18Mkk1ToBV3hjYRjcU5wCuoU7zP+7xoa32LGxpSKBLftEFeuucLoadWJspuTHrxXUBleVYs+tWBv8A3p1l//Gm8WGDz7uTEWT1Q+jnHRXcGHxN9syTWEEi+Tt+N5PVBW5YD/49oF+ZKFirqsVtMRm7g== Received: from AS8P250MB0744.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:541::14) by PR3P250MB0242.EURP250.PROD.OUTLOOK.COM (2603:10a6:102:17d::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5612.22; Sat, 10 Sep 2022 01:08:07 +0000 Received: from AS8P250MB0744.EURP250.PROD.OUTLOOK.COM ([fe80::611e:1608:45cb:b58a]) by AS8P250MB0744.EURP250.PROD.OUTLOOK.COM ([fe80::611e:1608:45cb:b58a%4]) with mapi id 15.20.5612.019; Sat, 10 Sep 2022 01:08:07 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 10 Sep 2022 03:07:26 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [OgWJoLTdWbZBrjRG/R161+yCfFjnIBkICWvQn5pSDcE=] X-ClientProxiedBy: FR0P281CA0102.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:a9::18) To AS8P250MB0744.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:541::14) X-Microsoft-Original-Message-ID: <20220910010729.2961339-14-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AS8P250MB0744:EE_|PR3P250MB0242:EE_ X-MS-Office365-Filtering-Correlation-Id: aea9c36a-47ad-4c0c-f597-08da92c8eb93 X-MS-Exchange-SLBlob-MailProps: ZILSnhm0P3nYUjUJgQ1LxEogv9AalAZhYJwX+wV8LTghWJ7E6NkI85BlGc25S3OENmFvTQDBpswQ7hSOazRuHGFu90XU3iJ1Op1xHx8igD/gGqBot+euhhYcw82R1KZagma83z7ABZK3pb6qGi2nwGwRUDkSNM+1YN1IPj4iWcic/oPlu+5cNfaj4M5IPMrTLg1kiqJhNkehlzA8njCor6bVbFDoM42tnippnsnYzfdo9vFmhVHi0oa2EN6VY94TYJgqZGPbBPP+zmYhcLsBKY//0/hR0ZPU1q+qL58WB17k353YpKgEX3RHBP7DYR+rX1Fe4rvxLaYq294V1e5XoNyk7DKOt2Bf3yI24HzCNpBvOQPRjeBtfu6iIaroMwWuxH2pCEcI/jO78BbkUnnBBhgTON7CBfXA2sOFP/SIPD7Fym00+w9tYfgozilSm4Yu4SOdihTRo58N+/sTU01dKnepZJkBWvYvhAMKnYDudrPtyX/Wdbzs/AJSF2EcVXYQn5IGaOrAdkfKDuEvELwwtaFi7jAUQMr1fRh/6MQfz2L84SGQVk4UAY+O4k1nMpmohvoO/rzluset1MzkosFQVdOr5b0/Apr1qnoIqS+CC/9YB142cCqAAkc8VU2gCnOVAS9cdrLUEkHQoyu+JB0Q5U6WfYGdl7N9CPc6WM+Rzz4tzQhWJ3LUhUPudc20zlbY/PizIRixTitQ/4j0X0ZIaZHF0CqbU3+lkhuWgHtwd7kEPusXs/2IgYM7kwIcDE15wuX4/NmgCmctPwXFmCLe9+H7Xnf7Sabw X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: brtww+rqkAKqYcLlEr3l4zC8uyk50gH2yY6iAO80MIz0y9VoUx0t6BrWTSmmqW8R/IYP480i6ZCBvsiWTrVTCFQZpQyJfsEeCsg4VsjHBZagIsSPQUf5rKdefJsv2jD2PZZWRM1rsgNruHqENLa7OemB2gIPLRC1z7WzN2tKJRNhK9wqUN3GI0mcTo3RE1U8QPu63z4nawU9QldGUtkiyftrNtPvWzV6olOUSiq75s2lT6TLVQcQIWZhKchobz3e+Fu2EJRpHO6fAaxBdvKYUJwLeNTJo1JkmIOJy1USR3PNFWJhL40VK3CuEbpSFdBEAhNoVhBA54kxXHsUwLFaPj87xutlNkYoqthXoz7cI8OHU1L5wcqAN1Bizxs1MYWAoqChqWGJwTOgEITZ29MRn+IVqJKSc53LHUGxXPGPTNNGtYb69/LApjdgsoxM+emZ39617s8/5RgnBvvb7EtbULTh6BjOfghTo2f+vGyClPM2VvoH5odwvZi2Nn+xCzyG27zCTet69LhT38fv8tSzjXiBPXpy2gIJ81Qw2lIBaQ8ha/D2xFSUrK6dBEJY5CqZ8TvN8kMkBIWRquU2sZgtB23iVkHaf9+8lwWCBTWLCh8gqt5rrFTcq0QDcyonsGqSxcYbeBYwEmxh+alNQendog== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: zwrBE2RyjFUdairIOLf9TQ/sMdLCG85jqMmyy+sNj1DkNiKJTqAPzvrVyde4ew97OWCizSN7Z+q7uRMiGKtFLcgYLcd5W5GKim5T+Wt99n3ruRbYQv/A+8STYeoZ6FO7amGhUh0CsME/gpZNMiTC2mxuv4mlGnLR0T+S2HpX7Eu286L1c6c1nh+Af4cCrZgLnCdtPD5b8Ck0UvIaD51ryNKCfpE77DObmtb+axVR1/QTzUd7LxN9xc3tuG3dKdzBR60vRZLMUMxgQ9lfCJzzLN94OZfZFDTrkCHHxydua0xejV2Azw9NFbyCDEVN9ayR7w7WMPfBZwUFjapKgkUIH4T89olvR2K7SGxSkFH3Px2YEvSEe6nEjC7a/YRMmhk3YPlWpj2nlVVsbvd0O0b/B+NRuqTWSDhoQsSQFKnZUqaayeJ44TsG6uFCEFXwhAMbv0z0LArj+/cIdc+ZXpFxAiKo+fgEXw+in7tNjsPXO8d22FviwZW+WMDhpLdLYrcJQ6g7lTuAbj1nBzzr1Wnq76dhjOg37SaFu7GzxaIodEmkA3mefsJYev1E7o4rNi7UuU6Khf7W2IHvio5z043FdCFJN6RXES4Y+s0U3Rh3LzTdU4VVR8TXX6LQrRI0zjQQw9jER1fY9fgU83smefJscfWyUPLMNBN9Quyv9StcIZ7nt3pIosmHD2GYHW1KxUJ2B/5sKlLoKbZ/BiZ6cApoHv9wIMI7V1PCn5EBa54PG4Urikq8/b2bUnmYCeLw7pVHEXKzloAFZV903nPF16cZdAIlw6X/p1B866q7tIobMRqsRj8OjMxdS0owIa0j7YPARyyX+n21kvKylj0OiMy/1ZuEqkKPLe8oGkvjr01m8LjQXz1/UeXJHU9yU0HIIcIEk4hqXvA65EfBq7aufZbWUcMum8BthM2rbqjfoMfw2Cy9N4g85Qb7nSF4ZmHq3tb46IKEieDSQUUVbhIiv0J3j4UJ3bH+Nndbz1qBOMPajmYyp7iwoXO03SqcvIIxHjdZHq34QwMeK7tLGsPcx7by5l/+TzlIVeo4j1knmckrAIG3o6A9gdntHAsaQp9Y+fMy7zeWBy0kx9MjMpWOnwwgWfSP1kFoZdD/IXys7fIIalPSpwOYJxtFalC5qp5tioM+5iRXS6VYAzpgNkRCyM2oy7ngb3/NJDp+bNBPDtilSH1bBkAJpd33TiOMLL50qzpS+k18ulLM6qlR2Ssv6x371xGXYIg3GYEaWt8NvhxAmRse+djFAIbkv5QEeP/t0i8kikcYH0o1ruIDb9nNnZZBltNZleX1hOemJp2ynW1u/Fh+PraT2pg7fq00NEWy8vqJ X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: aea9c36a-47ad-4c0c-f597-08da92c8eb93 X-MS-Exchange-CrossTenant-AuthSource: AS8P250MB0744.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Sep 2022 01:08:07.1521 (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: PR3P250MB0242 Subject: [FFmpeg-devel] [PATCH 15/18] avcodec/vp8: Disable frame-threading code for VP7 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: xQwyLXHUEr+U The VP7 decoder does not support frame threading. Signed-off-by: Andreas Rheinhardt --- libavcodec/vp8.c | 55 ++++++++++++++++++++++++++---------------------- 1 file changed, 30 insertions(+), 25 deletions(-) diff --git a/libavcodec/vp8.c b/libavcodec/vp8.c index baf9820ce6..91f3238245 100644 --- a/libavcodec/vp8.c +++ b/libavcodec/vp8.c @@ -1836,7 +1836,7 @@ void vp8_mc_luma(VP8Context *s, VP8ThreadData *td, uint8_t *dst, const ThreadFrame *ref, const VP8mv *mv, int x_off, int y_off, int block_w, int block_h, int width, int height, ptrdiff_t linesize, - vp8_mc_func mc_func[3][3]) + vp8_mc_func mc_func[3][3], int is_vp7) { uint8_t *src = ref->f->data[0]; @@ -1850,7 +1850,8 @@ void vp8_mc_luma(VP8Context *s, VP8ThreadData *td, uint8_t *dst, y_off += mv->y >> 2; // edge emulation - ff_thread_await_progress(ref, (3 + y_off + block_h + subpel_idx[2][my]) >> 4, 0); + if (!is_vp7) + ff_thread_await_progress(ref, (3 + y_off + block_h + subpel_idx[2][my]) >> 4, 0); src += y_off * linesize + x_off; if (x_off < mx_idx || x_off >= width - block_w - subpel_idx[2][mx] || y_off < my_idx || y_off >= height - block_h - subpel_idx[2][my]) { @@ -1866,7 +1867,8 @@ void vp8_mc_luma(VP8Context *s, VP8ThreadData *td, uint8_t *dst, } mc_func[my_idx][mx_idx](dst, linesize, src, src_linesize, block_h, mx, my); } else { - ff_thread_await_progress(ref, (3 + y_off + block_h) >> 4, 0); + if (!is_vp7) + ff_thread_await_progress(ref, (3 + y_off + block_h) >> 4, 0); mc_func[0][0](dst, linesize, src + y_off * linesize + x_off, linesize, block_h, 0, 0); } @@ -1894,7 +1896,7 @@ void vp8_mc_chroma(VP8Context *s, VP8ThreadData *td, uint8_t *dst1, uint8_t *dst2, const ThreadFrame *ref, const VP8mv *mv, int x_off, int y_off, int block_w, int block_h, int width, int height, ptrdiff_t linesize, - vp8_mc_func mc_func[3][3]) + vp8_mc_func mc_func[3][3], int is_vp7) { uint8_t *src1 = ref->f->data[1], *src2 = ref->f->data[2]; @@ -1908,7 +1910,8 @@ void vp8_mc_chroma(VP8Context *s, VP8ThreadData *td, uint8_t *dst1, // edge emulation src1 += y_off * linesize + x_off; src2 += y_off * linesize + x_off; - ff_thread_await_progress(ref, (3 + y_off + block_h + subpel_idx[2][my]) >> 3, 0); + if (!is_vp7) + ff_thread_await_progress(ref, (3 + y_off + block_h + subpel_idx[2][my]) >> 3, 0); if (x_off < mx_idx || x_off >= width - block_w - subpel_idx[2][mx] || y_off < my_idx || y_off >= height - block_h - subpel_idx[2][my]) { s->vdsp.emulated_edge_mc(td->edge_emu_buffer, @@ -1933,7 +1936,8 @@ void vp8_mc_chroma(VP8Context *s, VP8ThreadData *td, uint8_t *dst1, mc_func[my_idx][mx_idx](dst2, linesize, src2, linesize, block_h, mx, my); } } else { - ff_thread_await_progress(ref, (3 + y_off + block_h) >> 3, 0); + if (!is_vp7) + ff_thread_await_progress(ref, (3 + y_off + block_h) >> 3, 0); mc_func[0][0](dst1, linesize, src1 + y_off * linesize + x_off, linesize, block_h, 0, 0); mc_func[0][0](dst2, linesize, src2 + y_off * linesize + x_off, linesize, block_h, 0, 0); } @@ -1943,7 +1947,7 @@ static av_always_inline void vp8_mc_part(VP8Context *s, VP8ThreadData *td, uint8_t *dst[3], ThreadFrame *ref_frame, int x_off, int y_off, int bx_off, int by_off, int block_w, int block_h, - int width, int height, VP8mv *mv) + int width, int height, VP8mv *mv, int is_vp7) { VP8mv uvmv = *mv; @@ -1951,7 +1955,7 @@ void vp8_mc_part(VP8Context *s, VP8ThreadData *td, uint8_t *dst[3], vp8_mc_luma(s, td, dst[0] + by_off * s->linesize + bx_off, ref_frame, mv, x_off + bx_off, y_off + by_off, block_w, block_h, width, height, s->linesize, - s->put_pixels_tab[block_w == 8]); + s->put_pixels_tab[block_w == 8], is_vp7); /* U/V */ if (s->profile == 3) { @@ -1972,7 +1976,7 @@ void vp8_mc_part(VP8Context *s, VP8ThreadData *td, uint8_t *dst[3], dst[2] + by_off * s->uvlinesize + bx_off, ref_frame, &uvmv, x_off + bx_off, y_off + by_off, block_w, block_h, width, height, s->uvlinesize, - s->put_pixels_tab[1 + (block_w == 4)]); + s->put_pixels_tab[1 + (block_w == 4)], is_vp7); } /* Fetch pixels for estimated mv 4 macroblocks ahead. @@ -2002,7 +2006,7 @@ void prefetch_motion(VP8Context *s, VP8Macroblock *mb, int mb_x, int mb_y, */ static av_always_inline void inter_predict(VP8Context *s, VP8ThreadData *td, uint8_t *dst[3], - VP8Macroblock *mb, int mb_x, int mb_y) + VP8Macroblock *mb, int mb_x, int mb_y, int is_vp7) { int x_off = mb_x << 4, y_off = mb_y << 4; int width = 16 * s->mb_width, height = 16 * s->mb_height; @@ -2012,7 +2016,7 @@ void inter_predict(VP8Context *s, VP8ThreadData *td, uint8_t *dst[3], switch (mb->partitioning) { case VP8_SPLITMVMODE_NONE: vp8_mc_part(s, td, dst, ref, x_off, y_off, - 0, 0, 16, 16, width, height, &mb->mv); + 0, 0, 16, 16, width, height, &mb->mv, is_vp7); break; case VP8_SPLITMVMODE_4x4: { int x, y; @@ -2025,7 +2029,7 @@ void inter_predict(VP8Context *s, VP8ThreadData *td, uint8_t *dst[3], ref, &bmv[4 * y + x], 4 * x + x_off, 4 * y + y_off, 4, 4, width, height, s->linesize, - s->put_pixels_tab[2]); + s->put_pixels_tab[2], is_vp7); } } @@ -2054,32 +2058,32 @@ void inter_predict(VP8Context *s, VP8ThreadData *td, uint8_t *dst[3], dst[2] + 4 * y * s->uvlinesize + x * 4, ref, &uvmv, 4 * x + x_off, 4 * y + y_off, 4, 4, width, height, s->uvlinesize, - s->put_pixels_tab[2]); + s->put_pixels_tab[2], is_vp7); } } break; } case VP8_SPLITMVMODE_16x8: vp8_mc_part(s, td, dst, ref, x_off, y_off, - 0, 0, 16, 8, width, height, &bmv[0]); + 0, 0, 16, 8, width, height, &bmv[0], is_vp7); vp8_mc_part(s, td, dst, ref, x_off, y_off, - 0, 8, 16, 8, width, height, &bmv[1]); + 0, 8, 16, 8, width, height, &bmv[1], is_vp7); break; case VP8_SPLITMVMODE_8x16: vp8_mc_part(s, td, dst, ref, x_off, y_off, - 0, 0, 8, 16, width, height, &bmv[0]); + 0, 0, 8, 16, width, height, &bmv[0], is_vp7); vp8_mc_part(s, td, dst, ref, x_off, y_off, - 8, 0, 8, 16, width, height, &bmv[1]); + 8, 0, 8, 16, width, height, &bmv[1], is_vp7); break; case VP8_SPLITMVMODE_8x8: vp8_mc_part(s, td, dst, ref, x_off, y_off, - 0, 0, 8, 8, width, height, &bmv[0]); + 0, 0, 8, 8, width, height, &bmv[0], is_vp7); vp8_mc_part(s, td, dst, ref, x_off, y_off, - 8, 0, 8, 8, width, height, &bmv[1]); + 8, 0, 8, 8, width, height, &bmv[1], is_vp7); vp8_mc_part(s, td, dst, ref, x_off, y_off, - 0, 8, 8, 8, width, height, &bmv[2]); + 0, 8, 8, 8, width, height, &bmv[2], is_vp7); vp8_mc_part(s, td, dst, ref, x_off, y_off, - 8, 8, 8, 8, width, height, &bmv[3]); + 8, 8, 8, 8, width, height, &bmv[3], is_vp7); break; } } @@ -2470,7 +2474,7 @@ static av_always_inline int decode_mb_row_no_filter(AVCodecContext *avctx, void if (mb->mode <= MODE_I4x4) intra_predict(s, td, dst, mb, mb_x, mb_y, is_vp7); else - inter_predict(s, td, dst, mb, mb_x, mb_y); + inter_predict(s, td, dst, mb, mb_x, mb_y, is_vp7); prefetch_motion(s, mb, mb_x, mb_y, mb_xy, VP8_FRAME_GOLDEN); @@ -2629,7 +2633,7 @@ int vp78_decode_mb_row_sliced(AVCodecContext *avctx, void *tdata, int jobnr, td->mv_bounds.mv_min.y -= 64 * num_jobs; td->mv_bounds.mv_max.y -= 64 * num_jobs; - if (avctx->active_thread_type == FF_THREAD_FRAME) + if (!is_vp7 && avctx->active_thread_type == FF_THREAD_FRAME) ff_thread_report_progress(&curframe->tf, mb_y, 0); } @@ -2746,7 +2750,7 @@ int vp78_decode_frame(AVCodecContext *avctx, AVFrame *rframe, int *got_frame, s->next_framep[VP8_FRAME_CURRENT] = curframe; - if (ffcodec(avctx->codec)->update_thread_context) + if (!is_vp7 && ffcodec(avctx->codec)->update_thread_context) ff_thread_finish_setup(avctx); if (avctx->hwaccel) { @@ -2815,7 +2819,8 @@ int vp78_decode_frame(AVCodecContext *avctx, AVFrame *rframe, int *got_frame, } } - ff_thread_report_progress(&curframe->tf, INT_MAX, 0); + if (!is_vp7) + ff_thread_report_progress(&curframe->tf, INT_MAX, 0); memcpy(&s->framep[0], &s->next_framep[0], sizeof(s->framep[0]) * 4); skip_decode: