From 12bb2b0e1f068d1de30e7ee9577bbe01e0453eb1 Mon Sep 17 00:00:00 2001 From: Erik Moqvist Date: Fri, 17 May 2024 16:13:33 +0200 Subject: [PATCH] Added jitterBufferTarget to RtcRtpReceiver. --- CHANGELOG.md | 3 +++ .../web-sys/src/features/gen_RtcRtpReceiver.rs | 17 +++++++++++++++++ .../webidls/enabled/RTCRtpReceiver.webidl | 2 ++ 3 files changed, 22 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index c1c2ef677d7e..a2c9163c417e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -39,6 +39,9 @@ * Add bindings for `FocusOptions`. [#3996](https://github.com/rustwasm/wasm-bindgen/pull/3996) +* Add bindings for `RTCRtpReceiver.jitterBufferTarget`. + [#3968](https://github.com/rustwasm/wasm-bindgen/pull/3968) + ### Changed * Stabilize Web Share API. diff --git a/crates/web-sys/src/features/gen_RtcRtpReceiver.rs b/crates/web-sys/src/features/gen_RtcRtpReceiver.rs index 1491ae293731..1d15946511ed 100644 --- a/crates/web-sys/src/features/gen_RtcRtpReceiver.rs +++ b/crates/web-sys/src/features/gen_RtcRtpReceiver.rs @@ -20,6 +20,23 @@ extern "C" { #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaStreamTrack`, `RtcRtpReceiver`*"] pub fn track(this: &RtcRtpReceiver) -> MediaStreamTrack; + # [wasm_bindgen (structural , method , getter , js_class = "RTCRtpReceiver" , js_name = jitterBufferTarget)] + #[doc = "Getter for the `jitterBufferTarget` field of this object."] + #[doc = ""] + #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpReceiver/jitterBufferTarget)"] + #[doc = ""] + #[doc = "*This API requires the following crate features to be activated: `RtcRtpReceiver`*"] + pub fn jitter_buffer_target(this: &RtcRtpReceiver) -> Option; + # [wasm_bindgen (structural , catch , method , setter , js_class = "RTCRtpReceiver" , js_name = jitterBufferTarget)] + #[doc = "Setter for the `jitterBufferTarget` field of this object."] + #[doc = ""] + #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpReceiver/jitterBufferTarget)"] + #[doc = ""] + #[doc = "*This API requires the following crate features to be activated: `RtcRtpReceiver`*"] + pub fn set_jitter_buffer_target( + this: &RtcRtpReceiver, + value: Option, + ) -> Result<(), JsValue>; #[cfg(feature = "RtcRtpCapabilities")] # [wasm_bindgen (static_method_of = RtcRtpReceiver , js_class = "RTCRtpReceiver" , js_name = getCapabilities)] #[doc = "The `getCapabilities()` method."] diff --git a/crates/web-sys/webidls/enabled/RTCRtpReceiver.webidl b/crates/web-sys/webidls/enabled/RTCRtpReceiver.webidl index db9434cff486..31c4c5327757 100644 --- a/crates/web-sys/webidls/enabled/RTCRtpReceiver.webidl +++ b/crates/web-sys/webidls/enabled/RTCRtpReceiver.webidl @@ -17,6 +17,8 @@ interface RTCRtpReceiver { sequence getContributingSources(); [Pref="media.peerconnection.rtpsourcesapi.enabled"] sequence getSynchronizationSources(); + [SetterThrows] + attribute DOMHighResTimeStamp? jitterBufferTarget; [ChromeOnly] undefined setStreamIds(sequence streamIds);