From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTPS id 9F9E84BE53 for ; Mon, 3 Feb 2025 23:25:01 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 9F25968B27F; Tue, 4 Feb 2025 01:24:57 +0200 (EET) Received: from relay7-d.mail.gandi.net (relay7-d.mail.gandi.net [217.70.183.200]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 029EB68AD09 for ; Tue, 4 Feb 2025 01:24:50 +0200 (EET) Received: by mail.gandi.net (Postfix) with ESMTPSA id 38D2D42D83 for ; Mon, 3 Feb 2025 23:24:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=niedermayer.cc; s=gm1; t=1738625090; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=DKqDweYufwU8q6idK/N0FIdcu7AIfVJdXuNB5/5uLDQ=; b=IXzZAWVTbGPz1ixWxXhL9CMKgWiD8AHLefzFsY02VThfZsWjBWiMW/JlP1UvVzhGY8DYwk V+TlvsnBHJiqiCkL6OrafiGjwecaWIStG3fm09DMwgC1iMzlRdVJqBbkvuDh4fuSOywT/D KVT6WYkvZ4RZTxvok10Pu8AwbC7mMgoDfZdoX931nhHY+koUJDdadX6bbBtPyi4V5vT75w Td3ccVhKmrTcv7+PPGgpoLP4NJCsVvGi1XIp9fu1Es2Yb5s1c812aovVW22fPQouAoQBrF 5N99oz3SCyz+gkpfcl5zJTAt+mpP10zUApiF+q6qOn0RiUD5OTkPc1mUIOloIA== Date: Tue, 4 Feb 2025 00:24:49 +0100 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20250203232449.GB4991@pb2> References: <20250202211721.1469377-1-michael@niedermayer.cc> MIME-Version: 1.0 In-Reply-To: X-GND-State: clean X-GND-Score: -85 X-GND-Cause: gggruggvucftvghtrhhoucdtuddrgeefvddrtddtgddukeelfecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfitefpfffkpdcuggftfghnshhusghstghrihgsvgenuceurghilhhouhhtmecufedtudenucesvcftvggtihhpihgvnhhtshculddquddttddmnegfrhhlucfvnfffucdludehmdenucfjughrpeffhffvuffkfhggtggujgesghdtreertddtvdenucfhrhhomhepofhitghhrggvlhcupfhivgguvghrmhgrhigvrhcuoehmihgthhgrvghlsehnihgvuggvrhhmrgihvghrrdgttgeqnecuggftrfgrthhtvghrnheptefggedvffeiueffvefhiedtgfefjedukeefgeetgeevgeejgeekvdevjeelveeknecuffhomhgrihhnpehgihhthhhusgdrtghomhenucfkphepgedurdeiiedrieejrdduudefnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehinhgvthepgedurdeiiedrieejrdduudefpdhhvghloheplhhotggrlhhhohhsthdpmhgrihhlfhhrohhmpehmihgthhgrvghlsehnihgvuggvrhhmrgihvghrrdgttgdpnhgspghrtghpthhtohepuddprhgtphhtthhopehffhhmphgvghdquggvvhgvlhesfhhfmhhpvghgrdhorhhg X-GND-Sasl: michael@niedermayer.cc Subject: Re: [FFmpeg-devel] [PATCH 1/2] avcodec/vvc/refs: fix negative pps_scaling_win offsets 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 Content-Type: multipart/mixed; boundary="===============4641107639486220807==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============4641107639486220807== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="CSIOvYm71D2OspRc" Content-Disposition: inline --CSIOvYm71D2OspRc Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Feb 03, 2025 at 08:05:19AM +0000, Frank Plowman wrote: > On 02/02/2025 21:17, Michael Niedermayer wrote: > > The spec seems to allow these to be negative > >=20 > > Fixes: left shift of negative value -15 > > Fixes: 392687035/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VVC_= fuzzer-6559804532785152 > >=20 > > Found-by: continuous fuzzing process https://github.com/google/oss-fuzz= /tree/master/projects/ffmpeg > > Signed-off-by: Michael Niedermayer > > --- > > libavcodec/vvc/refs.c | 8 ++++---- > > 1 file changed, 4 insertions(+), 4 deletions(-) > >=20 > > diff --git a/libavcodec/vvc/refs.c b/libavcodec/vvc/refs.c > > index 8d4b7bb35b2..486515d06db 100644 > > --- a/libavcodec/vvc/refs.c > > +++ b/libavcodec/vvc/refs.c > > @@ -147,10 +147,10 @@ static VVCFrame *alloc_frame(VVCContext *s, VVCFr= ameContext *fc) > > for (int j =3D 0; j < frame->ctb_count; j++) > > frame->rpl_tab[j] =3D frame->rpl; > > =20 > > - win->left_offset =3D pps->r->pps_scaling_win_left_offset <= < sps->hshift[CHROMA]; > > - win->right_offset =3D pps->r->pps_scaling_win_right_offset <= < sps->hshift[CHROMA]; > > - win->top_offset =3D pps->r->pps_scaling_win_top_offset <= < sps->vshift[CHROMA]; > > - win->bottom_offset =3D pps->r->pps_scaling_win_bottom_offset <= < sps->vshift[CHROMA]; > > + win->left_offset =3D pps->r->pps_scaling_win_left_offset *= (1 << sps->hshift[CHROMA]); > > + win->right_offset =3D pps->r->pps_scaling_win_right_offset *= (1 << sps->hshift[CHROMA]); > > + win->top_offset =3D pps->r->pps_scaling_win_top_offset *= (1 << sps->vshift[CHROMA]); > > + win->bottom_offset =3D pps->r->pps_scaling_win_bottom_offset *= (1 << sps->vshift[CHROMA]); > > frame->ref_width =3D pps->r->pps_pic_width_in_luma_samples = - win->left_offset - win->right_offset; > > frame->ref_height =3D pps->r->pps_pic_height_in_luma_samples = - win->bottom_offset - win->top_offset; > > =20 >=20 > This patch LGTM. will apply thx [...] --=20 Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB During times of universal deceit, telling the truth becomes a revolutionary act. -- George Orwell --CSIOvYm71D2OspRc Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABEKAB0WIQSf8hKLFH72cwut8TNhHseHBAsPqwUCZ6FQNgAKCRBhHseHBAsP qw+1AJ9YVDXRWfDYq3uab/zRxdYAlQLJ4gCbBCqRxchqs8LeIofW3OZKGJJtx5M= =tXj/ -----END PGP SIGNATURE----- --CSIOvYm71D2OspRc-- --===============4641107639486220807== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". --===============4641107639486220807==--