<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
<div class="moz-text-flowed" style="font-family: -moz-fixed;
font-size: 12px;" lang="x-western">Here is s small example which
worked in PyQt 4.7.x
<br>
<br>
import sys
<br>
from PyQt4 import QtGui
<br>
from PyQt4 import QtCore
<br>
<br>
<br>
from PyQt4.phonon import Phonon
<br>
<br>
<br>
class MainWindow(QtGui.QMainWindow):
<br>
def __init__(self):
<br>
QtGui.QMainWindow.__init__(self)
<br>
self.verticalLayout = QtGui.QVBoxLayout()
<br>
self.videoPlayer =
Phonon.VideoPlayer(Phonon.VideoCategory)
<br>
self.connect(self.videoPlayer,
QtCore.SIGNAL("finished()"), self.videoPlayer,
QtCore.SLOT("deleteLater()"));
<br>
self.verticalLayout.addWidget(self.videoPlayer)
<br>
self.videoPlayer.play(Phonon.MediaSource("grattgratt.mpg"))
<br>
<br>
<br>
if __name__ == '__main__':
<br>
app = QtGui.QApplication(sys.argv)
<br>
app.setApplicationName("Phonvideo")
<br>
window = MainWindow()
<br>
window.show()
<br>
sys.exit(app.exec_())
<br>
<br>
Seems to be a windows issue. I get:
<br>
<br>
WARNING: Phonon::createPath: Cannot connect Phonon::MediaObject (
no
<br>
objectName ) to Phonon::VideoWidget ( no objectName ).
<br>
<br>
<br>
<br>
Could be this bug:
<br>
<a class="moz-txt-link-freetext"
href="http://bugreports.qt.nokia.com/browse/QTBUG-13062">http://bugreports.qt.nokia.com/browse/QTBUG-13062</a>
<br>
Can somebody confirm?
<br>
Did somebody experience similar problems?
<br>
<br>
Regards
<br>
<br>
Sebastian
<br>
<br>
On 11/25/2010 09:04 PM, Hans-Peter Jansen wrote:
<br>
<blockquote type="cite" style="color: rgb(0, 0, 0);">On Thursday
25 November 2010, 14:17:55 Sebastian Elsner wrote:
<br>
<blockquote type="cite" style="color: rgb(0, 0, 0);">Hello,
<br>
<br>
switching to 4.8.1 gave me this error:
<br>
<br>
WARNING: Phonon::createPath: Cannot connect
Phonon::MediaObject ( no
<br>
objectName ) to Phonon::VideoWidget ( no objectName ).
<br>
<br>
The VideoPlayer worked well in previous versions without any
errors?
<br>
i tried to track it down, but had no luck. Could it be a bug
<br>
introduced on Qt 4.7?
<br>
</blockquote>
The usual "please provide a minimum runnable example" applies
here too..
<br>
<br>
Pete
<br>
_______________________________________________
<br>
PyQt mailing list <a class="moz-txt-link-abbreviated"
href="mailto:PyQt@riverbankcomputing.com">PyQt@riverbankcomputing.com</a>
<br>
<a class="moz-txt-link-freetext"
href="http://www.riverbankcomputing.com/mailman/listinfo/pyqt">http://www.riverbankcomputing.com/mailman/listinfo/pyqt</a>
<br>
</blockquote>
<br>
</div>
</body>
</html>