Hi,
This is my first try with Phonon ... so be patient
I wrote this code:
#include <QApplication>
#include <QBoxLayout>
#include <QWidget>
#include <QUrl>
#include <Phonon>
int main(int argc, char *argv[]){
app.setApplicationName("myApp");
Phonon::VideoPlayer *myPlayer= new Phonon::VideoPlayer(Phonon::VideoCategory, video);
layout->addWidget(myPlayer);
window->setLayout(layout);
QUrl url
("http://www.youtube.com/watch?v=p916yeFa2Xk");
myPlayer->play(url);
window->show();
return app.exec();
}
#include <QApplication>
#include <QBoxLayout>
#include <QWidget>
#include <QUrl>
#include <Phonon>
int main(int argc, char *argv[]){
QApplication app(argc, argv);
app.setApplicationName("myApp");
QWidget *window = new QWidget;
QWidget *video = new QWidget;
Phonon::VideoPlayer *myPlayer= new Phonon::VideoPlayer(Phonon::VideoCategory, video);
QVBoxLayout *layout = new QVBoxLayout;
layout->addWidget(myPlayer);
window->setLayout(layout);
QUrl url("http://www.youtube.com/watch?v=p916yeFa2Xk");
myPlayer->play(url);
window->show();
return app.exec();
}
To copy to clipboard, switch view to plain text mode
What's missing so that i can watch this beautiful video?
Thanks
Bookmarks