mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2025-01-02 23:38:45 +00:00
webrtc: update further to WebRTCSessionDescription sdp accessor changes
See: https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1406 Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1491>
This commit is contained in:
parent
03abb5c681
commit
5b01e43a12
2 changed files with 8 additions and 7 deletions
|
@ -695,10 +695,10 @@ impl WhipServer {
|
||||||
gst::info!(CAT, obj: obj, "ICE gathering complete");
|
gst::info!(CAT, obj: obj, "ICE gathering complete");
|
||||||
let ans: Option<gst_sdp::SDPMessage>;
|
let ans: Option<gst_sdp::SDPMessage>;
|
||||||
let settings = obj.imp().settings.lock().unwrap();
|
let settings = obj.imp().settings.lock().unwrap();
|
||||||
if let Some(answer_sdp) = webrtcbin
|
if let Some(answer_desc) = webrtcbin
|
||||||
.property::<Option<WebRTCSessionDescription>>("local-description")
|
.property::<Option<WebRTCSessionDescription>>("local-description")
|
||||||
{
|
{
|
||||||
ans = Some(answer_sdp.sdp());
|
ans = Some(answer_desc.sdp().to_owned());
|
||||||
} else {
|
} else {
|
||||||
ans = None;
|
ans = None;
|
||||||
}
|
}
|
||||||
|
|
|
@ -901,7 +901,7 @@ impl WhepSrc {
|
||||||
.webrtcbin
|
.webrtcbin
|
||||||
.property::<Option<WebRTCSessionDescription>>("local-description");
|
.property::<Option<WebRTCSessionDescription>>("local-description");
|
||||||
|
|
||||||
let offer_sdp = match local_desc {
|
let sess_desc = match local_desc {
|
||||||
None => {
|
None => {
|
||||||
gst::element_imp_error!(
|
gst::element_imp_error!(
|
||||||
self,
|
self,
|
||||||
|
@ -910,18 +910,19 @@ impl WhepSrc {
|
||||||
);
|
);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Some(offer) => offer,
|
Some(mut local_desc) => {
|
||||||
|
local_desc.set_type(WebRTCSDPType::Offer);
|
||||||
|
local_desc
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
gst::debug!(
|
gst::debug!(
|
||||||
CAT,
|
CAT,
|
||||||
imp: self,
|
imp: self,
|
||||||
"Sending offer SDP: {:?}",
|
"Sending offer SDP: {:?}",
|
||||||
offer_sdp.sdp().as_text()
|
sess_desc.sdp().as_text()
|
||||||
);
|
);
|
||||||
|
|
||||||
let sess_desc = WebRTCSessionDescription::new(WebRTCSDPType::Offer, offer_sdp.sdp());
|
|
||||||
|
|
||||||
let timeout;
|
let timeout;
|
||||||
let endpoint;
|
let endpoint;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue