Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QWebKit and Video Cross Platform
Qt 6.11 is out! See what's new in the release blog

QWebKit and Video Cross Platform

Scheduled Pinned Locked Moved General and Desktop
8 Posts 4 Posters 5.6k 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.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    Hi there,

    i was just developing a project with QWebKit, it needs the html 5 video tag.

    I was developing on Linux and it worked (although i never actually played a video, but the video player controls show up).

    Now compiling first time on Windows (Qt 4.8/QtCreator 2.4.1), there is no support for the video tag... I thought QT was cross platform.

    Is there a way to get the video tag on Windows to run?

    Anyone tried it on mac yet?

    1 Reply Last reply
    0
    • L Offline
      L Offline
      leon.anavi
      wrote on last edited by
      #2

      Check which version of the Web Kit are you using on Windows. According to the official announcement I think that the video tag may be working on "web kit version 2.2":http://trac.webkit.org/wiki/QtWebKitFeatures22

      http://anavi.org/

      1 Reply Last reply
      0
      • ? Offline
        ? Offline
        A Former User
        wrote on last edited by
        #3

        Hm, this site says QtWebKit 2.2 is part of Qt 4.8, which i have installed. Does Qt deliver its own WebKit or does it use some system wide installation (which i don't remind installing).

        1 Reply Last reply
        0
        • L Offline
          L Offline
          leon.anavi
          wrote on last edited by
          #4

          [quote author="hellagot" date="1328347988"]Hm, this site says QtWebKit 2.2 is part of Qt 4.8, which i have installed. Does Qt deliver its own WebKit or does it use some system wide installation (which i don't remind installing).[/quote]

          I made a quick Google research and it seems that other people are experiencing the same issues with video like you but I haven't seen a solution yet :( :
          "QtWebKit 2.2 (from Qt 4.8 RC1) supports less than QtWebKit 2.0.2 (from Qt 4.7.4), test on html5test.com":http://developer.qt.nokia.com/forums/viewthread/11865
          "QtWebKit playing HTML5 video without installing flash player":http://stackoverflow.com/questions/8650119/qtwebkit-playing-html5-video-without-installing-flash-player

          http://anavi.org/

          1 Reply Last reply
          0
          • ? Offline
            ? Offline
            A Former User
            wrote on last edited by
            #5

            Did anything change in regards to this? I tried html5 video tag by creating new html5 application with default html page that I modified by adding video tag. It works on Mac but not on Windows. Anyone? Any workarounds for Windows?

            @<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
            <html xml:lang="en">
            <head>
            <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
            <style type="text/css">
            body { margin: 0; font-size: 2em; background-color: white; }
            h1 { text-align: center; color: red; }
            h1 + h1 { color: green; }
            h1:last-child { color: blue; }
            #quit { background-color: gray; color: white; font-weight: bold; display: block; text-align: right; }
            </style>
            [removed]
            var counter = 0;
            function toggleElement()
            {
            var elements = document.getElementsByTagName('h1');
            for (var i = 0; i < elements.length; ++i)
            elements[i].style.display = (counter % elements.length) == i ? '' : 'none';
            counter++;
            setTimeout('toggleElement()', 1000);
            }
            window.onload = function()
            {
            document.getElementById("quit").onmousedown = function()
            {
            Qt.quit();
            };
            toggleElement();
            }
            [removed]
            </head>
            <body>
            <a id="quit">X</a>
            <h1>Hello</h1>
            <h1>HTML5</h1>
            <h1>World</h1>

                &lt;video width="320" height="240" controls&gt;
                  <source src="http://www.w3schools.com/html/movie.mp4" type="video/mp4">
                  &lt;!--source src="http://www.w3schools.com/html/movie.ogg" type="video/ogg">
                  <source src="twnactive.mov" type="video/quicktime"--&gt;
                Your browser does not support the video tag.
                &lt;/video&gt;
            
            &lt;/body&gt;
            

            </html>
            @

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

              I've written a blog post about how I've solved this issue for 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/

              1 Reply Last reply
              0
              • L Offline
                L Offline
                leon.anavi
                wrote on last edited by
                #7

                [quote author="RobinD42" date="1364852920"]I've written a blog post about how I've solved this issue for 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/[/quote]

                Great, thank you for sharing the solution. Why don't you create a brief article at "Qt Project's wiki":http://qt-project.org/wiki/ based on your blog post?

                http://anavi.org/

                1 Reply Last reply
                0
                • ? Offline
                  ? Offline
                  A Former User
                  wrote on last edited by
                  #8

                  Hat down, Robin. So much work around it ... it should be really simple.

                  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