pub struct ComplexToFloat { /* private fields */ }Expand description
Convert a complex stream to two float streams.
If only one of the two streams are needed, then it’s better to use a Map
block.
use rustradio::Complex;
use rustradio::blocks::ConstantSource;
use rustradio::blocks::ComplexToFloat;
let (src_block, src) = ConstantSource::new(Complex::new(1.0, 2.0));
let (b, out_re, out_im) = ComplexToFloat::new(src);Implementations§
Source§impl ComplexToFloat
impl ComplexToFloat
pub fn new( src: ReadStream<Complex>, ) -> (Self, <WriteStream<Float> as StreamReadSide>::ReadSide, <WriteStream<Float> as StreamReadSide>::ReadSide)
Trait Implementations§
Source§impl Block for ComplexToFloat
impl Block for ComplexToFloat
Source§impl BlockName for ComplexToFloat
impl BlockName for ComplexToFloat
Source§fn block_name(&self) -> &str
fn block_name(&self) -> &str
Name of block Read more
Auto Trait Implementations§
impl Freeze for ComplexToFloat
impl RefUnwindSafe for ComplexToFloat
impl Send for ComplexToFloat
impl Sync for ComplexToFloat
impl Unpin for ComplexToFloat
impl UnwindSafe for ComplexToFloat
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more