Show HN: AudioNimbus – Steam Audio's immersive spatial audio, now in Rust
https://github.com/MaxenceMaire/audionimbus
Hi HN! I’m excited to share AudioNimbus, a Rust library that brings the powerful spatial audio capabilities of Steam Audio to the Rust ecosystem. Whether you’re building games, VR/AR experiences, or simulations, AudioNimbus makes it easier to integrate realistic, immersive audio into your projects.Steam Audio is a toolkit for spatial audio, developed by Valve. It simulates realistic sound propagation, including effects like directionality, distance attenuation, reflections, and reverb. It’s used in games like Half-Life: Alyx and Counter-Strike 2.
Rust is increasingly being adopted in game development, but there’s a need to bridge the gap with industry-proven tools like Steam Audio. AudioNimbus aims to fill that gap, making it easier to integrate immersive audio into Rust projects.
AudioNimbus supports a variety of spatial audio effects, including:
- Head-Related Transfer Function (HRTF): Simulates how the listener’s ears, head, and shoulders shape sound perception, providing the acoustic cues the brain uses to infer direction and distance.
- Ambisonics and surround sound: Uses multiple audio channels to create the sensation of sound coming from specific directions.
- Sound propagation: Models how sound is affected as it travels through its environment, including effects like distance attenuation and interaction with physical obstacles of varying materials.
- Reflections: Simulates how sound waves reflect off surrounding geometry, mimicking real-world acoustic behavior.
The project is open-source on GitHub: https://github.com/MaxenceMaire/audionimbus
It includes code snippets and examples to help you get started. Contributions and feedback are welcome!
I’d love to hear your thoughts and see what you build with AudioNimbus. Feel free to share your projects, ask questions, or suggest improvements.
Happy hacking!
Looks like it uses emitter positions and a virtual head. It also has the ability to utilize untextured scene geometry.
No, Steam Audio is a standalone library and does not require integration with the Steam client.
> Are there additional licenses?
Steam Audio is released under the Apache 2.0 license, which is permissive and allows for both open-source and commercial use.
As for how it works: some effects, like ambisonics or HRTF-based spatialization, don’t require 3D geometry and work purely based on the direction and distance of sound sources relative to the listener.
Other effects, like occlusion, reflections, and reverb, rely on a scene description (the 3D geometry and material properties of objects in the environment). For example, sound waves can reflect off walls or be absorbed by soft materials.
Simulating these effects in real-time can be computationally expensive, especially for complex scenes. To optimize performance, effects like reflections can be pre-baked using probes placed throughout the scene.