#include <C:/Users/Andres/source/repos/casm_viewer/external/tinc/external/allolib/include/al/sound/al_Ambisonics.hpp>
|
| AmbiEncode (int dim, int order) |
|
void | encode (float *ambiChans, int numFrames, int timeIndex, float timeSample) const |
| Encode a single time sample. More...
|
|
void | encode (float *ambiChans, const float *input, int numFrames) |
| Encode buffer with constant position throughout buffer. More...
|
|
template<class XYZ > |
void | encode (float *ambiChans, const XYZ *dir, const float *input, int numFrames) |
| Encode a buffer of samples. More...
|
|
void | direction (float az, float el) |
| Set spherical direction of source to be encoded.
|
|
void | direction (Vec3f direction) |
|
void | direction (float x, float y, float z) |
|
void | print (std::ostream &stream) |
|
int | dim () const |
| Get number dimensions.
|
|
void | dim (int dim) |
| Set the number of dimensions.
|
|
int | order () const |
| Get order.
|
|
void | order (int order) |
| Set the order.
|
|
const float * | weights () const |
| Get Ambisonic channel weights.
|
|
int | channels () const |
| Returns total number of Ambisonic domain (B-format) channels.
|
|
virtual void | onChannelsChange () |
| Called whenever the number of Ambisonic channels changes.
|
|
|
static int | channelsToUniformOrder (int channels) |
|
static void | encodeWeightsFuMa (float *weights, int dim, int order, float azimuth, float elevation) |
|
static void | encodeWeightsFuMa (float *ws, int dim, int order, float x, float y, float z) |
|
static void | encodeWeightsFuMa16 (float *weights, float azimuth, float elevation) |
| Brute force 3rd order. Weights must be of size 16.
|
|
static void | encodeWeightsFuMa16 (float *ws, float x, float y, float z) |
| (x,y,z unit vector in the listener's coordinate frame)
|
|
static int | orderToChannels (int dim, int order) |
|
static int | orderToChannelsH (int orderH) |
|
static int | orderToChannelsV (int orderV) |
|
static int | channelsToOrder (int channels) |
|
static int | channelsToDimensions (int channels) |
|
|
template<typename T > |
static void | resize (T *&a, int n) |
|
|
int | mDim |
|
int | mOrder |
|
int | mChannels |
|
float * | mWeights |
|
Higher Order Ambisonic encoding class
Definition at line 260 of file al_Ambisonics.hpp.
◆ AmbiEncode()
al::AmbiEncode::AmbiEncode |
( |
int |
dim, |
|
|
int |
order |
|
) |
| |
|
inline |
- Parameters
-
[in] | dim | number of spatial dimensions (2 or 3) |
[in] | order | highest spherical harmonic order |
Definition at line 264 of file al_Ambisonics.hpp.
◆ direction() [1/2]
void al::AmbiEncode::direction |
( |
float |
x, |
|
|
float |
y, |
|
|
float |
z |
|
) |
| |
|
inline |
Set Cartesian direction of source to be encoded (x,y,z unit vector in the listener's coordinate frame)
Definition at line 450 of file al_Ambisonics.hpp.
◆ direction() [2/2]
void al::AmbiEncode::direction |
( |
Vec3f |
direction | ) |
|
|
inline |
Set Cartesian direction of source to be encoded direction vector must be normalized
Definition at line 445 of file al_Ambisonics.hpp.
◆ encode() [1/3]
void al::AmbiEncode::encode |
( |
float * |
ambiChans, |
|
|
const float * |
input, |
|
|
int |
numFrames |
|
) |
| |
|
inline |
Encode buffer with constant position throughout buffer.
- Parameters
-
ambiChans | Ambisonic domain channels (non-interleaved) |
input | time-domain sample buffer to encode |
numFrames | number of frames to encode |
Definition at line 474 of file al_Ambisonics.hpp.
◆ encode() [2/3]
template<class XYZ >
void al::AmbiEncode::encode |
( |
float * |
ambiChans, |
|
|
const XYZ * |
dir, |
|
|
const float * |
input, |
|
|
int |
numFrames |
|
) |
| |
Encode a buffer of samples.
- Parameters
-
[in] | ambiChans | Ambisonic domain channels (non-interleaved) |
[in] | dir | unit vector in the listener's coordinate frame) |
[in] | input | time-domain sample buffer to encode |
[in] | numFrames | number of frames to encode |
Definition at line 489 of file al_Ambisonics.hpp.
◆ encode() [3/3]
void al::AmbiEncode::encode |
( |
float * |
ambiChans, |
|
|
int |
numFrames, |
|
|
int |
timeIndex, |
|
|
float |
timeSample |
|
) |
| const |
|
inline |
Encode a single time sample.
- Parameters
-
[out] | ambiChans | Ambisonic domain channels (non-interleaved) |
[in] | numFrames | number of frames in time buffer |
[in] | timeIndex | index at which to encode time sample |
[in] | timeSample | value of time sample |
Definition at line 454 of file al_Ambisonics.hpp.
◆ encodeWeightsFuMa() [1/2]
static void al::AmbiBase::encodeWeightsFuMa |
( |
float * |
weights, |
|
|
int |
dim, |
|
|
int |
order, |
|
|
float |
azimuth, |
|
|
float |
elevation |
|
) |
| |
|
staticinherited |
Compute spherical harmonic weights based on azimuth and elevation azimuth is anti-clockwise; both azimuth and elevation are in degrees
◆ encodeWeightsFuMa() [2/2]
static void al::AmbiBase::encodeWeightsFuMa |
( |
float * |
ws, |
|
|
int |
dim, |
|
|
int |
order, |
|
|
float |
x, |
|
|
float |
y, |
|
|
float |
z |
|
) |
| |
|
staticinherited |
Compute spherical harmonic weights based on unit direction vector (in the listener's coordinate frame)
The documentation for this class was generated from the following file: