Hello! I’m still understanding the ins and outs of FMOD and couldn’t find this topic anywhere. In Unity, I’m trying to set up a slider control in an audio settings menu for the Panner with the goal of helping people with hearing impairments adjust the location of the sound. So, in Routing, on the Master Bus, I have added a Panner effect, but don’t know how to navigate to it in order to control it within Unity. Any suggestions or resources would be greatly helpful.
An option would be adding
Automation (FMOD Studio | Authoring Events - Automation and Modulation) to the
Direction variable (FMOD API | Effect Reference - Pan) of the
Panner effect. Automation allows us to control parameters from code in Unity via:
FMODUnity.RuntimeManager.StudioSystem.setParameterByName() (FMOD API | Studio API Reference - Studio::System).
Here is the parameter I used to control the value:
I have the effect set up in Studio, with the
Extent set to
180 to limit the panning to the left or right when the
Direction is changed.
Then in Unity, you control the parameter like this:
// Pan right FMODUnity.RuntimeManager.StudioSystem.setParameterByName("Surround Direction", 90) // Pan left FMODUnity.RuntimeManager.StudioSystem.setParameterByName("Surround Direction", -90)
Hope this helps!
After doing a little tweaking, I was able to get this working based on your breakdown and information. Thank you for the help!
No worries, happy to help! If you have any more questions please do not hesitate to ask!