diff options
author | Chris Robinson <[email protected]> | 2017-03-09 07:23:12 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2017-03-09 07:23:12 -0800 |
commit | 9454d3e776792ed5762d72f28f6785b4b2d1606c (patch) | |
tree | a394127ff43f91a72cb4cf005ca149064f8cf9c9 /OpenAL32/Include | |
parent | ae22d742dc665fb5a75a24c9af24945a5722d8ff (diff) |
Move ALvoice declaration to alu.h
Diffstat (limited to 'OpenAL32/Include')
-rw-r--r-- | OpenAL32/Include/alSource.h | 54 | ||||
-rw-r--r-- | OpenAL32/Include/alu.h | 56 |
2 files changed, 55 insertions, 55 deletions
diff --git a/OpenAL32/Include/alSource.h b/OpenAL32/Include/alSource.h index 12b4587b..1dd835c4 100644 --- a/OpenAL32/Include/alSource.h +++ b/OpenAL32/Include/alSource.h @@ -77,60 +77,6 @@ struct ALsourceProps { }; -typedef struct ALvoice { - struct ALsourceProps *Props; - - ATOMIC(struct ALsource*) Source; - ATOMIC(bool) Playing; - - /* Current buffer queue item being played. */ - ATOMIC(ALbufferlistitem*) current_buffer; - - /** - * Source offset in samples, relative to the currently playing buffer, NOT - * the whole queue, and the fractional (fixed-point) offset to the next - * sample. - */ - ATOMIC(ALuint) position; - ATOMIC(ALuint) position_fraction; - - /** - * Number of channels and bytes-per-sample for the attached source's - * buffer(s). - */ - ALsizei NumChannels; - ALsizei SampleSize; - - /** Current target parameters used for mixing. */ - ALint Step; - - /* If not 'moving', gain/coefficients are set directly without fading. */ - ALboolean Moving; - - ALboolean IsHrtf; - - ALuint Offset; /* Number of output samples mixed since starting. */ - - alignas(16) ALfloat PrevSamples[MAX_INPUT_CHANNELS][MAX_PRE_SAMPLES]; - - InterpState ResampleState; - - struct { - DirectParams Params[MAX_INPUT_CHANNELS]; - - ALfloat (*Buffer)[BUFFERSIZE]; - ALsizei Channels; - } Direct; - - struct { - SendParams Params[MAX_INPUT_CHANNELS]; - - ALfloat (*Buffer)[BUFFERSIZE]; - ALsizei Channels; - } Send[]; -} ALvoice; - - typedef struct ALsource { /** Source properties. */ ALfloat Pitch; diff --git a/OpenAL32/Include/alu.h b/OpenAL32/Include/alu.h index b6f0e769..03f0090d 100644 --- a/OpenAL32/Include/alu.h +++ b/OpenAL32/Include/alu.h @@ -35,9 +35,9 @@ extern "C" { struct ALsource; struct ALsourceProps; +struct ALbufferlistitem; struct ALvoice; struct ALeffectslot; -struct ALbuffer; /* The number of distinct scale and phase intervals within the filter table. */ @@ -123,6 +123,7 @@ typedef struct MixHrtfParams { } Steps; } MixHrtfParams; + typedef struct DirectParams { enum ActiveFilters FilterType; ALfilterState LowPass; @@ -151,6 +152,59 @@ typedef struct SendParams { } Gains; } SendParams; +typedef struct ALvoice { + struct ALsourceProps *Props; + + ATOMIC(struct ALsource*) Source; + ATOMIC(bool) Playing; + + /* Current buffer queue item being played. */ + ATOMIC(struct ALbufferlistitem*) current_buffer; + + /** + * Source offset in samples, relative to the currently playing buffer, NOT + * the whole queue, and the fractional (fixed-point) offset to the next + * sample. + */ + ATOMIC(ALuint) position; + ATOMIC(ALuint) position_fraction; + + /** + * Number of channels and bytes-per-sample for the attached source's + * buffer(s). + */ + ALsizei NumChannels; + ALsizei SampleSize; + + /** Current target parameters used for mixing. */ + ALint Step; + + /* If not 'moving', gain/coefficients are set directly without fading. */ + ALboolean Moving; + + ALboolean IsHrtf; + + ALuint Offset; /* Number of output samples mixed since starting. */ + + alignas(16) ALfloat PrevSamples[MAX_INPUT_CHANNELS][MAX_PRE_SAMPLES]; + + InterpState ResampleState; + + struct { + DirectParams Params[MAX_INPUT_CHANNELS]; + + ALfloat (*Buffer)[BUFFERSIZE]; + ALsizei Channels; + } Direct; + + struct { + SendParams Params[MAX_INPUT_CHANNELS]; + + ALfloat (*Buffer)[BUFFERSIZE]; + ALsizei Channels; + } Send[]; +} ALvoice; + typedef const ALfloat* (*ResamplerFunc)(const InterpState *state, const ALfloat *restrict src, ALuint frac, ALint increment, |