|
Game Audio Module
A C++ audio system using miniaudio with Python bindings
|
3D vector class for spatial audio positioning More...
#include <cmath>Go to the source code of this file.
Classes | |
| struct | audio::Vec3 |
| 3D vector for spatial audio positioning More... | |
Namespaces | |
| namespace | audio |
Functions | |
| Vec3 | audio::Cross (const Vec3 &a, const Vec3 &b) |
| Cross product of two vectors. | |
| float | audio::Dot (const Vec3 &a, const Vec3 &b) |
| Dot product of two vectors. | |
3D vector class for spatial audio positioning
This is an engine-agnostic 3D vector implementation for spatial audio. It provides basic vector operations needed for 3D audio positioning.
Coordinate System: The audio system uses the OpenGL/miniaudio coordinate system:
This matches most 3D game engines. To convert from your engine's coordinate system, simply map your engine's X, Y, Z components to Vec3's x, y, z components. If your engine uses a different handedness or axis orientation, you may need to swap or negate components.