2 * Copyright (C) <2002> David A. Schleef <ds@schleef.org>
3 * Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu>
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Library General Public License for more details.
15 * You should have received a copy of the GNU Library General Public
16 * License along with this library; if not, write to the
17 * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
18 * Boston, MA 02110-1301, USA.
21 #ifndef __GST_SUBPARSE_H__
22 #define __GST_SUBPARSE_H__
25 #include <gst/base/gstadapter.h>
27 #include "gstsubparseelements.h"
31 #define GST_TYPE_SUBPARSE (gst_sub_parse_get_type ())
32 G_DECLARE_FINAL_TYPE (GstSubParse, gst_sub_parse, GST, SUBPARSE, GstElement)
40 guint64 max_duration; /* to clamp duration, 0 = no limit (used by tmplayer parser) */
43 gboolean have_internal_fps; /* If TRUE don't overwrite fps by property */
44 gint fps_n, fps_d; /* used by frame based parsers */
45 guint8 line_position; /* percent value */
46 gint line_number; /* line number, can be positive or negative */
47 guint8 text_position; /* percent value */
48 guint8 text_size; /* percent value */
49 gchar *vertical; /* "", "vertical", "vertical-lr" */
50 gchar *alignment; /* "", "start", "middle", "end" */
51 gconstpointer allowed_tags; /* list of markup tags allowed in the cue text. */
52 gboolean allows_tag_attributes;
53 #ifdef TIZEN_FEATURE_SUBPARSE_MODIFICATION
55 gchar* current_language;
56 gboolean langlist_msg_posted;
58 #ifdef TIZEN_FEATURE_HLS_WEBVTT
62 #ifdef TIZEN_FEATURE_SUBPARSE_DROP_OUT_OF_SEGMENT
63 gboolean drop_out_of_segment;
67 typedef gchar* (*Parser) (ParserState *state, const gchar *line);
72 GstPad *sinkpad,*srcpad;
74 /* contains the input in the input encoding */
76 /* contains the UTF-8 decoded input */
79 GstSubParseFormat parser_type;
80 gboolean parser_detected;
81 const gchar *subtitle_codec;
91 gboolean need_segment;
95 gchar *detected_encoding;
97 gboolean strip_pango_markup;
99 gboolean first_buffer;
101 /* used by frame based parsers */
103 #ifdef TIZEN_FEATURE_SUBPARSE_MODIFICATION
110 #endif /* __GST_SUBPARSE_H__ */