mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-25 03:01:03 +00:00
87aed1a256
Original commit message from CVS: * gst/avi/gstavisubtitle.c: (src_template), (gst_avi_subtitle_extract_utf8_file), (gst_avi_subtitle_parse_gab2_chunk), (gst_avi_subtitle_chain), (gst_avi_subtitle_base_init), (gst_avi_subtitle_class_init), (gst_avi_subtitle_init), (gst_avi_subtitle_change_state): * gst/avi/gstavisubtitle.h: Refactor a bit; fix name extraction; don't assume all the data in the chunk is actually subtitle data, there may be padding at the end; fix GST_ELEMENT_ERROR usage; store extracted subtitle file so it's there to send again after a seek (for future use).
39 lines
1.1 KiB
C
39 lines
1.1 KiB
C
|
|
#ifndef __GSTAVISUBTITLE_H__
|
|
#define __GSTAVISUBTITLE_H__
|
|
|
|
#include <glib.h>
|
|
#include <glib-object.h>
|
|
#include <gst/gst.h>
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
typedef struct _GstAviSubtitle GstAviSubtitle;
|
|
typedef struct _GstAviSubtitleClass GstAviSubtitleClass;
|
|
|
|
#define GST_TYPE_AVI_SUBTITLE (gst_avi_subtitle_get_type ())
|
|
#define GST_AVI_SUBTITLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_AVI_SUBTITLE, GstAviSubtitle))
|
|
#define GST_AVI_SUBTITLE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_AVI_SUBTITLE, GstAviSubtitleClass))
|
|
#define IS_GST_AVI_SUBTITLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_AVI_SUBTITLE))
|
|
#define IS_GST_AVI_SUBTITLE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_AVI_SUBTITLE))
|
|
#define GST_AVI_SUBTITLE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_AVI_SUBTITLE, GstAviSubtitleClass))
|
|
|
|
GType gst_avi_subtitle_get_type (void);
|
|
|
|
struct _GstAviSubtitle
|
|
{
|
|
GstElement parent;
|
|
|
|
GstPad *src;
|
|
GstPad *sink;
|
|
|
|
GstBuffer *subfile; /* the complete subtitle file in one buffer */
|
|
};
|
|
|
|
struct _GstAviSubtitleClass
|
|
{
|
|
GstElementClass parent;
|
|
};
|
|
|
|
G_END_DECLS
|
|
#endif
|