Table of Contents

Class WHEPSourceSettings

Namespace
VisioForge.Core.Types.X.Sources
Assembly
VisioForge.Core.dll

WHEP (WebRTC-HTTP Egress Protocol) source settings: the endpoint a WebRTC server such as MediaMTX, Janus or a CDN publishes a stream on for playback.

public class WHEPSourceSettings : IMediaBlockSettings

Inheritance

Implements

Inherited Members

Properties

AudioEnabled

Gets or sets a value indicating whether the block has an audio output. The audio stream is decoded; its format is the one the server sends. At least one of VisioForge.Core.Types.X.Sources.WHEPSourceSettings.VideoEnabled and VisioForge.Core.Types.X.Sources.WHEPSourceSettings.AudioEnabled must be on: the block's constructor rejects settings with neither. Both are read only when the block is constructed; changing them, or assigning new settings, later does not change its outputs.

public bool AudioEnabled { get; set; }

Property Value

bool

AuthToken

Gets or sets the authentication token sent as a Bearer token in the HTTP header.

public string AuthToken { get; set; }

Property Value

string

Location

Gets or sets the WHEP endpoint URL, for example http://server:8889/stream/whep on MediaMTX.

public string Location { get; set; }

Property Value

string

StunServer

Gets or sets the STUN server URL in format stun://hostname:port. When not set, no STUN server is used.

public string StunServer { get; set; }

Property Value

string

Timeout

Gets or sets the timeout for WHEP endpoint requests. The signaller counts in whole seconds, so the value is rounded up and capped at 1 hour. Zero, a negative value and InfiniteTimeSpan give that longest timeout: a request is never left unbounded, so stopping cannot hang on a server that stopped answering.

public TimeSpan Timeout { get; set; }

Property Value

TimeSpan

TurnServer

Gets or sets the TURN server URL in format turn(s)://username:password@host:port.

public string TurnServer { get; set; }

Property Value

string

UseLinkHeaders

Gets or sets a value indicating whether to use link headers from the WHEP server response to configure ICE servers.

public bool UseLinkHeaders { get; set; }

Property Value

bool

VideoEnabled

Gets or sets a value indicating whether the block has a video output. The video stream is decoded; its format is the one the server sends.

public bool VideoEnabled { get; set; }

Property Value

bool

Methods

CreateBlock()

Creates the media block instance for the WHEP source.

public MediaBlock CreateBlock()

Returns

MediaBlock

A new instance of VisioForge.Core.MediaBlocks.Sources.WHEPSourceBlock configured with these settings.