Phase Rotate

About

x42-phaserotate is an audio phase rotation plugin. It is a simple plugin with a single control-slider to shift the phase of the signal ± 180 deg.

Phase shift vs. time shift

Time shifting delays a signal by an absolute value in seconds (or samples). While phase shift uses a relative value, a fraction of the wave-length.

When phase shifting a signal, different components of the signal are delayed differently depending on their frequency.

The following figure shows an oscilloscope display of two sine-waves with different frequencies that play concurrently (green and blue) and respective shifted versions of each signal (red, violet).

The left images shows a phase shift by 90deg (1/4 wave-length). Note that the time-delay differs: The sine-wave with the lower frequency (top, red) is delayed further compared to the higher pitched sine-wave (bottom, violet).

In the right image both sine-waves are delayed by the same time. Note how this results in a different phase shift, as both waves differ in their wavelength.

Due to the periodic nature of the signal, a phase shift of +180 deg is equivalent to a shift of -180 deg. The signal is rotated around the unit circle on the complex plane.

Phase rotation

The interesting aspect is that phase rotation does not alter the sound of the signal nor the loudness. However changing the phase vs. frequency relationship between lower and upper harmonics changes the waveform and can affect where the digital peak occurs.

For this reason phase rotation is commonly used by radio stations to reduce the signal peak and make the signal more symmetrical. Phase rotation circuits are also used during mastering to increase headroom. This allows to increase gain and further compress the signal.

Caveat

By nature of the process phase-rotation affects transient response. Similar to a linear-phase EQ, there is also pre-ringing. Use this effect with caution because you are about to become a casualty in the loudness-war against quality. You have been warned.

CLI

In addition to the plugin, there is a command-line tool that can analyze an audio file, and find the phase shift which will result in a minimum peak.

This is for offline analysis and offline processing only, and not installed by default.