Start with one concrete task
Series: PerunTimePitch HQ — from tuning to sound. Part 1 of 6.
Picture a song you know almost by heart. You want to lower its tuning a little. The chorus should still arrive at the same moment, the drums should keep the same pulse, and the recording should last just as long. Asking the singer to go lower should not make the second chorus turn up late.
We are developing PerunTimePitch HQ as our own audio processing library for Perun applications. A library is an engine that an application calls when it works on a recording. This series will explain the tasks we tackle, how we check them, and what to listen for when judging the result. Our first subject is retuning a recording while preserving its duration.
Pitch and tempo are different things
Pitch shifting moves the sound of a recording higher or lower. Tempo describes the speed of the musical pulse, often expressed in beats per minute, or BPM. You might want a lower tuning with the same rhythm, or a slower rhythm with the same tuning.
A simple change in playback speed couples the two: slower playback also makes the recording lower and longer. Separating pitch from time requires additional signal processing. The table distinguishes three operations, starting with an example recording that lasts five minutes.
| Operation | Pitch | Duration |
|---|---|---|
| Retune 440 → 432 while preserving duration | Slightly lower | 5:00 |
| Slow the tempo from 120 to 96 BPM while preserving pitch | No intended change | 6:15 |
| Ordinary playback at 80% speed | Lower as playback slows | 6:15 |
These are calculated examples that explain the differences. The PerunTimePitch HQ processing discussed here addresses the first task: changing tuning while preserving duration.
What does 440 → 432 Hz actually mean?
A tuning reference of A4 = 440 Hz identifies the frequency of a reference note. Moving to A4 = 432 Hz gives a ratio of 432 / 440 ≈ 0.981818. The aim is to lower frequencies throughout the recording accordingly, rather than turn every instrument into a single 432 Hz tone. The bass should keep its own line, and the melody should retain the relationships between its notes.
Starting from the assumed 440 Hz reference, the shift is approximately −31.77 cents; a cent is one hundredth of a semitone. A duration-preserving five-minute recording should still last five minutes. The label “432 Hz” does not, however, establish the original recording’s actual tuning. The library needs the appropriate reference; a file should not be assumed to reveal its tuning automatically.
We will return to 528 Hz in part two. A4 = 528 Hz and C5 = 528 Hz describe two different shifts. First, we need to specify which note is supposed to have that frequency.
What does the engine do, and what does the app do?
A recording stored in a file must be read and decoded into audio samples. The library receives those samples and the retuning parameters, processes the signal, and returns a result. The application then handles writing the selected format and managing the user’s work.
That division has a practical consequence: correct retuning and a correctly saved file are two parts of the same operation. Duration, signal level and completion of the write all need attention. Simply changing sample-rate information in a file header is not equivalent to this processing.
The HQ line discussed here is being developed and evaluated in private library builds. The availability of a particular feature in an application depends on its release and integration.
Why is the correct frequency only part of the result?
A measurement can confirm that a tone has moved to the intended frequency while your ears still notice that something has changed too much. Music combines many overlapping elements: a sustained bass note, short impacts, vowel sounds and reverberation. The engine works with that whole mixture.
Later parts will look at formants, the resonances that help shape a voice’s character, and transients, short, abrupt changes such as the beginning of a snare hit. The relationship between the left and right channels also matters. We therefore assess a result through frequency, timing, rhythm, tone and stereo behaviour.
Your first listening comparison: short and consistent
- Choose a familiar excerpt. A short passage with vocals and a clear rhythm lets you focus on the same details.
- Write down the assumptions. Identify the source tuning, target tuning and whether duration should stay unchanged. Keep the original.
- Compare at similar listening levels. A louder result may immediately seem fuller, even though loudness is a separate change.
- Listen at specific moments. Check vowel sounds, the start of a snare hit, bass stability and the placement of instruments between the channels.
- Check duration and the ending. The return to the beginning and the final fading note are part of the recording too.
This provides a starting point for assessment. Precise measurements and listening complement each other: numbers help locate a problem, while your ears reveal its musical significance.
Where the series goes next
Part two will clarify the references behind 432, 440 and 528 Hz. We will then explore vocal character, drum attacks and stereo, processing long recordings, and how to assess quality. Each part will focus on a concrete question and example.
For now, keep one idea: lowering the tuning does not require slowing down the song. That independence is what we want to use while preserving the recording’s musical character.
- 432, 440 and 528 Hz — what exactly are we retuning?
- Retuned vocals — preserving the character of a voice
- Rhythm and stereo — drum attacks and a stable soundstage
- From excerpt to album — audio, memory and long recordings
- How do we assess PerunTimePitch HQ quality?