Bluish Coder

Programming Languages, Martials Arts and Computers. The Weblog of Chris Double.


Ogg Vorbis support for Factor

I've implemented Ogg Vorbis playback in Factor. The library is in the module 'libs/vorbis' and supports playing Vorbis encoded audio from .ogg files and streams:

"test.ogg" play-vorbis-file
"" http-get* [
] keep stream-close

The audio is played back using the OpenAL wrapper I wrote last month.

Some example Ogg Vorbis files are available at the Vorbis site.

I've been testing the library against a test.ogg file which contains Vorbis audio and Theora video. Currently the Factor library only plays back the Vorbis audio stream but I plan to get to Theora playback eventually. I converted test.ogg from the original Windows Media format file of James Hill playing Allegro con brio on the Ukulele.

You'll need libraries for Ogg and Vorbis installed. I've packed precompiled DLLs for Windows in

The playback yields timeslices while decoding and playing to allow other Factor threads to run. I'm able to play music, streamed from the Factor httpd server, while playing Factor Space Invaders all from the same Factor instance quite nicely.


This site is accessable over tor as hidden service 6vp5u25g4izec5c37wv52skvecikld6kysvsivnl6sdg6q7wy25lixad.onion, or Freenet using key: