mirror of
https://github.com/Moepchi/webspeak3.git
synced 2026-12-03 09:52:50 +08:00
Whisper settings: incoming whisper rights, sound, history auto-open/cleanup
Options -> Whispern like TS3: allow/block by default with per-contact overrides (new Whisper field in contacts) or block all. The connector drops blocked whispers before decoding (whisperpolicy stdin command) and reports accepted ones as whisperReceived, which logs them in the whisper history, plays the new whisper sound and can open the history. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Hu2cuPLqpuKVfd9wWFFakU
This commit is contained in:
1 parent
2e6b295185
commit
7b98cb2d7c
11 files changed
+295
-6
No files matched your search
+10
-1
@@ -7,7 +7,8 @@ export type SoundEventId =
|
||||
| "poke"
|
||||
| "mute"
|
||||
| "micClickOn"
|
||||
| "micClickOff";
|
||||
| "micClickOff"
|
||||
| "whisper";
|
||||
|
||||
export const SOUND_EVENTS: SoundEventId[] = [
|
||||
"connect",
|
||||
@@ -19,6 +20,7 @@ export const SOUND_EVENTS: SoundEventId[] = [
|
||||
"mute",
|
||||
"micClickOn",
|
||||
"micClickOff",
|
||||
"whisper",
|
||||
];
|
||||
|
||||
/** "ide" swaps the default chimes for synthetic terminal blips (Command Center layout). */
|
||||
@@ -238,6 +240,11 @@ function synthNotes(event: SoundEventId): SynthNote[] {
|
||||
return [{ delay: 0, freq: 1400, duration: 0.03, gain: 0.15 }];
|
||||
case "micClickOff":
|
||||
return [{ delay: 0, freq: 900, duration: 0.03, gain: 0.15 }];
|
||||
case "whisper":
|
||||
return [
|
||||
{ delay: 0, freq: 783.99, duration: 0.12, gain: 0.2 },
|
||||
{ delay: 0.1, freq: 659.25, duration: 0.16, gain: 0.18 },
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
@@ -274,6 +281,8 @@ function ideNotes(event: SoundEventId): SynthNote[] {
|
||||
return [{ delay: 0, freq: 1600, duration: 0.02, gain: 0.08, type: "square" }];
|
||||
case "micClickOff":
|
||||
return [{ delay: 0, freq: 1000, duration: 0.02, gain: 0.08, type: "square" }];
|
||||
case "whisper":
|
||||
return [{ delay: 0, freq: 900, endFreq: 700, duration: 0.08, gain: 0.1, type: "triangle" }];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user