File: PV_ConformalMap.schelp

package info (click to toggle)
supercollider 1%3A3.13.0%2Brepack-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 80,292 kB
  • sloc: cpp: 476,363; lisp: 84,680; ansic: 77,685; sh: 25,509; python: 7,909; makefile: 3,440; perl: 1,964; javascript: 974; xml: 826; java: 677; yacc: 314; lex: 175; objc: 152; ruby: 136
file content (95 lines) | stat: -rw-r--r-- 1,571 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
class:: PV_ConformalMap
summary:: Complex plane attack.
related:: Classes/FFT, Classes/IFFT
categories:: UGens>FFT

Description::

Applies the conformal mapping

code::

z → (z - a) / (1 - za*)

::

to the phase vocoder bins z with a given by the real and imag inputs to
the UGen.


Makes a transformation of the complex plane so the output is full of
phase vocoder artifacts but may be musically fun. Usually keep

code::
|a| < 1
::
but
you can of course try bigger values to make it really noisy.

code::
a = 0
::
should
give back the input mostly unperturbed.


See  link::http://mathworld.wolfram.com/ConformalMapping.html:: .


classmethods::

method::new

argument::buffer

FFT buffer.


argument::areal

Real part of a.


argument::aimag

Imaginary part of a.


Examples::

code::

// explore the effect

(
SynthDef("conformer2", { |out|
	var in, chain, sound;
	in = Mix.ar(LFSaw.ar(SinOsc.kr(Array.rand(3,0.1,0.5),0,10,[1,1.1,1.5,1.78,2.45,6.7]*220),0,0.3));
	chain = FFT(LocalBuf(2048), in);
	chain = PV_ConformalMap(chain, MouseX.kr(0.01,2.0, 'exponential'), MouseY.kr(0.01,10.0, 'exponential'));
	sound = IFFT(chain);

	Out.ar(out, Pan2.ar(CombN.ar(sound, 0.1, 0.1, 10, 0.5, sound), 0, 0.3));
}).add;
)

a = Synth("conformer2")
a.free

// sound input: use headphones to prevent feedback
(
SynthDef("conformer1", { |out|
	var in, chain;
	in = SoundIn.ar(0, 0.5);
	chain = FFT(LocalBuf(1024), in);
	chain = PV_ConformalMap(chain, MouseX.kr(-1.0,1.0), MouseY.kr(-1.0,1.0));
	Out.ar(out, Pan2.ar(IFFT(chain), 0));
}).add;
)

a = Synth("conformer1")
a.free


::