diff src/psf2/eng_psf2.c @ 2742:fd5373830ac1

Initial plugin. Don't use this unless you like aud to use 100% cpu.
author William Pitcock <nenolod@atheme.org>
date Mon, 30 Jun 2008 22:12:23 -0500
parents 62cc6d667119
children f0547285577e
line wrap: on
line diff
--- a/src/psf2/eng_psf2.c	Mon Jun 30 21:15:45 2008 -0500
+++ b/src/psf2/eng_psf2.c	Mon Jun 30 22:12:23 2008 -0500
@@ -586,20 +586,13 @@
 	return AO_SUCCESS;
 }
 
-void ps2_update(unsigned char *pSound, long lBytes)
-{
-	memcpy(spu_pOutput, pSound, lBytes);	// (for direct 44.1kHz output)
-}
-
-int32 psf2_gen(int16 *buffer, uint32 samples)
+int32 psf2_execute(InputPlayback *playback)
 {	
 	int i;
 
-	spu_pOutput = (char *)buffer;
-
-	for (i = 0; i < samples; i++)
+	for (i = 0; i < 44100 / 60; i++)
 	{
-		SPU2async(1);
+		SPU2async(1, playback);
 		ps2_hw_slice();
 	}