Blame gst/gststreamcollection.h

Packit Service 963350
/* GStreamer
Packit Service 963350
 * Copyright (C) 2015 Centricular Ltd
Packit Service 963350
 *  @author: Edward Hervey <edward@centricular.com>
Packit Service 963350
 *  @author: Jan Schmidt <jan@centricular.com>
Packit Service 963350
 *
Packit Service 963350
 * gststreams.h : Header for GstStreamCollection subsystem
Packit Service 963350
 *
Packit Service 963350
 * This library is free software; you can redistribute it and/or
Packit Service 963350
 * modify it under the terms of the GNU Library General Public
Packit Service 963350
 * License as published by the Free Software Foundation; either
Packit Service 963350
 * version 2 of the License, or (at your option) any later version.
Packit Service 963350
 *
Packit Service 963350
 * This library is distributed in the hope that it will be useful,
Packit Service 963350
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit Service 963350
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit Service 963350
 * Library General Public License for more details.
Packit Service 963350
 *
Packit Service 963350
 * You should have received a copy of the GNU Library General Public
Packit Service 963350
 * License along with this library; if not, write to the
Packit Service 963350
 * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
Packit Service 963350
 * Boston, MA 02110-1301, USA.
Packit Service 963350
 */
Packit Service 963350
Packit Service 963350
Packit Service 963350
#ifndef __GST_STREAM_COLLECTION_H__
Packit Service 963350
#define __GST_STREAM_COLLECTION_H__
Packit Service 963350
Packit Service 963350
#include <gst/gstobject.h>
Packit Service 963350
Packit Service 963350
G_BEGIN_DECLS
Packit Service 963350
Packit Service 963350
#define GST_TYPE_STREAM_COLLECTION             (gst_stream_collection_get_type ())
Packit Service 963350
#define GST_IS_STREAM_COLLECTION(obj)          (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_STREAM_COLLECTION))
Packit Service 963350
#define GST_IS_STREAM_COLLECTION_CLASS(klass)  (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_STREAM_COLLECTION))
Packit Service 963350
#define GST_STREAM_COLLECTION_GET_CLASS(obj)   (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_STREAM_COLLECTION, GstStreamCollectionClass))
Packit Service 963350
#define GST_STREAM_COLLECTION(obj)             (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_STREAM_COLLECTION, GstStreamCollection))
Packit Service 963350
#define GST_STREAM_COLLECTION_CLASS(klass)     (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_STREAM_COLLECTION, GstStreamCollectionClass))
Packit Service 963350
#define GST_STREAM_COLLECTION_CAST(obj)        ((GstStreamCollection*)(obj))
Packit Service 963350
Packit Service 963350
typedef struct _GstStreamCollection GstStreamCollection;
Packit Service 963350
typedef struct _GstStreamCollectionClass GstStreamCollectionClass;
Packit Service 963350
typedef struct _GstStreamCollectionPrivate GstStreamCollectionPrivate;
Packit Service 963350
Packit Service 963350
#include <gst/gststreamcollection.h>
Packit Service 963350
#include <gst/gststreams.h>
Packit Service 963350
Packit Service 963350
/**
Packit Service 963350
 * GstStreamCollection:
Packit Service 963350
 *
Packit Service 963350
 * A collection of #GstStream that are available.
Packit Service 963350
 *
Packit Service 963350
 * A #GstStreamCollection will be provided by elements that can make those
Packit Service 963350
 * streams available. Applications can use the collection to show the user
Packit Service 963350
 * what streams are available by using %gst_stream_collection_get_stream()
Packit Service 963350
 *
Packit Service 963350
 * Once posted, a #GstStreamCollection is immutable. Updates are made by sending
Packit Service 963350
 * a new #GstStreamCollection message, which may or may not share some of
Packit Service 963350
 * the #GstStream objects from the collection it replaces. The receiver can check
Packit Service 963350
 * the sender of a stream collection message to know which collection is
Packit Service 963350
 * obsoleted.
Packit Service 963350
 *
Packit Service 963350
 * Several elements in a pipeline can provide #GstStreamCollection.
Packit Service 963350
 *
Packit Service 963350
 * Applications can activate streams from a collection by using the
Packit Service 963350
 * #GST_EVENT_SELECT_STREAMS event on a pipeline, bin or element.
Packit Service 963350
 *
Packit Service 963350
 * Since: 1.10
Packit Service 963350
 */
Packit Service 963350
struct _GstStreamCollection {
Packit Service 963350
  /*< private >*/
Packit Service 963350
  GstObject object;
Packit Service 963350
Packit Service 963350
  gchar *upstream_id;
Packit Service 963350
  GstStreamCollectionPrivate *priv;
Packit Service 963350
Packit Service 963350
  gpointer _gst_reserved[GST_PADDING];
Packit Service 963350
};
Packit Service 963350
Packit Service 963350
/**
Packit Service 963350
 * GstStreamCollectionClass:
Packit Service 963350
 * @parent_class: the parent class structure
Packit Service 963350
 * @stream_notify: default signal handler for the stream-notify signal
Packit Service 963350
 *
Packit Service 963350
 * GstStreamCollection class structure
Packit Service 963350
 */
Packit Service 963350
struct _GstStreamCollectionClass {
Packit Service 963350
  GstObjectClass parent_class;
Packit Service 963350
Packit Service 963350
  /* signals */
Packit Service 963350
  void  (*stream_notify)      (GstStreamCollection *collection, GstStream *stream, GParamSpec * pspec);
Packit Service 963350
Packit Service 963350
  /*< private >*/
Packit Service 963350
  gpointer _gst_reserved[GST_PADDING];
Packit Service 963350
};
Packit Service 963350
Packit Service 963350
GST_API
Packit Service 963350
GType gst_stream_collection_get_type (void);
Packit Service 963350
Packit Service 963350
GST_API
Packit Service 963350
GstStreamCollection *gst_stream_collection_new (const gchar *upstream_id);
Packit Service 963350
Packit Service 963350
GST_API
Packit Service 963350
const gchar *gst_stream_collection_get_upstream_id (GstStreamCollection *collection);
Packit Service 963350
Packit Service 963350
GST_API
Packit Service 963350
guint gst_stream_collection_get_size (GstStreamCollection *collection);
Packit Service 963350
Packit Service 963350
GST_API
Packit Service 963350
GstStream *gst_stream_collection_get_stream (GstStreamCollection *collection, guint index);
Packit Service 963350
Packit Service 963350
GST_API
Packit Service 963350
gboolean gst_stream_collection_add_stream (GstStreamCollection *collection,
Packit Service 963350
                                           GstStream *stream);
Packit Service 963350
Packit Service 963350
#ifdef G_DEFINE_AUTOPTR_CLEANUP_FUNC
Packit Service 963350
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GstStreamCollection, gst_object_unref)
Packit Service 963350
#endif
Packit Service 963350
Packit Service 963350
G_END_DECLS
Packit Service 963350
Packit Service 963350
#endif /* __GST_STREAM_COLLECTION_H__ */