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 am a newbie in WWise. Recently, I am trying to integrate the Wwise plugin to my game project using UnrealEngine, with Event based packaging. Everything seems ok.

But I'm curious about what's the strategy the ebp used to load the events and banks.

Does it load all event and banks and their media data while starting the game? Or just load one after we call PostEvent?

I've try print a time before and after the postevent call? Found that it cost quite a small time, seems the event has already been loaded. But I don't think All Event will be loaded in start time, this cost too much.

Who can tell me the truth behind it?
in General Discussion by deXian z. (190 points)

1 Answer

+1 vote
 
Best answer
With EBP, AkAudioEvent and AkAudioBank assets serialize the bank data directly into the Unreal asset. When a map gets loaded, all assets referenced in the map (and in the map's blueprint nodes such as PostEvent) are loaded as well. When an event or bank asset is loaded, the media assets it references are also be loaded into memory (or an IO hook is opened if they are streaming). The loading system is designed this way so that all Wwise asset data required by a map will be in memory and usable once the map load is finished . In a similar way, unloading a map will unload the event, bank and media assets and their data will be garbage collected, freeing the memory.
by Etienne R. (Audiokinetic) (1.1k points)
selected by deXian z.
So, It means that if i want to control the event's loading time myself. I need to change  these AkEvent reference to SoftObjectPtr and async load them the time I need them?Thanks.
If you want to directly control the lifetime of an event and its media in memory, you will have to make sure you are loading and unloading the asset only in code (such as with  an asyncload). Otherwise its lifetime will be tied to that of the objects referencing it.

Another alternative that would work with just blueprints would be streaming sublevels with your events in and out depending on whether you need them.
...