From: Derek Buitenhuis <derek.buitenhuis@gmail.com> To: ffmpeg-devel@ffmpeg.org Subject: Re: [FFmpeg-devel] [PATCH v2] avformat/dhav: fix backward scanning for get_duration and optimize seeking Date: Wed, 21 May 2025 14:23:16 +0100 Message-ID: <10672112-3865-498a-acc8-7bfd76779217@gmail.com> (raw) In-Reply-To: <AS8P250MB07449F0EB8A33C927B9F5B228F9FA@AS8P250MB0744.EURP250.PROD.OUTLOOK.COM> On 5/20/2025 8:18 PM, Andreas Rheinhardt wrote: > The only thing that you want from parsing the end is the end timestamp > and this is given by data alone. date is a 32bit le number at offset 16 > from the start of the dhav tag; it can be read directly from the buffer, > so you do not need to seek again and use read_chunk to get the end. > It also means that your ffio_ensure_seekback() is unnecessary (unless > you wanted to ensure that the seek back to start_pos works (which is > currently not guaranteed at all and not ensured by your code and would > probably also be bad in general given that this would cache the whole > file in memory). Thanks for the review, v3 sent. > (The above is based on the presumption that we are not really interested > in what parse_ext() may parse in the chunk at the end; I don't know > whether this is true or not.) AFAICT, we are not. Cheers, - Derek _______________________________________________ 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".
prev parent reply other threads:[~2025-05-21 13:23 UTC|newest] Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top 2025-05-20 15:27 Derek Buitenhuis 2025-05-20 19:18 ` Andreas Rheinhardt 2025-05-21 13:23 ` Derek Buitenhuis [this message]
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=10672112-3865-498a-acc8-7bfd76779217@gmail.com \ --to=derek.buitenhuis@gmail.com \ --cc=ffmpeg-devel@ffmpeg.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git