Gabun/Bavaria

julian rohrhuber 2002 / 2005
licenced under Creative Commons 'some rights reserved'
dual fundamental harmonics scale examples
some approximations of mouthbow and mouthharp.

// beng (gabon mouthbow)
(
play {
  		var bowRoot, stick, bow, mouth;
		var speed, stickPattern, rootStickPattern, rootStick, tstick, trigger, hi, lo;

		
		speed = 0.7;
		trigger = Impulse.kr(12*speed);
		
		stickPattern = Dseq([
						Dseq(#[1, 0, 1, 0, 1, 1, 0, 1, 0.3, 1, 0], 8),
						Dseq(#[1, 0, 1, 0, 0.2, 1, 0, 1, 1, 1, 0], 2),
						Dseq(#[0, 1, 0, 1, 0, 1, 0, 0, 0.5, 1, 0], 2)
				], inf) * Dwhite(0.8, 1.2, inf);
		
		hi = Dwhite(65.95, 66.05, 1);
		lo = 68;
		rootStickPattern = Dseq([hi, hi, lo, hi, lo, lo, hi, lo], inf);

		stick = Demand.kr(trigger, 0, stickPattern) * trigger;
				
		rootStick = PulseDivider.kr(stick, 3, 3);
		bowRoot = Lag.kr(Demand.kr(rootStick, 0, rootStickPattern).midicps, 0.05, 1/3.5);
		
		bow = CombL.ar(
						GrayNoise.ar(Decay2.kr(stick, 0.001, LFNoise1.kr(12, 0.05, 0.1), 0.3)),
						0.01,
						Lag.kr(bowRoot, 0.15).reciprocal,
						LFNoise2.kr(0.32, 0.2, 0.5 - (0.2*ToggleFF.kr(rootStick)) * 4)
				);
		tstick = Trig.kr(stick,0.01);		 
		mouth = RLPF.ar(
						bow,
						Lag.kr(
						Demand.kr(tstick, 1,
								Dseq([Drand([
										Drand(#[3, 4, 5, 6], 2),
										Drand(#[2, 3, 5], 4 * 3),
										Drand(#[ 2, 4, 6, 3 ], 3 * 4),
										Dseq(#[6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 6], 2)
										
										], 3)], inf)
					 	), 0.05) * bowRoot,
						LFNoise1.kr(0.8, 0.05, 0.1)
				 );
		Pan2.ar(LPF.ar(mouth, 2000), -0.3) +
		Pan2.ar(HPF.ar(bow * 0.3, 5000), 0.4)

};
)

// bavarian mouth harp

(
	play {
			var root, finger, harp, mouth;
			var speed, trigger, troot;
			speed = MouseX.kr(0.7, 1.0) * 6;
			trigger = Impulse.ar(speed + LFNoise2.kr(0.1, 0.1));
			troot = PulseDivider.ar(trigger, 24, 24);
			root = Demand.ar(troot, 1, Dseq([ 47, 52 ], inf)).midicps;

			finger = Demand.ar(trigger, 0,
					Dseq([
							Dseq(#[1, 1, 0.05, 1, 0.7, 0.02, 1, 1, 0.1, 1, 0.1, 0.1], 4),
							Dseq(#[1, 1, 1, 0.1, 0.1, 0.2, 1, 1, 0.1, 1, 1, 0.1], 5),
							Dseq([1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 0, 0, 2] ++ (0 ! 16+2))
							
					])
			) * trigger;
			
			harp = Saw.ar(Lag.ar(root, 0.15), Decay.ar(finger, LFNoise1.ar(0.4, 0.3, 0.8), 0.2));
			mouth = RLPF.ar(
							harp,
							Lag.ar(
						 	 Demand.ar(finger, 0, 
									Dseq([
										Dseq([
											Dseq(#[4, 5, 6], 2),
											Dseq([6, 5, Drand(#[8, 7], 1)], 4),
											Dseq(
												#[3, 5, 6, 7, 6, 5, 7, 5, 6, 9, 
												8, 7, 5, 6, 4, 3], 2)
										], 3)
									], inf)
							), 0.1) * root,
							LFNoise1.kr(0.3, 0.05, 0.08),
							1,
							LPF.ar(harp, 2000) * 0.4
							);
						
		 Pan2.ar(
		 	LPF.ar(mouth, 4000), 
		 	LFNoise1.kr(0.5, 0.3)
		 );
			
	};
)