VisioForge

KLV / MISB Metadata SDK for .NET

Read KLV telemetry out of MPEG-TS, decode MISB ST 0601 elements, and record or restream live MISB feeds with the metadata kept — from C# and .NET.

What KLV and MISB are

KLV (Key-Length-Value, SMPTE ST 336) is the binary encoding that UAV, ISR and surveillance systems use to carry telemetry beside the video: time stamps, platform and sensor position, orientation, and the geolocation of the frame center. MISB ST 0601 (the UAS Datalink Local Set) defines those fields, and MISB / STANAG 4609 streams carry them as a separate metadata stream inside MPEG-TS.

What the SDK does with KLV

Two VisioForge SDKs handle KLV: Media Blocks SDK works with KLV in MPEG-TS files on Windows, Linux and macOS, and Video Capture SDK passes live KLV from an IP camera or UDP source into a recording or a restream on Windows.

  • Extract: MPEGTSDemuxBlock exposes the metadata stream of an MPEG-TS file on its MetadataOutput pad, and KLVFileSinkBlock writes the KLV packets to a .klv file
  • Decode: KLVParser reads MISB ST 0601 local-set elements — more than 90 of them, from precision time stamp to sensor and frame-center coordinates — and handles the BER-encoded lengths MISB uses
  • Embed (Media Blocks): MPEGTSSinkSettings.Metadata takes a KLVMetadata object built from a .klv file or a byte array; it is muxed as one static payload, not a per-frame timed track
  • Record and restream live KLV (Video Capture SDK, Windows): MPEGTSOutput.KLVEnabled muxes KLV from the source into the MPEG-TS file, and FFMPEGEXEOutput.KLVEnabled carries it in MPEG-TS, RTP MPEG-TS and HLS output (for file recording, also set UsePipe)
  • Read live packets: the OnDataFrameBuffer event delivers each KLV packet with its size and timestamp (DataFrameType.KLV)

Code Examples

Condensed from the KLV Demo and the ip-camera-klv-mpegts-recorder sample.

Extract KLV from an MPEG-TS file and decode MISB ST 0601

C#

Record a live MISB feed to MPEG-TS with KLV

C#

Pipeline

In Media Blocks SDK, KLV extraction is three blocks — file source, MPEG-TS demuxer and KLV file sink — and KLVParser then decodes the .klv file. The video and audio pads of the demuxer can feed a renderer or an encoder at the same time.

BasicFileSourceBlock
MPEGTSDemuxBlock
KLVFileSinkBlock
KLVParser