Struct reaper_medium::OwnedPreviewRegister
source · [−]pub struct OwnedPreviewRegister { /* private fields */ }
Expand description
An owned preview register.
It owns PCM source, mutex and critical section (and manages its lifetime) but it doesn’t own the track of course.
Implementations
sourceimpl OwnedPreviewRegister
impl OwnedPreviewRegister
sourcepub fn new() -> OwnedPreviewRegister
pub fn new() -> OwnedPreviewRegister
Creates a preview register.
Also takes care of initializing the mutex.
pub fn src(&self) -> Option<&FlexibleOwnedPcmSource>
pub fn src_mut(&mut self) -> Option<&mut FlexibleOwnedPcmSource>
pub fn set_src(
&mut self,
src: Option<FlexibleOwnedPcmSource>
) -> Option<FlexibleOwnedPcmSource>
pub fn volume(&self) -> ReaperVolumeValue
pub fn set_volume(&mut self, volume: ReaperVolumeValue)
pub fn cur_pos(&self) -> PositionInSeconds
pub fn set_cur_pos(&mut self, pos: PositionInSeconds)
pub fn is_looped(&self) -> bool
pub fn set_looped(&mut self, looped: bool)
pub fn preview_track(&self) -> Option<MediaTrack>
pub fn set_preview_track(&mut self, track: Option<MediaTrack>)
pub fn set_out_chan(&mut self, value: i32)
Trait Implementations
sourceimpl AsRef<preview_register_t> for OwnedPreviewRegister
impl AsRef<preview_register_t> for OwnedPreviewRegister
sourcefn as_ref(&self) -> &preview_register_t
fn as_ref(&self) -> &preview_register_t
Converts this type into a shared reference of the (usually inferred) input type.
sourceimpl AsRef<pthread_mutex_t> for OwnedPreviewRegister
impl AsRef<pthread_mutex_t> for OwnedPreviewRegister
sourcefn as_ref(&self) -> &pthread_mutex_t
fn as_ref(&self) -> &pthread_mutex_t
Converts this type into a shared reference of the (usually inferred) input type.
sourceimpl Clone for OwnedPreviewRegister
impl Clone for OwnedPreviewRegister
sourcefn clone(&self) -> OwnedPreviewRegister
fn clone(&self) -> OwnedPreviewRegister
Returns a copy of the value. Read more
1.0.0 · sourceconst fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for OwnedPreviewRegister
impl Debug for OwnedPreviewRegister
sourceimpl Default for OwnedPreviewRegister
impl Default for OwnedPreviewRegister
Auto Trait Implementations
impl !RefUnwindSafe for OwnedPreviewRegister
impl !Send for OwnedPreviewRegister
impl !Sync for OwnedPreviewRegister
impl Unpin for OwnedPreviewRegister
impl !UnwindSafe for OwnedPreviewRegister
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
sourcefn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read moresourcefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read moresourcefn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read moresourcefn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s. Read more