Struct cubeb_core::DeviceInfo
source · pub struct DeviceInfo(/* private fields */);
Implementations§
source§impl DeviceInfo
impl DeviceInfo
pub fn as_ptr(&self) -> *mut cubeb_device_info
Methods from Deref<Target = DeviceInfoRef>§
pub fn as_ptr(&self) -> *mut cubeb_device_info
pub fn device_id_bytes(&self) -> Option<&[u8]>
sourcepub fn friendly_name(&self) -> Option<&str>
pub fn friendly_name(&self) -> Option<&str>
Friendly device name which might be presented in a UI.
pub fn friendly_name_bytes(&self) -> Option<&[u8]>
sourcepub fn group_id(&self) -> Option<&str>
pub fn group_id(&self) -> Option<&str>
Two devices have the same group identifier if they belong to the same physical device; for example a headset and microphone.
pub fn group_id_bytes(&self) -> Option<&[u8]>
sourcepub fn vendor_name(&self) -> Option<&str>
pub fn vendor_name(&self) -> Option<&str>
Optional vendor name, may be None.
pub fn vendor_name_bytes(&self) -> Option<&[u8]>
sourcepub fn device_type(&self) -> DeviceType
pub fn device_type(&self) -> DeviceType
Type of device (Input/Output).
sourcepub fn state(&self) -> DeviceState
pub fn state(&self) -> DeviceState
State of device disabled/enabled/unplugged.
sourcepub fn preferred(&self) -> DevicePref
pub fn preferred(&self) -> DevicePref
Preferred device.
sourcepub fn format(&self) -> DeviceFormat
pub fn format(&self) -> DeviceFormat
Sample format supported.
sourcepub fn default_format(&self) -> DeviceFormat
pub fn default_format(&self) -> DeviceFormat
The default sample format for this device.
sourcepub fn max_channels(&self) -> u32
pub fn max_channels(&self) -> u32
Channels.
sourcepub fn default_rate(&self) -> u32
pub fn default_rate(&self) -> u32
Default/Preferred sample rate.
sourcepub fn latency_lo(&self) -> u32
pub fn latency_lo(&self) -> u32
Lowest possible latency in frames.
sourcepub fn latency_hi(&self) -> u32
pub fn latency_hi(&self) -> u32
Higest possible latency in frames.
Trait Implementations§
source§impl AsRef<DeviceInfoRef> for DeviceInfo
impl AsRef<DeviceInfoRef> for DeviceInfo
source§fn as_ref(&self) -> &DeviceInfoRef
fn as_ref(&self) -> &DeviceInfoRef
Converts this type into a shared reference of the (usually inferred) input type.
source§impl Borrow<DeviceInfoRef> for DeviceInfo
impl Borrow<DeviceInfoRef> for DeviceInfo
source§fn borrow(&self) -> &DeviceInfoRef
fn borrow(&self) -> &DeviceInfoRef
Immutably borrows from an owned value. Read more
source§impl Default for DeviceInfo
impl Default for DeviceInfo
source§fn default() -> DeviceInfo
fn default() -> DeviceInfo
Returns the “default value” for a type. Read more
source§impl Deref for DeviceInfo
impl Deref for DeviceInfo
§type Target = DeviceInfoRef
type Target = DeviceInfoRef
The resulting type after dereferencing.
source§fn deref(&self) -> &DeviceInfoRef
fn deref(&self) -> &DeviceInfoRef
Dereferences the value.
source§impl DerefMut for DeviceInfo
impl DerefMut for DeviceInfo
source§fn deref_mut(&mut self) -> &mut DeviceInfoRef
fn deref_mut(&mut self) -> &mut DeviceInfoRef
Mutably dereferences the value.
source§impl From<cubeb_device_info> for DeviceInfo
impl From<cubeb_device_info> for DeviceInfo
source§fn from(x: cubeb_device_info) -> DeviceInfo
fn from(x: cubeb_device_info) -> DeviceInfo
Converts to this type from the input type.
Auto Trait Implementations§
impl RefUnwindSafe for DeviceInfo
impl !Send for DeviceInfo
impl !Sync for DeviceInfo
impl Unpin for DeviceInfo
impl UnwindSafe for DeviceInfo
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more