SNES: fix BRR once again

This commit is contained in:
tildearrow 2023-05-24 02:38:43 -05:00
parent 4b12f440fa
commit 0fd5483b59

View file

@ -1130,8 +1130,9 @@ void DivSample::render(unsigned int formatMask) {
} }
} }
if (NOT_IN_FORMAT(DIV_SAMPLE_DEPTH_BRR)) { // BRR if (NOT_IN_FORMAT(DIV_SAMPLE_DEPTH_BRR)) { // BRR
if (!initInternal(DIV_SAMPLE_DEPTH_BRR,samples)) return; int sampleCount=loop?loopEnd:samples;
brrEncode(data16,dataBRR,samples,loop?loopStart:-1,brrEmphasis); if (!initInternal(DIV_SAMPLE_DEPTH_BRR,sampleCount)) return;
brrEncode(data16,dataBRR,sampleCount,loop?loopStart:-1,brrEmphasis);
} }
if (NOT_IN_FORMAT(DIV_SAMPLE_DEPTH_VOX)) { // VOX if (NOT_IN_FORMAT(DIV_SAMPLE_DEPTH_VOX)) { // VOX
if (!initInternal(DIV_SAMPLE_DEPTH_VOX,samples)) return; if (!initInternal(DIV_SAMPLE_DEPTH_VOX,samples)) return;