X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/80132b0b269cb147e42c61824a73ad70f707acf5..4074b1576f602ba339cd8da4e856316ce372acaa:/lib/dvb/pmt.h diff --git a/lib/dvb/pmt.h b/lib/dvb/pmt.h index 95d3cc43..9e7c5274 100644 --- a/lib/dvb/pmt.h +++ b/lib/dvb/pmt.h @@ -1,6 +1,7 @@ #ifndef __lib_dvb_dvbmid_h #define __lib_dvb_dvbmid_h +#ifndef SWIG #include #include #include @@ -19,7 +20,18 @@ class eDVBCAService; class eDVBScan; +struct channel_data: public Object +{ + ePtr m_channel; + ePtr m_stateChangedConn; + int m_prevChannelState; + int m_dataDemux; +}; + +// TODO .. put all static stuff into a 'eDVBCAServiceHandler class' + typedef std::map CAServiceMap; +typedef std::map ChannelMap; class eDVBCAService: public Object { @@ -35,17 +47,27 @@ class eDVBCAService: public Object void sendCAPMT(); void Connect(); + static void DVBChannelAdded(eDVBChannel*); + static void DVBChannelStateChanged(iDVBChannel*); static CAServiceMap exist; + static ChannelMap exist_channels; + static ePtr m_chanAddedConn; + static channel_data *getChannelData(eDVBChannelID &chid); + eDVBCAService(); ~eDVBCAService(); public: + static void registerChannelCallback(eDVBResourceManager *res_mgr); static RESULT register_service( const eServiceReferenceDVB &ref, int demux_nums[2], eDVBCAService *&caservice ); static RESULT unregister_service( const eServiceReferenceDVB &ref, int demux_nums[2], eTable *ptr ); void buildCAPMT(eTable *ptr); }; +#endif + class eDVBServicePMTHandler: public Object { +#ifndef SWIG friend class eDVBCAService; eServiceReferenceDVB m_reference; ePtr m_service; @@ -79,7 +101,14 @@ class eDVBServicePMTHandler: public Object public: eDVBServicePMTHandler(); ~eDVBServicePMTHandler(); - +#endif + +#ifdef SWIG +private: + eDVBServicePMTHandler(); +public: +#endif + enum { eventNoResources, // a requested resource couldn't be allocated @@ -93,7 +122,7 @@ public: eventSOF, // seek pre start eventEOF, // a file playback did end }; - +#ifndef SWIG Signal1 serviceEvent; struct videoStream @@ -146,12 +175,15 @@ public: { std::vector videoStreams; std::vector audioStreams; + int defaultAudioStream; std::vector subtitleStreams; std::set caids; int pcrPid; int pmtPid; int textPid; bool isCrypted() { return !caids.empty(); } + + PyObject *createPythonObject(); }; int getProgramInfo(struct program &program); @@ -171,6 +203,7 @@ public: private: bool m_have_cached_program; program m_cached_program; +#endif }; #endif