Dear all: I'm learning to use the Phonon in QT, followed up some examples in the help document to setup one VideoPlayer, but when running this programe, it always crashed, the example is so simple I don't known where is wrong. #include <QtCore> #include <QtGui> #include <phonon>
int main(int argc, char *argv[]) { QApplication app(argc, argv); QWidget *widget = new QWidget; widget->setWindowTitle("Video Player"); widget->resize(400,400); QString fileName = QFileDialog::getOpenFileName(0, ("Open videos"), "e:\\usr", ("All Files (*.*)")); Phonon::VideoPlayer *player = new Phonon::VideoPlayer(Phonon::VideoCategory, widget); player->load(Phonon::MediaSource(fileName)); player->play(); widget->show(); return app.exec(); } Anyone can give me a hand? The example is runned under Windows XP. _______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest