pub struct CachedBusConfig {
pub input_bus_count: usize,
pub output_bus_count: usize,
pub input_buses: Vec<CachedBusInfo>,
pub output_buses: Vec<CachedBusInfo>,
}Expand description
Cached bus configuration from plugin or host.
Stores bus and channel information for fast access during audio processing. This provides a common representation used by both VST3 and AU wrappers.
Fields§
§input_bus_count: usizeNumber of input buses.
output_bus_count: usizeNumber of output buses.
input_buses: Vec<CachedBusInfo>Input bus information.
output_buses: Vec<CachedBusInfo>Output bus information.
Implementations§
Source§impl CachedBusConfig
impl CachedBusConfig
Sourcepub fn new(
input_buses: Vec<CachedBusInfo>,
output_buses: Vec<CachedBusInfo>,
) -> Self
pub fn new( input_buses: Vec<CachedBusInfo>, output_buses: Vec<CachedBusInfo>, ) -> Self
Sourcepub fn from_plugin<P: Descriptor>(plugin: &P) -> Self
pub fn from_plugin<P: Descriptor>(plugin: &P) -> Self
Create from a plugin’s bus configuration.
Sourcepub fn input_bus_info(&self, bus: usize) -> Option<&CachedBusInfo>
pub fn input_bus_info(&self, bus: usize) -> Option<&CachedBusInfo>
Get information about an input bus.
Returns None if the bus index is out of bounds.
Sourcepub fn output_bus_info(&self, bus: usize) -> Option<&CachedBusInfo>
pub fn output_bus_info(&self, bus: usize) -> Option<&CachedBusInfo>
Get information about an output bus.
Returns None if the bus index is out of bounds.
Sourcepub fn total_input_channels(&self) -> usize
pub fn total_input_channels(&self) -> usize
Get the total number of input channels across all buses.
Sourcepub fn total_output_channels(&self) -> usize
pub fn total_output_channels(&self) -> usize
Get the total number of output channels across all buses.
Sourcepub fn to_bus_layout(&self) -> BusLayout
pub fn to_bus_layout(&self) -> BusLayout
Convert to a BusLayout for plugin preparation.
This enables passing the cached bus configuration to the plugin’s
prepare() method via FullAudioSetup.
Trait Implementations§
Source§impl Clone for CachedBusConfig
impl Clone for CachedBusConfig
Source§fn clone(&self) -> CachedBusConfig
fn clone(&self) -> CachedBusConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more