feat: per-track loudness normalization and server audio info
- measure downloads with ffmpeg's EBU R128 filter and store gain/LUFS - backfill the existing library one file at a time - expose gain on songs and a /info endpoint for source quality - chart knobs LOUDNESS_ENABLED and LOUDNESS_TARGET_LUFS
This commit is contained in:
1 parent
6763a83b03
commit
91312faa1c
15 files changed
+387
-9
No files matched your search
@@ -37,6 +37,9 @@ fun Route.apiRoutes(
|
||||
mediaStore: MediaStore,
|
||||
gc: MediaGcService,
|
||||
defaultSource: String,
|
||||
deezerQuality: Int,
|
||||
loudnessEnabled: Boolean,
|
||||
loudnessTargetLufs: Double,
|
||||
startScan: () -> Boolean,
|
||||
scanStatus: () -> ScanStatus,
|
||||
) {
|
||||
@@ -77,6 +80,19 @@ fun Route.apiRoutes(
|
||||
call.respond(user.toDto())
|
||||
}
|
||||
|
||||
/** Source and audio settings the client cannot infer from a song. */
|
||||
get("/info") {
|
||||
call.requireApiUser(users)
|
||||
call.respond(
|
||||
ServerInfoDto(
|
||||
defaultSource = defaultSource,
|
||||
deezerQuality = deezerQuality,
|
||||
loudnessEnabled = loudnessEnabled,
|
||||
loudnessTargetLufs = loudnessTargetLufs,
|
||||
),
|
||||
)
|
||||
}
|
||||
|
||||
post("/auth/logout") {
|
||||
call.requireApiUser(users)
|
||||
ApiTokenRepository.revokeRaw(call.bearerToken().orEmpty())
|
||||
|
||||
Reference in new issue
Block a user