using Whisper.Internal; namespace Whisper { /// Identifiers for an audio capture device public record struct CaptureDeviceId { /// The display name is suitable for showing to the user, but might not be unique. public string displayName; /// Endpoint ID for an audio capture device.
/// It uniquely identifies the device on the system, but is not a readable string.
public string endpoint; internal CaptureDeviceId( in sCaptureDevice rsi ) { displayName = rsi.displayName ?? ""; endpoint = rsi.endpoint ?? throw new ApplicationException( "The device has no endpoint ID" ); } /// Returns a String which represents the object instance public override string ToString() => $"Capture device: \"{displayName}\""; } }