From 44231b97fa8d8198eeb4323737f137fb6e795158 Mon Sep 17 00:00:00 2001 From: Nico de Poel Date: Fri, 30 Jul 2021 16:53:35 +0200 Subject: [PATCH] Move FMOD mixer thread off the same core as the Unity main thread --- Assets/Scripts/AudioManager.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Assets/Scripts/AudioManager.cs b/Assets/Scripts/AudioManager.cs index c00020e..a47e29a 100644 --- a/Assets/Scripts/AudioManager.cs +++ b/Assets/Scripts/AudioManager.cs @@ -81,6 +81,11 @@ public class AudioManager : MonoBehaviour if (fmodSystem.hasHandle()) return; +#if UNITY_PS4 || UNITY_PS5 || UNITY_GAMECORE + // Move FMOD mixer thread off the already heavily congested core 1 + FMOD.Thread.SetAttributes(FMOD.THREAD_TYPE.MIXER, FMOD.THREAD_AFFINITY.CORE_4); +#endif + FMOD.RESULT result = FMOD.Factory.System_Create(out fmodSystem); CheckFmodResult(result, "FMOD.Factory.System_Create");