[PR #4935] Add natural volume scaling option for web client #4376

Open
opened 2026-04-25 00:19:30 +02:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/advplyr/audiobookshelf/pull/4935
Author: @lerndmina
Created: 12/25/2025
Status: 🔄 Open

Base: masterHead: master


📝 Commits (2)

  • 9012c7f Add option for logarithmic volume scaling
  • f22df2b Merge branch 'advplyr:master' into master

📊 Changes

4 files changed (+17 additions, -2 deletions)

View changed files

📝 client/components/modals/PlayerSettingsModal.vue (+11 -0)
📝 client/players/LocalAudioPlayer.js (+3 -1)
📝 client/store/user.js (+2 -1)
📝 client/strings/en-us.json (+1 -0)

📄 Description

Brief summary

Adds a "Natural volume scaling" toggle in Player Settings that applies a quadratic curve to volume output, making the volume slider feel more responsive and natural across its full range.

Which issue is fixed?

Fixes #4889

In-depth Description

The current volume slider uses a linear scale, but human hearing perceives loudness logarithmically. This causes the top portion of the slider to feel unresponsive while small adjustments at the bottom cause large perceived volume changes.

This PR applies a quadratic curve (volume²) when the setting is enabled:

  • 50% slider → 25% actual volume
  • 70% slider → 49% actual volume
  • 100% slider → 100% actual volume

This gives users finer control in the quiet range where small changes are more noticeable, while moving through the loud range faster where differences are harder to perceive.

The setting is disabled by default. Only affects web client playback.

How have you tested this?

  1. Started the dev server and client with hot-reload
  2. Played an audiobook in the web client
  3. Opened Player Settings and toggled "Natural volume scaling" on/off
  4. Adjusted volume slider while audio was playing
  5. Confirmed the slider feels more responsive with the setting enabled
  6. Verified setting persists after page refresh

Screenshots

image

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/advplyr/audiobookshelf/pull/4935 **Author:** [@lerndmina](https://github.com/lerndmina) **Created:** 12/25/2025 **Status:** 🔄 Open **Base:** `master` ← **Head:** `master` --- ### 📝 Commits (2) - [`9012c7f`](https://github.com/advplyr/audiobookshelf/commit/9012c7f0a85a3a4a0e783c1f841893bae9ed1af2) Add option for logarithmic volume scaling - [`f22df2b`](https://github.com/advplyr/audiobookshelf/commit/f22df2b76c4a00177e496bd3cb908126f9ba06d8) Merge branch 'advplyr:master' into master ### 📊 Changes **4 files changed** (+17 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `client/components/modals/PlayerSettingsModal.vue` (+11 -0) 📝 `client/players/LocalAudioPlayer.js` (+3 -1) 📝 `client/store/user.js` (+2 -1) 📝 `client/strings/en-us.json` (+1 -0) </details> ### 📄 Description ## Brief summary Adds a "Natural volume scaling" toggle in Player Settings that applies a quadratic curve to volume output, making the volume slider feel more responsive and natural across its full range. ## Which issue is fixed? Fixes #4889 ## In-depth Description The current volume slider uses a linear scale, but human hearing perceives loudness logarithmically. This causes the top portion of the slider to feel unresponsive while small adjustments at the bottom cause large perceived volume changes. This PR applies a quadratic curve (`volume²`) when the setting is enabled: - 50% slider → 25% actual volume - 70% slider → 49% actual volume - 100% slider → 100% actual volume This gives users finer control in the quiet range where small changes are more noticeable, while moving through the loud range faster where differences are harder to perceive. The setting is disabled by default. Only affects web client playback. ## How have you tested this? 1. Started the dev server and client with hot-reload 2. Played an audiobook in the web client 3. Opened Player Settings and toggled "Natural volume scaling" on/off 4. Adjusted volume slider while audio was playing 5. Confirmed the slider feels more responsive with the setting enabled 6. Verified setting persists after page refresh ## Screenshots <img width="453" height="519" alt="image" src="https://github.com/user-attachments/assets/8f5f19d4-f709-4817-9cfb-d328ba3c0add" /> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2026-04-25 00:19:30 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/audiobookshelf#4376