diff options
author | Chris Robinson <[email protected]> | 2016-03-17 10:10:26 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2016-03-17 10:10:26 -0700 |
commit | ce575718ef495c3c146d7a1b443ce556014e057f (patch) | |
tree | f8482707b34b158a78a10634b55fc5aaaa098545 /Alc/ALc.c | |
parent | 606402fff05b115bc8b4728f9444fa46ef7e5e35 (diff) |
Store the effect's output buffer in the effect state
Diffstat (limited to 'Alc/ALc.c')
-rw-r--r-- | Alc/ALc.c | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -2170,6 +2170,8 @@ static ALCenum UpdateDeviceParams(ALCdevice *device, const ALCint *attrList) { ALeffectslot *slot = context->EffectSlotMap.array[pos].value; + slot->EffectState->OutBuffer = device->Dry.Buffer; + slot->EffectState->OutChannels = device->Dry.NumChannels; if(V(slot->EffectState,deviceUpdate)(device) == AL_FALSE) { UnlockUIntMapRead(&context->EffectSlotMap); @@ -2217,8 +2219,11 @@ static ALCenum UpdateDeviceParams(ALCdevice *device, const ALCint *attrList) if(device->DefaultSlot) { ALeffectslot *slot = device->DefaultSlot; + ALeffectState *state = slot->EffectState; - if(V(slot->EffectState,deviceUpdate)(device) == AL_FALSE) + state->OutBuffer = device->Dry.Buffer; + state->OutChannels = device->Dry.NumChannels; + if(V(state,deviceUpdate)(device) == AL_FALSE) { V0(device->Backend,unlock)(); RestoreFPUMode(&oldMode); |