voelin-audio: dim everyone else while a priority speaker talks

The server sends virtualserver_priority_speaker_dimm_modificator (-18 dB
by default) but nothing read it. ServerDetails carries it now, the
session tells the audio thread the priority speakers when they or the
value change, and the mixer dims every other queue (watched streams too)
while an unmuted priority speaker has one, fading sample by sample over
5 frames.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AVRENKftQqGoEeswiR9TDQ
This commit is contained in:
Claude committed 2026-10-06 18:59:23 +00:00
1 parent 42639fd206
commit 68dd48d607
8 files changed
+364 -20

No files matched your search

+3
View File
@@ -60,6 +60,8 @@ fn server_details(server: &data::Server, uid: Option<&str>) -> ServerDetails {
platform: server.platform.clone(),
version: server.version.clone(),
max_clients: server.max_clients,
// `as` saturates (and turns NaN into 0); the mixer clamps it.
priority_speaker_dimm_db: server.priority_speaker_dimm_modificator.round() as i32,
default_server_group: Some(server.default_server_group.0),
default_channel_group: Some(server.default_channel_group.0),
}
@@ -265,5 +267,6 @@ mod tests {
assert_eq!(p.server.banner_gfx_interval_s, 60);
assert_eq!(p.server.banner_mode, BannerMode::KeepAspect);
assert_eq!(BannerMode::from_wire("7"), BannerMode::NoAdjust);
assert_eq!(p.server.priority_speaker_dimm_db, -18);
}
}