Struct cubeb::StreamParamsRef
source · pub struct StreamParamsRef(/* private fields */);
Implementations§
source§impl StreamParamsRef
impl StreamParamsRef
sourcepub unsafe fn from_ptr<'a>(ptr: *mut cubeb_stream_params) -> &'a StreamParamsRef
pub unsafe fn from_ptr<'a>(ptr: *mut cubeb_stream_params) -> &'a StreamParamsRef
§Safety
This function is unsafe because it dereferences the given ptr
pointer.
The caller should ensure that pointer is valid.
sourcepub unsafe fn from_ptr_mut<'a>(
ptr: *mut cubeb_stream_params
) -> &'a mut StreamParamsRef
pub unsafe fn from_ptr_mut<'a>( ptr: *mut cubeb_stream_params ) -> &'a mut StreamParamsRef
§Safety
This function is unsafe because it dereferences the given ptr
pointer.
The caller should ensure that pointer is valid.
pub fn as_ptr(&self) -> *mut cubeb_stream_params
source§impl StreamParamsRef
impl StreamParamsRef
pub fn format(&self) -> SampleFormat
pub fn rate(&self) -> u32
pub fn channels(&self) -> u32
pub fn layout(&self) -> ChannelLayout
pub fn prefs(&self) -> StreamPrefs
Trait Implementations§
source§impl AsRef<StreamParamsRef> for StreamParams
impl AsRef<StreamParamsRef> for StreamParams
source§fn as_ref(&self) -> &StreamParamsRef
fn as_ref(&self) -> &StreamParamsRef
Converts this type into a shared reference of the (usually inferred) input type.
source§impl Borrow<StreamParamsRef> for StreamParams
impl Borrow<StreamParamsRef> for StreamParams
source§fn borrow(&self) -> &StreamParamsRef
fn borrow(&self) -> &StreamParamsRef
Immutably borrows from an owned value. Read more
Auto Trait Implementations§
impl !Freeze for StreamParamsRef
impl !RefUnwindSafe for StreamParamsRef
impl Send for StreamParamsRef
impl !Sync for StreamParamsRef
impl Unpin for StreamParamsRef
impl UnwindSafe for StreamParamsRef
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