版本

menu_open
Wwise SDK 2021.1.14

◆ SetSpeakerAngles()

AKSOUNDENGINE_API AKRESULT AK::SoundEngine::SetSpeakerAngles ( const AkReal32 in_pfSpeakerAngles,
AkUInt32  in_uNumAngles,
AkReal32  in_fHeightAngle,
AkOutputDeviceID  in_idOutput = 0 
)

Sets speaker angles of the specified device. Speaker angles are used for 3D positioning of sounds over standard configurations. Note that the current version of Wwise only supports positioning on the plane. The speaker angles are expressed as an array of loudspeaker pairs, in degrees, relative to azimuth ]0,180]. Supported loudspeaker setups are always symmetric; the center speaker is always in the middle and thus not specified by angles. Angles must be set in ascending order. Note:

  • This function requires that the minimum speaker angle is at least 5 degrees; as well as the subsequent speaker pairs are at least 5 degrees apart. Typical usage:
  • Initialize the sound engine and/or add secondary output(s).
  • Get number of speaker angles and their value into an array using GetSpeakerAngles().
  • Modify the angles and call SetSpeakerAngles(). This function posts a message to the audio thread through the command queue, so it is thread safe. However the result may not be immediately read with GetSpeakerAngles().
    警告
    This function only applies to configurations (or subset of these configurations) that are standard and whose speakers are on the plane (2D).
    返回
  • AK_Success if successful.
  • AK_InvalidFloatValue if the value specified was NaN or Inf
  • AK_InsufficientMemory if there wasn't enough memory in the message queue
    参见
    GetSpeakerAngles()
参数
in_pfSpeakerAngles Array of loudspeaker pair angles, in degrees relative to azimuth [0,180].
in_uNumAngles Number of elements in in_pfSpeakerAngles. It must correspond to AK::GetNumberOfAnglesForConfig( AK_SPEAKER_SETUP_DEFAULT_PLANE ) (the value returned by GetSpeakerAngles()).
in_fHeightAngle Elevation of the height layer, in degrees relative to the plane [-90,90].
in_idOutput Output ID to set the bus on. As returned from AddOutput or GetOutputID. You can pass 0 for the main (default) output

此页面对您是否有帮助?

需要技术支持?

仍有疑问?或者问题?需要更多信息?欢迎联系我们,我们可以提供帮助!

查看我们的“技术支持”页面

介绍一下自己的项目。我们会竭力为您提供帮助。

来注册自己的项目,我们帮您快速入门,不带任何附加条件!

开始 Wwise 之旅