Author: dmeyer
Date: Thu Nov 2 16:21:49 2006
New Revision: 1961
Modified:
trunk/popcorn/src/backends/xine/child.py
Log:
detect if all parts of the stream are handled
Modified: trunk/popcorn/src/backends/xine/child.py
==============================================================================
--- trunk/popcorn/src/backends/xine/child.py (original)
+++ trunk/popcorn/src/backends/xine/child.py Thu Nov 2 16:21:49 2006
@@ -49,6 +49,19 @@
self._xine.set_config_value("effects.goom.csc_method", "Slow but looks
better")
+ def _check_stream_handles(self):
+ """
+ Check if stream is ok.
+ """
+ v_unhandled = self._stream.get_info(xine.STREAM_INFO_HAS_VIDEO) and \
+ not self._stream.get_info(xine.STREAM_INFO_IGNORE_VIDEO) and \
+ not self._stream.get_info(xine.STREAM_INFO_VIDEO_HANDLED)
+ a_unhandled = self._stream.get_info(xine.STREAM_INFO_HAS_AUDIO) and \
+ not self._stream.get_info(xine.STREAM_INFO_IGNORE_AUDIO) and \
+ not self._stream.get_info(xine.STREAM_INFO_AUDIO_HANDLED)
+ return not (v_unhandled or a_unhandled)
+
+
def _status_output(self):
"""
Outputs stream status information.
@@ -234,6 +247,10 @@
self.parent.set_stream_info(False, self._stream.get_error())
print "Open failed:", self._stream.get_error()
return
+ if not self._check_stream_handles():
+ self.parent.set_stream_info(False, None)
+ print "unable to play stream"
+ return
self.parent.set_stream_info(True, self._get_stream_info())
self._status.start(0.001)
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Freevo-cvslog mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog