diff examples/10-Instruments/airharp/render.cpp @ 543:8f8809c77dda prerelease

updated basics, digital, instruments, extras examples
author chnrx <chris.heinrichs@gmail.com>
date Fri, 24 Jun 2016 13:19:52 +0100
parents 8fcfbfb32aa0
children
line wrap: on
line diff
--- a/examples/10-Instruments/airharp/render.cpp	Fri Jun 24 13:00:31 2016 +0100
+++ b/examples/10-Instruments/airharp/render.cpp	Fri Jun 24 13:19:52 2016 +0100
@@ -1,6 +1,31 @@
+/*
+ ____  _____ _        _    
+| __ )| ____| |      / \   
+|  _ \|  _| | |     / _ \  
+| |_) | |___| |___ / ___ \ 
+|____/|_____|_____/_/   \_\
+
+The platform for ultra-low latency audio and sensor processing
+
+http://bela.io
+
+A project of the Augmented Instruments Laboratory within the
+Centre for Digital Music at Queen Mary University of London.
+http://www.eecs.qmul.ac.uk/~andrewm
+
+(c) 2016 Augmented Instruments Laboratory: Andrew McPherson,
+	Astrid Bin, Liam Donovan, Christian Heinrichs, Robert Jack,
+	Giulio Moro, Laurel Pardue, Victor Zappi. All rights reserved.
+
+The Bela software is distributed under the GNU Lesser General Public License
+(LGPL 3.0), available here: https://www.gnu.org/licenses/lgpl-3.0.txt
+*/
+
+
 /*
  * AIR-HARP
  * Physically modelled strings using waveguide junctions and mass-spring-dampers
+ * controllable using an accelerometer
  *
  * render.cpp
  *
@@ -44,7 +69,7 @@
 
 // DC BLOCK BUTTERWORTH
 
-// Coefficients for 100hz cut-off
+// Coefficients for 100hz high-pass centre frequency
 float a0_l = 0.9899759179893742;
 float a1_l = -1.9799518359787485;
 float a2_l = 0.9899759179893742;
@@ -194,8 +219,8 @@
     	y2_r = y1_r;
    	 	y1_r = out_r;
 
-		context->audioOut[n * context->audioChannels + 1] = out_l * out_gain;
-		context->audioOut[n * context->audioChannels + 0] = out_r * out_gain;
+		context->audioOut[n * context->audioOutChannels + 1] = out_l * out_gain;
+		context->audioOut[n * context->audioOutChannels + 0] = out_r * out_gain;
 
 	}