|
Packit |
1f69a5 |
/* GStreamer
|
|
Packit |
1f69a5 |
* Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu>
|
|
Packit |
1f69a5 |
*
|
|
Packit |
1f69a5 |
* This library is free software; you can redistribute it and/or
|
|
Packit |
1f69a5 |
* modify it under the terms of the GNU Library General Public
|
|
Packit |
1f69a5 |
* License as published by the Free Software Foundation; either
|
|
Packit |
1f69a5 |
* version 2 of the License, or (at your option) any later version.
|
|
Packit |
1f69a5 |
*
|
|
Packit |
1f69a5 |
* This library is distributed in the hope that it will be useful,
|
|
Packit |
1f69a5 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
Packit |
1f69a5 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
Packit |
1f69a5 |
* Library General Public License for more details.
|
|
Packit |
1f69a5 |
*
|
|
Packit |
1f69a5 |
* You should have received a copy of the GNU Library General Public
|
|
Packit |
1f69a5 |
* License along with this library; if not, write to the
|
|
Packit |
1f69a5 |
* Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
|
|
Packit |
1f69a5 |
* Boston, MA 02110-1301, USA.
|
|
Packit |
1f69a5 |
*/
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
#include <gst/gst.h>
|
|
Packit |
1f69a5 |
#include <gst/video/gstvideofilter.h>
|
|
Packit |
1f69a5 |
#include <gst/video/video.h>
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
#ifndef __GST_VIDEO_BOX_H__
|
|
Packit |
1f69a5 |
#define __GST_VIDEO_BOX_H__
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
#define GST_TYPE_VIDEO_BOX \
|
|
Packit |
1f69a5 |
(gst_video_box_get_type())
|
|
Packit |
1f69a5 |
#define GST_VIDEO_BOX(obj) \
|
|
Packit |
1f69a5 |
(G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_VIDEO_BOX,GstVideoBox))
|
|
Packit |
1f69a5 |
#define GST_VIDEO_BOX_CLASS(klass) \
|
|
Packit |
1f69a5 |
(G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_VIDEO_BOX,GstVideoBoxClass))
|
|
Packit |
1f69a5 |
#define GST_IS_VIDEO_BOX(obj) \
|
|
Packit |
1f69a5 |
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_VIDEO_BOX))
|
|
Packit |
1f69a5 |
#define GST_IS_VIDEO_BOX_CLASS(klass) \
|
|
Packit |
1f69a5 |
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_VIDEO_BOX))
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
typedef struct _GstVideoBox GstVideoBox;
|
|
Packit |
1f69a5 |
typedef struct _GstVideoBoxClass GstVideoBoxClass;
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
typedef enum
|
|
Packit |
1f69a5 |
{
|
|
Packit |
1f69a5 |
VIDEO_BOX_FILL_BLACK,
|
|
Packit |
1f69a5 |
VIDEO_BOX_FILL_GREEN,
|
|
Packit |
1f69a5 |
VIDEO_BOX_FILL_BLUE,
|
|
Packit |
1f69a5 |
VIDEO_BOX_FILL_RED,
|
|
Packit |
1f69a5 |
VIDEO_BOX_FILL_YELLOW,
|
|
Packit |
1f69a5 |
VIDEO_BOX_FILL_WHITE,
|
|
Packit |
1f69a5 |
VIDEO_BOX_FILL_LAST
|
|
Packit |
1f69a5 |
}
|
|
Packit |
1f69a5 |
GstVideoBoxFill;
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
struct _GstVideoBox
|
|
Packit |
1f69a5 |
{
|
|
Packit |
1f69a5 |
GstVideoFilter element;
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
/* <private> */
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
/* Guarding everything below */
|
|
Packit |
1f69a5 |
GMutex mutex;
|
|
Packit |
1f69a5 |
/* caps */
|
|
Packit |
1f69a5 |
GstVideoFormat in_format;
|
|
Packit |
1f69a5 |
gint in_width, in_height;
|
|
Packit |
1f69a5 |
gboolean in_sdtv;
|
|
Packit |
1f69a5 |
GstVideoFormat out_format;
|
|
Packit |
1f69a5 |
gint out_width, out_height;
|
|
Packit |
1f69a5 |
gboolean out_sdtv;
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
gint box_left, box_right, box_top, box_bottom;
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
gint border_left, border_right, border_top, border_bottom;
|
|
Packit |
1f69a5 |
gint crop_left, crop_right, crop_top, crop_bottom;
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
gdouble alpha;
|
|
Packit |
1f69a5 |
gdouble border_alpha;
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
GstVideoBoxFill fill_type;
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
gboolean autocrop;
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
void (*fill) (GstVideoBoxFill fill_type, guint b_alpha, GstVideoFrame *dest, gboolean sdtv);
|
|
Packit |
1f69a5 |
void (*copy) (guint i_alpha, GstVideoFrame * dest, gboolean dest_sdtv, gint dest_x, gint dest_y, GstVideoFrame * src, gboolean src_sdtv, gint src_x, gint src_y, gint w, gint h);
|
|
Packit |
1f69a5 |
};
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
struct _GstVideoBoxClass
|
|
Packit |
1f69a5 |
{
|
|
Packit |
1f69a5 |
GstVideoFilterClass parent_class;
|
|
Packit |
1f69a5 |
};
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
GType gst_video_box_get_type (void);
|
|
Packit |
1f69a5 |
|
|
Packit |
1f69a5 |
#endif /* __GST_VIDEO_BOX_H__ */
|