Options
All
  • Public
  • Public/Protected
  • All
Menu

Class AudioFormat

An audio format.

Hierarchy

  • MediaFormat<AudioFormat>
    • AudioFormat

Index

Constructors

constructor

  • new AudioFormat(name: string, clockRate: number, channelCount: number): AudioFormat
  • new AudioFormat(name: string, config: AudioConfig): AudioFormat
  • new AudioFormat(): AudioFormat
  • Initializes a new instance of the fm.icelink.audioFormat class.

    Parameters

    • name: string

      The name.

    • clockRate: number

      The clock rate.

    • channelCount: number

      The channel count.

    Returns AudioFormat

  • Initializes a new instance of the fm.icelink.audioFormat class.

    Parameters

    • name: string

      The name.

    • config: AudioConfig

      The configuration.

    Returns AudioFormat

  • Initializes a new instance of the fm.icelink.audioFormat class.

    Returns AudioFormat

Properties

Private _channelCount

_channelCount: number
internal

Private _littleEndian

_littleEndian: boolean
internal

Methods

clone

  • clone(): AudioFormat
  • Clones this instance.

    Returns AudioFormat

Protected createInstance

  • createInstance(): AudioFormat

getChannelCount

  • getChannelCount(): number
  • Gets the channel count.

    Returns number

getClockRate

  • getClockRate(): number
  • Gets the clock rate.

    Returns number

getConfig

  • getConfig(): AudioConfig
  • Gets the clock rate and channel count as a configuration.

    Returns AudioConfig

getFullName

  • getFullName(): string
  • Gets the full name, including clock rate and encoding parameters.

    Returns string

getIsDtmf

  • getIsDtmf(): boolean
  • Gets a value indicating whether this format is DTMF.

    Returns boolean

getIsEncrypted

  • getIsEncrypted(): boolean
  • Gets a value indicating that the data is encrypted.

    Returns boolean

getIsInjected

  • getIsInjected(): boolean
  • Gets a value indicating that the data is injected into the primary media stream (e.g. DTMF).

    Returns boolean

getIsOpus

  • getIsOpus(): boolean
  • Gets a value indicating whether this format is Opus.

    Returns boolean

getIsPacketized

  • getIsPacketized(): boolean
  • Gets a value indicating that the data is packetized for network transmission.

    Returns boolean

getIsPcm

  • getIsPcm(): boolean
  • Gets a value indicating whether this format is PCM.

    Returns boolean

getIsPcma

  • getIsPcma(): boolean
  • Gets a value indicating whether this format is PCMA.

    Returns boolean

getIsPcmu

  • getIsPcmu(): boolean
  • Gets a value indicating whether this format is PCMU.

    Returns boolean

getLittleEndian

  • getLittleEndian(): boolean
  • Gets whether the format uses little endian byte order.

    Returns boolean

getName

  • getName(): string
  • Gets the name.

    Returns string

getParameters

  • getParameters(): string

getRegisteredPayloadType

  • getRegisteredPayloadType(): number

getStaticPayloadType

  • getStaticPayloadType(): number
  • Gets the static payload type, if this format has a static payload type registered with IANA.

    Returns number

getTypeString

  • getTypeString(): string

isEquivalent

  • isEquivalent(format: AudioFormat, ignoreIsPacketized: boolean): boolean
  • Determines whether the specified format is equivalent.

    Parameters

    • format: AudioFormat

      The format.

    • ignoreIsPacketized: boolean

      Whether to ignore if the two formats differ in whether they are packetized.

    Returns boolean

setChannelCount

  • setChannelCount(value: number): void
  • Sets the channel count.

    Parameters

    • value: number

    Returns void

setClockRate

  • setClockRate(value: number): void
  • Sets the clock rate.

    Parameters

    • value: number

    Returns void

setIsEncrypted

  • setIsEncrypted(value: boolean): void
  • Sets a value indicating that the data is encrypted.

    Parameters

    • value: boolean

    Returns void

setIsInjected

  • setIsInjected(value: boolean): void
  • Sets a value indicating that the data is injected into the primary media stream (e.g. DTMF).

    Parameters

    • value: boolean

    Returns void

setIsPacketized

  • setIsPacketized(value: boolean): void
  • Sets a value indicating that the data is packetized for network transmission.

    Parameters

    • value: boolean

    Returns void

setLittleEndian

  • setLittleEndian(value: boolean): void
  • Sets whether the format uses little endian byte order.

    Parameters

    • value: boolean

    Returns void

setName

  • setName(value: string): void
  • Sets the name.

    Parameters

    • value: string

    Returns void

setRegisteredPayloadType

  • setRegisteredPayloadType(value: number): void

Protected setStaticPayloadType

  • setStaticPayloadType(value: number): void
  • Sets the static payload type, if this format has a static payload type registered with IANA.

    Parameters

    • value: number

    Returns void

toString

  • toString(): string
  • Returns a string that represents this instance.

    Returns string

Static getDtmfName

  • getDtmfName(): string
  • Gets the name of the DTMF audio format ("telephone-event").

    Returns string

Static getOpusName

  • getOpusName(): string
  • Gets the name of the Opus audio format ("opus").

    Returns string

Static getPcmName

  • getPcmName(): string
  • Gets the name of the PCM audio format ("PCM").

    Returns string

Static getPcmaName

  • getPcmaName(): string
  • Gets the name of the PCMA audio format ("PCMA").

    Returns string

Static getPcmuName

  • getPcmuName(): string
  • Gets the name of the PCMU audio format ("PCMU").

    Returns string

Static getRedName

  • getRedName(): string
  • Gets the name of the RED media format.

    Returns string

Static getUlpFecName

  • getUlpFecName(): string
  • Gets the name of the ULPFEC media format.

    Returns string