UdpTsInputNode class

Signature:

export declare class UdpTsInputNode extends TsCommonInputNode<UdpTsInputMessage, UdpTsInputNode>

Extends: TsCommonInputNode<UdpTsInputMessage, UdpTsInputNode>

Methods

Method Modifiers Description

closeSource(options)

Kick whoever is sending to this input (on both paths, with UdpTsInputSettings.seamlessProtection). UDP has no connection to close, so the sender is refused for blockMs (default 5000): the input goes offline at once, and the sender is back only when the block runs out. blockMs: 0 drops it for a moment only — it is back with its next datagram.

The block is on the sender’s address AND port, and the kick releases the sender lock (UdpTsInputSettings.senderPolicy): the next sender to arrive takes the input, so a second encoder, even on the same host, can replace one that cannot be stopped. wholeHost: true blocks every port of the sender’s address instead.

startRecording(recording, sourceName)

Starts recording the source’s bytes as they arrive, before any demux, while the input runs: the contributor stays connected throughout. Starting again stops the current recording first. Events arrive on onRecording; a source that is not there yet fails the recording, not the input.

stopRecording(sourceName)

Stops a recording started with startRecording.