pub struct AudioNodeInfo { /* private fields */ }Expand description
Information about an AudioNode.
This struct enforces the use of the builder pattern for future-proofness, as it is likely that more fields will be added in the future.
Implementations§
Source§impl AudioNodeInfo
impl AudioNodeInfo
Sourcepub const fn new() -> Self
pub const fn new() -> Self
Construct a new AudioNodeInfo builder struct.
Sourcepub const fn debug_name(self, debug_name: &'static str) -> Self
pub const fn debug_name(self, debug_name: &'static str) -> Self
A unique name for this type of node, used for debugging purposes.
Sourcepub const fn channel_config(self, channel_config: ChannelConfig) -> Self
pub const fn channel_config(self, channel_config: ChannelConfig) -> Self
The channel configuration of this node.
By default this has a channel configuration with zero input and output channels.
Sourcepub const fn uses_events(self, uses_events: bool) -> Self
pub const fn uses_events(self, uses_events: bool) -> Self
Set to true if this node type uses events, false otherwise.
Setting to false will help the system save some memory by not
allocating an event buffer for this node.
By default this is set to false.
Sourcepub const fn call_update_method(self, call_update_method: bool) -> Self
pub const fn call_update_method(self, call_update_method: bool) -> Self
Set to true if this node wishes to have the Firewheel context call
AudioNode::update on every update cycle.
By default this is set to false.
Sourcepub fn custom_state<T: 'static>(self, custom_state: T) -> Self
pub fn custom_state<T: 'static>(self, custom_state: T) -> Self
Custom !Send state that can be stored in the Firewheel context and accessed
by the user.
The user accesses this state via FirewheelCtx::node_state and
FirewheelCtx::node_state_mut.
Trait Implementations§
Source§impl Debug for AudioNodeInfo
impl Debug for AudioNodeInfo
Source§impl Into<AudioNodeInfoInner> for AudioNodeInfo
impl Into<AudioNodeInfoInner> for AudioNodeInfo
Source§fn into(self) -> AudioNodeInfoInner
fn into(self) -> AudioNodeInfoInner
Auto Trait Implementations§
impl Freeze for AudioNodeInfo
impl !RefUnwindSafe for AudioNodeInfo
impl !Send for AudioNodeInfo
impl !Sync for AudioNodeInfo
impl Unpin for AudioNodeInfo
impl !UnwindSafe for AudioNodeInfo
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
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.