ValveSoftware / steam-audio

Steam Audio
https://valvesoftware.github.io/steam-audio/
Apache License 2.0
2.2k stars 152 forks source link

[UE5.3.2] Plugin does not work #293

Closed magswag closed 6 months ago

magswag commented 6 months ago

System Information Please provide the following information about your system:

Issue Description I went through the necessary steps of deleting the version of Steam Audio that ships with the engine, and downloaded the 4.5.0 release from Github. Then I extracted the "SteamAudio" folder into my blank project's plugin folder, enabled it in the project, and set it up in the [Project Settings/Platforms/Windows] settings. I then created a simple scene consisting of an extruded cube making up a wall, and an extruded cube making up the floor. I then tagged these cubes with the geometry component and exported the geometry, which I verified to be exported properly. However, when I created an actor with an audio component in the scene and set up the sound attenuation to use binaural spatialization with the steam audio config, it did not work, it sounded exactly the same as panning. Occlusion did not work either, at all.

Steps To Reproduce Steps to reproduce the behavior:

  1. Delete the built-in SteamAudio from UE5.3.2
  2. Install SteamAudio 4.5.0 to a blank project.
  3. Enable it, and set it up in platform settings.
  4. Blockout a simple scene.
  5. Tag all meshes using the plugin and export geometry.
  6. Drag a soundcue into the scene and override it's attenuation settings.
  7. Set the spatialization method to Binaural, and create a new steam audio asset for the spatialization plugin settings, where you enable binaural and set the interpolation to bilinear.
  8. Enable occlusion and create a new steam audio asset for the plugin settings. Enable "apply occlusion" on this asset.
lakulish commented 6 months ago

I tried to repro this issue, and I observed the following:

I think this has to do with the way the plugin is re-initialized when entering play-in-editor mode. Can you try commenting out line 138 of the function FSteamAudioModule::OnPIEStarted in Plugins/SteamAudio/Source/SteamAudio/Private/SteamAudioModule.cpp? This line currently reads:

Manager->ShutDownSteamAudio();

After commenting this line out, you will need to rebuild your project. If you are able to try this, let me know if it helps fix the issue. Thanks!

magswag commented 6 months ago

Commenting out line 138 and recompiling the plugin worked, thank you! 😄

lakulish commented 5 months ago

This issue should now be fixed in v4.5.1.