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 CDF814566F for ; Wed, 15 Mar 2023 15:03:53 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id B73A668BE85; Wed, 15 Mar 2023 17:03:51 +0200 (EET) Received: from mail0.khirnov.net (red.khirnov.net [176.97.15.12]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id C837B68BC49 for ; Wed, 15 Mar 2023 17:03:45 +0200 (EET) Received: from localhost (localhost [IPv6:::1]) by mail0.khirnov.net (Postfix) with ESMTP id 7D1172404EA for ; Wed, 15 Mar 2023 16:03:45 +0100 (CET) Received: from mail0.khirnov.net ([IPv6:::1]) by localhost (mail0.khirnov.net [IPv6:::1]) (amavisd-new, port 10024) with ESMTP id UQFogixcMuLw for ; Wed, 15 Mar 2023 16:03:44 +0100 (CET) Received: from lain.khirnov.net (lain.khirnov.net [IPv6:2001:67c:1138:4306::3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "lain.khirnov.net", Issuer "smtp.khirnov.net SMTP CA" (verified OK)) by mail0.khirnov.net (Postfix) with ESMTPS id B8818240178 for ; Wed, 15 Mar 2023 16:03:44 +0100 (CET) Received: by lain.khirnov.net (Postfix, from userid 1000) id 798C91601B2; Wed, 15 Mar 2023 16:03:43 +0100 (CET) From: Anton Khirnov To: FFmpeg development discussions and patches In-Reply-To: <20230314230006.GC375355@pb2> References: <38e8f429-9da3-fe23-7514-e9d6aa7f32bf@gmail.com> <20230311105452.12933-1-anton@khirnov.net> <20230314230006.GC375355@pb2> Mail-Followup-To: FFmpeg development discussions and patches Date: Wed, 15 Mar 2023 16:03:43 +0100 Message-ID: <167889262346.10789.2142261321211598191@lain.khirnov.net> User-Agent: alot/0.8.1 MIME-Version: 1.0 Subject: Re: [FFmpeg-devel] [PATCH v2 6/6] lavu/frame: deprecate AVFrame.pkt_{pos, size} 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: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: Quoting Michael Niedermayer (2023-03-15 00:00:06) > On Sat, Mar 11, 2023 at 11:54:52AM +0100, Anton Khirnov wrote: > > These fields are supposed to store information about the packet the > > frame was decoded from, specifically the byte offset it was stored at > > and its size. > > > > However, > > - the fields are highly ad-hoc - there is no strong reason why > > specifically those (and not any other) packet properties should have a > > dedicated field in AVFrame; unlike e.g. the timestamps, there is no > > fundamental link between coded packet offset/size and decoded frames > > - they only make sense for frames produced by decoding demuxed packets, > > and even then it is not always the case that the encoded data was > > stored in the file as a contiguous sequence of bytes (in order for pos > > to be well-defined) > > > - pkt_pos was added without much explanation, apparently to allow > > passthrough of this information through lavfi in order to handle byte > > seeking in ffplay. That is now implemented using arbitrary user data > > passthrough in AVFrame.opaque_ref. > > One intended use i remember was that errors are detected after decoding, > be that bitstream, metadata, aspect ratio, yuv type, ... > while the location of the error is in the source file around the packets > position. pkt_pos allows one to patch errors in the source file without > remuxing That is still possible, as shown in patches 2 and 4. -- Anton Khirnov _______________________________________________ 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".