fix(stepdown): restart the audio pipe around encoder changes
A quality step-down now closes the named audio pipe before stopping/flushing the pump, then opens a fresh server before restarting the pump. This prevents ffmpeg from waiting on the old audio input and avoids reconnecting to a broken pipe. EncoderRestartTests pins the audio-stop → video-stop → audio-start → video-start order. 616 tests green, clean build with 0 warnings.
This commit is contained in:
@@ -74,7 +74,9 @@ public partial class MainViewModel
|
||||
|
||||
_encoderTierOverride = landed;
|
||||
AppLog.Write($"Quality step-down: {decision.Why}");
|
||||
await _framePump.ChangeEncoderAsync();
|
||||
await _framePump.ChangeEncoderAsync(
|
||||
_audioMixer.StopLive,
|
||||
() => _audioMixer.StartLive(InstanceProfile.AudioPipeName(EncoderOptions.DefaultAudioPipeName)));
|
||||
|
||||
// Show what is actually going out. The dropdown keeps the creator's choice — the policy
|
||||
// does not get to rewrite their intent, only the encoder's output.
|
||||
|
||||
Reference in New Issue
Block a user