webrtc examples: Force regular non-MULTIOPUS

Using MULTIOPUS breaks with most browsers

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3685>
This commit is contained in:
Olivier Crête 2023-01-03 17:44:37 -05:00 committed by Tim-Philipp Müller
parent 45b4bca877
commit 2544c7cb78
4 changed files with 7 additions and 6 deletions

View file

@ -160,7 +160,7 @@ impl App {
&format!(
"videotestsrc is-live=true ! vp8enc deadline=1 ! rtpvp8pay pt=96 ! tee name=video-tee ! \
queue ! fakesink sync=true \
audiotestsrc wave=ticks is-live=true ! opusenc ! rtpopuspay pt=97 ! tee name=audio-tee ! \
audiotestsrc wave=ticks is-live=true ! opusenc ! rtpopuspay pt=97 ! application/x-rtp,encoding-name=OPUS ! tee name=audio-tee ! \
queue ! fakesink sync=true \
audiotestsrc wave=silence is-live=true ! audio-mixer. \
audiomixer name=audio-mixer sink_0::mute=true ! audioconvert ! audioresample ! autoaudiosink \

View file

@ -244,7 +244,8 @@ create_receiver_entry (SoupWebsocketConnection * connection)
"application/x-rtp,media=video,encoding-name=H264,payload="
RTP_PAYLOAD_TYPE " ! webrtcbin. "
"autoaudiosrc is-live=1 ! queue max-size-buffers=1 leaky=downstream ! audioconvert ! audioresample ! opusenc ! rtpopuspay pt="
RTP_AUDIO_PAYLOAD_TYPE " ! webrtcbin. ", &error);
RTP_AUDIO_PAYLOAD_TYPE
" ! application/x-rtp,encoding-name=OPUS ! webrtcbin. ", &error);
if (error != NULL) {
g_error ("Could not create WebRTC pipeline: %s\n", error->message);
g_error_free (error);

View file

@ -115,7 +115,7 @@ impl App {
// Create the GStreamer pipeline
let pipeline = gst::parse_launch(
"videotestsrc pattern=ball is-live=true ! vp8enc deadline=1 ! rtpvp8pay pt=96 ! webrtcbin. \
audiotestsrc is-live=true ! opusenc ! rtpopuspay pt=97 ! webrtcbin. \
audiotestsrc is-live=true ! opusenc ! rtpopuspay pt=97 ! application/x-rtp,encoding-name=OPUS ! webrtcbin. \
webrtcbin name=webrtcbin"
)?;

View file

@ -445,9 +445,9 @@ start_pipeline (gboolean create_offer, guint opus_pt, guint vp8_pt)
* fixes stuttery video playback in Chrome */
"rtpvp8pay name=videopay picture-id-mode=15-bit ! "
"queue ! %s,payload=%u ! sendrecv. "
"audiotestsrc is-live=true wave=red-noise ! audioconvert ! audioresample ! queue ! opusenc ! rtpopuspay name=audiopay ! "
"queue ! %s,payload=%u ! sendrecv. ", RTP_CAPS_VP8, vp8_pt,
RTP_CAPS_OPUS, opus_pt);
"audiotestsrc is-live=true wave=red-noise ! audioconvert ! audioresample ! queue ! opusenc ! rtpopuspay name=audiopay "
" ! application/x-rtp, encoding-name=OPUS ! queue ! %s,payload=%u ! sendrecv. ",
RTP_CAPS_VP8, vp8_pt, RTP_CAPS_OPUS, opus_pt);
pipe1 = gst_parse_launch (pipeline, &error);
g_free (pipeline);