service: Make use of buffer element count helpers

This commit is contained in:
Lioncash
2022-11-23 13:25:14 -05:00
parent 59335f6796
commit 97f273e94e
12 changed files with 41 additions and 47 deletions

View File

@ -68,7 +68,7 @@ private:
ExtraBehavior extra_behavior) {
u32 consumed = 0;
u32 sample_count = 0;
std::vector<opus_int16> samples(ctx.GetWriteBufferSize() / sizeof(opus_int16));
std::vector<opus_int16> samples(ctx.GetWriteBufferNumElements<opus_int16>());
if (extra_behavior == ExtraBehavior::ResetContext) {
ResetDecoderContext();