mirror of
https://github.com/libretro/FBNeo.git
synced 2025-03-09 04:43:17 +00:00
replace memset(pBurnSoundOut, 0, ....) with BurnSoundClear()
This commit is contained in:
parent
c501d217a3
commit
96827e2a8e
@ -146,7 +146,7 @@ void cps3SndUpdate()
|
||||
return;
|
||||
}
|
||||
|
||||
memset(pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
INT8 * base = (INT8 *)chip->rombase;
|
||||
cps3_voice *vptr = &chip->voice[0];
|
||||
|
||||
|
@ -491,7 +491,7 @@ static INT32 HvysmshInit()
|
||||
deco16_set_graphics(DrvGfxROM0, 0x400000, DrvGfxROM1, 0x400000, DrvGfxROM1, 0x100);
|
||||
deco16_set_global_offsets(0, 8);
|
||||
|
||||
MSM6295Init(0, (28000000 / 28) / MSM6295_PIN7_HIGH, 1);
|
||||
MSM6295Init(0, (28000000 / 28) / MSM6295_PIN7_HIGH, 0);
|
||||
MSM6295Init(1, (28000000 / 14) / MSM6295_PIN7_HIGH, 1);
|
||||
|
||||
EEPROMInit(&eeprom_interface_93C46);
|
||||
@ -732,7 +732,6 @@ static INT32 DrvFrame()
|
||||
if (has_ymz) {
|
||||
YMZ280BRender(pBurnSoundOut, nBurnSoundLen);
|
||||
} else {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 4);
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
}
|
||||
|
@ -496,7 +496,6 @@ static INT32 DrvFrame()
|
||||
SekClose();
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -386,7 +386,7 @@ static INT32 CommonInit(INT32 (*pRomLoad)(INT32 *, INT32 *), void (*pMap)(), INT
|
||||
|
||||
EEPROMInit(&eeprom_interface_93C46);
|
||||
|
||||
MSM6295Init(0, 1006875 / 132, 1);
|
||||
MSM6295Init(0, 1006875 / 132, 0);
|
||||
MSM6295Init(1, 2013750 / 132 / msm, 1);
|
||||
MSM6295SetRoute(0, 0.60, BURN_SND_ROUTE_BOTH);
|
||||
MSM6295SetRoute(1, 0.20, BURN_SND_ROUTE_BOTH);
|
||||
@ -555,7 +555,6 @@ static INT32 DrvFrame()
|
||||
ArmClose();
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * sizeof(INT16) * 2);
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -1080,7 +1080,7 @@ static INT32 DrvFrame()
|
||||
nCyclesTotal[1] = (INT32)((INT64)(7159090 / 60) * nBurnCPUSpeedAdjust / 0x0100);
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
}
|
||||
|
||||
nInterleave = 256 * 8; // * 8 for tight sync
|
||||
|
@ -666,7 +666,7 @@ static INT32 DrvFrame()
|
||||
if (K052109_irq_enabled) M6809SetIRQLine(0, CPU_IRQSTATUS_AUTO);
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset(pBurnSoundOut, 0, nBurnSoundLen * sizeof(INT16) * 2);
|
||||
BurnSoundClear();
|
||||
K007232Update(0, pBurnSoundOut, nBurnSoundLen);
|
||||
K007232Update(1, pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
@ -537,7 +537,7 @@ static INT32 DrvFrame()
|
||||
}
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * sizeof(UINT16) * 2);
|
||||
BurnSoundClear();
|
||||
K007232Update(0, pBurnSoundOut, nBurnSoundLen);
|
||||
K007232Update(1, pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
@ -727,7 +727,7 @@ static INT32 DrvFrame()
|
||||
}
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * 2);
|
||||
BurnSoundClear();
|
||||
K054539Update(0, pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -713,7 +713,7 @@ static INT32 DrvFrame()
|
||||
}
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * 2);
|
||||
BurnSoundClear();
|
||||
K054539Update(0, pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -2939,7 +2939,7 @@ static INT32 DrvFrame()
|
||||
}
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * 2);
|
||||
BurnSoundClear();
|
||||
K054539Update(0, pBurnSoundOut, nBurnSoundLen);
|
||||
K054539Update(1, pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
@ -448,7 +448,7 @@ static INT32 DrvFrame()
|
||||
INT16* pSoundBuf = pBurnSoundOut + (nSoundBufferPos << 1);
|
||||
|
||||
if (sound_mute) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * sizeof(INT16) * 2);
|
||||
BurnSoundClear();
|
||||
} else {
|
||||
TimepltSndUpdate(pSoundBuf, nSegmentLength);
|
||||
}
|
||||
|
@ -597,7 +597,7 @@ static INT32 DrvFrame()
|
||||
if (sl_control & 0x10) {
|
||||
AY8910Render(pBurnSoundOut, nBurnSoundLen);
|
||||
} else {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(UINT16));
|
||||
BurnSoundClear();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3582,7 +3582,7 @@ static INT32 System1DFrame() // peekaboo
|
||||
SekClose();
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * sizeof(INT16) * 2);
|
||||
BurnSoundClear();
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -1056,7 +1056,7 @@ static INT32 DrvFrame()
|
||||
}
|
||||
|
||||
if (sound_disable) {
|
||||
memset(pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1016,7 +1016,7 @@ static INT32 DrvFrame()
|
||||
if (sound_enable) {
|
||||
AY8910Render(pBurnSoundOut, nBurnSoundLen);
|
||||
} else {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -572,7 +572,7 @@ static INT32 DrvDoReset()
|
||||
}
|
||||
|
||||
if (pBurnSoundOut) { // fix ym2203 junk..
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen);
|
||||
BurnSoundClear();
|
||||
}
|
||||
|
||||
HiscoreReset();
|
||||
|
@ -532,7 +532,7 @@ static INT32 DrvFrame()
|
||||
SekClose();
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset(pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -482,7 +482,7 @@ static INT32 DrvFrame()
|
||||
SekClose();
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -844,7 +844,7 @@ static INT32 DrvFrame()
|
||||
SekClose();
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * sizeof(INT16) * 2);
|
||||
BurnSoundClear();
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -7372,7 +7372,7 @@ static INT32 ShogwarrFrame()
|
||||
SekClose();
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -528,7 +528,7 @@ static INT32 DrvFrame()
|
||||
SekClose();
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -618,7 +618,7 @@ static INT32 MwarrInit()
|
||||
// SekSetReadWordHandler(0, mwarr_read_word);
|
||||
SekClose();
|
||||
|
||||
MSM6295Init(0, 937500 / 132, 1);
|
||||
MSM6295Init(0, 937500 / 132, 0);
|
||||
MSM6295Init(1, 937500 / 132, 1);
|
||||
MSM6295SetRoute(0, 1.00, BURN_SND_ROUTE_BOTH);
|
||||
MSM6295SetRoute(1, 1.00, BURN_SND_ROUTE_BOTH);
|
||||
@ -915,9 +915,8 @@ static INT32 stlforceFrame()
|
||||
SekSetIRQLine(4, CPU_IRQSTATUS_AUTO);
|
||||
}
|
||||
|
||||
nCycleSegment = nBurnSoundLen / nInterleave;
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
nCycleSegment = nBurnSoundLen / nInterleave;
|
||||
MSM6295Render(pBurnSoundOut + nSoundBufferPos, nCycleSegment);
|
||||
nSoundBufferPos += (nCycleSegment << 1);
|
||||
}
|
||||
@ -978,7 +977,6 @@ static INT32 DrvFrame()
|
||||
nCycleSegment = nBurnSoundLen / nInterleave;
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut + nSoundBufferPos, 0, nCycleSegment * 2 * sizeof(INT16));
|
||||
MSM6295Render(pBurnSoundOut + nSoundBufferPos, nCycleSegment);
|
||||
nSoundBufferPos += (nCycleSegment << 1);
|
||||
}
|
||||
@ -986,7 +984,6 @@ static INT32 DrvFrame()
|
||||
|
||||
nCycleSegment = nBurnSoundLen - (nSoundBufferPos>>1);
|
||||
if (pBurnSoundOut && nCycleSegment > 0) {
|
||||
memset (pBurnSoundOut + nSoundBufferPos, 0, nCycleSegment * 2 * sizeof(INT16));
|
||||
MSM6295Render(pBurnSoundOut + nSoundBufferPos, nCycleSegment);
|
||||
}
|
||||
|
||||
|
@ -5637,7 +5637,7 @@ static INT32 BjtwinFrame()
|
||||
}
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -269,7 +269,7 @@ static INT32 DrvInit()
|
||||
SekSetReadWordHandler(0, patapata_read_word);
|
||||
SekClose();
|
||||
|
||||
MSM6295Init(0, 4000000 / 165, 1);
|
||||
MSM6295Init(0, 4000000 / 165, 0);
|
||||
MSM6295Init(1, 4000000 / 165, 1);
|
||||
MSM6295SetRoute(0, 0.40, BURN_SND_ROUTE_BOTH);
|
||||
MSM6295SetRoute(1, 0.40, BURN_SND_ROUTE_BOTH);
|
||||
@ -379,7 +379,6 @@ static INT32 DrvFrame()
|
||||
SekClose();
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset (pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(UINT16));
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
@ -1086,9 +1086,9 @@ static INT32 powerinsFrame()
|
||||
|
||||
if (game_drv == GAME_POWERINB) {
|
||||
ZetRun(nCyclesTotal[1] - nCyclesDone[1]);
|
||||
|
||||
|
||||
if (pBurnSoundOut) {
|
||||
memset(pBurnSoundOut, 0, nBurnSoundLen * 2 * sizeof(INT16));
|
||||
BurnSoundClear();
|
||||
MSM6295Render(pBurnSoundOut, nBurnSoundLen);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user