optris::sdk::rec::SessionSourceStats
What one source of a running -- or just-finished -- session did.
Public attributes
frames_written
uint64_t frames_written = 0
Frames the session has taken into the file for this source.
As for RecordingStats::frames_written: a frame counts here once the container has accepted it, which is a moment before its bytes are necessarily on the disk. Stopping the session is what makes the file complete.
frames_dimension_mismatch
uint64_t frames_dimension_mismatch = 0
Frames refused because they were not the size the source was declared with. A mid-session mode switch produces these, and every one is a frame missing from the file.
frames_write_error
uint64_t frames_write_error = 0
Frames lost to a write or encode failure.
frames_dropped_backlog
uint64_t frames_dropped_backlog = 0
Frames refused because the hand-over queue was full under SessionBacklogPolicy::kDropNewest. Always zero under SessionBacklogPolicy::kBlock.
frames_pts_repaired
uint64_t frames_pts_repaired = 0
Frames whose session stamp did not advance past the previous one's.
Each is written at the millisecond after the previous frame's, because a recording keeps whole milliseconds. A frame whose stamp did advance, but by less than that, is moved the same way and is not counted here: this counts a clock that stood still, not every frame the file had to move. See Recorder::WriteFrameAt().
Counted rather than hidden. Two frames of one source landing in the same microsecond is ordinary on a fast source and harmless; a large count means the supplied SessionConfig::clock has resolution the session cannot use, which is not harmless and is otherwise invisible.
first_frame_us
uint64_t first_frame_us = 0
Session time of this source's first frame, in microseconds from the start of the session. Zero before its first frame.
last_frame_us
uint64_t last_frame_us = 0
Session time of its most recent frame, on the same clock. Zero before its first frame.
max_gap_us
uint64_t max_gap_us = 0
The longest run of session time this source went without delivering a frame, after its first. A stall shows up here even if the camera recovered and nobody was watching when it happened.
outages
uint64_t outages = 0
How many times this source was reported lost. Counts the outages, whether or not the camera came back from them.
outage_total_us
uint64_t outage_total_us = 0
Total session time, in microseconds, that this source spent disconnected. An outage still open when the session stopped counts up to the moment it stopped.
Worth reading beside max_gap_us, which they are not the same as. max_gap_us is the largest hole, whatever caused it -- a disconnection, a busy disk, a camera that was idle. This is only the time somebody said the camera was gone.
frames_from_own_stamp
uint64_t frames_from_own_stamp = 0
Frames whose session time came from the frame's own arrival stamp rather than from the moment of hand-over. Always zero under SessionTimestampSource::kHandover.
Not decoration: under SessionTimestampSource::kFrameStamp a source whose frames carry no stamp silently falls back to hand-over for every one of them, which is correct and is also indistinguishable from the feature working. This is how a caller tells those two apart.
last_error
std::string last_error
The most recent write failure for this source, or empty.