| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
#ifndef __GST_MPEGVIDEO_PARSE_H__ |
| 26 |
#define __GST_MPEGVIDEO_PARSE_H__ |
| 27 |
|
| 28 |
#include <gst/gst.h> |
| 29 |
#include <gst/base/gstbaseparse.h> |
| 30 |
#include "gstvideoparseutils.h" |
| 31 |
#include <gst/codecparsers/gstmpegvideoparser.h> |
| 32 |
|
| 33 |
G_BEGIN_DECLS |
| 34 |
|
| 35 |
#define GST_TYPE_MPEGVIDEO_PARSE (gst_mpegv_parse_get_type()) |
| 36 |
#define GST_MPEGVIDEO_PARSE(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),\ |
| 37 |
GST_TYPE_MPEGVIDEO_PARSE, GstMpegvParse)) |
| 38 |
#define GST_MPEGVIDEO_PARSE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),\ |
| 39 |
GST_TYPE_MPEGVIDEO_PARSE, GstMpegvParseClass)) |
| 40 |
#define GST_MPEGVIDEO_PARSE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj),\ |
| 41 |
GST_TYPE_MPEGVIDEO_PARSE, GstMpegvParseClass)) |
| 42 |
#define GST_IS_MPEGVIDEO_PARSE(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),\ |
| 43 |
GST_TYPE_MPEGVIDEO_PARSE)) |
| 44 |
#define GST_IS_MPEGVIDEO_PARSE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),\ |
| 45 |
GST_TYPE_MPEGVIDEO_PARSE)) |
| 46 |
|
| 47 |
typedef struct _GstMpegvParse GstMpegvParse; |
| 48 |
typedef struct _GstMpegvParseClass GstMpegvParseClass; |
| 49 |
|
| 50 |
|
| 51 |
enum { |
| 52 |
FLAG_NONE = 0, |
| 53 |
FLAG_MPEG2 = 1, |
| 54 |
FLAG_SEQUENCE_EXT = 2, |
| 55 |
FLAG_SEQUENCE_DISPLAY_EXT = 4 |
| 56 |
}; |
| 57 |
|
| 58 |
struct _GstMpegvParse { |
| 59 |
GstBaseParse element; |
| 60 |
|
| 61 |
|
| 62 |
gint ext_offsets[10]; |
| 63 |
gint ext_count; |
| 64 |
gint last_sc; |
| 65 |
gint seq_offset; |
| 66 |
gint seq_size; |
| 67 |
gint pic_offset; |
| 68 |
guint slice_count; |
| 69 |
guint slice_offset; |
| 70 |
gboolean update_caps; |
| 71 |
gboolean send_codec_tag; |
| 72 |
gboolean send_mpeg_meta; |
| 73 |
|
| 74 |
GstBuffer *config; |
| 75 |
guint8 profile; |
| 76 |
guint config_flags; |
| 77 |
GstMpegVideoSequenceHdr sequencehdr; |
| 78 |
GstMpegVideoSequenceExt sequenceext; |
| 79 |
GstMpegVideoSequenceDisplayExt sequencedispext; |
| 80 |
GstMpegVideoPictureHdr pichdr; |
| 81 |
GstMpegVideoPictureExt picext; |
| 82 |
GstMpegVideoQuantMatrixExt quantmatrext; |
| 83 |
|
| 84 |
gboolean seqhdr_updated; |
| 85 |
gboolean seqext_updated; |
| 86 |
gboolean seqdispext_updated; |
| 87 |
gboolean picext_updated; |
| 88 |
gboolean quantmatrext_updated; |
| 89 |
|
| 90 |
GstVideoParseUserData user_data; |
| 91 |
|
| 92 |
|
| 93 |
gboolean drop; |
| 94 |
gboolean gop_split; |
| 95 |
|
| 96 |
int fps_num; |
| 97 |
int fps_den; |
| 98 |
int frame_repeat_count; |
| 99 |
}; |
| 100 |
|
| 101 |
struct _GstMpegvParseClass { |
| 102 |
GstBaseParseClass parent_class; |
| 103 |
}; |
| 104 |
|
| 105 |
GType gst_mpegv_parse_get_type (void); |
| 106 |
|
| 107 |
G_END_DECLS |
| 108 |
|
| 109 |
#endif |