Splicing music

A long day spent Googling has taught me a lot about DJ mixes and such,
but nothing about what I really want to know. I’ve little experience
with using SDL’s audio routines, but I’d like to transition between
various loops of music without a hitch. How do people do this? Is it
as simple as waiting for a zero crossing, or are there some tricks to
match beats or harmonics? Thanks!

no idea, but you might want to have a look in audacity or ardour, both are
opensource audio mixing progams, they might have some clues…On Fri, Aug 1, 2008 at 7:03 AM, Samwyse wrote:

A long day spent Googling has taught me a lot about DJ mixes and such, but
nothing about what I really want to know. I’ve little experience with using
SDL’s audio routines, but I’d like to transition between various loops of
music without a hitch. How do people do this? Is it as simple as waiting
for a zero crossing, or are there some tricks to match beats or harmonics?
Thanks!


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Iskandar Prins wrote:

no idea, but you might want to have a look in audacity or ardour, both
are opensource audio mixing progams, they might have some clues…

Sorry, I guess I wasn’t clear. I don’t want to do it myself; if so, I’d
learn how to use a DJ mixing tool, like Rapid Evolution (available at
http://www.mixshare.com/software.html).

I’m interested in the situation where just the player’s character is on
screen (and the music is relatively sedate) and then a boss appears and
the music increases in its speed and intensity. The game needs to do
the transition at “any” time, since the change usually happens in
response to a player’s action. If the loops have much length, I don’t
want to wait for the current cycle to end, but I don’t want a jarring
transition, either. The good news is that I get to choose the loops so
that they are in the same or compatible keys and their beats-per-minute
are all even multiples of some greatest-common-divisor.

I imagine that there are other “cheats” available, I just don’t know
what they are. Now that I’ve written all this our, maybe I’ll go search
gamasutra again.

Iskandar Prins wrote:

no idea, but you might want to have a look in audacity or ardour,
both are opensource audio mixing progams, they might have some
clues…

Sorry, I guess I wasn’t clear. I don’t want to do it myself; if so,
I’d learn how to use a DJ mixing tool, like Rapid Evolution
(available at http://www.mixshare.com/software.html).

I’m interested in the situation where just the player’s character is
on screen (and the music is relatively sedate) and then a boss
appears and the music increases in its speed and intensity. The
game needs to do the transition at “any” time, since the change
usually happens in response to a player’s action. If the loops have
much length, I don’t want to wait for the current cycle to end, but
I don’t want a jarring transition, either.
The simplest way to do it programatically would be a cross fade of
length determined by delta bpm. Although a jarring transition may be
appropriate for shock value.
EdOn 1 Aug 2008, at 13:23, Samwyse wrote:
The good news is that I get to choose the loops so that they are in
the same or compatible keys and their beats-per-minute are all even
multiples of some greatest-common-divisor.

I imagine that there are other “cheats” available, I just don’t know
what they are. Now that I’ve written all this our, maybe I’ll go
search gamasutra again.


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Samwyse wrote:

I imagine that there are other “cheats” available, I just don’t know
what they are. Now that I’ve written all this our, maybe I’ll go
search gamasutra again.

i would use midi or some kind of tracker. changing tempo/key gets
trivial there and you get some more possibillities for free too.
( for example adding/removing tracks in realtime without having millions
of samples and loops around).

best regards …
clemens