Struct voicemeeter::interface::callback::data::output::WriteDevices
source · pub struct WriteDevices<'a, 'b> {
pub output_a1: DeviceBuffer<[&'b mut [f32]; 8]>,
pub output_a2: DeviceBuffer<[&'b mut [f32]; 8]>,
pub output_a3: DeviceBuffer<[&'b mut [f32]; 8]>,
pub output_a4: DeviceBuffer<[&'b mut [f32]; 8]>,
pub output_a5: DeviceBuffer<[&'b mut [f32]; 8]>,
pub virtual_output_b1: DeviceBuffer<[&'b mut [f32]; 8]>,
pub virtual_output_b2: DeviceBuffer<[&'b mut [f32]; 8]>,
pub virtual_output_b3: DeviceBuffer<[&'b mut [f32]; 8]>,
/* private fields */
}
Available on crate feature
interface
only.Expand description
Write interface for output mode
Fields§
§output_a1: DeviceBuffer<[&'b mut [f32]; 8]>
§output_a2: DeviceBuffer<[&'b mut [f32]; 8]>
§output_a3: DeviceBuffer<[&'b mut [f32]; 8]>
§output_a4: DeviceBuffer<[&'b mut [f32]; 8]>
§output_a5: DeviceBuffer<[&'b mut [f32]; 8]>
§virtual_output_b1: DeviceBuffer<[&'b mut [f32]; 8]>
Channel write buffer for VirtualOutputB1
.
Is None
if the device is not available.
virtual_output_b2: DeviceBuffer<[&'b mut [f32]; 8]>
Channel write buffer for VirtualOutputB2
.
Is None
if the device is not available.
virtual_output_b3: DeviceBuffer<[&'b mut [f32]; 8]>
Channel write buffer for VirtualOutputB3
.
Is None
if the device is not available.
Implementations§
source§impl<'a, 'b> WriteDevices<'a, 'b>
impl<'a, 'b> WriteDevices<'a, 'b>
sourcepub fn copy_device_from<'i>(
&mut self,
read: &ReadDevices<'_, '_>,
devices: impl IntoIterator<Item = &'i Device>
)
pub fn copy_device_from<'i>( &mut self, read: &ReadDevices<'_, '_>, devices: impl IntoIterator<Item = &'i Device> )
Copies data from a output read buffer into the output write buffer for specified devices
§Examples
use voicemeeter::{interface::callback::BufferInData, types::Device};
buffer
.write
.copy_device_from(&buffer.read, &[Device::Strip1, Device::Strip2]);
assert!(
buffer.read.strip1.to_slice() == buffer.write.strip1.to_mut_slice(),
"strip1 was copied"
);
assert!(
buffer.read.strip2.to_slice() == buffer.write.strip2.to_mut_slice(),
"strip2 was copied"
);
sourcepub fn device_mut(
&mut self,
device: &Device
) -> DeviceBuffer<&mut [&'b mut [f32]]>
pub fn device_mut( &mut self, device: &Device ) -> DeviceBuffer<&mut [&'b mut [f32]]>
Grab the device buffer for a specific device
Trait Implementations§
source§impl<'a, 'b> Default for WriteDevices<'a, 'b>
impl<'a, 'b> Default for WriteDevices<'a, 'b>
source§fn default() -> WriteDevices<'a, 'b>
fn default() -> WriteDevices<'a, 'b>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<'a, 'b> RefUnwindSafe for WriteDevices<'a, 'b>
impl<'a, 'b> Send for WriteDevices<'a, 'b>
impl<'a, 'b> Sync for WriteDevices<'a, 'b>
impl<'a, 'b> Unpin for WriteDevices<'a, 'b>
impl<'a, 'b> !UnwindSafe for WriteDevices<'a, 'b>
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