webrtcsrc

webrtcsrc is the source counterpart of the webrtcsink element and can be used to receive streams from it, it can also be used to easily playback WebRTC streams coming from a web browser.

To try the element, you should run webrtcsink as described in its documentation, finding its peer-id (in the signalling server logs for example) and then run:

gst-launch-1.0 webrtcsrc signaller::producer-peer-id=<webrtcsink-peer-id> ! videoconvert ! autovideosink

or directly using playbin:

gst-launch-1.0 playbin3 uri="gstwebrtc://localhost:8443?peer-id=<webrtcsink-peer-id>"

Decoding

To be able to precisely negotiate the WebRTC SDP, webrtcsrc is able to decode streams. During SDP negotiation we expose our pads based on the peer offer and right after query caps to see what downstream supports. In practice in uridecodebinX or playbinX, decoding will happen in decodebinX but for the case where a videoconvert is placed after a video_XX pad, decoding will happen inside webrtcsrc.

Hierarchy

GObject
    ╰──GInitiallyUnowned
        ╰──GstObject
            ╰──GstElement
                ╰──GstBin
                    ╰──webrtcsrc

Implemented interfaces

Factory details

Authors: – Thibault Saunier

Classification:Source/Network/WebRTC

Rank – primary

Plugin – rswebrtc

Package – gst-plugin-webrtc

Pad Templates

audio_%u

audio/x-raw(ANY):
audio/x-opus:
application/x-rtp:

Presencesometimes

Directionsrc

Object typeGstWebRTCSrcPad


video_%u

video/x-raw(ANY):
application/x-rtp:

Presencesometimes

Directionsrc

Object typeGstWebRTCSrcPad


Signals

request-encoded-filter

GstElement *
request_encoded_filter_callback (GstElement * param_0,
                                 gchararray arg0,
                                 gchararray arg1,
                                 GstCaps * arg2,
                                 gpointer udata)
def request_encoded_filter_callback (param_0, arg0, arg1, arg2, udata):
    #python callback for the 'request-encoded-filter' signal
function request_encoded_filter_callback(param_0: GstElement * param_0, arg0: gchararray arg0, arg1: gchararray arg1, arg2: GstCaps * arg2, udata: gpointer udata): {
    // javascript callback for the 'request-encoded-filter' signal
}

Parameters:

param_0
No description available
arg0
No description available
arg1
No description available
arg2
No description available
udata
No description available
Returns (GstElement *)
No description available

Flags: Run Last


Properties

audio-codecs

“audio-codecs” GstValueArray *

Names of audio codecs to be be used during the SDP negotiation. Valid values: [OPUS]

Flags : Read / Write


meta

“meta” GstStructure *

Free form metadata about the consumer

Flags : Read / Write


signaller

“signaller” GstRSWebRTCSignallableIface *

The Signallable object to use to handle WebRTC Signalling

Flags : Read / Write


stun-server

“stun-server” gchararray

NULL

Flags : Read / Write

Default value : stun://stun.l.google.com:19302


video-codecs

“video-codecs” GstValueArray *

Names of video codecs to be be used during the SDP negotiation. Valid values: [VP8, H264, VP9, H265]

Flags : Read / Write


The results of the search are