[PD] Phase Cancellation

Mathieu Bouchard matju at artengine.ca
Sat Aug 5 17:16:44 CEST 2006


On Fri, 4 Aug 2006, beau c wrote:

>  I am trying to extract a drum loop from a soundfile, which has a violin 
> loop mixed in. Earlier in the song I got a clean pass of the violin with 
> by itself. I was wondering how I could change the phase of the violin 
> loop by 180 degrees so that when I mixed it in [+~] with the other 
> sample the violin loops would cancel eachother out. Leaving only the 
> drum loop. Does anyone know how to do this with pd? Or any other 
> programs/plug-ins?

Chances are that it won't work because the violin isn't played in exactly 
the same way. If the violin wasn't sampled and replayed exactly the same, 
it won't work. Each manually replayed violin note will have different 
timing and thus a rather random phase difference from the original one.

a 180-degree phase shift is [*~ -1].

there's a shortcut for both that and a [+~], called [-~] (duh)

therefore, a 180-degree phase shift can be computed efficiently using only 
the right inlet of [-~].

to do phase-insensitive cancellation you'd need more complex tools, like 
[fft~] and such, unless I'm missing something.

  _ _ __ ___ _____ ________ _____________ _____________________ ...
| Mathieu Bouchard - tél:+1.514.383.3801 - http://artengine.ca/matju
| Freelance Digital Arts Engineer, Montréal QC Canada


More information about the Pd-list mailing list