Don't look up the dry buffer's FrontCenter in the Dedicated effect

The real FrontCenter output is used if it exists, and if it doesn't, it's
unlikely the dry buffer will have it (and even if it does, it won't be any
better than panning).
This commit is contained in:
Chris Robinson
2016-04-16 14:11:10 -07:00
parent d1f3a15470
commit d2e8fae005
+4 -8
View File
@@ -77,16 +77,12 @@ static ALvoid ALdedicatedState_update(ALdedicatedState *state, const ALCdevice *
}
else
{
ALfloat coeffs[MAX_AMBI_COEFFS];
CalcXYZCoeffs(0.0f, 0.0f, -1.0f, coeffs);
STATIC_CAST(ALeffectState,state)->OutBuffer = device->Dry.Buffer;
STATIC_CAST(ALeffectState,state)->OutChannels = device->Dry.NumChannels;
if((idx=GetChannelIdxByName(device->Dry, FrontCenter)) != -1)
state->gains[idx] = Gain;
else
{
ALfloat coeffs[MAX_AMBI_COEFFS];
CalcXYZCoeffs(0.0f, 0.0f, -1.0f, coeffs);
ComputePanningGains(device->Dry, coeffs, Gain, state->gains);
}
ComputePanningGains(device->Dry, coeffs, Gain, state->gains);
}
}
}