From: notaz Date: Sat, 22 Jan 2022 20:20:42 +0000 (+0200) Subject: spu: save/restore decode_pos X-Git-Tag: r24l~536 X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0ad5d4a1638695c19f111a682423230646c7e9f7;p=pcsx_rearmed.git spu: save/restore decode_pos SPUOSSFreeze_t conveniently had padding space for it --- diff --git a/plugins/dfsound/freeze.c b/plugins/dfsound/freeze.c index 43e6535c..3bdbab1b 100644 --- a/plugins/dfsound/freeze.c +++ b/plugins/dfsound/freeze.c @@ -119,6 +119,7 @@ typedef struct typedef struct { unsigned short spuIrq; + unsigned short decode_pos; uint32_t pSpuIrq; uint32_t spuAddr; uint32_t dummy1; @@ -261,6 +262,7 @@ long CALLBACK SPUfreeze(uint32_t ulFreezeMode, SPUFreeze_t * pF, pFO->spuAddr=spu.spuAddr; if(pFO->spuAddr==0) pFO->spuAddr=0xbaadf00d; + pFO->decode_pos = spu.decode_pos; for(i=0;ispuAddr == 0xbaadf00d) spu.spuAddr = 0; else spu.spuAddr = pFO->spuAddr & 0x7fffe; } + spu.decode_pos = pFO->decode_pos & 0x1ff; spu.dwNewChannel=0; spu.dwChannelOn=0;