[SDL] Sound and Music

Tyler Montbriand tsm at accesscomm.ca
Sat Sep 17 21:18:02 PDT 2005


On September 17, 2005 08:14 pm, Marian Schedenig wrote:
> What I'd still like to know: Is streaming an ogg file from the HD the right
> way to play music, or would it be better to load the entire ogg and just
> "stream decode" from RAM?
I'd stream from file.  You might get a little performance benefit from having 
it all in memory but not much, and using excessive amounts of memory can lead 
to swapping, which will slow things down a LOT.

If you want to get fancy, you can "map" the file into to memory, to have the 
OS automatically load the appropriate bits as needed;  but not everything can 
do this.




More information about the SDL mailing list