Discussion Board

Results 1 to 15 of 15
  1. #1
    Registered User arttu76's Avatar
    Join Date
    Oct 2010
    Posts
    12
    Hi!

    I've been fiddling with Qt Creator (2.0.1) for couple of days now. Running my app with the simulator and with N8 works well but there are couple of problems with video streamed over http. The player code is basically:
    Code:
    player=new Phonon::VideoPlayer(Phonon::VideoCategory, 0);
    player->play(url);
    Problems:
    1. The video window in simulator is placed randomly, usually behind my app. Using player->showFullScreen(); etc doesn't seem to make any difference. Why's that? On simulator, streaming, sounds, controls, video player slots etc works just fine - I just can't see the video!
    2. When running the app on N8, I don't seem to be able to stream any video. Is N8's Qt version up to it? Is there something I can do? Is my code incorrect? The last thing I see is
      Code:
      ADEV    1286394558    1797    Setting callback granulatiry percentage to 40
      and sometimes I got
      Code:
      QVGPaintEngine::compositionModeChanged unsupported mode 2
      What can I do to display http video streaming (full screen is fine, no need for fancy placements) on N8?
    3. If it's not possible to use Qt (or any C++ way) to do http video streaming in a homebrew app, is it possible to launch the media player and tell it the url (an advantage with this would be that then I dont have to code the video player UI at all). I tried using QDesktopServices : : openUrl() but naturally it first opens the browser which is pretty ugly... Could I use QProcess to open the video player to stream the video over http? If yes, how?


    Thanks very much in advance!


    SOLVED! Simply create a .ram file, for example foo.ram into file system. The file must contain nothing but the url of the video stream. Then simply open that file with QDesktopServices : : openUrl(file://....)
    Last edited by arttu76; 2010-10-16 at 21:39.

  2. #2
    Registered User phunware's Avatar
    Join Date
    Dec 2010
    Posts
    2
    Quote Originally Posted by arttu76 View Post
    Hi!

    SOLVED! Simply create a .ram file, for example foo.ram into file system. The file must contain nothing but the url of the video stream. Then simply open that file with QDesktopServices : : openUrl(file://....)
    Hi Arttu76,

    I've tried what I understood you suggested but I couldn't see the stream on Qt Creator 2.0.1, nor the N8.

    Can you please clarify and post the code, even though it may be simple and obvious.

    Thanks

    Code:
    #include "mainwindow.h"
    #include <QDesktopServices>
    #include <QUrl>
    
    MainWindow::MainWindow(QWidget *parent)
        : QMainWindow(parent)
    { 
    //    http://www.youtube.com/watch?v=acvIVA9-FMQ    <--- the only line in foo.ram
    
    //    QDesktopServices::openUrl(QUrl(":/foo.ram"));
    //    QDesktopServices::openUrl(QUrl(":/foo.ram"));
    
          QDesktopServices::openUrl(QUrl("file:///d:/Nokia.Code/DesktopVideo/foo.ram));        
    }

  3. #3
    Registered User phunware's Avatar
    Join Date
    Dec 2010
    Posts
    2
    yes, there's a missing end quote but that's not what is causing the video problem.

    Code:
    QDesktopServices::openUrl(QUrl("file:///d:/Nokia.Code/DesktopVideo/foo.ram"));

  4. #4
    Registered User marcogt's Avatar
    Join Date
    Aug 2008
    Posts
    2
    hi guys, i am a total noob about programming and stuff, but i like to study a bit, now that i have my new n8.
    It is embedded with nice codec and it is a pretty complete multimedia machine.
    The point is that i can't get the http stream from my dreambox decoder which would be awesome. Basically i get from the decoder, when i request to stream a channel, a file with m3u extension with this written inside
    Code:
    #EXTM3U
    #EXTVLCOPT--http-reconnect=true
    http://decoderlocaladd:port/cid:pid
    it is basically a http stream. The stream is a simple TS stream so no problem for codec support i believe....
    i tried to leave only the http address and then rename the file into ram or mkv or avi, it do open the video player but nothing happens....is there a way to get it working without having to write a program???
    should i consider try the qt simulator or not what's your suggestion?

    thanks

  5. #5
    Registered User realjobe's Avatar
    Join Date
    Jun 2010
    Posts
    19
    Excelent Info! I've been searching a way to start VideoPlayer with a file (.m3u eg.) and .ram did the job!

    I created a stream.ram into E: and clicked it from Filebrowser..

    There is only one problem. The system Does not Obey internet Accesspoint priority list at all!!!! It tryes to access 1st priority WLAN and not the 2nd access point (3G), despite that there is no WLAN available. Browser obeys the priority. And this does not matter wheather the 3G connection would already be at use.. !

    edit: to sorcery-ltd: Thank you! Did not remember those settings..
    Last edited by realjobe; 2011-01-12 at 12:28.

  6. #6
    Registered User realjobe's Avatar
    Join Date
    Jun 2010
    Posts
    19
    Quote Originally Posted by marcogt View Post
    .. it is basically a http stream. The stream is a simple TS stream so no problem for codec support i believe....
    You'r doing it wrong... h264&aac in FLV wrap (mime="video/mp4") is the only way. Raw DVB- .ts mux is too much and too verbose for mobiles.. 500kbit h264 is very impressive. VLC does this. You need webServer with vlc for this and some services/ php site...

  7. #7
    Registered User Sorcery-ltd's Avatar
    Join Date
    Dec 2006
    Posts
    2,280
    The video player has it's own access point setting (Menu -> Videos -> Options -> Settings -> Access point in use) which ignores the other preferences - this is because several operators around the world have (at least historically) only allowed streaming on a dedicated access point and blocked the ports on their standard "internet" access points.

    You can set this access point programatically but I don't think there's a public API call to do it (if you can't find one then you'd have to ask FN tech support). I think the alternative is to go native Symbian for the video playback and use CVideoPlayerUtility - the OpenUrlL method lets you specify an access point. I believe the Phonon backend uses this anyway but leaves the access point as default. I'm guessing the Phonon backend is using the video player utility in a way that's incompatible with the OpenVG painting backend in the N8 (which is a bug in Qt and should be reported if not already logged).

  8. #8
    Registered User realjobe's Avatar
    Join Date
    Jun 2010
    Posts
    19
    Great. Can you tell me a little more about the Videoplayer's streaming cabapilities:
    - can it do RSTP & Http?
    - what are the video codec & container cabapilities?
    - Streaming autoresume, if broken?
    - Buffering adjustments....

  9. #9
    Registered User Sorcery-ltd's Avatar
    Join Date
    Dec 2006
    Posts
    2,280
    The built-in video player has the capabilities of the device as far as streaming goes - go check the device specifications page for details of container formats and codecs.

    Last time I checked HTTP streaming wasn't supported but it may be in Symbian^3 (N8). The video player there is Helix from Real Networks which is also open source. It is in general a very capable player.

    If you use the CVideoPlayerUtility API it uses the same basic engine as the built-in player.

  10. #10
    Registered User realjobe's Avatar
    Join Date
    Jun 2010
    Posts
    19
    Got it to work.. RTSP with H264 & mp4-audio.. works quite good, some SymbianFrame's problems with videoplayer to maintain the stream without visualdetiorations..
    Last edited by realjobe; 2011-01-17 at 06:28.

  11. #11
    Registered User realjobe's Avatar
    Join Date
    Jun 2010
    Posts
    19
    Well.. The problem at hand is that RTSP (udp) is really not suitable delievering stream through various types of networks. The UDP ports needed jumps around like idiots and NAT's & firewalls will cut' em down. TCP is needed!

    What other streaming methods does The VideoPlayer do? HTTP / RTMP and with what encapsulation / Mux!

    Can someone just give the VideoPlayer capabilitieslist, what the player can pull & show.

  12. #12
    Registered User Sorcery-ltd's Avatar
    Join Date
    Dec 2006
    Posts
    2,280
    TCP is a really stupid idea for streaming - that's a much better option for progressive download. However I understand the pain with ports. This question no longer has anything to do with Qt though, so I'd suggest asking it on a more specialist board. There used to be one specifically for this sort of question but it has been archived. This is probably your best bet now:
    http://discussion.forum.nokia.com/fo...-amp-Sounds%29

  13. #13
    Registered User ciffa85's Avatar
    Join Date
    Feb 2011
    Posts
    1
    Could someone please provide a more detailed code of how to do this? When I try to open the .ram file after creating in programmatically, I only get a black screen with "Services" displayed in the header. I know the link and .ram file works, because when I open it manually after its creation, the video loads correctly.

    I have tested this on both a C7 and a N8.

    PS: Do I need SwEvent capability to do this?

  14. #14
    Registered User huluyige's Avatar
    Join Date
    Mar 2011
    Posts
    3
    Quote Originally Posted by ciffa85 View Post
    Could someone please provide a more detailed code of how to do this? When I try to open the .ram file after creating in programmatically, I only get a black screen with "Services" displayed in the header. I know the link and .ram file works, because when I open it manually after its creation, the video loads correctly.

    I have tested this on both a C7 and a N8.

    PS: Do I need SwEvent capability to do this?
    Hi
    I got the same problem, did you solve it?

  15. #15
    Registered User gauravJoshi's Avatar
    Join Date
    Jun 2011
    Posts
    1
    Hi I tried doing this
    but i am getting system error when i open .ram file and video player gets opened but it is not abel to play the video

Similar Threads

  1. Symbian^3 (N8) video streaming
    By AltoRetrato in forum Symbian Media (Closed)
    Replies: 1
    Last Post: 2010-06-14, 22:57
  2. play video over http via streaming..
    By mudit.agar in forum Streaming and Video
    Replies: 1
    Last Post: 2010-01-22, 08:40
  3. play video over http via streaming..
    By mudit.agar in forum Mobile Java Media (Graphics & Sounds)
    Replies: 1
    Last Post: 2010-01-22, 08:39
  4. streaming video from a http server
    By LailaBiju in forum Symbian Media (Closed)
    Replies: 6
    Last Post: 2009-03-26, 12:50
  5. which API to display video streaming (not RTSP/http streaming)
    By jcaradec in forum Symbian Media (Closed)
    Replies: 2
    Last Post: 2008-05-15, 21:24

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved