public static void Init(int device) { IsInitialized = true; Device = device; var info = default(DeviceInfo); BassUtils.OK(Bass.GetDeviceInfo(BassUtils.GetDeviceNumber(Device), out info)); Devices[Device] = new BassDirectSoundDeviceInfo( info.Name, Bass.Info.SampleRate, 0, Bass.Info.SpeakerCount, OutputRate.GetRates(Bass.Info.MinSampleRate, Bass.Info.MaxSampleRate) ); LogManager.Logger.Write(typeof(BassDirectSoundDevice), LogLevel.Debug, "Detected DS device: {0} => Name => {1}, Inputs => {2}, Outputs = {3}, Rate = {4}", Device, Info.Name, Info.Inputs, Info.Outputs, Info.Rate); LogManager.Logger.Write(typeof(BassDirectSoundDevice), LogLevel.Debug, "Detected DS device: {0} => Rates => {1}", Device, string.Join(", ", Info.SupportedRates)); }