recording windowed FFT.

Feb 16, 2007 at 6:27am

recording windowed FFT.

I have an idea which is a sync NIGHTMARE. the idea requires me
compare windowed fft frames of a number of buffers in non real time.
and then resynthesize a composite

I’m hoping to record windowed fft information of [SendMeBuffer] into
[intoMeBuffer]. obviously [intoMeBuffer] is going to be a number of
times longer than [SendMeBuffer]

it seems like I have a two options

OPTION A:
find a way to figure out which frame is currently playing inside a
pfft~ and then use send~ (since pfft sums its outputs)
my question here is how to do this.

OPTION B:
do a windowed FFT by hand.
(I’ve included my first attempt which is totally flawed)
my question here is how to do it correctly

#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P newex 605 169 48 196617 loadbang;
#P user gain~ 182 514 24 100 158 0 1.071519 7.94321 10.;
#P newex 451 90 91 196617 fft~ 512 512 256;
#P newex 341 315 27 196617 *~;
#P newex 341 274 94 196617 ifft~ 512 512 256;
#P newex 341 192 27 196617 *~;
#P newex 452 140 90 196617 index~ windowing;
#P newex 341 233 91 196617 fft~ 512 512 256;
#P newex 217 94 79 196617 fft~ 512 512 0;
#P newex 107 319 27 196617 *~;
#P newex 107 278 82 196617 Ifft~ 512 512 0;
#N vpatcher 20 74 620 474;
#P window setfont “Sans Serif” 9.;
#P newex 106 85 44 196617 *~ 300;
#P newex 118 50 49 196617 cycle~ 2;
#P newex 61 145 43 196617 +~ 300;
#P newex 52 79 44 196617 *~ 300;
#P newex 50 53 61 196617 cycle~ 400;
#P newex 102 179 40 196617 cycle~;
#P outlet 102 201 15 0;
#P connect 2 0 3 0;
#P connect 3 0 4 0;
#P connect 6 0 4 1;
#P connect 4 0 1 0;
#P connect 1 0 0 0;
#P connect 5 0 6 0;
#P pop;
#P newobj 106 50 80 196617 p TEST_SIGNAL;
#P newex 107 196 27 196617 *~;
#P newex 218 144 90 196617 index~ windowing;
#N vpatcher 20 74 620 474;
#P window setfont “Sans Serif” 9.;
#P newex 326 209 167 196617 expr (-$i1+($f2/2)) / ($f2/2)+ 1;
#P newex 135 212 91 196617 expr $i1/($f2/2);
#P message 229 68 50 196617 clear;
#P newex 50 50 27 196617 t i b;
#P newex 98 268 83 196617 peek~ windowing;
#P newex 98 243 50 196617 pack 0 0.;
#P newex 130 173 181 196617 if $i1< ($f2/2) then $i1 else out2 $i1;
#P newex 50 144 59 196617 uzi 1024 0;
#P newex 229 90 112 196617 buffer~ windowing 100;
#P inlet 50 30 15 0;
#P connect 0 0 6 0;
#P connect 6 0 2 0;
#P connect 2 2 4 0;
#P connect 4 0 5 0;
#P connect 2 2 3 0;
#P connect 3 0 8 0;
#P connect 9 0 4 1;
#P connect 8 0 4 1;
#P connect 6 0 8 1;
#P connect 6 1 7 0;
#P connect 7 0 1 0;
#P connect 6 0 3 1;
#P connect 3 1 9 0;
#P connect 6 0 9 1;
#P pop;
#P newobj 605 232 87 196617 p trianglewindow;
#P message 605 207 26 196617 512;
#P user ezdac~ 175 666 219 699 0;
#P newex 107 237 79 196617 fft~ 512 512 0;
#P window linecount 2;
#P message 606 130 72 196617 ; dsp sigvs 64;
#P window linecount 1;
#P hidden newex 606 110 45 196617 loadbang;
#P connect 19 0 4 0;
#P connect 18 0 3 0;
#P connect 18 0 3 1;
#P connect 16 0 18 0;
#P connect 10 0 18 0;
#P connect 8 0 7 0;
#P fasten 8 0 14 0 111 120 346 120;
#P connect 17 2 13 0;
#P connect 12 1 15 1;
#P connect 12 0 15 0;
#P connect 15 0 16 0;
#P connect 14 0 12 0;
#P connect 7 0 2 0;
#P connect 2 0 9 0;
#P connect 9 0 10 0;
#P connect 6 0 7 1;
#P connect 6 0 10 1;
#P connect 2 1 9 1;
#P connect 11 2 6 0;
#P connect 13 0 14 1;
#P connect 13 0 16 1;
#P connect 4 0 5 0;
#P hidden connect 0 0 1 0;
#P window clipboard copycount 20;

#30312
Feb 16, 2007 at 10:50pm

I reread my original pfft~ post. it didn’t make much sense did it?
please allow me a do-over.

simply put:
does anyone have an example of a pfft done by hand with fft objects?
the one in the tutorial does not look very promising. heres my try at
it.

#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P newex 63 448 27 196617 + 1;
#P toggle 65 409 15 0;
#P newex 110 442 62 196617 selector~ 2;
#P newex 612 176 48 196617 loadbang;
#P user gain~ 189 521 24 100 158 0 1.071519 7.94321 10.;
#P newex 431 94 91 196617 fft~ 512 512 256;
#B color 1;
#P newex 348 322 27 196617 *~;
#P newex 348 281 94 196617 ifft~ 512 512 256;
#P newex 348 199 27 196617 *~;
#P newex 432 144 90 196617 index~ windowing;
#B color 1;
#P newex 348 240 91 196617 fft~ 512 512 256;
#P newex 211 130 79 196617 fft~ 512 512 0;
#B color 1;
#P newex 114 326 27 196617 *~;
#P newex 114 285 82 196617 Ifft~ 512 512 0;
#N vpatcher 20 74 620 474;
#P window setfont “Sans Serif” 9.;
#P newex 106 85 44 196617 *~ 300;
#P newex 118 50 49 196617 cycle~ 2;
#P newex 61 145 43 196617 +~ 300;
#P newex 52 79 44 196617 *~ 300;
#P newex 50 53 61 196617 cycle~ 400;
#P newex 102 179 40 196617 cycle~;
#P outlet 102 201 15 0;
#P connect 2 0 3 0;
#P connect 3 0 4 0;
#P connect 6 0 4 1;
#P connect 4 0 1 0;
#P connect 1 0 0 0;
#P connect 5 0 6 0;
#P pop;
#P newobj 113 57 80 196617 p TEST_SIGNAL;
#P newex 114 203 27 196617 *~;
#P newex 212 180 90 196617 index~ windowing;
#B color 1;
#N vpatcher 20 74 620 474;
#P window setfont “Sans Serif” 9.;
#P newex 326 209 167 196617 expr (-$i1+($f2/2)) / ($f2/2)+ 1;
#P newex 135 212 91 196617 expr $i1/($f2/2);
#P message 229 68 50 196617 clear;
#P newex 50 50 27 196617 t i b;
#P newex 98 268 83 196617 peek~ windowing;
#P newex 98 243 50 196617 pack 0 0.;
#P newex 130 173 181 196617 if $i1< ($f2/2) then $i1 else out2 $i1;
#P newex 50 144 59 196617 uzi 1024 0;
#P newex 229 90 112 196617 buffer~ windowing 100;
#P inlet 50 30 15 0;
#P connect 0 0 6 0;
#P connect 6 0 2 0;
#P connect 2 2 4 0;
#P connect 4 0 5 0;
#P connect 2 2 3 0;
#P connect 3 0 8 0;
#P connect 8 0 4 1;
#P connect 9 0 4 1;
#P connect 6 0 8 1;
#P connect 6 1 7 0;
#P connect 7 0 1 0;
#P connect 6 0 3 1;
#P connect 3 1 9 0;
#P connect 6 0 9 1;
#P pop;
#P newobj 612 239 87 196617 p trianglewindow;
#P message 612 214 26 196617 512;
#P user ezdac~ 182 673 226 706 0;
#P newex 114 244 79 196617 fft~ 512 512 0;
#P window linecount 2;
#P message 613 137 72 196617 ; dsp sigvs 64;
#P window linecount 1;
#P hidden newex 613 117 45 196617 loadbang;
#P connect 13 0 14 1;
#P lcolor 2;
#P connect 13 0 16 1;
#P lcolor 2;
#P connect 12 1 15 1;
#P connect 12 0 15 0;
#P connect 15 0 16 0;
#P connect 14 0 12 0;
#P connect 6 0 7 1;
#P lcolor 2;
#P connect 6 0 10 1;
#P lcolor 2;
#P connect 22 0 20 0;
#P connect 8 0 7 0;
#P fasten 8 0 20 1 118 89 97 89 97 410 141 410;
#P fasten 8 0 14 0 118 127 353 127;
#P connect 20 0 18 0;
#P connect 16 0 20 2;
#P connect 10 0 20 2;
#P connect 21 0 22 0;
#P hidden connect 0 0 1 0;
#P connect 4 0 5 0;
#P connect 11 2 6 0;
#P lcolor 2;
#P connect 2 1 9 1;
#P connect 9 0 10 0;
#P connect 2 0 9 0;
#P connect 7 0 2 0;
#P connect 17 2 13 0;
#P lcolor 2;
#P connect 18 0 3 1;
#P connect 18 0 3 0;
#P connect 19 0 4 0;
#P window clipboard copycount 23;

#96643

You must be logged in to reply to this topic.