[−][src]Struct cubeb_backend::Context
Methods
impl Context
[src]
pub fn init(
context_name: Option<&CStr>,
backend_name: Option<&CStr>
) -> Result<Context, Error>
[src]
context_name: Option<&CStr>,
backend_name: Option<&CStr>
) -> Result<Context, Error>
impl Context
[src]
Methods from Deref<Target = ContextRef>
pub fn backend_id(&self) -> &str
[src]
pub fn backend_id_bytes(&self) -> &[u8]
[src]
pub fn max_channel_count(&self) -> Result<u32, Error>
[src]
pub fn min_latency(&self, params: &StreamParamsRef) -> Result<u32, Error>
[src]
pub fn preferred_sample_rate(&self) -> Result<u32, Error>
[src]
pub unsafe fn stream_init(
&self,
stream_name: Option<&CStr>,
input_device: *const c_void,
input_stream_params: Option<&StreamParamsRef>,
output_device: *const c_void,
output_stream_params: Option<&StreamParamsRef>,
latency_frames: u32,
data_callback: Option<unsafe extern "C" fn(*mut cubeb_stream, *mut c_void, *const c_void, *mut c_void, i64) -> i64>,
state_callback: Option<unsafe extern "C" fn(*mut cubeb_stream, *mut c_void, u32)>,
user_ptr: *mut c_void
) -> Result<Stream, Error>
[src]
&self,
stream_name: Option<&CStr>,
input_device: *const c_void,
input_stream_params: Option<&StreamParamsRef>,
output_device: *const c_void,
output_stream_params: Option<&StreamParamsRef>,
latency_frames: u32,
data_callback: Option<unsafe extern "C" fn(*mut cubeb_stream, *mut c_void, *const c_void, *mut c_void, i64) -> i64>,
state_callback: Option<unsafe extern "C" fn(*mut cubeb_stream, *mut c_void, u32)>,
user_ptr: *mut c_void
) -> Result<Stream, Error>
pub fn enumerate_devices(
&self,
devtype: DeviceType
) -> Result<DeviceCollection, Error>
[src]
&self,
devtype: DeviceType
) -> Result<DeviceCollection, Error>
pub unsafe fn register_device_collection_changed(
&self,
devtype: DeviceType,
callback: Option<unsafe extern "C" fn(*mut cubeb, *mut c_void)>,
user_ptr: *mut c_void
) -> Result<(), Error>
[src]
&self,
devtype: DeviceType,
callback: Option<unsafe extern "C" fn(*mut cubeb, *mut c_void)>,
user_ptr: *mut c_void
) -> Result<(), Error>
Trait Implementations
impl AsRef<ContextRef> for Context
[src]
fn as_ref(&self) -> &ContextRef
[src]
impl Borrow<ContextRef> for Context
[src]
fn borrow(&self) -> &ContextRef
[src]
impl DerefMut for Context
[src]
fn deref_mut(&mut self) -> &mut ContextRef
[src]
impl Deref for Context
[src]
impl Drop for Context
[src]
Auto Trait Implementations
impl !Send for Context
impl Unpin for Context
impl !Sync for Context
impl UnwindSafe for Context
impl RefUnwindSafe for Context
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,