[FFmpeg-devel] [PATCH 2/3] avformat/mux: Avoid overhead of packet list in case of single streams
Andreas Rheinhardt
andreas.rheinhardt at outlook.com
Sat Oct 9 18:50:47 EEST 2021
Hendrik Leppkes:
> On Sat, Oct 9, 2021 at 5:14 PM Andreas Rheinhardt
> <andreas.rheinhardt at outlook.com> wrote:
>>
>> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
>> ---
>> libavformat/internal.h | 7 +++++++
>> libavformat/mux.c | 11 ++++++++++-
>> 2 files changed, 17 insertions(+), 1 deletion(-)
>>
>> diff --git a/libavformat/internal.h b/libavformat/internal.h
>> index 223befdbc0..867b5de514 100644
>> --- a/libavformat/internal.h
>> +++ b/libavformat/internal.h
>> @@ -760,6 +760,13 @@ int ff_add_attached_pic(AVFormatContext *s, AVStream *st, AVIOContext *pb,
>> int ff_interleave_packet_per_dts(AVFormatContext *s, AVPacket *pkt,
>> int flush, int has_packet);
>>
>> +/**
>> + * Interleave packets directly in the order in which they arrive
>> + * without any sort of buffering.
>> + */
>> +int ff_interleave_packet_passthrough(AVFormatContext *s, AVPacket *pkt,
>> + int flush, int has_packet);
>> +
>
> The name seems inaccurate if its designed for a single stream and does
> not in fact do any actual interleaving.
>
The name stems from the fact that it is used as an interleavement
function. And in 3/3 it is used in a scenario where there might be more
than one stream.
- Andreas
More information about the ffmpeg-devel
mailing list