[Vorbis] example code with streaming?
xiphmont at xiph.org
xiphmont at xiph.org
Tue Aug 28 11:37:00 PDT 2007
On 3/4/07, David.Stehlik at criticallink.com
<David.Stehlik at criticallink.com> wrote:
> Hello,
>
> I'm looking at vorbis for sending live audio over a network. This would probably be
> running on an embedded system (some challenges there, but that's ok).
> I've used the encoder example to get things compiling/running with sample data,
> but it seems to file based. Is there an example for streaming live audio?
You can send the output from the example encoder straight to a network
socket or any other stream, and similarly take the input from a stream
as well. The only 'file based' aspect of the encoder example is
sort-of kind-of expecting a WAV header. You can modify it to expect
anything at all.
> A secondary problem I may be running into is the amount of time to encode.
The Vorbis libs do not need any duration information; unlike WAV, that
information is not required for any kind of header. Ogg and Vorbis
are both true streaming formats and are fully function in a single
streaming pass.
Monty
More information about the Vorbis
mailing list