9c. The clock, tempo and key
Pompas lines lanes up by doing sums on one clock, not by ticking. This section is what you see of those sums: how a lane's tempo and key follow the lane above, and how Sync now lands two lanes on the same bar.
9c.1 One clock#
Works now
Know why lanes stay together.
What happens: every lane is placed on the server's clock: a playing lane remembers the moment its position was zero, and its position at any time after is worked out from that, never ticked. Pompas adds a rate to it, how much faster or slower than the song's own tempo the lane plays. Your page learns the server's clock from its answers and plays on it.
Good to know: the sums are done twice, once on the server and once in the page, and a test runs both on the same cases so that they never differ.
9c.2 Tempo: how a following lane chooses its speed#
Works now
Put two songs at the same tempo, without one running double.
What happens: a following lane plays at the tempo of the lane above it, and it picks among the half, whole and double multiples the one nearest normal speed. A 70 BPM loop under a 140 BPM lane plays at its own speed, on every other beat, and not at double. The speed is kept between half speed and double speed.
Good to know:
- When the lane above has nothing playing, or has no tempo, the follower looks further up. With nothing above, it keeps normal speed. Lane 0 always plays at normal speed.
- When the speed changes while a lane plays, the lane keeps its place: the music never jumps, only its speed changes.
- A tempo change does not move the downbeats. Use Sync now (9c.8) to line them up.
See also: 9b.1
9c.3 A free lane keeps its own tempo#
Works now
Leave one lane out of the tempo.
What happens: with FOLLOW off, a lane plays at its song's own tempo, and when you turn it on again it takes the lane above's tempo once more.
9c.4 The speed is kept#
Works now
Come back to the same sound after a restart.
What happens: each lane's speed is saved, so after a restart Pompas places every lane exactly where it would have been.
9c.5 Audio stretches without changing pitch#
Works now
Slow down or speed up a recording and keep its pitch.
What happens: a recording is time-stretched in your browser, and its pitch stays. This works for files your page may read: the site's own, and corpus recordings that come through the site.
Good to know:
- Any other recording still changes speed and keeps its pitch, but its timing is looser. The lane is marked LOOSE SYNC, and a loose lane cannot be chopped into a sniplet (9a.8).
- A MIDI lane needs no stretching: its notes are simply scaled.
9c.6 Transpose a lane#
Works now
Move a MIDI lane up or down in pitch.
| On | Do this |
|---|---|
| Computer | Press − or + beside the lane. The number between them is the semitones |
What happens: a MIDI lane moves by up to 12 semitones either way. Drums never move: a drum part stays a drum part.
Good to know: an audio lane does not change key yet. It says so, and keeps its transposition for when it plays MIDI.
9c.7 Follow the key of the lane above#
Works now
Put two songs in the same key.
| On | Do this |
|---|---|
| Computer | Press KEY on the lane |
What happens: the lane moves to the key of the lane above, by the smallest interval between the two, from 5 semitones down to 6 up. A minor key is read as its relative major, so A minor and C major count as the same. Your own transposition is added on top.
Good to know: key follow is off to begin with, and lane 0 has nothing above it to follow.
See also: 9c.6
9c.8 Sync now#
Works now · the station reworks it
Land a lane on the primary's next bar, together with everyone playing.
| On | Do this |
|---|---|
| Computer | Press SYNC on the lane. It is not available on lane 0, or when lane 0 is not playing |
What happens: 1. Pompas picks the primary's next bar line, at least a quarter of a second ahead. 2. It works out where your lane would be then, at its new speed, and rounds that to its own nearest bar line. A lane that was stopped or paused starts there. 3. At that bar, your lane's bars line up with the primary's.
Every page sees the change coming and plays it at the same moment, so it lands on the bar on every page at once.
Good to know: pressing play, pause, seek or skip on the lane before the bar cancels the sync.
See also: Tempo (9c.2) · Launching on the beat (1.1)