fix: platform specific init

This commit is contained in:
tux
2025-07-05 18:30:05 +05:30
parent e0f1c54dee
commit 3c01781503
2 changed files with 17 additions and 6 deletions

View File

@@ -1,4 +1,5 @@
using System.IO;
using System;
using System.IO;
using SoundFlow.Backends.MiniAudio;
using SoundFlow.Components;
using SoundFlow.Enums;
@@ -7,7 +8,9 @@ namespace highminded.utils;
public class AudioCapture
{
private readonly MiniAudioEngine _audioEngine = new(48000, Capability.Loopback);
private readonly MiniAudioEngine _audioEngine =
new(48000, OperatingSystem.IsWindows() ? Capability.Loopback : Capability.Mixed);
private Stream? _fileStream;
private Recorder? _recorder;