| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
#ifndef __GST_DVDSUBDEC_H__ |
| 21 |
#define __GST_DVDSUBDEC_H__ |
| 22 |
|
| 23 |
#include <gst/gst.h> |
| 24 |
#include <gst/video/video.h> |
| 25 |
|
| 26 |
G_BEGIN_DECLS |
| 27 |
|
| 28 |
#define GST_TYPE_DVD_SUB_DEC (gst_dvd_sub_dec_get_type()) |
| 29 |
#define GST_DVD_SUB_DEC(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_DVD_SUB_DEC,GstDvdSubDec)) |
| 30 |
#define GST_DVD_SUB_DEC_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_DVD_SUB_DEC,GstDvdSubDecClass)) |
| 31 |
#define GST_IS_DVD_SUB_DEC(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_DVD_SUB_DEC)) |
| 32 |
#define GST_IS_DVD_SUB_DEC_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_DVD_SUB_DEC)) |
| 33 |
|
| 34 |
typedef struct _GstDvdSubDec GstDvdSubDec; |
| 35 |
typedef struct _GstDvdSubDecClass GstDvdSubDecClass; |
| 36 |
|
| 37 |
|
| 38 |
typedef struct Color_val |
| 39 |
{ |
| 40 |
guchar Y_R; |
| 41 |
guchar U_G; |
| 42 |
guchar V_B; |
| 43 |
guchar A; |
| 44 |
|
| 45 |
} Color_val; |
| 46 |
|
| 47 |
struct _GstDvdSubDec |
| 48 |
{ |
| 49 |
GstElement element; |
| 50 |
|
| 51 |
GstPad *sinkpad; |
| 52 |
GstPad *srcpad; |
| 53 |
|
| 54 |
gint in_width, in_height; |
| 55 |
|
| 56 |
|
| 57 |
GstBuffer *partialbuf; |
| 58 |
GstMapInfo partialmap; |
| 59 |
gboolean have_title; |
| 60 |
|
| 61 |
guchar subtitle_index[4]; |
| 62 |
guchar menu_index[4]; |
| 63 |
guchar subtitle_alpha[4]; |
| 64 |
guchar menu_alpha[4]; |
| 65 |
|
| 66 |
guint32 current_clut[16]; |
| 67 |
Color_val palette_cache_yuv[4]; |
| 68 |
Color_val hl_palette_cache_yuv[4]; |
| 69 |
|
| 70 |
Color_val palette_cache_rgb[4]; |
| 71 |
Color_val hl_palette_cache_rgb[4]; |
| 72 |
|
| 73 |
GstVideoInfo info; |
| 74 |
gboolean use_ARGB; |
| 75 |
GstClockTime next_ts; |
| 76 |
|
| 77 |
|
| 78 |
|
| 79 |
|
| 80 |
|
| 81 |
guchar *parse_pos; |
| 82 |
|
| 83 |
guint16 packet_size; |
| 84 |
guint16 data_size; |
| 85 |
|
| 86 |
gint offset[2]; |
| 87 |
|
| 88 |
gboolean forced_display; |
| 89 |
gboolean visible; |
| 90 |
|
| 91 |
gint left, top, right, bottom; |
| 92 |
gint hl_left, hl_top, hl_right, hl_bottom; |
| 93 |
|
| 94 |
gint current_button; |
| 95 |
|
| 96 |
GstClockTime next_event_ts; |
| 97 |
|
| 98 |
gboolean buf_dirty; |
| 99 |
}; |
| 100 |
|
| 101 |
struct _GstDvdSubDecClass |
| 102 |
{ |
| 103 |
GstElementClass parent_class; |
| 104 |
}; |
| 105 |
|
| 106 |
GType gst_dvd_sub_dec_get_type (void); |
| 107 |
GST_ELEMENT_REGISTER_DECLARE (dvdsubdec); |
| 108 |
|
| 109 |
G_END_DECLS |
| 110 |
|
| 111 |
#endif |