Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt WebKit
  4. Does QtWebkit 2.2.1 fix the HTML5 media support problem?
Forum Updated to NodeBB v4.3 + New Features

Does QtWebkit 2.2.1 fix the HTML5 media support problem?

Scheduled Pinned Locked Moved Qt WebKit
13 Posts 6 Posters 13.8k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    AllenYC
    wrote on last edited by
    #1

    Has the latest Qt libraries 4.8.0 release fixed the HTML5 video and audio support problem as described in http://developer.qt.nokia.com/forums/viewthread/11865/
    yet ?

    I installed the “Qt libraries 4.8.0 for Windows (VS 2010, 275 MB)” and launched fancyBrowser demo. The html5test.com still shows 0 score for both video and audio support. Youtube asked me to install flash to play the video.

    If this works, should I expect to play youtube video without installing flash player?

    Thanks.

    1 Reply Last reply
    0
    • X Offline
      X Offline
      xulinguestc
      wrote on last edited by
      #2

      I face up this problem too, does anyone know how to make it support video tag?

      1 Reply Last reply
      0
      • L Offline
        L Offline
        LeoTseng
        wrote on last edited by
        #3

        Our team & I have figured out the way of how to play a html5 file containing video tag, hopefully by following these detailed steps can solve your problem.

        1. Download "qt-everywhere-opensource-src-4.8.1.zip" from official website.
        2. Unzip it and then enter the installation location, e.g. C:\Qt\4.8.1
        3. Type "configure -opensource -debug-and-release", "nmake".
          PS. What if there's a error happened in this file, "DefaultLocalizationStrategy.cpp", just go to the error line and fix it by modifying the capital character error from " to ". (This error will just happen in my XP system, I am not sure whether it will happen in another OS system like win 7.)
        4. Add this value inside the user variable of environment variables, QTDIR, which its value is "C:\Qt\4.8.1", and then append this value into system variable, Path, value is "C:\Qt\4.8.1\bin".
        5. Download "qt-mobility-opensource-src-1.2.0.zip" from official website.
        6. Unzip it and then enter the installation location, e.g. C:\QtMobility
        7. Type "configure -prefix C:\QtMobility -modules sensors" and then "nmake", "nmake install".
        8. Type "configure -prefix C:\QtMobility -modules multimedia" and then "nmake", "nmake install".
        9. Copy the files "QtMultimediaKit1.dll" and "QtSensors1.dll" just were made by step 7 & 8, located at "C:\QtMobility\lib" , into this location "C:\Qt\4.8.1\demos\browser\release".
        10. run browser.exe and throw a html file containing <video> tag of html5 to it. It should play it successfully, by the way, you should be able to see a play/pause button, the seeking bar and audio volume control button, that is because your qtwebkit can recognize the video tag finanlly.
        11. What if it can't be played, maybe your pc hasn't been installed the correct codec well, check your pc whether your pc has been installed the correct codec or not, maybe you cango to the website "http://www.free-codecs.com/" to download a suitable codec for directshow to play.
        1 Reply Last reply
        0
        • H Offline
          H Offline
          hmuelner
          wrote on last edited by
          #4

          This does not work for me. I am using Visual Studio 2010 on Windows7/64. The browser does not try to load QtMultimediaKit1.dll (checked with SysInternal's ProcMon). I have the Qt components on drive D (D:\Qt\4.8.1 and d:\QtMobility).

          Helmut Mülner

          1 Reply Last reply
          0
          • D Offline
            D Offline
            duongnh
            wrote on last edited by
            #5

            Me too, I tried to test HTML5 by use sample [formextractor] in Webkit sample then add
            <video width="400" height="300" controls="controls">
            <source src="myvideo.mp4" type="video/mp4" />
            </video>
            to form.html It is not woking.

            1 Reply Last reply
            0
            • L Offline
              L Offline
              LeoTseng
              wrote on last edited by
              #6

              By my successful example of playing a video tag, just like...

              <video controls>
              <source src="./MyVideo.mp4" type="video/mp4">
              </video>

              PS1. I am using a XP 32-bit system with VS2008 to do these things...
              PS2. If you could see a play button or seeking bar but there's no any video playing, it could be you didn't install a correct codec.

              1 Reply Last reply
              0
              • D Offline
                D Offline
                duongnh
                wrote on last edited by
                #7

                Thank you very much for your replying , LeoTseng
                I tried your suggestion but it is still not working on my environment.
                Nothing is display on executed program.

                PS:

                • I am using The Qt SDK version 1.2.1 released on April 11th
                • Windows 7, VS 2010
                1 Reply Last reply
                0
                • L Offline
                  L Offline
                  LeoTseng
                  wrote on last edited by
                  #8

                  oh...I did not download or install the Qt SDK. Instead, I installed the Qt libraries for Windows (VS2008 version). You mentioned that you're using the platform of Win7, VS2010. I think that would be OK as well, because one of my colleagues is using the same platform like yours to do the same thing. BUT he didn't install Qt SDK but using Qt libraries. (His platform is Win 7 64-bit, VS2010)

                  1 Reply Last reply
                  0
                  • H Offline
                    H Offline
                    hmuelner
                    wrote on last edited by
                    #9

                    One step further for me:

                    I used qt-everywhere-opensource-src-4.8.2.zip, configure and nmake as usual, The I used qt-mobility-opensource-src-1.2.0.zip, configure -prefix D:\QtMobility, nmake , nmake install and added D:\QtMobility\bin and D:\QtMobility\lib to PATH. Then I did another configure and nmake for qt-everywhere-opensource-src-4.8.2. (It may be sufficient to just rebuild webkit.)

                    When I pointed the demos\browser to http://html5test.com a got 326 points + 3 bonus points. The page says: Video 21/31, video element Yes, Subtitle support No, Poster image support Yes, MPEG-4 support No, H.264 support No, Ogg Theora support No, WebM support No; Audio (+1 bonus points ) 20, audio element Yes, PCM audio support No, AAC support No, MP3 support Yes, Ogg Vorbis support No, WebM support No.

                    The missing codec support is surprising, because I had installed DirectShow Filters for WebM, DivX H.264 and Mpeg4.

                    http://www.youtube.com/html5 says that the browser supports the Video tag, h.264 and WebM, but if I join the HMTL5 I cannot play any video.

                    Helmut Mülner

                    1 Reply Last reply
                    0
                    • D Offline
                      D Offline
                      duongnh
                      wrote on last edited by
                      #10

                      Thank you for your information,
                      I do not continue to try using html5 to play video in QtWebkit, now I am using [Phonon multimedia] then embed Phonon media player to QtWebkit, it is working.
                      To do that,
                      I referred to qmediaplayer(example of Qt) and this link
                      http://daniel-albuschat.blogspot.jp/2008/12/embedding-qt-widgets-into-qtwebkit.html

                      1 Reply Last reply
                      0
                      • L Offline
                        L Offline
                        LeoTseng
                        wrote on last edited by
                        #11

                        hmuelner,
                        I got a almost identical result of when I am using qt browser to enter the website you mentioned, even worse than yours... I got 321 points + 3 bonus. And the video score was 21/31, this part was completely identical as you have described. Even though, I can still use a <video> tag to play a webm format movie or mp4 (AVC+AAC format) movie inside the Qt's browser. So I think you don't have to totally trust that score from that website, at least it works to me & my colleague.

                        1 Reply Last reply
                        0
                        • R Offline
                          R Offline
                          RobinD42
                          wrote on last edited by
                          #12

                          Thanks in part to some of the helpful hints on this page I've been able to get HTML5 video working in our project. It involves building Qt + qt-mobility, and also a bug fix in qt-mobility. See http://blog.enthought.com/open-source/fun-with-qtwebkit-html5-video/ for a blog post where I have documented what worked for us.

                          1 Reply Last reply
                          0
                          • H Offline
                            H Offline
                            hmuelner
                            wrote on last edited by
                            #13

                            I followed the instructions on this page and managed to build Qt-4.8.4, QtMobility and QtWebkit on Windows-7 (64) using VS-2010, including the patches for QtMobility and installing lavfilters. The Qt demo browser works with the page http://camendesign.com/code/video_for_everybody/test.html and on http://www.youtube.com/html5, but when I load the page http://html5test.com the browser crashes.

                            With SysInternals' dbgview I see the message: "Qt has caught an exception thrown from an event handler. Throwing exceptions from an event handler is not supported in Qt. You must reimplement QApplication::notify() and catch all exceptions there."

                            Helmut Mülner

                            1 Reply Last reply
                            0

                            • Login

                            • Login or register to search.
                            • First post
                              Last post
                            0
                            • Categories
                            • Recent
                            • Tags
                            • Popular
                            • Users
                            • Groups
                            • Search
                            • Get Qt Extensions
                            • Unsolved