[][src]Struct sacn_unofficial::receive::DMXData

pub struct DMXData {
    pub universe: u16,
    pub values: Vec<u8>,
    pub sync_uni: u16,
    pub priority: u8,
    pub src_cid: Option<Uuid>,
    pub preview: bool,
    pub recv_timestamp: Instant,
}

Holds a universes worth of DMX data.

Fields

universe: u16

The universe that the data was sent to.

values: Vec<u8>

The actual universe data, if less than 512 values in length then implies trailing 0's to pad to a full-universe of data.

sync_uni: u16

The universe the data is (or was if now acted upon) waiting for a synchronisation packet from. 0 indicates it isn't waiting for a universe synchronisation packet.

priority: u8

The priority of the data, this may be useful for receivers which want to implement their own implementing merge algorithms. Must be less than packet::E131_MAX_PRIORITY.

src_cid: Option<Uuid>

The unique id of the source of the data, this may be useful for receivers which want to implement their own merge algorithms which use the identity of the source to decide behaviour. A value of None indicates that there is no clear source, for example if a merge algorithm has merged data from 2 or more sources together.

preview: bool

Indicates if the data is marked as 'preview' data indicating it is for use by visualisers etc. as per ANSI E1.31-2018 Section 6.2.6.

recv_timestamp: Instant

The timestamp that the data was received.

Trait Implementations

impl Clone for DMXData[src]

impl Debug for DMXData[src]

impl Eq for DMXData[src]

See PartialEq trait implementation for DMXData.

impl Ord for DMXData[src]

DMXData has a total ordering based on the universe, then sync-universe and finally values.

impl PartialEq<DMXData> for DMXData[src]

DMXData is taken to be equivalent iff: - The universes are the same - The synchronisation universes are the same - The values are all the same

impl PartialOrd<DMXData> for DMXData[src]

See Ord trait implementation for DMXData.

Auto Trait Implementations

impl RefUnwindSafe for DMXData

impl Send for DMXData

impl Sync for DMXData

impl Unpin for DMXData

impl UnwindSafe for DMXData

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.