Audio Raycasting Demo

Описание к видео Audio Raycasting Demo

Music To Wear Fingerless Gloves To - by Punch Deck -    • Punch Deck - Music To Wear Fingerless...  

Hey all, it's been about a week since I first shared video of this audio raycasting system. Since then I faced some limitations with OpenAL and had to redo the majority of the system, and I have also optimised the raycasting algorithm, which can now cast 6.4 million rays per second per thread, up from 1.3 million in the first video.

I've also visualised the rays, which helped with debugging and I think it looks cool.

Directional sound calculation and low pass filters have also received an improvement - the low frequencies of a sound will now travel straight to the listener (i.e. the bass can be heard when the sound is enclosed) and the higher frequencies will bounce around in an attempt to reach the listener.

I have also increased how many times each ray bounces. When a sound first plays it casts 484 rays outwards that each bounce up to 8 times, checking for line-of-sight with the listener each time. This process takes ~0.6 milliseconds and happens on another thread, meaning the user will not notice the delay or stutter when multiple new sounds are created at once.

Then - to adapt to changes in the environment and increase ray coverage over time - another thread casts 32 rays out from each actively playing sound, which each bounce up to 32 times. This process takes ~0.15 milliseconds, meaning 16.6 / 0.15 = 110 sounds can be actively playing at once while maintaining 60 FPS on the audio thread.

My next step is to improve outdoor scenarios since the sky is stealing all my rays.

Комментарии

Информация по комментариям в разработке