Set an audio device
AdvancedProgrammer
You can set which audio device Xenko uses. For example, you can access the Oculus Rift audio device from your custom game constructor.
If you don't specify a device, Xenko uses the default audio advice.
Example code
This code sets the Oculus Rift device at runtime:
namespace OculusRenderer
{
public class OculusGame : Game
{
public OculusGame()
{
var deviceName = OculusOvr.GetAudioDeviceFullName();
var deviceUuid = new AudioDevice { Name = deviceName };
Audio.RequestedAudioDevice = deviceUuid;
}
}
}