跳转到内容

在 SuperCollider 中设计声音/流水

来自维基教科书,开放世界中的开放书籍

图 36.3:随机频率正弦波

[编辑 | 编辑源代码]

不是一个物理上真实的模型,但请注意它具有一些相同的听觉特性

x = {SinOsc.ar(LFNoise0.kr(170).range(800, 2400), 0, 0.3)}.play;
x.free;


图 36.4:上升音调

[编辑 | 编辑源代码]

调整以上内容,使声音在音调上漂移,并倾向于上升

(
x = {
	var trigs, freq;
	trigs = Dust.kr(170);
	freq = 
		// Generally choose from a varied base freq
		TExpRand.kr(800, 2000, trigs)
		// Wobbly variation
		+ LFNoise2.kr(20, mul: 300)
		// General tendency for upward rise
		+ EnvGen.kr(Env.perc(1).range(0,17), trigs)
		;
	SinOsc.ar(freq, 0, 0.3)
}.play;
)
x.free;


// hmmm, let's try combining a few of these in parallel.
// do we sound like a river yet?
(
x = {
	var trigs, freq;
	6.collect{
		trigs = Dust.kr(170);
		freq = 
			// Generally choose from a varied base freq
			TExpRand.kr(800, 2000, trigs)
			// Wobbly variation
			+ LFNoise2.kr(20, mul: 300)
			// General tendency for upward rise
			+ EnvGen.kr(Env.perc(1).range(0,17), trigs)
			;
		SinOsc.ar(freq, 0, 0.3)
	}.mean
}.play;
)
x.free;
华夏公益教科书