pub struct ObsFilterRef { /* private fields */ }Implementations§
Source§impl ObsFilterRef
impl ObsFilterRef
Sourcepub fn new<T: Into<ObsString> + Sync + Send, K: Into<ObsString> + Sync + Send>(
id: T,
name: K,
settings: Option<ImmutableObsData>,
hotkey_data: Option<ImmutableObsData>,
runtime: ObsRuntime,
) -> Result<Self, ObsError>
pub fn new<T: Into<ObsString> + Sync + Send, K: Into<ObsString> + Sync + Send>( id: T, name: K, settings: Option<ImmutableObsData>, hotkey_data: Option<ImmutableObsData>, runtime: ObsRuntime, ) -> Result<Self, ObsError>
Creates a new OBS filter, this is a more advanced usage as you’ll have to specify the id, name, settings and hotkey_data yourself. This will be easier in the future…
Source§impl ObsFilterRef
impl ObsFilterRef
pub fn inner_source(&self) -> &ObsSourceRef
pub fn inner_source_mut(&mut self) -> &mut ObsSourceRef
Sourcepub fn into_inner_source(self) -> ObsSourceRef
pub fn into_inner_source(self) -> ObsSourceRef
Consumes self and returns the inner ObsSourceRef
You can still update this source (if created by libobs-simple) and create an updater like so:
let updater = my_custom_source.create_updater()?;
let source = my_custom_source.into_inner_source();
let updater = source.create_updater::<MyCustomSourceUpdater>()?;Trait Implementations§
Source§impl Clone for ObsFilterRef
impl Clone for ObsFilterRef
Source§fn clone(&self) -> ObsFilterRef
fn clone(&self) -> ObsFilterRef
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ObsFilterRef
impl Debug for ObsFilterRef
Source§impl Hash for ObsFilterRef
impl Hash for ObsFilterRef
Source§impl ObsObjectTrait<*mut obs_source> for ObsFilterRef
impl ObsObjectTrait<*mut obs_source> for ObsFilterRef
fn name(&self) -> ObsString
fn id(&self) -> ObsString
fn runtime(&self) -> &ObsRuntime
fn settings(&self) -> Result<ImmutableObsData, ObsError>
fn hotkey_data(&self) -> Result<ImmutableObsData, ObsError>
Source§fn update_settings(&self, settings: ObsData) -> Result<(), ObsError>
fn update_settings(&self, settings: ObsData) -> Result<(), ObsError>
Updates the settings of this output. Fails if active.
Source§fn as_ptr(&self) -> SmartPointerSendable<*mut obs_source_t>
fn as_ptr(&self) -> SmartPointerSendable<*mut obs_source_t>
Creates a new reference to the drop guard.
This is useful if you are using the underlying raw pointer, make sure to store it along the drop guard
Source§fn create_updater<'a, T: ObsObjectUpdater<'a, K, ToUpdate = Self> + Send + Sync>(
&'a mut self,
) -> Result<T, ObsError>
fn create_updater<'a, T: ObsObjectUpdater<'a, K, ToUpdate = Self> + Send + Sync>( &'a mut self, ) -> Result<T, ObsError>
Updates the object with the current settings.
For examples please take a look at the Github repository.
Source§impl ObsSourceTrait for ObsFilterRef
impl ObsSourceTrait for ObsFilterRef
fn signals(&self) -> &Arc<ObsSourceSignals>
fn get_active_filters(&self) -> Result<Vec<ObsFilterGuardPair>, ObsError>
fn apply_filter(&self, filter: &ObsFilterRef) -> Result<(), ObsError>
Source§impl PartialEq for ObsFilterRef
impl PartialEq for ObsFilterRef
impl Eq for ObsFilterRef
Auto Trait Implementations§
impl Freeze for ObsFilterRef
impl !RefUnwindSafe for ObsFilterRef
impl Send for ObsFilterRef
impl Sync for ObsFilterRef
impl Unpin for ObsFilterRef
impl !UnwindSafe for ObsFilterRef
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T, K> ObsObjectClone<K> for T
impl<T, K> ObsObjectClone<K> for T
fn clone_box(&self) -> Box<dyn ObsObjectTrait<K>>
Source§impl<K> ObsPropertyObject for Kwhere
K: ObsSourceTrait,
impl<K> ObsPropertyObject for Kwhere
K: ObsSourceTrait,
Source§fn get_properties(&self) -> Result<HashMap<String, ObsProperty>, ObsError>
fn get_properties(&self) -> Result<HashMap<String, ObsProperty>, ObsError>
Returns the properties of the object