[FFmpeg-devel] [PATCH] RTSP-MS 14/15: ASF packet parsing
Michael Niedermayer
michaelni
Thu Apr 23 21:38:48 CEST 2009
On Thu, Apr 23, 2009 at 03:12:57PM -0400, Ronald S. Bultje wrote:
> Hi,
>
> On Thu, Apr 23, 2009 at 3:06 PM, Michael Niedermayer <michaelni at gmx.at> wrote:
> > there are 17 get_byte, 3 get_buffer and 101 get_le* in asfdec.c
> > each could fail with EAGAIN in case of a non blocking pipe
>
> We're using a buffered I/O, so you could create a public
> fill_buffer_for_at_least(pb, size) which does the obvious. After a
> succesful call to this function, we would guarantee that the next size
> bytes would be available without blocking.
such function may be usefull ...
>
> One call to this function at the top of get_packet() where size =
> HEADER_SIZE,
get_packet() can read an arbitrary amount, and its data dependant on
where the right bytes are found for resync
> and one in parse_packet() where size =
> next_packet_data_size.
i think you have a strangely oversimplified view of the asf demuxer
there are many other things, the main header being one, and other
things that can read more then the packet size being another ...
If you want to make the asf demuxer support arbitrary non blocking streams
i dont mind but this wont be easy, also this contains things that are not
needed for rtp-asf.
remember we need to handle EAGAIN at a single spot for rtp-asf. for
non blocking streams it must be handled or avoided at every spot.
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Good people do not need laws to tell them to act responsibly, while bad
people will find a way around the laws. -- Plato
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090423/b026710e/attachment.pgp>
More information about the ffmpeg-devel
mailing list