Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. [Solved] I want to run youtube video or embed code in my qml application.
QtWS25 Last Chance

[Solved] I want to run youtube video or embed code in my qml application.

Scheduled Pinned Locked Moved Mobile and Embedded
18 Posts 4 Posters 10.0k Views
  • 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.
  • AlicemirrorA Offline
    AlicemirrorA Offline
    Alicemirror
    wrote on last edited by
    #2

    Try embedding first somethings that you are sure that works with the browser. Thus you reduce the problem complexity and focus the attention to the real problem.

    Enrico Miglino (aka Alicemirror)
    Balearic Dynamics
    Islas Baleares, Ibiza (Spain)
    www.balearicdynamics.com

    1 Reply Last reply
    0
    • D Offline
      D Offline
      DanSiddiqui
      wrote on last edited by
      #3

      My basic Question is why N950's default browser not running youtube videos?

      1 Reply Last reply
      0
      • AlicemirrorA Offline
        AlicemirrorA Offline
        Alicemirror
        wrote on last edited by
        #4

        Hi, I have opened just now for test (I was already sure) http://www.youtube.com and I see any video with the N950 browser. It is possible that you have some problem or some component not installed correctly on your device. As is, it is also possible that your program works but the device not due to this problem. The advice I can give to you is to reset the device and if it already has problems reflast the N950.

        Enrico Miglino (aka Alicemirror)
        Balearic Dynamics
        Islas Baleares, Ibiza (Spain)
        www.balearicdynamics.com

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

          Hi, AFAIK N950 web browser can't handle yet video. When you try to play a video from YouTube, an external player is raised. Web browser is still in a early stage... I read somewhere.

          @Alicemirror: OT: hey ! You look different with your new avatar :-)

          1 Reply Last reply
          0
          • AlicemirrorA Offline
            AlicemirrorA Offline
            Alicemirror
            wrote on last edited by
            #6

            @deimos: the last image was with in a windy day on the reef in Ibiza and the shoot was done by myself. This other is of a couple of days ago, quite in studio at home. And the shoot was done by my wife. Always happy the same :)

            Enrico Miglino (aka Alicemirror)
            Balearic Dynamics
            Islas Baleares, Ibiza (Spain)
            www.balearicdynamics.com

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

              I want to run youtube video or embed code in my qml application, i am developing Qt qml application for N950 meego device.

              1 Reply Last reply
              0
              • EddyE Offline
                EddyE Offline
                Eddy
                wrote on last edited by
                #8

                merged the 2 topics since it's the same question.

                Qt Certified Specialist
                www.edalsolutions.be

                1 Reply Last reply
                0
                • D Offline
                  D Offline
                  DanSiddiqui
                  wrote on last edited by
                  #9

                  any one :( youtube embed code using qt qml for meego N950 device.I wan to develop an application for N950 device will play lots of videos from youtube ,any idea , any suggestion.

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

                    I would like to suggest you to use QtMultimediaKit to play videos. Also take a look at "youtube API":http://code.google.com/apis/youtube/2.0/developers_guide_protocol.html

                    Another thing to take care for youtube, are cookies. Since some time, to get streams to play, youtube wants cookies that are retrieved when a search is made (I don't know, but maybe if you use a developer key, cookies are not needed).

                    1 Reply Last reply
                    0
                    • D Offline
                      D Offline
                      DanSiddiqui
                      wrote on last edited by
                      #11

                      Can QtMultimediaKit (Video or Audio) control play videos from youtube ? or some websource like "http://abc.com/abc.wav" ?

                      1 Reply Last reply
                      0
                      • D Offline
                        D Offline
                        deimos
                        wrote on last edited by
                        #12

                        yes. Look at "here":http://doc.qt.nokia.com/qtmobility-1.2/qml-multimedia.html

                        1 Reply Last reply
                        0
                        • D Offline
                          D Offline
                          DanSiddiqui
                          wrote on last edited by
                          #13

                          Thanks deimos,plz show me the code which play any youtube video using Qt qml or qml Html5 code.

                          1 Reply Last reply
                          0
                          • D Offline
                            D Offline
                            DanSiddiqui
                            wrote on last edited by
                            #14

                            anyone:(

                            1 Reply Last reply
                            0
                            • D Offline
                              D Offline
                              deimos
                              wrote on last edited by
                              #15

                              Hi,

                              sorry for the late, my site get down. I made a software that maybe you will be find interesting for your purpose. The new address is "here":http://marcobavagnoli.wordpress.com
                              but there is not yet the page with N950 port made with c++/QML even if it wont be usefull because the youtube query and video player is made in c++. If you want to try it its available only .deb file for now, "here":http://my-meego.com/software/applications.php?fldAuto=261&faq=9

                              But, playing youtube video, is not so simple like assign to "Video::source" the url of the video. You must first query youtube API for infos about the video you are willing to play (look at my previous post to get the youtube API page). The query will be returned in xml/json format containing all the video infos. Next step will be to assign the right video url address to Video component. That's something all :)

                              In my previous post I told you about cookies. In QML isn't possible yet to pass cookies to Video element. In my app I made my own component subclassing QDeclarativeItem to play video with QMediaPlayer. But I think that with a YouTube developer key it is not needed.

                              hope this helps

                              1 Reply Last reply
                              0
                              • D Offline
                                D Offline
                                deimos
                                wrote on last edited by
                                #16

                                you can take a look also at "cuteTube-QML":http://my-meego.com/software/applications.php?fldAuto=35&faq=2

                                1 Reply Last reply
                                0
                                • D Offline
                                  D Offline
                                  DanSiddiqui
                                  wrote on last edited by
                                  #17

                                  Thanks again deimos, i have dowloaded this cuteTube-QML project,and also deployed it on my N950 device.this application is searching videos from youtube but not playing both in E7 and on N950.

                                  1 Reply Last reply
                                  0
                                  • D Offline
                                    D Offline
                                    DanSiddiqui
                                    wrote on last edited by
                                    #18

                                    I have played youtube video directly on button click in N950 meego device by sending following request:
                                    @
                                    manager = new QNetworkAccessManager();
                                    QObject::connect(manager, SIGNAL(finished(QNetworkReply*)),this, SLOT(handleNetworkReply(QNetworkReply*)));
                                    QNetworkRequest request(QUrl(QString("http://gdata.youtube.com/feeds/api/videos/"+videoId)));
                                    manager->get(request);
                                    @

                                    (where videoid=Q4ng-G03PgM or any other youtube videoid)
                                    and getting following link through QNetworkReply.
                                    @
                                    Stryoutubelink=QString("rtsp://v2.cache7.c.youtube.com/CiILENy73wIaGQkDPjdt-OCJQxMYDSANFEgGUgZ2aWRlb3MM/0/0/0/video.3gp");
                                    @
                                    (where Stryoutubelink is a Qstring)
                                    and then i put this link on button click.
                                    @
                                    QDesktopServices::openUrl(QUrl(Stryoutubelink));
                                    @

                                    it will open youtube video ridrect on mobile's video player.

                                    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