Fix flipped argument order and update CNFA

This commit is contained in:
cnlohr 2020-07-05 23:43:26 -07:00
parent 204fa77004
commit b6be6c14a4
3 changed files with 4 additions and 5 deletions

@ -1 +1 @@
Subproject commit f0f478f619e5db0ef5b3cb5e7da2b7d5d6f317be
Subproject commit aa931ed2db1991381867a1722b0e6a7bac98f467

View file

@ -22,7 +22,7 @@ wininput = -1
#Compiled version will default to PULSE (or ALSA) on Linux, WASAPI (winmm) [or WIN for winmm] on Windows and ANDROID on Android
# sound_source = ALSA
sound_source = WASAPI
# sound_source = WASAPI
#-1 indicates left and right, 0 left, 1 right.
sample_channel = -1
@ -30,7 +30,7 @@ sample_channel = -1
devplay = default
# Sets the device to get audio from, for WASAPI, "default" searches for a mic, and "defaultRender" searches for your loopback.
# devrecord = default
devrecord = default
#Render
# For Linux mostly use the following command to find valid devices to read from:

View file

@ -233,7 +233,7 @@ void HandleMotion( int x, int y, int mask )
{
}
void SoundCB( struct CNFADriver * sd, short * in, short * out, int framesr, int framesp )
void SoundCB( struct CNFADriver * sd, short * out, short * in, int framesp, int framesr )
{
int channelin = sd->channelsRec;
int channelout = sd->channelsPlay;
@ -265,7 +265,6 @@ void SoundCB( struct CNFADriver * sd, short * in, short * out, int framesr, int
// printf( "Sound fault A %d/%d %d/%d %f\n", j, channelin, i, samplesr, f );
}
}
fo /= channelin;
sound[soundhead] = fo*in_amplitude;
soundhead = (soundhead+1)%SOUNDCBSIZE;