SuperCollider Forum
May 20, 2013, 04:40:12 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: The SuperCollider forum is currently experiencing a rash of spambot registrations. New user requests may not be approved quickly as a result -- and if your email address looks like spam, it might not be approved at all. We are working to improve the security of the registration process, and to provide alternate means to contact the administrators to get a new account. Thanks for your patience.
 
   Home   Help Search Calendar Login Register  
Pages: [1]
  Print  
Author Topic: fun: frequency-stretching evil  (Read 2572 times)
0 Members and 1 Guest are viewing this topic.
dewdrop_world
AdminGroup
Full Member
*

Karma: 9
Posts: 193



View Profile WWW
« on: December 18, 2008, 01:10:49 PM »

Code:
b = Buffer.read(s, "sounds/a11wlk01.wav");

(
SynthDef('freq-stretch-evil', { |stretch = 1, center = 440, out|
var sig = PlayBuf.ar(1, b, loop: 1);
// stretched
sig = PitchShift.ar(sig, 0.2, stretch, timeDispersion: 0.05);
// re-centered
sig = FreqShift.ar(sig, center * (1-stretch));
Out.ar(out, sig ! 2);
}, metadata: (specs: (stretch: [0.25, 4, \exp], center: \freq))).memStore;

SynthDescLib.at('freq-stretch-evil').makeWindow;
)

(Metadata is post-3.2 I believe... if you're on 3.2, leave it out and play the synth manually.)

James
Logged

joshp
AdminGroup
Full Member
*

Karma: 5
Posts: 121



View Profile WWW
« Reply #1 on: December 20, 2008, 10:47:11 PM »

a little more evil?
Code:
b = Buffer.read(s, "sounds/a11wlk01.wav");

(
SynthDef('freq-stretch-evil', { |stretch = 1, center = 440, out|
var sig = PlayBuf.ar(1, b, loop: 1);
// stretched
sig = PitchShift.ar(sig, 0.2, stretch * [0.25, 0.33], timeDispersion: 0.5, pitchDispersion: 0.5).sum;
// re-centered
sig = FreqShift.ar(sig, center * (1-stretch) - [200, 100, 50]).sum;
Out.ar(out, sig ! 2);
}, metadata: (specs: (stretch: [0.25, 4, \exp], center: \freq))).memStore;

SynthDescLib.at('freq-stretch-evil').makeWindow;
)

Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.4 | SMF © 2006-2007, Simple Machines LLC Valid XHTML 1.0! Valid CSS!