# srtsink

srtsink is a network sink that sends SRT packets to the network.

## Examples

     gst-launch-1.0 -v audiotestsrc ! srtsink uri=srt://host

This pipeline shows how to serve SRT packets through the default port.

     gst-launch-1.0 -v audiotestsrc ! srtsink uri=srt://:port

This pipeline shows how to wait SRT callers.

## Hierarchy

    GObject
        ╰──GInitiallyUnowned
            ╰──GstObject
                ╰──GstElement
                    ╰──GstBaseSink
                        ╰──srtsink

## Implemented interfaces

    GstURIHandler

## Factory details

Authors: – Justin Kim <justin.joy.9to5></justin.joy.9to5>

Classification: – `Sink/Network`

Rank – primary

Plugin – srt

Package – GStreamer Bad Plug-ins

## Pad Templates

### `sink`

    ANY

Presence – always

Direction – sink

Object type – GstPad

## Signals

### caller-added

    caller_added_callback (GstElement * gstsrtsink,
                           gint unused,
                           GSocketAddress * addr,
                           gpointer udata)

    def caller_added_callback (gstsrtsink, unused, addr, udata):
        #python callback for the 'caller-added' signal

    function caller_added_callback(gstsrtsink: GstElement * gstsrtsink, unused: gint unused, addr: GSocketAddress * addr, udata: gpointer udata): {
        // javascript callback for the 'caller-added' signal
    }

A new caller has connected to gstsrtsink.

Parameters:

`gstsrtsink` –

the srtsink element that emitted this signal

`unused` –

always zero (for ABI compatibility with previous versions)

`addr` –

the GSocketAddress of the new caller

`udata` –
No description available

Flags: Run Last

### caller-connecting

    gboolean
    caller_connecting_callback (GstElement * gstsrtsink,
                                GSocketAddress * addr,
                                gchararray stream_id,
                                gpointer udata)

    def caller_connecting_callback (gstsrtsink, addr, stream_id, udata):
        #python callback for the 'caller-connecting' signal

    function caller_connecting_callback(gstsrtsink: GstElement * gstsrtsink, addr: GSocketAddress * addr, stream_id: gchararray stream_id, udata: gpointer udata): {
        // javascript callback for the 'caller-connecting' signal
    }

Whether to accept or reject a caller's connection to srtsink in listener mode. The Caller's connection is rejected if the callback returns FALSE, else the connection is accepeted.

Parameters:

`gstsrtsink` –

the srtsink element that emitted this signal

`addr` –

the GSocketAddress that describes the client socket

`stream_id` –

the stream Id to which the caller wants to connect

`udata` –
No description available
Returns (gboolean) –
No description available

Flags: Run Last

Since : 1.20

### caller-rejected

    caller_rejected_callback (GstElement * gstsrtsink,
                              GSocketAddress * addr,
                              gchararray stream_id,
                              gpointer udata)

    def caller_rejected_callback (gstsrtsink, addr, stream_id, udata):
        #python callback for the 'caller-rejected' signal

    function caller_rejected_callback(gstsrtsink: GstElement * gstsrtsink, addr: GSocketAddress * addr, stream_id: gchararray stream_id, udata: gpointer udata): {
        // javascript callback for the 'caller-rejected' signal
    }

A caller's connection to srtsink in listener mode has been rejected.

Parameters:

`gstsrtsink` –

the srtsink element that emitted this signal

`addr` –

the GSocketAddress that describes the client socket

`stream_id` –

the stream Id to which the caller wants to connect

`udata` –
No description available

Flags: Run Last

Since : 1.20

### caller-removed

    caller_removed_callback (GstElement * gstsrtsink,
                             gint unused,
                             GSocketAddress * addr,
                             gpointer udata)

    def caller_removed_callback (gstsrtsink, unused, addr, udata):
        #python callback for the 'caller-removed' signal

    function caller_removed_callback(gstsrtsink: GstElement * gstsrtsink, unused: gint unused, addr: GSocketAddress * addr, udata: gpointer udata): {
        // javascript callback for the 'caller-removed' signal
    }

The given caller has disconnected.

Parameters:

`gstsrtsink` –

the srtsink element that emitted this signal

`unused` –

always zero (for ABI compatibility with previous versions)

`addr` –

the GSocketAddress of the caller

`udata` –
No description available

Flags: Run Last

## Properties

#### authentication

    “authentication” gboolean

Boolean to authenticate a connection. If TRUE, the incoming connection is authenticated. Else, all the connections are accepted.

Flags : Read / Write

Default value : false

Since : 1.20

#### auto-reconnect

    “auto-reconnect” gboolean

Automatically reconnect when connection fails

Flags : Read / Write

Default value : true

#### latency

    “latency” gint

Minimum latency (milliseconds)

Flags : Read / Write

Default value : 125

#### localaddress

    “localaddress” gchararray

Local address to bind

Flags : Read / Write

Default value : NULL

#### localport

    “localport” guint

Local port to bind

Flags : Read / Write

Default value : 7001

#### mode

    “mode” GstSRTConnectionMode *

SRT connection mode

Flags : Read / Write

Default value : caller (1)

#### passphrase

    “passphrase” gchararray

Password for the encrypted transmission

Flags : Read / Write

#### pbkeylen

    “pbkeylen” GstSRTKeyLength *

Crypto key length in bytes

Flags : Read / Write

Default value : no-key (0)

#### poll-timeout

    “poll-timeout” gint

Return poll wait after timeout milliseconds (-1 = infinite)

Flags : Read / Write

Default value : 1000

#### stats

    “stats” GstStructure *

SRT Statistics

Flags : Read

Default value :

    application/x-srt-statistics, bytes-sent-total=(guint64)0;

#### streamid

    “streamid” gchararray

Stream ID for the SRT access control

Flags : Read / Write

Default value : NULL

#### uri

    “uri” gchararray

URI in the form of srt://address:port

Flags : Read / Write

Default value : srt://127.0.0.1:7001

#### wait-for-connection

    “wait-for-connection” gboolean

Boolean to block streaming until a client connects. If TRUE, `srtsink' will stream only when a client is connected.

Flags : Read / Write

Default value : true

The results of the search are