menu
Version
2023.1.9.8628
2024.1.1.8691
2023.1.9.8628
2022.1.18.8567
2021.1.14.8108
2019.2.15.7667
2019.1.11.7296
2018.1.11.6987
2017.2.10.6745
2017.1.9.6501
2016.2.6.6153
2015.1.9.5624
2024.1.1.8691
2023.1.9.8628
2022.1.18.8567
2021.1.14.8108
2019.2.15.7667
2019.1.11.7296
2018.1.11.6987
2017.2.10.6745
2017.1.9.6501
2016.2.6.6153
2015.1.9.5624
Wwise SDK 2023.1.9
|
If you are working on a project that includes a firearm with a rapid rate of fire, such as a machine gun, it can be difficult to accurately synchronize the bullet sounds with the firing action. Because Wwise events are processed asynchronously on the audio thread, there might be a slight delay between the break action and the termination of a gunshot sound if you implement the sound through a Sample Accurate transition on a looping container.
To achieve a sample-accurate trigger rate with rapid gunshots, we recommend that you use MIDI to trigger each bullet sound. PostMIDIOnEvent
makes it possible to respect the exact offset (in samples) within a given audio frame, which allows for high accuracy.
A MIDI-based solution requires the following:
AK::SoundEngine::RenderAudio()
yourself to place Play and Stop actions on the desired frame. Refer to the Audio Rendering Thread section in Optimizing CPU usage for details. <WwiseInstallationFolder>\SDK\samples\IntegrationDemo\DemoPages\DemoMIDIMetronome.cpp
and the corresponding documentation is available at Integration Demo Sample (see the MIDI API section).Questions? Problems? Need more info? Contact us, and we can help!
Visit our Support pageRegister your project and we'll help you get started with no strings attached!
Get started with Wwise