-/*
- * Farsight Voice+Video library
+/* GStreamer valve element
*
* Copyright 2007 Collabora Ltd,
* Copyright 2007 Nokia Corporation
*
* You should have received a copy of the GNU Library General Public
* License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
+ * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
*
*/
#define __GST_VALVE_H__
#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
G_BEGIN_DECLS
-
/* #define's don't like whitespacey bits */
#define GST_TYPE_VALVE \
(gst_valve_get_type())
typedef struct _GstValve GstValve;
typedef struct _GstValveClass GstValveClass;
-typedef struct _GstValvePrivate GstValvePrivate;
+/**
+ * GstValve:
+ *
+ * The private valve structure
+ */
struct _GstValve
{
- GstBaseTransform parent;
+ /*< private >*/
+ GstElement parent;
- gboolean drop;
+ /* atomic boolean */
+ volatile gint drop;
- /*< private > */
- gpointer _gst_reserved[GST_PADDING];
+ /* Protected by the stream lock */
+ gboolean discont;
+ gboolean need_repush_sticky;
+
+ GstPad *srcpad;
+ GstPad *sinkpad;
};
struct _GstValveClass
{
- GstBaseTransformClass parent_class;
-
- /*< private > */
- gpointer _gst_reserved[GST_PADDING];
+ GstElementClass parent_class;
};
-GType gst_valve_get_type (void);
+G_GNUC_INTERNAL GType gst_valve_get_type (void);
G_END_DECLS