[ogg-dev] ogg decoding without "synchronization"
Ralph Giles
giles at thaumas.net
Wed Feb 24 17:42:44 PST 2010
On 24 February 2010 16:45, Nicolas Montgermont
<nicolas_montgermont at yahoo.fr> wrote:
> In this project I would like to read an ogg stream from an icecast
> server and decode data in the order it is incoming.
> I would like to skip the step that is reordering the data conforming to
> the order it was send.
The data reordering happens a couple of layers below the ogg
encapsulation, which itself assumes the data is in order. Icecast
sends the Ogg streams over HTTP, which is itself carried over the TCP
protocol, which does the reordering inside the kernel.
You could do what you want if you sent the vorbis data over RTP (in
UDP datagrams) instead of icecast's ogg-over-http approach. I believe
gstreamer can do this, with rtpvorbispay/depay, etc. There's also some
sample code at http://svn.xiph.org/trunk/xiph-rtp/ (possibly it's out
of date relative to the spec; I haven't looked at it in a few years).
UDP packets aren't reordered by the OS kernel's networking stack so
you can access the delivery order directly in your application.
Hope that helps,
-r
More information about the ogg-dev
mailing list