Class VideoCodecCapability

VideoCodecCapability represents a higher level type to wrap RTCRtpCodec and the codec name used in the SDP, while also namespacing static create functions for codecs supported in the SDK.

Note that codecName is different then codecCapability.mimeType

Implements

Constructors

Properties

codecCapability: RTCRtpCodec
codecName: string

Methods

  • Return true if the other value is exactly equal to this value.

    Parameters

    • other: this

      the value against which to compare.

    Returns boolean

  • Returns whether the codec capability fmtp line matches. This will not attempt to match H.264 profile levels (e.g. 5.2, 3.1), see internal comments for more detailed information. This function takes care of checking for an expected payload type as well.

    This function is meant to only be used internally.

    Parameters

    • line: string
    • expectedPayloadType: number

    Returns boolean

  • Returns the configuration of H.264 High Profile supported by the SDK.

    Currently most browsers do not have software fallback for high profile which may impact stability. Its usage should be done with caution.

    On MacOS, until https://bugs.chromium.org/p/chromium/issues/detail?id=1520287 is resolved, receivers will fail to allocate the decoder for this profile if the sender switches away and back to this codec (e.g. fallback for a Firefox receiver, and then recovery when the Firefox receiver leaves).

    If you expect a decent amount of iOS safari traffic, you should include h264ConstrainedHighProfile in your preferences as well. It will be forwarded as High profile to receivers that negotiated High but not Constrained High

    Returns VideoCodecCapability

  • Returns the configuration of H.264 Main Profile supported by the SDK

    This profile is more likely to use hardware for encode on most browsers then constrained baseline profile. It may have modest quality/bitrate improvements over baseline/constrained baseline profile.

    Returns VideoCodecCapability