diff options
author | phintuka <phintuka> | 2006-08-16 13:18:42 +0000 |
---|---|---|
committer | phintuka <phintuka> | 2006-08-16 13:18:42 +0000 |
commit | 71b20faaebe29552b368aeebaf48dbc6311609ef (patch) | |
tree | dcc5733d587aa5e5fcb1df0d0407273224028f3d | |
parent | 4f796145cbfdb5509f033a850b32623cc3134278 (diff) | |
download | xineliboutput-71b20faaebe29552b368aeebaf48dbc6311609ef.tar.gz xineliboutput-71b20faaebe29552b368aeebaf48dbc6311609ef.tar.bz2 |
Fixed EndOfStreamReached when there is local frontend and remote frontend server without clients
ePlayMode GetPlayMode(void) added
If playMode is pmAudioOnlyBlack, video is discarded
-rw-r--r-- | device.c | 14 | ||||
-rw-r--r-- | device.h | 6 |
2 files changed, 17 insertions, 3 deletions
@@ -4,7 +4,7 @@ * See the main source file 'xineliboutput.c' for copyright information and * how to reach the author. * - * $Id: device.c,v 1.7 2006-08-07 18:20:43 phintuka Exp $ + * $Id: device.c,v 1.8 2006-08-16 13:18:42 phintuka Exp $ * */ @@ -615,8 +615,17 @@ int cXinelibDevice::PlayFileCtrl(const char *Cmd) bool cXinelibDevice::EndOfStreamReached(void) { +#if 1 + if(m_local && !m_local->EndOfStreamReached()) + return false; + if(m_server && !m_server->EndOfStreamReached()) + return false; + return true; +#else + // problem when local frontend and remote server with no clients return (((!m_server) || m_server->EndOfStreamReached()) && ((!m_local) || m_local->EndOfStreamReached())); +#endif } bool cXinelibDevice::PlayFile(const char *FileName, int Position, bool LoopPlay) @@ -721,6 +730,9 @@ int cXinelibDevice::PlayVideo(const uchar *buf, int length) { TRACEF("cXinelibDevice::PlayVideo"); + if(playMode == pmAudioOnlyBlack) + return length; + if(m_RadioStream) { m_RadioStream = false; m_AudioCount = 0; @@ -4,7 +4,7 @@ * See the main source file 'xineliboutput.c' for copyright information and * how to reach the author. * - * $Id: device.h,v 1.5 2006-08-07 18:20:43 phintuka Exp $ + * $Id: device.h,v 1.6 2006-08-16 13:18:42 phintuka Exp $ * */ @@ -148,9 +148,11 @@ class cXinelibDevice : public cDevice bool HasDvdSpuTrack(int Type) const; #endif + virtual bool SetPlayMode(ePlayMode PlayMode); + ePlayMode GetPlayMode(void) const { return playMode; }; + protected: ePlayMode playMode; - virtual bool SetPlayMode(ePlayMode PlayMode); cList<cXinelibThread> m_clients; cXinelibThread *m_server; |