From e81b2d30bed8396be1cb2ceeb0c2a166abbf418c Mon Sep 17 00:00:00 2001 From: Fraxinas Date: Wed, 26 May 2010 16:45:23 +0200 Subject: [PATCH] =?utf8?q?experimentally=20implement=20vobsub=20display=20?= =?utf8?q?(fixes=20=C3#537,=20requires=20gst-plugin-dvdsub)?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- lib/service/servicemp3.h | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/lib/service/servicemp3.h b/lib/service/servicemp3.h index 56a068b9..d38dbb84 100644 --- a/lib/service/servicemp3.h +++ b/lib/service/servicemp3.h @@ -47,9 +47,15 @@ public: typedef struct _GstElement GstElement; typedef enum { atUnknown, atMPEG, atMP3, atAC3, atDTS, atAAC, atPCM, atOGG, atFLAC } audiotype_t; -typedef enum { stPlainText, stSSA, stSRT } subtype_t; +typedef enum { stUnknown, stPlainText, stSSA, stSRT, stVOB } subtype_t; typedef enum { ctNone, ctMPEGTS, ctMPEGPS, ctMKV, ctAVI, ctMP4, ctVCD, ctCDA } containertype_t; +struct SubtitlePage +{ + ePangoSubtitlePage *pango_page; + eVobSubtitlePage *vob_page; +}; + class eServiceMP3: public iPlayableService, public iPauseableService, public iServiceInformation, public iSeekableService, public iAudioTrackSelection, public iAudioChannelSelection, public iSubtitleOutput, public iStreamedService, public iAudioDelay, public Object @@ -198,6 +204,7 @@ private: }; int m_state; GstElement *m_gst_playbin; + GstElement *m_gst_subtitlebin; GstTagList *m_stream_tags; eFixedMessagePump m_pump; std::string m_error_message; @@ -206,10 +213,11 @@ private: void gstBusCall(GstBus *bus, GstMessage *msg); static GstBusSyncReply gstBusSyncHandler(GstBus *bus, GstMessage *message, gpointer user_data); static void gstCBsubtitleAvail(GstElement *element, gpointer user_data); + static void gstCBsubtitleCAPS(GObject *obj, GParamSpec *pspec, gpointer user_data); GstPad* gstCreateSubtitleSink(eServiceMP3* _this, subtype_t type); void gstPoll(const int&); - std::list m_subtitle_pages; + std::list m_subtitle_pages; ePtr m_subtitle_sync_timer; void pushSubtitles(); void pullSubtitle(); -- 2.30.2