Interesting. It must be a lot of work, though, to position the loop-to point
perfectly in a waveform so it’ll loop without popping!
BTW if you’ve got code to add cue chunk checking to .wav and .ogg files, could
you incorporate that into SDL_Mixer? It would definitely be helpful!>----- Original Message ----
From: Forest Hale
Subject: Re: [SDL] SDL_mixer resource leak fixes -> RWops revampOn 04/26/2011 10:41 AM, Mason Wheeler wrote:
No, they have different capabilities. Tracked (“MOD”) music, for example,
has the all-important capability to loop to an arbitrary section of the song,
which is crucial for video game music. Waveform formats simply can’t
do this.This can be done.
In DarkPlaces I parse the "cue " chunk from .wav files which specifies the loop
point (so when it hits the end of the sound, it goes back to this point),
unfortunately not many editors can write this chunk.And for .ogg someone added custom tags to music which specifies the sample
position to loop to, and DarkPlaces looks for those tags.That said, mod music has other nice features like custom commands which could
enable gameplay synchronized to the music, or vice versa.I’ve been told that OpenAL can’t do this sort of intro+loop effect… how
strange.P.S. Quake used the "cue " chunks in wav in the same way back in 1996 for its
intro+loop sound effects for door opening/lift moving sounds and all the ambient
sounds (swampy noises, torch crackle, flickering fluorescent lights, etc), this
is nothing new, a huge portion of its sound files had such looping.