[vlc-devel] [PATCH] stream: add stream_ForcedPeekNew

Francois Cartegnie fcvlcdev at free.fr
Thu Sep 10 17:53:31 CEST 2015


Le 10/09/2015 17:43, Rémi Denis-Courmont a écrit :
> As for wrapping an existing block of data as a stream, there are already
> (at least) 3 existing implementations (memory stream, SDP access and
> attachment access) doing essentially just that.

Memory stream needs to know buffer size prior creation (see below).

>> (using stream_Readline for exemple)
> 
> stream_ReadLine() does not seek to begin with!

It does Read.

> If a demuxer needs to read up to 200KiB to detect the format, it most
> certainly should be restricted to truly seekable streams anyway
> (possibly even only fast seekable).

Subtitles are 256 lines probing with 2K max line probing in
stream_Readline which is 512K.

Peeking 512K to fail late is a no go.

Francois




More information about the vlc-devel mailing list