David Schleef | 1bdd2c9 | 2003-07-02 06:16:39 +0000 | [diff] [blame] | 1 | /* GStreamer |
| 2 | * Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu> |
| 3 | * |
| 4 | * This library is free software; you can redistribute it and/or |
| 5 | * modify it under the terms of the GNU Library General Public |
| 6 | * License as published by the Free Software Foundation; either |
| 7 | * version 2 of the License, or (at your option) any later version. |
| 8 | * |
| 9 | * This library is distributed in the hope that it will be useful, |
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 12 | * Library General Public License for more details. |
| 13 | * |
| 14 | * You should have received a copy of the GNU Library General Public |
| 15 | * License along with this library; if not, write to the |
Tim-Philipp Müller | 230cf41 | 2012-11-04 00:07:18 +0000 | [diff] [blame^] | 16 | * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, |
| 17 | * Boston, MA 02110-1301, USA. |
David Schleef | 1bdd2c9 | 2003-07-02 06:16:39 +0000 | [diff] [blame] | 18 | */ |
| 19 | |
Thomas Vander Stichele | 0b05eee | 2005-11-29 01:30:40 +0000 | [diff] [blame] | 20 | #ifndef __GST_VIDEO_FLIP_H__ |
| 21 | #define __GST_VIDEO_FLIP_H__ |
David Schleef | 1bdd2c9 | 2003-07-02 06:16:39 +0000 | [diff] [blame] | 22 | |
Sebastian Dröge | 8c4aeb2 | 2010-04-18 13:03:48 +0200 | [diff] [blame] | 23 | #include <gst/gst.h> |
Sebastian Dröge | e8ca390 | 2010-04-18 14:29:30 +0200 | [diff] [blame] | 24 | #include <gst/video/video.h> |
Thomas Vander Stichele | 01f2c2f | 2005-11-29 10:46:00 +0000 | [diff] [blame] | 25 | #include <gst/video/gstvideofilter.h> |
David Schleef | 1bdd2c9 | 2003-07-02 06:16:39 +0000 | [diff] [blame] | 26 | |
Johan Dahlin | 5acffea | 2004-03-15 16:32:54 +0000 | [diff] [blame] | 27 | G_BEGIN_DECLS |
| 28 | |
Wim Taymans | e85d163 | 2006-03-03 14:39:55 +0000 | [diff] [blame] | 29 | /** |
| 30 | * GstVideoFlipMethod: |
| 31 | * @GST_VIDEO_FLIP_METHOD_IDENTITY: Identity (no rotation) |
| 32 | * @GST_VIDEO_FLIP_METHOD_90R: Rotate clockwise 90 degrees |
| 33 | * @GST_VIDEO_FLIP_METHOD_180: Rotate 180 degrees |
| 34 | * @GST_VIDEO_FLIP_METHOD_90L: Rotate counter-clockwise 90 degrees |
| 35 | * @GST_VIDEO_FLIP_METHOD_HORIZ: Flip horizontally |
| 36 | * @GST_VIDEO_FLIP_METHOD_VERT: Flip vertically |
| 37 | * @GST_VIDEO_FLIP_METHOD_TRANS: Flip across upper left/lower right diagonal |
| 38 | * @GST_VIDEO_FLIP_METHOD_OTHER: Flip across upper right/lower left diagonal |
| 39 | * |
| 40 | * The different flip methods. |
| 41 | */ |
Johan Dahlin | 5acffea | 2004-03-15 16:32:54 +0000 | [diff] [blame] | 42 | typedef enum { |
Thomas Vander Stichele | 0b05eee | 2005-11-29 01:30:40 +0000 | [diff] [blame] | 43 | GST_VIDEO_FLIP_METHOD_IDENTITY, |
| 44 | GST_VIDEO_FLIP_METHOD_90R, |
| 45 | GST_VIDEO_FLIP_METHOD_180, |
| 46 | GST_VIDEO_FLIP_METHOD_90L, |
| 47 | GST_VIDEO_FLIP_METHOD_HORIZ, |
| 48 | GST_VIDEO_FLIP_METHOD_VERT, |
| 49 | GST_VIDEO_FLIP_METHOD_TRANS, |
| 50 | GST_VIDEO_FLIP_METHOD_OTHER |
| 51 | } GstVideoFlipMethod; |
David Schleef | e22a782 | 2003-07-02 06:50:32 +0000 | [diff] [blame] | 52 | |
Thomas Vander Stichele | 0b05eee | 2005-11-29 01:30:40 +0000 | [diff] [blame] | 53 | #define GST_TYPE_VIDEO_FLIP \ |
| 54 | (gst_video_flip_get_type()) |
| 55 | #define GST_VIDEO_FLIP(obj) \ |
| 56 | (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_VIDEO_FLIP,GstVideoFlip)) |
| 57 | #define GST_VIDEO_FLIP_CLASS(klass) \ |
| 58 | (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_VIDEO_FLIP,GstVideoFlipClass)) |
| 59 | #define GST_IS_VIDEO_FLIP(obj) \ |
| 60 | (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_VIDEO_FLIP)) |
Stefan Kost | 1def669 | 2006-06-01 21:07:26 +0000 | [diff] [blame] | 61 | #define GST_IS_VIDEO_FLIP_CLASS(klass) \ |
Thomas Vander Stichele | 0b05eee | 2005-11-29 01:30:40 +0000 | [diff] [blame] | 62 | (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_VIDEO_FLIP)) |
David Schleef | 1bdd2c9 | 2003-07-02 06:16:39 +0000 | [diff] [blame] | 63 | |
Thomas Vander Stichele | 0b05eee | 2005-11-29 01:30:40 +0000 | [diff] [blame] | 64 | typedef struct _GstVideoFlip GstVideoFlip; |
| 65 | typedef struct _GstVideoFlipClass GstVideoFlipClass; |
David Schleef | 1bdd2c9 | 2003-07-02 06:16:39 +0000 | [diff] [blame] | 66 | |
Wim Taymans | e85d163 | 2006-03-03 14:39:55 +0000 | [diff] [blame] | 67 | /** |
| 68 | * GstVideoFlip: |
| 69 | * |
| 70 | * Opaque datastructure. |
| 71 | */ |
Thomas Vander Stichele | 0b05eee | 2005-11-29 01:30:40 +0000 | [diff] [blame] | 72 | struct _GstVideoFlip { |
Thomas Vander Stichele | 4ad25ff | 2005-11-30 08:26:47 +0000 | [diff] [blame] | 73 | GstVideoFilter videofilter; |
Wim Taymans | 2214657 | 2011-12-21 23:51:03 +0100 | [diff] [blame] | 74 | |
Sebastian Dröge | 8c4aeb2 | 2010-04-18 13:03:48 +0200 | [diff] [blame] | 75 | /* < private > */ |
Thomas Vander Stichele | 0b05eee | 2005-11-29 01:30:40 +0000 | [diff] [blame] | 76 | GstVideoFlipMethod method; |
Wim Taymans | ead60ad | 2011-06-28 14:03:43 +0200 | [diff] [blame] | 77 | void (*process) (GstVideoFlip *videoflip, GstVideoFrame *dest, const GstVideoFrame *src); |
David Schleef | 1bdd2c9 | 2003-07-02 06:16:39 +0000 | [diff] [blame] | 78 | }; |
| 79 | |
Thomas Vander Stichele | 0b05eee | 2005-11-29 01:30:40 +0000 | [diff] [blame] | 80 | struct _GstVideoFlipClass { |
Thomas Vander Stichele | 4ad25ff | 2005-11-30 08:26:47 +0000 | [diff] [blame] | 81 | GstVideoFilterClass parent_class; |
David Schleef | 1bdd2c9 | 2003-07-02 06:16:39 +0000 | [diff] [blame] | 82 | }; |
| 83 | |
Thomas Vander Stichele | 4ad25ff | 2005-11-30 08:26:47 +0000 | [diff] [blame] | 84 | GType gst_video_flip_get_type (void); |
David Schleef | 1bdd2c9 | 2003-07-02 06:16:39 +0000 | [diff] [blame] | 85 | |
| 86 | G_END_DECLS |
Johan Dahlin | 5acffea | 2004-03-15 16:32:54 +0000 | [diff] [blame] | 87 | |
Thomas Vander Stichele | 0b05eee | 2005-11-29 01:30:40 +0000 | [diff] [blame] | 88 | #endif /* __GST_VIDEO_FLIP_H__ */ |