X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=plugins%2Fdfsound%2Fxa.c;h=397ed592f7dd2b61043bb3ddffbc526c4cf6a5e7;hb=6c62131f8b4a923e02bb8a9d8cd9f62a90fa20a7;hp=c93612f892d895b6ffa3b7bfd696b25526d8e09e;hpb=db3bfe5cdcd21f077c3f6bf8b82eb6676ddae8c0;p=pcsx_rearmed.git diff --git a/plugins/dfsound/xa.c b/plugins/dfsound/xa.c index c93612f8..397ed592 100644 --- a/plugins/dfsound/xa.c +++ b/plugins/dfsound/xa.c @@ -16,6 +16,7 @@ ***************************************************************************/ #include "stdafx.h" +#include "spu.h" #define _IN_XA #include @@ -60,8 +61,8 @@ INLINE void MixXA(int *SSumLR, int ns_to, int decode_pos) SSumLR[ns++] += l; SSumLR[ns++] += r; - spu.spuMem[cursor] = v; - spu.spuMem[cursor + 0x400/2] = v >> 16; + spu.spuMem[cursor] = HTOLE16(v); + spu.spuMem[cursor + 0x400/2] = HTOLE16(v >> 16); cursor = (cursor + 1) & 0x1ff; } spu.XALastVal = v; @@ -80,8 +81,8 @@ INLINE void MixXA(int *SSumLR, int ns_to, int decode_pos) SSumLR[ns++] += l; SSumLR[ns++] += r; - spu.spuMem[cursor] = v; - spu.spuMem[cursor + 0x400/2] = v >> 16; + spu.spuMem[cursor] = HTOLE16(v); + spu.spuMem[cursor + 0x400/2] = HTOLE16(v >> 16); cursor = (cursor + 1) & 0x1ff; } spu.XALastVal = v; @@ -120,7 +121,7 @@ INLINE void FeedXA(xa_decode_t *xap) if(!spu.bSPUIsOpen) return; spu.xapGlobal = xap; // store info for save states - spu.XARepeat = 100; // set up repeat + spu.XARepeat = 3; // set up repeat #if 0//def XA_HACK iSize=((45500*xap->nsamples)/xap->freq); // get size