21 #ifndef PLUGINS_E131_E131_E131HEADER_H_
22 #define PLUGINS_E131_E131_E131HEADER_H_
43 bool is_preview =
false,
44 bool has_terminated =
false,
50 m_is_preview(is_preview),
51 m_has_terminated(has_terminated),
56 const string Source()
const {
return m_source; }
57 uint8_t Priority()
const {
return m_priority; }
58 uint8_t Sequence()
const {
return m_sequence; }
59 uint16_t
Universe()
const {
return m_universe; }
60 bool PreviewData()
const {
return m_is_preview; }
61 bool StreamTerminated()
const {
return m_has_terminated; }
63 bool UsingRev2()
const {
return m_is_rev2; }
65 bool operator==(
const E131Header &other)
const {
66 return m_source == other.m_source &&
67 m_priority == other.m_priority &&
68 m_sequence == other.m_sequence &&
69 m_universe == other.m_universe &&
70 m_is_preview == other.m_is_preview &&
71 m_has_terminated == other.m_has_terminated &&
72 m_is_rev2 == other.m_is_rev2;
75 enum { SOURCE_NAME_LEN = 64 };
78 char source[SOURCE_NAME_LEN];
84 } __attribute__((packed));
87 static const uint8_t PREVIEW_DATA_MASK = 0x80;
88 static const uint8_t STREAM_TERMINATED_MASK = 0x40;
96 bool m_has_terminated;
107 bool is_preview =
false,
108 bool has_terminated =
false)
109 :
E131Header(source, priority, sequence, universe, is_preview,
110 has_terminated,
true) {
113 enum { REV2_SOURCE_NAME_LEN = 32 };
116 char source[REV2_SOURCE_NAME_LEN];
125 #endif // PLUGINS_E131_E131_E131HEADER_H_