QWebKit, Qt 5.0.2, videos.
-
I have no idea how to include any video into pages that are shown by QWebView. Neither HTML5-video tag (with any codec) nor Flash-player doesn't work. I've read that it can't play HTML5 video (I've found also kind of a patch, but it doesn't want to compile anyway). But what is wrong with Flash? I try to play it with the following code.
@QString _client = "http://www.chemgapedia.de/vsengine/info/en/help/requirements/flash.html";
ui->_client->settings()->setAttribute(QWebSettings::PluginsEnabled, true);
ui->_client->settings()->setAttribute(QWebSettings::DeveloperExtrasEnabled, true);
ui->_client->setUrl(QUrl(_client));@
Who can help? Most likely if there is some way to make HTML5-video work. -
Maybe your flash.html have problems.
Please check this example:
@import sys
from PySide import QtGui, QtWebKit
TESTURL = "http://camendesign.com/code/video_for_everybody/test.html"
app = QtGui.QApplication(sys.argv)
QtWebKit.QWebSettings.globalSettings().setAttribute(
QtWebKit.QWebSettings.PluginsEnabled, True)
view = QtWebKit.QWebView()
url = sys.argv[1] if len(sys.argv) > 1 else TESTURL
view.load(url)
view.show()
app.exec_()@You can find more about this here:
"http://blog.enthought.com/open-source/fun-with-qtwebkit-html5-video/":http://blog.enthought.com/open-source/fun-with-qtwebkit-html5-video/ -
bq. http://blog.enthought.com/open-source/fun-with-qtwebkit-html5-video/ [blog.enthought.com]
Is this tutorial for qt5? I thought it's for previous versions, 'cause qt-mobility doesn't want to be compiled (it wants QtMultimediaKit, which is part of previous ones).
And can you provide the following code for c++/Qt, not for python.
-
Can you check this link:
"http://qt-project.org/videos/watch/html5-in-qtwebkit":http://qt-project.org/videos/watch/html5-in-qtwebkitTell me if helps, otherwise I can assist you to show a html5 file with video working
-
Hm... I've watched it. Yes, he shows that he use some videos on HTML5. But I didn't understand if it is under QtWebKit. Anyway, there is no any explanation how to do such in things in this video.
-
Yes it's inside QtWebKit.
-
Then why it works on his presentation and doesn't work on mine?
-
Or then.... In other words. What steps should I do to insert working HTML5-video and(!) Flash-video. (I need both but I have nothing actually). What steps? I thought it must work out of box.
-
i have written the QWebview application used to display the video when i run it in the development system it works fine but when i move it to different CLEAN system it only plays audio but it dont show the video,
QWeview is loading the url from the server which consist the html video tag through which i am loading the video