Blame gst-libs/gst/video/gstvideofilter.h

Packit 971217
/* GStreamer
Packit 971217
 * Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu>
Packit 971217
 *
Packit 971217
 * This library is free software; you can redistribute it and/or
Packit 971217
 * modify it under the terms of the GNU Library General Public
Packit 971217
 * License as published by the Free Software Foundation; either
Packit 971217
 * version 2 of the License, or (at your option) any later version.
Packit 971217
 *
Packit 971217
 * This library is distributed in the hope that it will be useful,
Packit 971217
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 971217
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit 971217
 * Library General Public License for more details.
Packit 971217
 *
Packit 971217
 * You should have received a copy of the GNU Library General Public
Packit 971217
 * License along with this library; if not, write to the
Packit 971217
 * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
Packit 971217
 * Boston, MA 02110-1301, USA.
Packit 971217
 */
Packit 971217
Packit 971217
Packit 971217
#ifndef __GST_VIDEO_FILTER_H__
Packit 971217
#define __GST_VIDEO_FILTER_H__
Packit 971217
Packit 971217
#include <gst/base/gstbasetransform.h>
Packit 971217
#include <gst/video/video.h>
Packit 971217
Packit 971217
G_BEGIN_DECLS
Packit 971217
Packit 971217
typedef struct _GstVideoFilter GstVideoFilter;
Packit 971217
typedef struct _GstVideoFilterClass GstVideoFilterClass;
Packit 971217
Packit 971217
#define GST_TYPE_VIDEO_FILTER \
Packit 971217
  (gst_video_filter_get_type())
Packit 971217
#define GST_VIDEO_FILTER(obj) \
Packit 971217
  (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_VIDEO_FILTER,GstVideoFilter))
Packit 971217
#define GST_VIDEO_FILTER_CLASS(klass) \
Packit 971217
  (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_VIDEO_FILTER,GstVideoFilterClass))
Packit 971217
#define GST_VIDEO_FILTER_GET_CLASS(obj) \
Packit 971217
  (G_TYPE_INSTANCE_GET_CLASS((obj), GST_TYPE_VIDEO_FILTER, GstVideoFilterClass))
Packit 971217
#define GST_IS_VIDEO_FILTER(obj) \
Packit 971217
  (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_VIDEO_FILTER))
Packit 971217
#define GST_IS_VIDEO_FILTER_CLASS(klass) \
Packit 971217
  (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_VIDEO_FILTER))
Packit 971217
#define GST_VIDEO_FILTER_CAST(obj)  ((GstVideoFilter *)(obj))
Packit 971217
Packit 971217
struct _GstVideoFilter {
Packit 971217
  GstBaseTransform element;
Packit 971217
Packit 971217
  gboolean negotiated;
Packit 971217
  GstVideoInfo in_info;
Packit 971217
  GstVideoInfo out_info;
Packit 971217
Packit 971217
  /*< private >*/
Packit 971217
  gpointer _gst_reserved[GST_PADDING];
Packit 971217
};
Packit 971217
Packit 971217
/**
Packit 971217
 * GstVideoFilterClass:
Packit 971217
 * @parent_class: the parent class structure
Packit 971217
 * @set_info: function to be called with the negotiated caps and video infos
Packit 971217
 * @transform_frame: transform a video frame
Packit 971217
 * @transform_frame_ip: transform a video frame in place
Packit 971217
 *
Packit 971217
 * The video filter class structure.
Packit 971217
 */
Packit 971217
struct _GstVideoFilterClass {
Packit 971217
  GstBaseTransformClass parent_class;
Packit 971217
Packit 971217
  gboolean      (*set_info)           (GstVideoFilter *filter,
Packit 971217
                                       GstCaps *incaps, GstVideoInfo *in_info,
Packit 971217
                                       GstCaps *outcaps, GstVideoInfo *out_info);
Packit 971217
Packit 971217
  /* transform */
Packit 971217
  GstFlowReturn (*transform_frame)    (GstVideoFilter *filter,
Packit 971217
                                       GstVideoFrame *inframe, GstVideoFrame *outframe);
Packit 971217
  GstFlowReturn (*transform_frame_ip) (GstVideoFilter *trans, GstVideoFrame *frame);
Packit 971217
Packit 971217
  /*< private >*/
Packit 971217
  gpointer _gst_reserved[GST_PADDING];
Packit 971217
};
Packit 971217
Packit 971217
GST_VIDEO_API
Packit 971217
GType gst_video_filter_get_type (void);
Packit 971217
Packit 971217
#ifdef G_DEFINE_AUTOPTR_CLEANUP_FUNC
Packit 971217
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GstVideoFilter, gst_object_unref)
Packit 971217
#endif
Packit 971217
Packit 971217
G_END_DECLS
Packit 971217
Packit 971217
#endif /* __GST_VIDEO_FILTER_H__ */