diff projects/basic_sensor/render.cpp @ 12:a6beeba3a648

Initial support for higher matrix sample rates by reducing the number of channels. Input not tested yet, and not all examples updated to new format.
author andrewm
date Thu, 22 Jan 2015 19:00:22 +0000
parents 09f03ac40fcc
children 6adb088196a7
line wrap: on
line diff
--- a/projects/basic_sensor/render.cpp	Thu Nov 13 16:02:59 2014 +0100
+++ b/projects/basic_sensor/render.cpp	Thu Jan 22 19:00:22 2015 +0000
@@ -31,16 +31,18 @@
 //
 // Return true on success; returning false halts the program.
 
-bool initialise_render(int numChannels, int numMatrixFramesPerPeriod,
-					   int numAudioFramesPerPeriod, float matrixSampleRate,
-					   float audioSampleRate, void *userData)
+bool initialise_render(int numMatrixChannels, int numAudioChannels,
+					   int numMatrixFramesPerPeriod,
+					   int numAudioFramesPerPeriod,
+					   float matrixSampleRate, float audioSampleRate,
+					   void *userData)
 {
 	if(numMatrixFramesPerPeriod*2 != numAudioFramesPerPeriod) {
 		rt_printf("Error: this example needs the matrix enabled, running at half audio rate\n");
 		return false;
 	}
 
-	gNumChannels = numChannels;
+	gNumChannels = numAudioChannels;
 	gInverseSampleRate = 1.0 / audioSampleRate;
 	gPhase = 0.0;