appsrc

## appsrc appsrc — Allow the application to feed buffers to a pipeline |

## Synopsis

    struct              GstAppSrc;

## Object Hierarchy

      GObject
       +----GInitiallyUnowned
             +----GstObject
                   +----GstElement
                         +----GstBaseSrc
                               +----GstAppSrc

## Implemented Interfaces

GstAppSrc implements GstURIHandler.

## Properties

      "block"                    gboolean              : Read / Write
      "caps"                     GstCaps*              : Read / Write
      "format"                   GstFormat             : Read / Write
      "is-live"                  gboolean              : Read / Write
      "max-bytes"                guint64               : Read / Write
      "max-latency"              gint64                : Read / Write
      "min-latency"              gint64                : Read / Write
      "size"                     gint64                : Read / Write
      "stream-type"              GstAppStreamType      : Read / Write
      "emit-signals"             gboolean              : Read / Write
      "min-percent"              guint                 : Read / Write

## Signals

      "end-of-stream"                                  : Action
      "enough-data"                                    : Run Last
      "need-data"                                      : Run Last
      "push-buffer"                                    : Action
      "seek-data"                                      : Run Last

## Description

The appsrc element can be used by applications to insert data into a GStreamer pipeline. Unlike most GStreamer elements, Appsrc provides external API functions.

For the documentation of the API, please see the libgstapp section in the GStreamer Plugins Base Libraries documentation.

## Synopsis

### Element Information

plugin | app
author | David Schleef <ds@schleef.org>, Wim Taymans <wim.taymans@gmail.com>
class | Generic/Source

### Element Pads

name | src
direction | source
presence | always
details | ANY

## Details

### struct GstAppSrc

    struct GstAppSrc;

## Property Details

### The `"block"` property

      "block"                    gboolean              : Read / Write

Block push-buffer when max-bytes are queued.

Default value: FALSE

### The `"caps"` property

      "caps"                     GstCaps*              : Read / Write

The allowed caps for the src pad.

### The `"format"` property

      "format"                   GstFormat             : Read / Write

The format of the segment events and seek.

Default value: GST_FORMAT_BYTES

### The `"is-live"` property

      "is-live"                  gboolean              : Read / Write

Whether to act as a live source.

Default value: FALSE

### The `"max-bytes"` property

      "max-bytes"                guint64               : Read / Write

The maximum number of bytes to queue internally (0 = unlimited).

Default value: 200000

### The `"max-latency"` property

      "max-latency"              gint64                : Read / Write

The maximum latency (-1 = unlimited).

Allowed values: >= G_MAXULONG

Default value: -1

### The `"min-latency"` property

      "min-latency"              gint64                : Read / Write

The minimum latency (-1 = default).

Allowed values: >= G_MAXULONG

Default value: -1

### The `"size"` property

      "size"                     gint64                : Read / Write

The size of the data stream in bytes (-1 if unknown).

Allowed values: >= G_MAXULONG

Default value: -1

### The `"stream-type"` property

      "stream-type"              GstAppStreamType      : Read / Write

the type of the stream.

Default value: GST_APP_STREAM_TYPE_STREAM

### The `"emit-signals"` property

      "emit-signals"             gboolean              : Read / Write

Emit need-data, enough-data and seek-data signals.

Default value: TRUE

### The `"min-percent"` property

      "min-percent"              guint                 : Read / Write

Emit need-data when queued bytes drops below this percent of max-bytes.

Allowed values: <= 100

Default value: 0

## Signal Details

### The `"end-of-stream"` signal

    GstFlowReturn       user_function                      (GstAppSrc *gstappsrc,
                                                            gpointer   user_data)      : Action

`gstappsrc` : | the object which received the signal.
`user_data` : | user data set when the signal handler was connected.

### The `"enough-data"` signal

    void                user_function                      (GstAppSrc *gstappsrc,
                                                            gpointer   user_data)      : Run Last

`gstappsrc` : | the object which received the signal.
`user_data` : | user data set when the signal handler was connected.

### The `"need-data"` signal

    void                user_function                      (GstAppSrc *gstappsrc,
                                                            guint      arg1,
                                                            gpointer   user_data)      : Run Last

`gstappsrc` : | the object which received the signal.
`user_data` : | user data set when the signal handler was connected.

### The `"push-buffer"` signal

    GstFlowReturn       user_function                      (GstAppSrc *gstappsrc,
                                                            GstBuffer *arg1,
                                                            gpointer   user_data)      : Action

`gstappsrc` : | the object which received the signal.
`user_data` : | user data set when the signal handler was connected.

### The `"seek-data"` signal

    gboolean            user_function                      (GstAppSrc *gstappsrc,
                                                            guint64    arg1,
                                                            gpointer   user_data)      : Run Last

`gstappsrc` : | the object which received the signal.
`user_data` : | user data set when the signal handler was connected.