zenilib: zenilib/jni/external/openal-soft/Alc/mixer_c.c File Reference

zenilib 0.5.3.0

- Main Page
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Macros | Functions
mixer_c.c File Reference
`#include "config.h"`
`#include <assert.h>`
`#include "alMain.h"`
`#include "alu.h"`
`#include "alSource.h"`
`#include "alAuxEffectSlot.h"`
`#include "mixer_inc.c"`

Go to the source code of this file.

## Macros

#define | DECL_TEMPLATE(Sampler)
#define | SUFFIX C

## Functions

static __inline void | ApplyCoeffs (ALuint Offset, ALfloat(*RESTRICT Values)[2], const ALuint IrSize, ALfloat(*RESTRICT Coeffs)[2], ALfloat left, ALfloat right)
static __inline void | ApplyCoeffsStep (ALuint Offset, ALfloat(*RESTRICT Values)[2], const ALuint IrSize, ALfloat(*RESTRICT Coeffs)[2], const ALfloat(*RESTRICT CoeffStep)[2], ALfloat left, ALfloat right)
static __inline ALfloat | cubic32 (const ALfloat *vals, ALuint frac)
static __inline ALfloat | lerp32 (const ALfloat *vals, ALuint frac)
void | MixDirect_C (const DirectParams *params, const ALfloat *RESTRICT data, ALuint srcchan, ALuint OutPos, ALuint SamplesToDo, ALuint BufferSize)
void | MixSend_C (const SendParams *params, const ALfloat *RESTRICT data, ALuint OutPos, ALuint SamplesToDo, ALuint BufferSize)
static __inline ALfloat | point32 (const ALfloat *vals, ALuint frac)
void | Resample_copy32_C (const ALfloat *data, ALuint frac, ALuint increment, ALfloat *RESTRICT OutBuffer, ALuint BufferSize)

## Macro Definition Documentation

#define DECL_TEMPLATE | ( |  | Sampler | ) |

Value:
void Resample_##Sampler##_C(const ALfloat *data, ALuint frac, \
ALuint increment, ALfloat *RESTRICT OutBuffer, ALuint BufferSize) \
{ \
ALuint pos = 0; \
ALuint i; \
\
for(i = 0;i < BufferSize+1;i++) \
{ \
OutBuffer[i] = Sampler(data + pos, frac); \
\
frac += increment; \
pos += frac>>FRACTIONBITS; \
frac &= FRACTIONMASK; \
} \
}
ALfloat
float ALfloat
Definition: al.h:68
for
for(;;)
Definition: glslang_tab.cpp:4773
data
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl2ext.h:848
ALuint
unsigned int ALuint
Definition: al.h:59
FRACTIONMASK
#define FRACTIONMASK
Definition: alu.h:51
FRACTIONBITS
#define FRACTIONBITS
Definition: alu.h:49
i
int i
Definition: pngrutil.c:1377

Definition at line 26 of file mixer_c.c.

#define SUFFIX C

Definition at line 81 of file mixer_c.c.

## Function Documentation

static __inline void ApplyCoeffs | ( | ALuint | Offset,
|  | ALfloat(*) | Values[2],
|  | const ALuint | IrSize,
|  | ALfloat(*) | Coeffs[2],
|  | ALfloat | left,
|  | ALfloat | right
| ) |  |

static

Definition at line 67 of file mixer_c.c.

References HRIR_MASK.

static __inline void ApplyCoeffsStep | ( | ALuint | Offset,
|  | ALfloat(*) | Values[2],
|  | const ALuint | IrSize,
|  | ALfloat(*) | Coeffs[2],
|  | const ALfloat(*) | CoeffStep[2],
|  | ALfloat | left,
|  | ALfloat | right
| ) |  |

static

Definition at line 50 of file mixer_c.c.

References HRIR_MASK.

static __inline ALfloat cubic32 | ( | const ALfloat * | vals,
|  | ALuint | frac
| ) |  |

static

Definition at line 15 of file mixer_c.c.

References cubic(), and FRACTIONONE.

static __inline ALfloat lerp32 | ( | const ALfloat * | vals,
|  | ALuint | frac
| ) |  |

static

Definition at line 13 of file mixer_c.c.

References FRACTIONONE, and lerp().

void MixDirect_C | ( | const DirectParams * | params,
|  | const ALfloat *RESTRICT | data,
|  | ALuint | srcchan,
|  | ALuint | OutPos,
|  | ALuint | SamplesToDo,
|  | ALuint | BufferSize
| ) |  |

Definition at line 86 of file mixer_c.c.

References BUFFERSIZE, DirectParams::ClickRemoval, DirectParams::Gains, MaxChannels, DirectParams::OutBuffer, and DirectParams::PendingClicks.

Referenced by SelectDirectMixer().

void MixSend_C | ( | const SendParams * | params,
|  | const ALfloat *RESTRICT | data,
|  | ALuint | OutPos,
|  | ALuint | SamplesToDo,
|  | ALuint | BufferSize
| ) |  |

Definition at line 112 of file mixer_c.c.

References BUFFERSIZE, ALeffectslot::ClickRemoval, SendParams::Gain, ALeffectslot::PendingClicks, and SendParams::Slot.

Referenced by SelectSendMixer().

static __inline ALfloat point32 | ( | const ALfloat * | vals,
|  | ALuint | frac
| ) |  |

static

Definition at line 11 of file mixer_c.c.

void Resample_copy32_C | ( | const ALfloat * | data,
|  | ALuint | frac,
|  | ALuint | increment,
|  | ALfloat *RESTRICT | OutBuffer,
|  | ALuint | BufferSize
| ) |  |

Definition at line 18 of file mixer_c.c.

References assert, FRACTIONONE, and memcpy.

Referenced by SelectResampler().