Support pitch change, like how speed change is

Feature description:

If related to media, be sure to explain for what media provider this request is.

Add as much details as possible.
Please be precise about your need and not the solution you think you need.

Problem solved:

Describe your problem precisely as it’s more important than the solution you may think of.

There’s a slider for changing the speed; it’d be great if there was one to change the pitch, too.

Brought benefits:

Explain what benefits it brings to all users and not just you and your possibly very unique need.

Pitch change is a natural side-effect of speed change. In fact, “pro audio editors” use the term “tempo” when changing the speed without changing the pitch, and the term “speed” when they are changed together (like a record playing too slowly).

Other application solutions:

If other applications have solved this, please describe their solution (If it fits your needs, else explain why their solution is not perfect)

VLC (Android version) has a setting to opt out of time-stretching audio. This locks tempo and pitch together, like a record (see above).

Additional description and context:

The more details the better to understand the need and figure out the best solution.

Screenshots / Mockup:

If possible please provide screenshots of your idea of the implementation or how other application do this.

The Ui in my mockups below are influenced by Audacious

So from ExoPlayer doc (what I use) PlaybackParameters (ExoPlayer library)

I guess your lock to pitch would be passing the same pitch value as the speed one? Or would that be 1? (Currently used value is 1)

For the rest it says it must be a positive value no idea how to convert that into your semitones :frowning:

I guess your lock to pitch would be passing the same pitch value as the speed one?

That’s sounds right to me.

no idea how to convert that into your semitones

semitones = log( speed_multiplier ) ÷ log(2 ** (1 ÷ 12))
speed_multiplier = 2 ** (semitones / 12)

or, in (pseudo)Java (I’m not familiar with Java):

double speedMutltiplierToSemitones(double mutiplier) {
    return Math.log(mutiplier) / Math.log(Math.pow(2.0, Math.log(1.0 / 12.0)));

double semitonesToSpeedMutltiplier(double semitones) {
    return Math.pow(2.0, semitones / 12.0);

Hum it’s late so I’m probably just tired, but those calculations are related to speed not the pitch.

Is this supposed to be speed * pitch?

You’d send a number like the speed number (0.5 to 3.0) to ExoPlayer, but show a “semitones” number on the UI. These calculations convert to and from the “semitones” number to the ExoPlayer number.

So a speed-like number of “2” would display as “+12 semitones”, and a speed-like number of “0.5” would display as “-12 semitones”.

Also, the names of my Java functions call the speed-like number the “speedMultiplier”.

ExoPlayer takes 2 arguments the speed and the pitch.

On your screenshot the speed is the same as now.

And the semitones are tied to the pitch. So your functions that are tied to speed as per their name does not match hence why I’m lost.

And your functions also does not seem to tie the 2 parameters between them.

I guess I’ll go simple. A switch to enable a pitch control that will be 0.5 to 3 like the speed and pass both :slight_smile: Most users won’t know about semitones anyway.

OK, then. Does this make more sense?

double convertExoPlayerNumberToSemitones(double exoPlayerNumber) {
    return Math.log(exoPlayerNumber) / Math.log(Math.pow(2.0, Math.log(1.0 / 12.0)));

double convertSemitonesToExoPlayerNumber(double semitones) {
    return Math.pow(2.0, semitones / 12.0);

Edit: I totally get how I could’ve been confusing.

Lol yes a lot more :slight_smile:

So by default lock to pitch unchecked as now and exovalue of pitch to 1.

Nothing change for the speed.

For the pitch use the same 0.5 / 3 range converted to semitones.

Both can be changed.

When lock to pitch is checked hide the pitch selector and just display the value of the semitone calculated from the exo speed value.

All good?

Sounds good to me! :+1:


Just got the update. Nicely done. Thank you so much.

Apologies if replying to this thread isn’t the correct procedure but I have a small suggestion to make off the back of this solution.

Is it possible to adjust the play speed at smaller intervals? Currently, there appears to be only 0.1x (10%) jumps (+/-) allowed, whereas if we could feed a number or have 1% jumps that would be perfect.

Coming from a music production/DJ background, 10% jumps in speed is quite a drastic change in tempo, whereas 1% would allow for more subtle changes, and IMO, much more practical.

Thanks :slight_smile:

1 Like

Please open your own feature request for tracking.

1 Like

Thanks Tolriq, will do so!