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 ESMTP id 4E79E44746 for ; Thu, 24 Nov 2022 23:07:57 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id D4DBD68B9F3; Fri, 25 Nov 2022 01:07:55 +0200 (EET) Received: from relay11.mail.gandi.net (relay11.mail.gandi.net [217.70.178.231]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 5430268B7DB for ; Fri, 25 Nov 2022 01:07:49 +0200 (EET) Received: (Authenticated sender: michael@niedermayer.cc) by mail.gandi.net (Postfix) with ESMTPSA id 24B17100002 for ; Thu, 24 Nov 2022 23:07:47 +0000 (UTC) Date: Fri, 25 Nov 2022 00:07:46 +0100 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20221124230746.GA3806951@pb2> References: <20221104141336.1812-1-ovchinnikov.dmitrii@gmail.com> <20221104141336.1812-2-ovchinnikov.dmitrii@gmail.com> <20221104153422.GP1814017@pb2> MIME-Version: 1.0 In-Reply-To: Subject: Re: [FFmpeg-devel] [crop support for matroska demuxer, V4 2/3] libavcodec: Public code to support container crop 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="===============3332131152933806345==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============3332131152933806345== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="r5Pyd7+fXNt84Ff3" Content-Disposition: inline --r5Pyd7+fXNt84Ff3 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Nov 23, 2022 at 03:44:25PM +0100, Dmitrii Ovchinnikov wrote: > >>The types seems mismatching >=20 > The reason for the mismatch of types is that I left the > int type according to the comments : > " > James Almer > IMO the AVFrame ones should have not been size_t to begin with, not just > because the actual dimensions you'll apply them to are int, but because > these fields are not arch dependent or meant for the size of some object > in memory. > " >=20 > It seems that performing casts would not be a good idea. > Should I make crop fields size_t type as in AVFrame? > Or is there a more correct way? the type specified in the format string has to match the types passed in the argument to av_log "%"SIZE_SPECIFIER" + size_t or %d + int otherwise you have undefined behavior [...] --=20 Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB The greatest way to live with honor in this world is to be what we pretend to be. -- Socrates --r5Pyd7+fXNt84Ff3 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABEIAB0WIQSf8hKLFH72cwut8TNhHseHBAsPqwUCY3/5PAAKCRBhHseHBAsP qwoXAJsFAEzPUhVIwP+LnJ/7JW3ZrCYFqgCfXxKnABID1CdfErVVCHQR8/408W4= =XdTb -----END PGP SIGNATURE----- --r5Pyd7+fXNt84Ff3-- --===============3332131152933806345== 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". --===============3332131152933806345==--