Audiokinetic's Community Q&A is the forum where users can ask and answer questions within the Wwise and Strata communities. If you would like to get an answer from Audiokinetic's Technical support team, make sure you use the Support Tickets page.

0 votes
I music playing when player starts the level, but I need the beats per minute of the song. The songs can be different for the same level, so was wondering if Wwise has a function to get the bpm. Otherwise I feel I am just going to have to know the bpm of each song and hard code it?
in General Discussion by Tyler D. (100 points)

1 Answer

+2 votes

Hey Tyler, 

Yes there is a way to get the tempo in the game engine. If you are using Unity, you can get it in your callback function like this: 

void CallbackFunction(object in_cookie, AkCallbackType in_type, object in_info)
{

     AkMusicSyncCallbackInfo info = (AkMusicSyncCallbackInfo)in_info;
     print(60/info.segmentInfo_fBeatDuration);
}

And here is there's more on Music Callbacks.

by Mads Maretty S. (Audiokinetic) (40.2k points)
...