# unixfdsink

Send file-descriptor backed buffers (e.g. memfd, dmabuf) over unix socket to matching unixfdsrc. There can be any number of clients, if none are connected buffers are dropped.

Buffers can have any number of GstMemory, but it is an error if any one of them lacks a file-descriptor.

GstShmAllocator is added into the allocation proposition, which makes most sources write their data into shared memory automatically.

## Example launch lines

     gst-launch-1.0 -v videotestsrc ! video/x-raw,format=RGBx,width=1920,height=1080 ! timeoverlay ! unixfdsink socket-path=/tmp/blah
     gst-launch-1.0 -v unixfdsrc socket-path=/tmp/blah ! videoconvert ! autovideosink

## Hierarchy

    GObject
        ╰──GInitiallyUnowned
            ╰──GstObject
                ╰──GstElement
                    ╰──GstBaseSink
                        ╰──unixfdsink

## Factory details

Authors: – Xavier Claessens

Classification: – `Sink`

Rank – none

Plugin – unixfd

Package – GStreamer Bad Plug-ins

## Pad Templates

### `sink`

    ANY

Presence – always

Direction – sink

Object type – GstPad

## Properties

### min-memory-size

    “min-memory-size” gint64

Minimum size to allocate in the case a copy into shared memory is needed. Memories are kept in a pool and reused when possible.

A value of 0 (the default) means only the needed size is allocated which reduces the possibility of reusing the memory in the case not all buffers need the same size.

A negative value disables copying and the pipeline will stop with an error in the case a copy into shared memory is needed.

Flags : Read / Write / Construct

Default value : 0

Since : 1.28

### num-clients

    “num-clients” guint

The number of clients that are currently connected to the sink. This property is read-only and reflects the current connection count.

Flags : Read

Default value : 0

Since : 1.28

### socket-path

    “socket-path” gchararray

The path to the control socket used to control the shared memory transport. This may be modified during the NULL->READY transition

Flags : Read / Write

Default value : NULL

### socket-type

    “socket-type” GUnixSocketAddressType *

The type of underlying socket

Flags : Read / Write / Construct

Default value : path (2)

### wait-for-connection

    “wait-for-connection” gboolean

Block the stream until a least one client is connected.

Flags : Read / Write / Construct

Default value : false

Since : 1.26

The results of the search are