SrtPcapCaptureInputNode class

Experimental: passive SRT probe from a live packet capture. see: NorskInput.srtPcapCapture()

Signature:

export declare class SrtPcapCaptureInputNode extends SourceMediaNode

Extends: SourceMediaNode

Methods

Method Modifiers Description

closeStream(streamIndex)

Closes a connection (one session of the capture) as specified by 'streamIndex'

nudge(sourceName, programNumber, nudge)

Nudges the timestamps of one source’s program on this input.

nudge is an ABSOLUTE target offset, in milliseconds, from the source’s own timestamps — not an increment: nudging 500 then 200 leaves the program 200ms ahead of the source, and nudging 0 removes the offset. The engine moves the output timestamps to the target gradually rather than jumping.

The nudge addresses that program’s timestamp corrector, which exists only once the source’s media has started arriving. Before then the returned Promise rejects with a TimestampNudgeError whose reason is "not_ready" ("nudge not ready: no timestamp corrector for …​ yet"); the node is not affected, so retry shortly. The corrector is created on the same context change that reports the source to you, so a nudge sent from that callback can still be "not_ready".

With no answer from the engine within 10 seconds (an engine older than this SDK never answers) it rejects with reason "timeout"; the nudge may still have been applied.