Struct streamduck_core::modules::core_module::CoreModule
source · [−]pub struct CoreModule { /* private fields */ }Expand description
The core module, for exposing renderer component to requests and such
Trait Implementations
sourceimpl SDModule for CoreModule
impl SDModule for CoreModule
sourcefn components(&self) -> HashMap<String, ComponentDefinition>
fn components(&self) -> HashMap<String, ComponentDefinition>
Definition for components that module will be providing
sourcefn add_component(&self, _: CoreHandle, button: &mut Button, name: &str)
fn add_component(&self, _: CoreHandle, button: &mut Button, name: &str)
Method for adding components onto buttons
sourcefn remove_component(&self, _: CoreHandle, button: &mut Button, name: &str)
fn remove_component(&self, _: CoreHandle, button: &mut Button, name: &str)
Method for removing components from buttons
sourcefn paste_component(
&self,
_: CoreHandle,
reference_button: &Button,
new_button: &mut Button
)
fn paste_component(
&self,
_: CoreHandle,
reference_button: &Button,
new_button: &mut Button
)
Method for handling pasting components of plugin, can be used for any additional handling
sourcefn component_values(
&self,
core: CoreHandle,
button: &Button,
name: &str
) -> Vec<UIValue>
fn component_values(
&self,
core: CoreHandle,
button: &Button,
name: &str
) -> Vec<UIValue>
Method for letting core know what values component currently has
sourcefn set_component_value(
&self,
core: CoreHandle,
button: &mut Button,
name: &str,
value: Vec<UIValue>
)
fn set_component_value(
&self,
core: CoreHandle,
button: &mut Button,
name: &str,
value: Vec<UIValue>
)
Method for setting values on components
sourcefn listening_for(&self) -> Vec<String>
fn listening_for(&self) -> Vec<String>
Specifies which components the module will be receiving events for
sourcefn settings(&self, core_manager: Arc<CoreManager>) -> Vec<UIValue>
fn settings(&self, core_manager: Arc<CoreManager>) -> Vec<UIValue>
Current settings state of the plugin
sourcefn set_setting(&self, core_manager: Arc<CoreManager>, value: Vec<UIValue>)
fn set_setting(&self, core_manager: Arc<CoreManager>, value: Vec<UIValue>)
Method for updating plugin settings from UI
sourcefn event(&self, core: CoreHandle, event: SDCoreEvent)
fn event(&self, core: CoreHandle, event: SDCoreEvent)
Method for handling core events, add CORE_EVENTS feature to the plugin metadata to receive core events
sourcefn metadata(&self) -> PluginMetadata
fn metadata(&self) -> PluginMetadata
Metadata of the module, auto-implemented for plugins from plugin metadata
sourcefn global_event(&self, event: SDGlobalEvent)
fn global_event(&self, event: SDGlobalEvent)
Method for handling global events, add GLOBAL_EVENTS feature to the plugin metadata to receive global events
sourcefn render(&self, core: CoreHandle, button: &UniqueButton, frame: &mut DynamicImage)
fn render(&self, core: CoreHandle, button: &UniqueButton, frame: &mut DynamicImage)
Method renderer will run for rendering additional information on a button if RENDERING feature was specified
sourcefn render_hash(
&self,
core: CoreHandle,
button: &UniqueButton,
hash: &mut Box<dyn Hasher>
)
fn render_hash(
&self,
core: CoreHandle,
button: &UniqueButton,
hash: &mut Box<dyn Hasher>
)
Method for telling renderer if anything changed Read more
Auto Trait Implementations
impl RefUnwindSafe for CoreModule
impl Send for CoreModule
impl Sync for CoreModule
impl Unpin for CoreModule
impl UnwindSafe for CoreModule
Blanket Implementations
sourceimpl<S, D, Swp, Dwp, T> AdaptInto<D, Swp, Dwp, T> for S where
T: FloatComponent,
Swp: WhitePoint,
Dwp: WhitePoint,
D: AdaptFrom<S, Swp, Dwp, T>,
impl<S, D, Swp, Dwp, T> AdaptInto<D, Swp, Dwp, T> for S where
T: FloatComponent,
Swp: WhitePoint,
Dwp: WhitePoint,
D: AdaptFrom<S, Swp, Dwp, T>,
sourcefn adapt_into_using<M>(self, method: M) -> D where
M: TransformMatrix<Swp, Dwp, T>,
fn adapt_into_using<M>(self, method: M) -> D where
M: TransformMatrix<Swp, Dwp, T>,
Convert the source color to the destination color using the specified method Read more
sourcefn adapt_into(self) -> D
fn adapt_into(self) -> D
Convert the source color to the destination color using the bradford method by default Read more
impl<Src, Scheme> ApproxFrom<Src, Scheme> for Src where
Scheme: ApproxScheme,
impl<Src, Scheme> ApproxFrom<Src, Scheme> for Src where
Scheme: ApproxScheme,
type Err = NoError
type Err = NoError
The error type produced by a failed conversion.
fn approx_from(src: Src) -> Result<Src, <Src as ApproxFrom<Src, Scheme>>::Err>
fn approx_from(src: Src) -> Result<Src, <Src as ApproxFrom<Src, Scheme>>::Err>
Convert the given value into an approximately equivalent representation.
impl<Dst, Src, Scheme> ApproxInto<Dst, Scheme> for Src where
Dst: ApproxFrom<Src, Scheme>,
Scheme: ApproxScheme,
impl<Dst, Src, Scheme> ApproxInto<Dst, Scheme> for Src where
Dst: ApproxFrom<Src, Scheme>,
Scheme: ApproxScheme,
type Err = <Dst as ApproxFrom<Src, Scheme>>::Err
type Err = <Dst as ApproxFrom<Src, Scheme>>::Err
The error type produced by a failed conversion.
fn approx_into(self) -> Result<Dst, <Src as ApproxInto<Dst, Scheme>>::Err>
fn approx_into(self) -> Result<Dst, <Src as ApproxInto<Dst, Scheme>>::Err>
Convert the subject into an approximately equivalent representation.
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
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
impl<T> ConvUtil for T
impl<T> ConvUtil for T
fn approx_as<Dst>(self) -> Result<Dst, Self::Err> where
Self: ApproxInto<Dst, DefaultApprox>,
fn approx_as<Dst>(self) -> Result<Dst, Self::Err> where
Self: ApproxInto<Dst, DefaultApprox>,
Approximate the subject to a given type with the default scheme.
fn approx_as_by<Dst, Scheme>(self) -> Result<Dst, Self::Err> where
Self: ApproxInto<Dst, Scheme>,
Scheme: ApproxScheme,
fn approx_as_by<Dst, Scheme>(self) -> Result<Dst, Self::Err> where
Self: ApproxInto<Dst, Scheme>,
Scheme: ApproxScheme,
Approximate the subject to a given type with a specific scheme.
sourceimpl<T, U> IntoColor<U> for T where
U: FromColor<T>,
impl<T, U> IntoColor<U> for T where
U: FromColor<T>,
sourcefn into_color(self) -> U
fn into_color(self) -> U
Convert into T with values clamped to the color defined bounds Read more
sourceimpl<T, U> IntoColorUnclamped<U> for T where
U: FromColorUnclamped<T>,
impl<T, U> IntoColorUnclamped<U> for T where
U: FromColorUnclamped<T>,
sourcefn into_color_unclamped(self) -> U
fn into_color_unclamped(self) -> U
Convert into T. The resulting color might be invalid in its color space Read more
impl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T, U> TryIntoColor<U> for T where
U: TryFromColor<T>,
impl<T, U> TryIntoColor<U> for T where
U: TryFromColor<T>,
sourcefn try_into_color(self) -> Result<U, OutOfBounds<U>>
fn try_into_color(self) -> Result<U, OutOfBounds<U>>
Convert into T, returning ok if the color is inside of its defined
range, otherwise an OutOfBounds error is returned which contains
the unclamped color. Read more
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
impl<Src> ValueFrom<Src> for Src
impl<Src> ValueFrom<Src> for Src
type Err = NoError
type Err = NoError
The error type produced by a failed conversion.
fn value_from(src: Src) -> Result<Src, <Src as ValueFrom<Src>>::Err>
fn value_from(src: Src) -> Result<Src, <Src as ValueFrom<Src>>::Err>
Convert the given value into an exactly equivalent representation.
impl<Src, Dst> ValueInto<Dst> for Src where
Dst: ValueFrom<Src>,
impl<Src, Dst> ValueInto<Dst> for Src where
Dst: ValueFrom<Src>,
type Err = <Dst as ValueFrom<Src>>::Err
type Err = <Dst as ValueFrom<Src>>::Err
The error type produced by a failed conversion.
fn value_into(self) -> Result<Dst, <Src as ValueInto<Dst>>::Err>
fn value_into(self) -> Result<Dst, <Src as ValueInto<Dst>>::Err>
Convert the subject into an exactly equivalent representation.