Skip to content

Commit

Permalink
Added getCapabilities() to RtcRtpReceiver
Browse files Browse the repository at this point in the history
  • Loading branch information
erik-moqvist committed Apr 29, 2024
1 parent e78db23 commit 656cd95
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions crates/web-sys/src/features/gen_RtcRtpReceiver.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,14 @@ extern "C" {
#[doc = ""]
#[doc = "*This API requires the following crate features to be activated: `MediaStreamTrack`, `RtcRtpReceiver`*"]
pub fn track(this: &RtcRtpReceiver) -> MediaStreamTrack;
#[cfg(feature = "RtcRtpCapabilities")]
# [wasm_bindgen (static_method_of = RtcRtpReceiver , js_class = "RTCRtpReceiver" , js_name = getCapabilities)]
#[doc = "The `getCapabilities()` method."]
#[doc = ""]
#[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpReceiver/getCapabilities)"]
#[doc = ""]
#[doc = "*This API requires the following crate features to be activated: `RtcRtpCapabilities`, `RtcRtpReceiver`*"]
pub fn get_capabilities(kind: &str) -> Option<RtcRtpCapabilities>;
# [wasm_bindgen (method , structural , js_class = "RTCRtpReceiver" , js_name = getContributingSources)]
#[doc = "The `getContributingSources()` method."]
#[doc = ""]
Expand Down
1 change: 1 addition & 0 deletions crates/web-sys/webidls/enabled/RTCRtpReceiver.webidl
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
JSImplementation="@mozilla.org/dom/rtpreceiver;1"]
interface RTCRtpReceiver {
readonly attribute MediaStreamTrack track;
static RTCRtpCapabilities? getCapabilities(DOMString kind);
Promise<RTCStatsReport> getStats();
[Pref="media.peerconnection.rtpsourcesapi.enabled"]
sequence<RTCRtpContributingSource> getContributingSources();
Expand Down

0 comments on commit 656cd95

Please sign in to comment.