OptrisOptrisDocumentation

Documentation/OTC SDK/Optris.Sdk — C# API referencev12.0

SessionSourceInfo

public sealed record SessionSourceInfo : IEquatable<SessionSourceInfo>

What a session file says about one of its sources, plus what a scan of the file found out about it.

SessionSourceInfo: constructors

public SessionSourceInfo(int Index, int VideoStreamIndex, SessionSourceKind Kind, uint Width, uint Height, float FrameRate, string Name, string Model, string Serial, ulong FrameCount, TimeSpan FirstFrame, TimeSpan LastFrame, TimeSpan MaxGap)

What a session file says about one of its sources, plus what a scan of the file found out about it.

  • Index: Source index, matching the recording side.
  • VideoStreamIndex: The container's stream index for this source's video track, for anyone correlating with ffprobe output, or −1.
  • Kind: Thermal or visual. Check this before reading a temperature: a visual source has none. Read from the track's own tag rather than from the session document, so it is right even for a file whose document is missing.
  • Width: Frame width in pixels.
  • Height: Frame height in pixels.
  • FrameRate: Nominal frame rate as the container declares it. What the source actually delivered is FrameCount over the span between FirstFrame and LastFrame, and on a camera that drifts the two differ, which is what sessions exist for.
  • Name: What the operator called this camera, or an empty string.
  • Model: Camera model, or an empty string.
  • Serial: Camera serial, or an empty string.
  • FrameCount: Frames this source has in the file, counted when it was opened.
  • FirstFrame: Session time of its first frame. A source that joined late has one well past zero, and that is real rather than an artefact; it is when the camera actually started.
  • LastFrame: Session time of its last frame. A source that ended early has one well short of the session duration, for the same reason.
  • MaxGap: The longest hole in this track. Worth reading before playing anything, but a hole does not say why. Use SessionPlayer.GetOutages(…) for the spans somebody recorded a reason for.

SessionSourceInfo: properties

public TimeSpan FirstFrame { get; init; }

Session time of its first frame. A source that joined late has one well past zero, and that is real rather than an artefact; it is when the camera actually started.

public ulong FrameCount { get; init; }

Frames this source has in the file, counted when it was opened.

public float FrameRate { get; init; }

Nominal frame rate as the container declares it. What the source actually delivered is FrameCount over the span between FirstFrame and LastFrame, and on a camera that drifts the two differ, which is what sessions exist for.

public uint Height { get; init; }

Frame height in pixels.

public int Index { get; init; }

Source index, matching the recording side.

public SessionSourceKind Kind { get; init; }

Thermal or visual. Check this before reading a temperature: a visual source has none. Read from the track's own tag rather than from the session document, so it is right even for a file whose document is missing.

public TimeSpan LastFrame { get; init; }

Session time of its last frame. A source that ended early has one well short of the session duration, for the same reason.

public TimeSpan MaxGap { get; init; }

The longest hole in this track.

Worth reading before playing anything, but a hole does not say why. Use SessionPlayer.GetOutages(…) for the spans somebody recorded a reason for.

public string Model { get; init; }

Camera model, or an empty string.

public string Name { get; init; }

What the operator called this camera, or an empty string.

public string Serial { get; init; }

Camera serial, or an empty string.

public int VideoStreamIndex { get; init; }

The container's stream index for this source's video track, for anyone correlating with ffprobe output, or −1.

public uint Width { get; init; }

Frame width in pixels.