summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--device.c14
-rw-r--r--device.h6
2 files changed, 17 insertions, 3 deletions
diff --git a/device.c b/device.c
index 482cacfb..41f619cd 100644
--- a/device.c
+++ b/device.c
@@ -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;
diff --git a/device.h b/device.h
index 114c5c9d..7686f15f 100644
--- a/device.h
+++ b/device.h
@@ -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;