sACN  3.0.0
Implementation of ANSI E1.31 (Streaming ACN)
View other versions:
Loading...
Searching...
No Matches
Receiver::NotifyHandler Class Referenceabstract

A base class for a class that receives notification callbacks from a sACN receiver. More...

#include <receiver.h>

Public Member Functions

virtual void HandleUniverseData (Handle receiver_handle, const etcpal::SockAddr &source_addr, const SacnRemoteSource &source_info, const SacnRecvUniverseData &universe_data)=0
 Notify that new universe data within the configured footprint has been received.
 
virtual void HandleSourcesLost (Handle handle, uint16_t universe, const std::vector< SacnLostSource > &lost_sources)=0
 Notify that one or more sources have entered a source loss state.
 
virtual void HandleSamplingPeriodStarted (Handle handle, uint16_t universe)
 Notify that a receiver's sampling period has begun.
 
virtual void HandleSamplingPeriodEnded (Handle handle, uint16_t universe)
 Notify that a receiver's sampling period has ended.
 
virtual void HandleSourcePapLost (Handle handle, uint16_t universe, const SacnRemoteSource &source)
 Notify that a source has stopped transmission of per-address priority packets.
 
virtual void HandleSourceLimitExceeded (Handle handle, uint16_t universe)
 Notify that more than the configured maximum number of sources are currently sending on the universe being listened to.
 

Detailed Description

A base class for a class that receives notification callbacks from a sACN receiver.

Member Function Documentation

◆ HandleSamplingPeriodEnded()

virtual void HandleSamplingPeriodEnded ( Handle handle,
uint16_t universe )
inlinevirtual

Notify that a receiver's sampling period has ended.

All sources that were included in this sampling period can officially be used in the merge result for the universe. If there was a networking reset during this sampling period, another sampling period may have been scheduled, in which case this will be immediately followed by a sampling period started notification.

Parameters
handleThe receiver's handle.
universeThe universe the receiver is monitoring.

◆ HandleSamplingPeriodStarted()

virtual void HandleSamplingPeriodStarted ( Handle handle,
uint16_t universe )
inlinevirtual

Notify that a receiver's sampling period has begun.

If this sampling period was due to a networking reset, some sources may not be included in it. See the universe data callback to determine if a source is included or not.

Parameters
handleThe receiver's handle.
universeThe universe the receiver is monitoring.

◆ HandleSourceLimitExceeded()

virtual void HandleSourceLimitExceeded ( Handle handle,
uint16_t universe )
inlinevirtual

Notify that more than the configured maximum number of sources are currently sending on the universe being listened to.

Parameters
handleThe receiver's handle.
universeThe universe this receiver is monitoring.

◆ HandleSourcePapLost()

virtual void HandleSourcePapLost ( Handle handle,
uint16_t universe,
const SacnRemoteSource & source )
inlinevirtual

Notify that a source has stopped transmission of per-address priority packets.

Parameters
handleThe receiver's handle.
universeThe universe this receiver is monitoring.
sourceInformation about the source that has stopped transmission of per-address priority.

◆ HandleSourcesLost()

virtual void HandleSourcesLost ( Handle handle,
uint16_t universe,
const std::vector< SacnLostSource > & lost_sources )
pure virtual

Notify that one or more sources have entered a source loss state.

Parameters
handleThe receiver's handle.
universeThe universe this receiver is monitoring.
lost_sourcesVector of structs describing the source or sources that have been lost.

◆ HandleUniverseData()

virtual void HandleUniverseData ( Handle receiver_handle,
const etcpal::SockAddr & source_addr,
const SacnRemoteSource & source_info,
const SacnRecvUniverseData & universe_data )
pure virtual

Notify that new universe data within the configured footprint has been received.

This will not be called if the Stream_Terminated bit is set, or if the Preview_Data bit is set and preview packets are being filtered.

During the sampling period, any valid sACN data packet received will trigger this notification, no matter the start code.

After the sampling period, if SACN_ETC_PRIORITY_EXTENSION is set to 1, NULL start code packets will not trigger this notification until either the PAP timeout expires or a PAP (0xDD) packet is received. PAP packets received will always trigger this notification. This guarantees that if both start codes are active, PAP will always notify first. All other start codes will always trigger this notification once received. If SACN_ETC_PRIORITY_EXTENSION is set to 0, NULL start code packets received will always trigger this notification.

If the source is sending sACN Sync packets, this callback will only be called when the sync packet is received, if the source forces the packet, or if the source sends a data packet without a sync universe. TODO: this version of the sACN library does not support sACN Sync. This paragraph will be valid in the future.

Parameters
receiver_handleThe receiver's handle.
source_addrIP address & port of the packet source.
source_infoInformation about the source that sent this data.
universe_dataThe universe data (and relevant information about that data), starting from the first slot of the currently configured footprint.

The documentation for this class was generated from the following file: