Skip to content

Commit

Permalink
Remove RTCRtpContributingSource dictionary (mdn#30079)
Browse files Browse the repository at this point in the history
* Move RTCRtpContributingSource info into RTCRtpReceiver.getContributingSources()

* Delete RTCRtpContributingSource, redirecting to RTCRtpReceiver.getContributingSources

* Remove RTCRtpContributingSource from API top level dictionary list

* Minor typo

* RTCRtpReceiver.getSynchronizationSources() - add info about returned object
  • Loading branch information
hamishwillee authored Nov 9, 2023
1 parent a3385f7 commit 9716100
Show file tree
Hide file tree
Showing 12 changed files with 61 additions and 216 deletions.
5 changes: 5 additions & 0 deletions files/en-us/_redirects.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9525,6 +9525,11 @@
/en-US/docs/Web/API/RTCPeerConnectionIceEvent.candidate /en-US/docs/Web/API/RTCPeerConnectionIceEvent/candidate
/en-US/docs/Web/API/RTCRtpCapabilities /en-US/docs/Web/API/RTCRtpSender/getCapabilities_static
/en-US/docs/Web/API/RTCRtpCodecCapability /en-US/docs/Web/API/RTCRtpSender/getCapabilities_static
/en-US/docs/Web/API/RTCRtpContributingSource /en-US/docs/Web/API/RTCRtpReceiver/getContributingSources
/en-US/docs/Web/API/RTCRtpContributingSource/audioLevel /en-US/docs/Web/API/RTCRtpReceiver/getContributingSources
/en-US/docs/Web/API/RTCRtpContributingSource/rtpTimestamp /en-US/docs/Web/API/RTCRtpReceiver/getContributingSources
/en-US/docs/Web/API/RTCRtpContributingSource/source /en-US/docs/Web/API/RTCRtpReceiver/getContributingSources
/en-US/docs/Web/API/RTCRtpContributingSource/timestamp /en-US/docs/Web/API/RTCRtpReceiver/getContributingSources
/en-US/docs/Web/API/RTCRtpParameters /en-US/docs/Web/API/RTCRtpSender/setParameters
/en-US/docs/Web/API/RTCRtpReceiveParameters /en-US/docs/Web/API/RTCRtpReceiver/getParameters
/en-US/docs/Web/API/RTCRtpReceiver/getCapabilities /en-US/docs/Web/API/RTCRtpReceiver/getCapabilities_static
Expand Down
20 changes: 0 additions & 20 deletions files/en-us/_wikihistory.json
Original file line number Diff line number Diff line change
Expand Up @@ -55024,26 +55024,6 @@
"modified": "2019-05-20T18:28:16.993Z",
"contributors": ["Sheppy"]
},
"Web/API/RTCRtpContributingSource": {
"modified": "2020-10-15T21:55:35.352Z",
"contributors": ["Sheppy", "fscholz", "Onkar316", "jpmedley"]
},
"Web/API/RTCRtpContributingSource/audioLevel": {
"modified": "2020-10-15T21:55:34.869Z",
"contributors": ["fscholz", "Sheppy", "jpmedley"]
},
"Web/API/RTCRtpContributingSource/rtpTimestamp": {
"modified": "2020-10-15T22:25:34.965Z",
"contributors": ["Sheppy"]
},
"Web/API/RTCRtpContributingSource/source": {
"modified": "2020-10-15T21:55:40.516Z",
"contributors": ["fscholz", "Sheppy", "jpmedley"]
},
"Web/API/RTCRtpContributingSource/timestamp": {
"modified": "2020-10-15T21:55:38.833Z",
"contributors": ["sideshowbarker", "fscholz", "Sheppy", "jpmedley"]
},
"Web/API/RTCRtpEncodingParameters": {
"modified": "2020-10-15T22:01:53.269Z",
"contributors": ["Sheppy"]
Expand Down
2 changes: 1 addition & 1 deletion files/en-us/mozilla/firefox/releases/72/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ _No changes._
#### Media, Web Audio, and WebRTC

- The {{domxref("MediaDevices.getDisplayMedia()")}} method can now only be called in response to a user gesture such as a [`click`](/en-US/docs/Web/API/Element/click_event) event ([Firefox bug 1580944](https://bugzil.la/1580944)).
- The {{domxref("RTCRtpContributingSource")}} dictionary can now include the {{domxref("RTCRtpContributingSource.rtpTimestamp", "rtpTimestamp")}} property, which is a source-generated time at which the packet's media was generated or sampled ([Firefox bug 1583867](https://bugzil.la/1583867)).
- The `RTCRtpContributingSource` dictionary can now include the `rtpTimestamp` property, which is a source-generated time at which the packet's media was generated or sampled ([Firefox bug 1583867](https://bugzil.la/1583867)).

#### Removals

Expand Down
46 changes: 0 additions & 46 deletions files/en-us/web/api/rtcrtpcontributingsource/audiolevel/index.md

This file was deleted.

31 changes: 0 additions & 31 deletions files/en-us/web/api/rtcrtpcontributingsource/index.md

This file was deleted.

29 changes: 0 additions & 29 deletions files/en-us/web/api/rtcrtpcontributingsource/rtptimestamp/index.md

This file was deleted.

33 changes: 0 additions & 33 deletions files/en-us/web/api/rtcrtpcontributingsource/source/index.md

This file was deleted.

27 changes: 0 additions & 27 deletions files/en-us/web/api/rtcrtpcontributingsource/timestamp/index.md

This file was deleted.

35 changes: 27 additions & 8 deletions files/en-us/web/api/rtcrtpreceiver/getcontributingsources/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,7 @@ browser-compat: api.RTCRtpReceiver.getContributingSources

{{APIRef("WebRTC API")}}

The **`getContributingSources()`**
method of the {{domxref("RTCRtpReceiver")}} interface returns an array of
{{domxref("RTCRtpContributingSource")}} instances, each corresponding to one CSRC
(contributing source) identifier received by the current `RTCRtpReceiver`
in the last ten seconds.
The **`getContributingSources()`** method of the {{domxref("RTCRtpReceiver")}} interface returns an array of objects, each corresponding to one CSRC (contributing source) identifier received by the current `RTCRtpReceiver` in the last ten seconds.

## Syntax

Expand All @@ -26,9 +22,32 @@ None.

### Return value

An array of {{domxref("RTCRtpContributingSource")}} instances. Each instance describes
one of the contributing sources that provided data to the incoming stream in the past
ten seconds.
An array of objects, each describing one of the contributing sources that provided data to the incoming stream in the past ten seconds.
These objects contain the following properties:

- `audioLevel` {{optional_inline}}

- : A floating-point value between 0.0 and 1.0 specifying the audio level contained in the last RTP packet played from the contributing source.

The value is on a linear scale and is defined in units of dBov, or decibels (overload).
This is the amplitude relative to the point at which clipping of the audio begins to occur.
A value of 1.0 represents 0 dBov (maximum volume), a value of 0.0 represents silence, and a value of 0.5 represents approximately 6 dB SPL (decibels of sound pressure level) change in the sound pressure level from 0 dBov.

If this property is not present then no volume level was provided by the source.

- `rtpTimestamp` {{optional_inline}}

- : The RTP timestamp (an integer {{domxref("DOMHighResTimeStamp")}}) of the media.
This source-generated timestamp indicates the time at which the media in this packet, scheduled for play out at the time indicated by `timestamp`, was initially sampled or generated.
It may be useful for sequencing and synchronization purposes.

- `source` {{optional_inline}}

- : A positive integer value specifying the CSRC identifier of the contributing source.
This uniquely identifies the source of the particular stream RTP packets.

- `timestamp` {{optional_inline}}
- : A {{domxref("DOMHighResTimeStamp")}} indicating the most recent time at which a frame originating from this source was delivered to the receiver's {{domxref("MediaStreamTrack")}}

## Specifications

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,7 @@ browser-compat: api.RTCRtpReceiver.getSynchronizationSources

{{APIRef("WebRTC API")}}

The **`getSynchronizationSources()`**
method of the {{domxref("RTCRtpReceiver")}} interface returns an array of
{{domxref("RTCRtpContributingSource")}} instances, each corresponding to one SSRC
(synchronization source) identifier received by the current
`RTCRtpReceiver` in the last ten seconds.
The **`getSynchronizationSources()`** method of the {{domxref("RTCRtpReceiver")}} interface returns an array of objects, each corresponding to one SSRC (synchronization source) identifier received by the current `RTCRtpReceiver` in the last ten seconds.

## Syntax

Expand All @@ -26,16 +22,32 @@ None.

### Return value

An array of object describing one of the synchronization sources that provided data to the incoming stream in the past ten seconds. These objects contain the following properties:
An array of objects, each describing one of the synchronization sources that provided data to the incoming stream in the past ten seconds.
These objects contain the following properties:

- {{domxref("RTCRtpContributingSource.audioLevel", "audioLevel")}} {{optional_inline}}
- : A double-precision floating-point value between 0.0 and 1.0 specifying the audio level (in dBov) contained in the last RTP packet played from this source.
- {{domxref("RTCRtpContributingSource.rtpTimestamp", "rtpTimestamp")}} {{optional_inline}}
- : The RTP timestamp of the media played out at the time indicated by `timestamp`. This value is a source-generated time value which can be used to help with sequencing and synchronization.
- {{domxref("RTCRtpContributingSource.source", "source")}} {{optional_inline}}
- : A 32-bit unsigned integer value specifying the CSRC identifier of the contributing source.
- {{domxref("RTCRtpContributingSource.timestamp", "timestamp")}} {{optional_inline}}
- : A {{domxref("DOMHighResTimeStamp")}} indicating the most recent time at which a frame originating from this source was delivered to the receiver's {{domxref("MediaStreamTrack")}}.
- `audioLevel`

- : A floating-point value between 0.0 and 1.0 specifying the audio level contained in the last RTP packet played from the synchronization source.

The value is on a linear scale and is defined in units of dBov, or decibels (overload).
This is the amplitude relative to the point at which clipping of the audio begins to occur.
A value of 1.0 represents 0 dBov (maximum volume), a value of 0.0 represents silence, and a value of 0.5 represents approximately 6 dB SPL (decibels of sound pressure level) change in the sound pressure level from 0 dBov.

This value is required and always present.

- `rtpTimestamp` {{optional_inline}}

- : The RTP timestamp (an integer {{domxref("DOMHighResTimeStamp")}}) of the media.
This source-generated timestamp indicates the time at which the media in this packet, scheduled for play out at the time indicated by `timestamp`, was initially sampled or generated.
It may be useful for sequencing and synchronization purposes.

- `source` {{optional_inline}}

- : A positive integer value specifying the SSRC identifier of the synchronization source.
This uniquely identifies the source of the particular stream RTP packets.

- `timestamp` {{optional_inline}}
- : A {{domxref("DOMHighResTimeStamp")}} indicating the most recent time at which a frame originating from this source was delivered to the receiver's {{domxref("MediaStreamTrack")}}

## Specifications

Expand Down
4 changes: 2 additions & 2 deletions files/en-us/web/api/rtcrtpreceiver/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,13 @@ The **`RTCRtpReceiver`** interface of the [WebRTC API](/en-US/docs/Web/API/WebRT
## Instance methods

- {{domxref("RTCRtpReceiver.getContributingSources()")}}
- : Returns an array of {{domxref("RTCRtpContributingSource")}} instances for each unique CSRC (contributing source) identifier received by the current `RTCRtpReceiver` in the last ten seconds.
- : Returns an array that contains an object for each unique CSRC (contributing source) identifier received by the current `RTCRtpReceiver` in the last ten seconds.
- {{domxref("RTCRtpReceiver.getParameters()")}}
- : Returns an object that contains information about how the RTC data is to be decoded.
- {{domxref("RTCRtpReceiver.getStats()")}}
- : Returns a {{jsxref("Promise")}} whose fulfillment handler receives a {{domxref("RTCStatsReport")}} which contains statistics about the incoming streams and their dependencies.
- {{domxref("RTCRtpReceiver.getSynchronizationSources()")}}
- : Returns an array including one `RTCRtpSynchronizationSource` instance for each unique SSRC (synchronization source) identifier received by the current `RTCRtpReceiver` in the last ten seconds.
- : Returns an array that contains an object for each unique SSRC (synchronization source) identifier received by the current `RTCRtpReceiver` in the last ten seconds.

## Specifications

Expand Down
5 changes: 0 additions & 5 deletions files/en-us/web/api/webrtc_api/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,6 @@ These interfaces, dictionaries, and types are used to set up, open, and manage W
- {{DOMxRef("RTCSctpTransport")}}
- : Provides information which describes a Stream Control Transmission Protocol (**{{Glossary("SCTP")}}**) transport and also provides a way to access the underlying Datagram Transport Layer Security (**{{Glossary("DTLS")}}**) transport over which SCTP packets for all of an [`RTCPeerConnection`](/en-US/docs/Web/API/RTCPeerConnection)'s data channels are sent and received.

#### Dictionaries

- {{DOMxRef("RTCRtpContributingSource")}}
- : Contains information about a given contributing source (CSRC) including the most recent time a packet that the source contributed was played out.

#### Events

- {{domxref("RTCDataChannel.bufferedamountlow_event", "bufferedamountlow")}}
Expand Down

0 comments on commit 9716100

Please sign in to comment.