Version

menu_open
Warning: you were redirected to the latest documentation corresponding to your major release ( 2023.1.8.8601 ). Should you wish to access your specific version's documentation, please download the offline documentation from the Audiokinetic Launcher and check the Offline Documentation option in Wwise Authoring.
Wwise SDK 2023.1.8

◆ QueryDiffractionPaths()

AKSOUNDENGINE_API AKRESULT AK::SpatialAudio::QueryDiffractionPaths ( AkGameObjectID  in_gameObjectID,
AkUInt32  in_positionIndex,
AkVector64 out_listenerPos,
AkVector64 out_emitterPos,
AkDiffractionPathInfo out_aPaths,
AkUInt32 io_uArraySize 
)

Query information about the diffraction state for a particular listener and emitter, which has been calculated using the data provided via the spatial audio emitter API. This function can be used for debugging purposes. Returned in out_aPaths, this array contains the sound paths calculated from diffraction around a geometric edge and/or diffraction through portals connecting rooms. No paths will be returned in any of the following conditions: (1) the emitter game object has a direct line of sight to the listener game object, (2) the emitter and listener are in the same room, and the listener is completely outside the radius of the emitter, or (3) The emitter and listener are in different rooms, but there are no paths found via portals between the emitter and the listener. A single path with zero diffraction nodes is returned when all of the following conditions are met: (1) the emitter and listener are in the same room, (2) there is no direct line of sight, and (3) either the Voice's Attenuation's curve max distance is exceeded or the accumulated diffraction coefficient exceeds 1.0. This function must acquire the global sound engine lock and, therefore, may block waiting for the lock.

See also
Parameters
in_gameObjectIDThe ID of the game object that the client wishes to query.
in_positionIndexThe index of the associated game object position.
out_listenerPosReturns the position of the listener game object that is associated with the game object in_gameObjectID.
out_emitterPosReturns the position of the emitter game object in_gameObjectID.
out_aPathsPointer to an array of AkDiffractionPathInfo's which will be filled on return.
io_uArraySizeThe number of slots in out_aPaths, after returning the number of valid elements written.

Was this page helpful?

Need Support?

Questions? Problems? Need more info? Contact us, and we can help!

Visit our Support page

Tell us about your project. We're here to help.

Register your project and we'll help you get started with no strings attached!

Get started with Wwise