31 : m_identifier(identifier) {
38 m_latestMeasurement = meas;
39 m_brightnessHistory.push_back(meas.
brightness);
46 auto const oldId = m_id;
47 m_id = m_identifier->
getId(m_id, m_brightnessHistory, m_lastBright,
50 if (Id(SENTINEL_MARKED_MISIDENTIFIED) == oldId &&
51 (Id(SENTINEL_NO_IDENTIFIER_OBJECT_OR_INSUFFICIENT_DATA) ==
53 Id(SENTINEL_NO_PATTERN_RECOGNIZED_DESPITE_SUFFICIENT_DATA) ==
58 m_id = Id(SENTINEL_MARKED_MISIDENTIFIED);
68 m_novelty = MAX_NOVELTY;
69 }
else if (m_novelty != 0) {
78 if (!m_brightnessHistory.empty()) {
79 m_brightnessHistory.clear();
80 m_brightnessHistory.push_back(getMeasurement().brightness);
Led(LedIdentifier *identifier, LedMeasurement const &meas)
void addMeasurement(LedMeasurement const &meas, bool blobsKeepId)
Add a new measurement for this LED, which must be for a frame that is just following the previous mea...
Header file for class that tracks and identifies LEDs.
Brightness brightness
"Brightness" - currently actually diameter.
Helper class to identify an LED based on its pattern of brightness over time. The base class defines ...
virtual ZeroBasedBeaconId getId(ZeroBasedBeaconId currentId, BrightnessList &brightnesses, bool &lastBright, bool blobsKeepId) const =0
Determine the identity of the LED whose brightness pattern is passed in. Truncates the passed-in list...