pulsesrc

pulsesrc

Properties

gchar * device Read / Write
gchar * server Read / Write
gchar * device-name Read
GstStructure * stream-properties Read / Write
gboolean mute Read / Write
guint source-output-index Read
gdouble volume Read / Write
gchar * client-name Read / Write
gchar * current-device Read

Types and Values

struct GstPulseSrc

Object Hierarchy

    GObject
    ╰── GInitiallyUnowned
        ╰── GstObject
            ╰── GstElement
                ╰── GstBaseSrc
                    ╰── GstPushSrc
                        ╰── GstAudioBaseSrc
                            ╰── GstAudioSrc
                                ╰── GstPulseSrc

Implemented Interfaces

GstPulseSrc implements GstStreamVolume, GstImplementsInterface, GstMixer and GstPropertyProbe.

Description

This element captures audio from a

PulseAudio sound server.

Example pipelines

1
gst-launch-1.0 -v pulsesrc ! audioconvert ! vorbisenc ! oggmux ! filesink location=alsasrc.ogg
Record from a sound card using pulseaudio and encode to Ogg/Vorbis.

Synopsis

Element Information

plugin

pulseaudio

author

Lennart Poettering

class

Source/Audio

Element Pads

name

src

direction

source

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 ]

Functions

Types and Values

struct GstPulseSrc

struct GstPulseSrc;

Property Details

The “device” property

  “device”                   gchar *

The PulseAudio source device to connect to.

Flags: Read / Write

Default value: NULL


The “server” property

  “server”                   gchar *

The PulseAudio server to connect to.

Flags: Read / Write

Default value: NULL


The “device-name” property

  “device-name”              gchar *

Human-readable name of the sound device.

Flags: Read

Default value: NULL


The “stream-properties” property

  “stream-properties”        GstStructure *

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 (props);

Flags: Read / Write


The “mute” property

  “mute”                     gboolean

Whether the stream is muted or not.

Flags: Read / Write

Default value: FALSE


The “source-output-index” property

  “source-output-index”      guint

The index of the PulseAudio source output corresponding to this element.

Flags: Read

Default value: 4294967295


The “volume” property

  “volume”                   gdouble

The volume of the record stream.

Flags: Read / Write

Allowed values: [0,10]

Default value: 1


The “client-name” property

  “client-name”              gchar *

The PulseAudio client name to use.

Flags: Read / Write

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


The “current-device” property

  “current-device”           gchar *

The current PulseAudio source device.

Flags: Read

Default value: NULL

See Also

pulsesink