pulsesink

pulsesink

Synopsis

struct              GstPulseSink;

Object Hierarchy

  GObject
   +----GInitiallyUnowned
         +----GstObject
               +----GstElement
                     +----GstBaseSink
                           +----GstAudioBaseSink
                                 +----GstPulseSink

Implemented Interfaces

GstPulseSink implements GstStreamVolume, GstImplementsInterface and GstPropertyProbe.

Properties

  "device"                   gchar*                : Read / Write
  "server"                   gchar*                : Read / Write
  "device-name"              gchar*                : Read
  "volume"                   gdouble               : Read / Write
  "mute"                     gboolean              : Read / Write
  "stream-properties"        GstStructure*         : Read / Write
  "client-name"              gchar*                : Read / Write
  "current-device"           gchar*                : Read

Description

This element outputs audio to a PulseAudio sound server.

Example pipelines

1
gst-launch-1.0 -v filesrc location=sine.ogg ! oggdemux ! vorbisdec ! audioconvert ! audioresample ! pulsesink
Play an Ogg/Vorbis file.
1
gst-launch-1.0 -v audiotestsrc ! audioconvert ! volume volume=0.4 ! pulsesink
Play a 440Hz sine wave.
1
gst-launch-1.0 -v audiotestsrc ! pulsesink stream-properties="props,media.title=test"
Play a sine wave and set a stream property. The property can be checked with "pactl list".

Synopsis

Element Information

plugin

pulseaudio

author

Lennart Poettering

class

Sink/Audio

Element Pads

name

sink

direction

sink

presence

always

details

audio/x-raw, format=(string){ S16LE, S16BE, F32LE, F32BE, S32LE, S32BE, S24LE, S24BE, S24_32LE, S24_32BE, U8 }, layout=(string)interleaved, rate=(int)[ 1, 2147483647 ], channels=(int)[ 1, 32 ]

audio/x-alaw, rate=(int)[ 1, 2147483647 ], channels=(int)[ 1, 32 ]

audio/x-mulaw, rate=(int)[ 1, 2147483647 ], channels=(int)[ 1, 32 ]

audio/x-ac3, framed=(boolean)true

audio/x-eac3, framed=(boolean)true

audio/x-dts, framed=(boolean)true, block-size=(int){ 512, 1024, 2048 }

audio/mpeg, mpegversion=(int)1, mpegaudioversion=(int)[ 1, 2 ], parsed=(boolean)true

audio/mpeg, mpegversion=(int){ 2, 4 }, framed=(boolean)true, stream-format=(string)adts

Details

struct GstPulseSink

struct GstPulseSink;

Property Details

The "device" property

  "device"                   gchar*                : Read / Write

The PulseAudio sink device to connect to.

Default value: NULL


The "server" property

  "server"                   gchar*                : Read / Write

The PulseAudio server to connect to.

Default value: NULL


The "device-name" property

  "device-name"              gchar*                : Read

Human-readable name of the sound device.

Default value: NULL


The "volume" property

  "volume"                   gdouble               : Read / Write

Linear volume of this stream, 1.0=100%.

Allowed values: [0,10]

Default value: 1


The "mute" property

  "mute"                     gboolean              : Read / Write

Mute state of this stream.

Default value: FALSE


The "stream-properties" property

  "stream-properties"        GstStructure*         : Read / Write

List of pulseaudio stream properties. A list of defined properties can be found in the pulseaudio api docs.

Below is an example for registering as a music application to pulseaudio.

1
2
3
4
5
GstStructure *props;

props = gst_structure_from_string ("props,media.role=music", NULL);
g_object_set (pulse, "stream-properties", props, NULL);
gst_structure_free


The "client-name" property

  "client-name"              gchar*                : Read / Write

The PulseAudio client name to use.

Default value: "gst-plugins-good-plugins-scan"


The "current-device" property

  "current-device"           gchar*                : Read

The current PulseAudio sink device.

Default value: NULL

See Also

pulsesrc