mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2024-12-18 16:16:28 +00:00
webrtc: janus: handle slow_link videoroom event
Fix this warning: webrtc-janusvr-signaller imp.rs:426:gstrswebrtc::janusvr_signaller:👿:Signaller::handle_msg:<GstJanusVRWebRTCSignallerU64@0x7f317009b4d0> Unknown message from server: { "janus": "event", "session_id": 980554280060589, "sender": 5867141593320621, "plugindata": { "plugin": "janus.plugin.videoroom", "data": { "videoroom": "slow_link", "current-bitrate": 0 } } } Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1929>
This commit is contained in:
parent
4d31001c4b
commit
867c2b78b6
1 changed files with 11 additions and 0 deletions
|
@ -211,6 +211,12 @@ struct RoomTalking {
|
|||
audio_level: f32,
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Debug)]
|
||||
struct SlowLink {
|
||||
#[serde(rename = "current-bitrate")]
|
||||
current_bitrate: u32,
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Debug)]
|
||||
#[serde(tag = "videoroom", rename_all = "kebab-case")]
|
||||
enum VideoRoomData {
|
||||
|
@ -219,6 +225,8 @@ enum VideoRoomData {
|
|||
Destroyed(RoomDestroyed),
|
||||
Talking(RoomTalking),
|
||||
StoppedTalking(RoomTalking),
|
||||
#[serde(rename = "slow_link")]
|
||||
SlowLink(SlowLink),
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Debug)]
|
||||
|
@ -542,6 +550,9 @@ impl Signaller {
|
|||
VideoRoomData::StoppedTalking(talking) => {
|
||||
self.emit_talking(false, talking.id, talking.audio_level);
|
||||
}
|
||||
VideoRoomData::SlowLink(_slow_link) => {
|
||||
// TODO: use to reduce the bitrate?
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue