public static BASS_DEVICEINFO BASS_RecordGetDeviceInfo(int device) { BASS_DEVICEINFO info = new BASS_DEVICEINFO(); if (BASS_RecordGetDeviceInfo(device, info)) { return(info); } return(null); }
public static bool BASS_RecordGetDeviceInfo(int device, BASS_DEVICEINFO info) { bool flag = BASS_RecordGetDeviceInfoInternal(device, ref info._internal); if (flag) { info.name = Marshal.PtrToStringAnsi(info._internal.name); info.driver = Marshal.PtrToStringAnsi(info._internal.driver); info.flags = info._internal.flags; } return(flag); }
public static int BASS_GetDeviceCount() { BASS_DEVICEINFO info = new BASS_DEVICEINFO(); int device = 0; while (BASS_GetDeviceInfo(device, info)) { device++; } BASS_GetCPU(); return(device); }
public bool Init() { _Devices = new List<SRecordDevice>(); try { BASS_DEVICEINFO info = new BASS_DEVICEINFO(); for (int n = 0; Bass.BASS_RecordGetDeviceInfo(n, info); n++) { if (info.IsEnabled) { SRecordDevice dev = new SRecordDevice(); dev.ID = n; dev.Name = info.name; dev.Driver = info.driver; dev.Inputs = new List<SInput>(); if (Bass.BASS_RecordInit(n)) { string name = String.Empty; for (int j = 0; ((name = Bass.BASS_RecordGetInputName(j)) != null); j++) { SInput inp = new SInput(); inp.Name = name; inp.Channels = 2; //TODO: how to retrieve the amount of channels? dev.Inputs.Add(inp); } _Devices.Add(dev); Bass.BASS_RecordFree(); } } } } catch (Exception) { //throw; } return true; }
public static bool BASS_RecordGetDeviceInfo(int device, BASS_DEVICEINFO info) { bool flag = BASS_RecordGetDeviceInfoInternal(device, ref info._internal); if (flag) { info.name = Marshal.PtrToStringAnsi(info._internal.name); info.driver = Marshal.PtrToStringAnsi(info._internal.driver); info.flags = info._internal.flags; } return flag; }
public static BASS_DEVICEINFO BASS_RecordGetDeviceInfo(int device) { BASS_DEVICEINFO info = new BASS_DEVICEINFO(); if (BASS_RecordGetDeviceInfo(device, info)) { return info; } return null; }
public static int BASS_RecordGetDeviceCount() { BASS_DEVICEINFO info = new BASS_DEVICEINFO(); int device = 0; while (BASS_RecordGetDeviceInfo(device, info)) { device++; } BASS_GetCPU(); return device; }
public Device(int i) { DeviceInfo = Bass.BASS_GetDeviceInfo(i); }