mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
webrtc: Change H264 examples to use aggregate-mode=zero-latency for best compatibility
The default changed back to none because it broke existing code. See https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/749 Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-examples/-/merge_requests/22>
This commit is contained in:
parent
6378337a0e
commit
bbed24d919
3 changed files with 3 additions and 3 deletions
|
@ -78,7 +78,7 @@ from gi.repository import GstSdp
|
|||
if DO_VP8:
|
||||
( encoder, payloader, rtp_encoding) = ( "vp8enc target-bitrate=100000 overshoot=25 undershoot=100 deadline=33000 keyframe-max-dist=1", "rtpvp8pay picture-id-mode=2", "VP8" )
|
||||
else:
|
||||
( encoder, payloader, rtp_encoding) = ( "x264enc", "rtph264pay", "H264" )
|
||||
( encoder, payloader, rtp_encoding) = ( "x264enc", "rtph264pay aggregate-mode=zero-latency", "H264" )
|
||||
|
||||
PIPELINE_DESC = '''
|
||||
webrtcbin name=sendrecv stun-server=stun://stun.l.google.com:19302
|
||||
|
|
|
@ -66,7 +66,7 @@ const VP8: VideoParameter = VideoParameter {
|
|||
const H264: VideoParameter = VideoParameter {
|
||||
encoder: "x264enc tune=zerolatency",
|
||||
encoding_name: "H264",
|
||||
payloader: "rtph264pay",
|
||||
payloader: "rtph264pay aggregate-mode=zero-latency",
|
||||
};
|
||||
|
||||
impl std::str::FromStr for VideoParameter {
|
||||
|
|
|
@ -179,7 +179,7 @@ create_receiver_entry (SoupWebsocketConnection * connection)
|
|||
gst_parse_launch ("webrtcbin name=webrtcbin stun-server=stun://"
|
||||
STUN_SERVER " "
|
||||
"v4l2src ! videorate ! video/x-raw,width=640,height=360,framerate=15/1 ! videoconvert ! queue max-size-buffers=1 ! x264enc bitrate=600 speed-preset=ultrafast tune=zerolatency key-int-max=15 ! video/x-h264,profile=constrained-baseline ! queue max-size-time=100000000 ! h264parse ! "
|
||||
"rtph264pay config-interval=-1 name=payloader ! "
|
||||
"rtph264pay config-interval=-1 name=payloader aggregate-mode=zero-latency ! "
|
||||
"application/x-rtp,media=video,encoding-name=H264,payload="
|
||||
RTP_PAYLOAD_TYPE " ! webrtcbin. ", &error);
|
||||
if (error != NULL) {
|
||||
|
|
Loading…
Reference in a new issue