Struct smpte2022_1_fec::Decoder [−][src]
Decoder state-machine for SMPTE 2022-1 FEC.
The decoder instance owns the storage for all RTP packets being processed. An application receiving data from the network will borrow buffers from the decoder and arrange for UDP packet payloads to be written into these.
Note that this does not try to solve the following problems,
- Reordering
- Out-of-order packets on the main stream are passed on to the application still out-of-order
- Recovery of lost packets may occur after packets with later sequence numbers have already been passed to the application
- Pacing
- Packets are passed to the application as soon as possible, without regard for the timestamps on the packets
Planned changes
This design will change in future as required to
support things like AF_XDP
, and the caller will be able to plug in their own allocation
strategy. In this future design, the decoder will just hold on to references to packets
Implementations
impl<BP: BufferPool, Recv: Receiver<BP::P>> Decoder<BP, Recv>
[src]
pub fn new(buffer_pool: BP, receiver: Recv) -> Decoder<BP, Recv>
[src]
pub fn add_main_packets<T: Iterator<Item = BP::P>>(
&mut self,
pk: T
) -> Result<(), FecDecodeError>
[src]
&mut self,
pk: T
) -> Result<(), FecDecodeError>
pub fn add_row_packets<T: Iterator<Item = BP::P>>(
&mut self,
packets: T
) -> Result<(), FecDecodeError>
[src]
&mut self,
packets: T
) -> Result<(), FecDecodeError>
pub fn add_column_packets<T: Iterator<Item = BP::P>>(
&mut self,
pk: T
) -> Result<(), FecDecodeError>
[src]
&mut self,
pk: T
) -> Result<(), FecDecodeError>
Auto Trait Implementations
impl<BP, Recv> RefUnwindSafe for Decoder<BP, Recv> where
BP: RefUnwindSafe,
Recv: RefUnwindSafe,
<BP as BufferPool>::P: RefUnwindSafe,
BP: RefUnwindSafe,
Recv: RefUnwindSafe,
<BP as BufferPool>::P: RefUnwindSafe,
impl<BP, Recv> Send for Decoder<BP, Recv> where
BP: Send,
Recv: Send,
<BP as BufferPool>::P: Send,
BP: Send,
Recv: Send,
<BP as BufferPool>::P: Send,
impl<BP, Recv> Sync for Decoder<BP, Recv> where
BP: Sync,
Recv: Sync,
<BP as BufferPool>::P: Sync,
BP: Sync,
Recv: Sync,
<BP as BufferPool>::P: Sync,
impl<BP, Recv> Unpin for Decoder<BP, Recv> where
BP: Unpin,
Recv: Unpin,
<BP as BufferPool>::P: Unpin,
BP: Unpin,
Recv: Unpin,
<BP as BufferPool>::P: Unpin,
impl<BP, Recv> UnwindSafe for Decoder<BP, Recv> where
BP: UnwindSafe,
Recv: UnwindSafe,
<BP as BufferPool>::P: UnwindSafe,
BP: UnwindSafe,
Recv: UnwindSafe,
<BP as BufferPool>::P: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,