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 18200403C4 for ; Mon, 20 Dec 2021 18:29:00 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 5609668AFCF; Mon, 20 Dec 2021 20:28:59 +0200 (EET) Received: from relay9-d.mail.gandi.net (relay9-d.mail.gandi.net [217.70.183.199]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 7F23168AEAD for ; Mon, 20 Dec 2021 20:28:51 +0200 (EET) Received: from localhost (213-47-68-29.cable.dynamic.surfer.at [213.47.68.29]) (Authenticated sender: michael@niedermayer.cc) by relay9-d.mail.gandi.net (Postfix) with ESMTPSA id CAFFDFF802 for ; Mon, 20 Dec 2021 18:28:50 +0000 (UTC) Date: Mon, 20 Dec 2021 19:28:49 +0100 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20211220182849.GW2829255@pb2> References: <20211220083105.1452-1-ffmpeg@gyani.pro> MIME-Version: 1.0 In-Reply-To: <20211220083105.1452-1-ffmpeg@gyani.pro> Subject: Re: [FFmpeg-devel] [PATCH v2] avformat/mov: add option max_stts_delta 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="===============4614957216993147517==" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: --===============4614957216993147517== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="oJ+zcsIdWj6upy5+" Content-Disposition: inline --oJ+zcsIdWj6upy5+ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Dec 20, 2021 at 02:01:05PM +0530, Gyan Doshi wrote: > Very high stts sample deltas may occasionally be intended but usually > they are written in error or used to store a negative value for dts corre= ction > when treated as signed 32-bit integers. >=20 > This option lets the user set an upper limit, beyond which the delta is c= lamped to 1. > Values greater than the limit if negative when cast to int32 are used to = adjust onward dts. >=20 > Unit is the track time scale. Default is UINT_MAX - 48000*10 which > allows upto a 10 second dts correction for 48 kHz audio streams while > accommodating 99.9% of uint32 range. > --- >=20 > v2 changes: >=20 > mp4-negative-stts-problem.mp4 plays in sync with the default value > chosen. > stts adjustment shifted to mov_read_stts so that any downstream code > that references raw stts does not have to contend with possibly changed > stts values. >=20 > libavformat/isom.h | 1 + > libavformat/mov.c | 64 +++++++++++++++++++++++++++------------------- > 2 files changed, 39 insertions(+), 26 deletions(-) Thanks for looking into this, this patch seems to add another bug though which is the newly added loop. Its a few million times too slow. A sample file which takes a fraction of a second before has not finished demuxing after an hour ill mail you the sample privatly [...] > + int32_t delta_magnitude =3D *((int32_t *)&sample_duratio= n); a plain cast should be fine with no pointers [...] thx --=20 Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Never trust a computer, one day, it may think you are the virus. -- Compn --oJ+zcsIdWj6upy5+ Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABEIAB0WIQSf8hKLFH72cwut8TNhHseHBAsPqwUCYcDLXgAKCRBhHseHBAsP qygGAJ9BxcwyRXvrMucKPHsnS81+/t/l7QCfUu6HdzjbSF88St6ooLTLG5AI13A= =Q8Is -----END PGP SIGNATURE----- --oJ+zcsIdWj6upy5+-- --===============4614957216993147517== 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". --===============4614957216993147517==--