diff options
author | Chris Robinson <[email protected]> | 2023-12-21 00:27:39 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2023-12-21 00:27:39 -0800 |
commit | e349b63335e9512a8434d72368520315c7b15197 (patch) | |
tree | d071a8608b1bdfa18bd6f6455c93fe5409ef06e3 /alc | |
parent | 10693d306340dfc4c6c7ee7c71aa73a31f0b8ea9 (diff) |
Use a variant instead of a union for InterpState
Diffstat (limited to 'alc')
-rw-r--r-- | alc/alu.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/alc/alu.cpp b/alc/alu.cpp index a660b7bd..3b4c659f 100644 --- a/alc/alu.cpp +++ b/alc/alu.cpp @@ -261,15 +261,15 @@ ResamplerFunc PrepareResampler(Resampler resampler, uint increment, InterpState case Resampler::Linear: break; case Resampler::Cubic: - state->cubic.filter = gCubicSpline.Tab.data(); + state->emplace<CubicState>().filter = gCubicSpline.Tab.data(); break; case Resampler::FastBSinc12: case Resampler::BSinc12: - BsincPrepare(increment, &state->bsinc, &gBSinc12); + BsincPrepare(increment, &state->emplace<BsincState>(), &gBSinc12); break; case Resampler::FastBSinc24: case Resampler::BSinc24: - BsincPrepare(increment, &state->bsinc, &gBSinc24); + BsincPrepare(increment, &state->emplace<BsincState>(), &gBSinc24); break; } return SelectResampler(resampler, increment); |