Menu

HTTP Streaming

Help
2011-04-26
2014-08-01
1 2 > >> (Page 1 of 2)
  • Cyril Concolato

    Cyril Concolato - 2011-04-26

    I'm creating a separate topic because it might interest other GPAC users.

    GPAC has some support for HTTP Streaming technologies. The support is for the Apple approach (m3u8 and MPEG-2 TS files) and for the on-going MPEG/3GPP/OIPF approach (mpd and MPEG-2 TS/MP4 files). The support is in both client or server side.

    In the server, you can use MP4Box  (-dash option) to:
    - segment an MP4 file and generate an MPD
    - segment an MPEG-2 TS and generate an M3U8 or MPD

    For live cases, you can use the (very experimental and very simple) udptsseg application which generates an M3U8 and MPEG-2 TS segments from a live TS over UDP.

    In the client, you can read M3U8 files (and MPEG-2 TS) with MP4Client for instance http://stream7.france24.yacast.net/iphone/france24/fr/f24_fr.m3u8. You can also read MPD files.

     
  • Anonymous

    Anonymous - 2011-04-27

    - segment an MPEG-2 TS and generate an M3U8 or MPD  <-- may I know how could I convert mp4 to mpeg2-ts and generate m3u8 file using mp4box?

     
  • Anonymous

    Anonymous - 2011-04-28

    cconcolato, any comment on this?

     
  • Cyril Concolato

    Cyril Concolato - 2011-04-28

    Hi,

    As I wrote, MP4Box -dash file.ts will segment the TS and produce an M3U8.
    For the conversion from MP4 to M3U8, MP4Box does not do it. There is a tool in GPAC called MP42TS but it has not been thoroughly tested.

    Cyril

     
  • Anonymous

    Anonymous - 2011-04-29

    I got this when I try to do mp42ts:
    mp42ts  -prog=20110426.mp4 -rate=1000 -dst-file=a.ts
    mp42ts: media_tools/m2ts_mux.c:1031: gf_m2ts_mux_pes_get_next_packet: Assertion `stream->pid' failed.
    Aborted

     
  • lux mark

    lux mark - 2011-05-03

    Hello,
    Tanks to everybody for the hard work on this project. I have been testing HLS streaming on Gpac and Osmo4 player for windows, and have the following questions for you:

    1) When i generate from Mp4 file a DASH segmneted file, i generate MPD playlist files, but i am not able to read them from Osmo4 player for Windows. How should i play it ?
    2) Once i generate Mp4 DASH fragemeneted only files, i see genereted a new MP4 file, that i am not able to play, how i can do it ?
    3)  Does the ISMA/OMA encryption of MP4 and DASH functionalities work togheter or not possible ?
    4) I tred different gpac frameworks, but i cannot find yet a stable vesion that handles M3u8 playlists. Which one is the most stable release for m3u8 HLS functionalities ?
    5) Does OSMO4/MP4CLIENT supports HLS AES 128 encryption/decryption ?

    Thanks a lot for your help in advance,

    Kind regads,
    Luxian

     
  • Anonymous

    Anonymous - 2011-05-04

    I am sorry to be rude but are you hijacking my post ? my question still not resolve!

     
  • Cyril Concolato

    Cyril Concolato - 2011-05-04

    To the anonymous user,

    There is no such thing as hijacking a post. Luxian is indeed asking about HTTP Streaming, therefore his post is relevant. We try to answer the questions as soon as we can, so be patient. And it would be good if you could be logged as a non anonymous person. It helps to have a name to answer to.

    Concerning your question about mp42ts, as I wrote, it has not been tested thouroughly. You seem to have found a bug but it's hard to know if you don't give details about the input. What's in your MP4 file? Can you provide the result of
    MP4Box -info 20110426.mp4

     
  • Cyril Concolato

    Cyril Concolato - 2011-05-04

    Hi Luxian,

    1) This should work, but since the MPD syntax has changed, it's possible that there is a discrepancy between the generation and playback. I will check

    2) if you mean that when you're using the -segment-name  option, the segment files are not playable in the GPAC player. This is kind of normal. When the input is an MP4 file, the segments are not valid MP4 files. They don't contain the moov structure. In DASH terminology, the segments are not self-initializing.  So the player does not have the necessary metadata to play the file. If you want to test a segment, you should concatenate the initialisation segment (file_dash.mp4) with the segment. The result should play.

    3) Good question. It should but it has never tested. Please try and report.

    4) HLS playback should be stable in the latest SVN (e.g. revision 3057). You can try to play the URL I gave in the first post.  HLS generation shoud also be close to stable. MPD generation and playback is definitely not stable.

    5) No. We don't have support for encryption/decryption of TS.

    Cyril

     
  • Cyril Concolato

    Cyril Concolato - 2011-05-04

    Luxian,

    Concerning your point 1) 'playback of MPD', you can try revision 3062. I have fixed some issues in the playback. You can try for instance to play: http://perso.enst.fr/~concolat/DASH/MP4/bbb_dash.mpd. The files were generated using MP4Box. The playback should be fine (except maybe for some glitches in the audio).

    Cyril

     
  • lux mark

    lux mark - 2011-05-04

    Hello Cyril,

    Thanks for your reply, and for all kind. Regarding the last post :

    1) I am ging to test your last 3062, and let you know the results. For now i only tested your 3060 GPAC framework installer package for Windows. On thisrevision, i found an error whien i execute Osmo4 application. The error i get is : "Cannot load GPAC termial". I am then thinking if it would be possible to have a 3062 revision Windows installer to test ?

    2) Thank for the helpfull information;

    3) I tested the encryption & DASH togheter, but before to enter into tis matter, i have already another related question that i posted into this forum: ( https://sourceforge.net/projects/gpac/forums/forum/287547/topic/4514450). I am not able to decrypt an MP4 ISMA/OMA encrypted file during playback from both Osmo4 and Mp4client. On both the players, i get the following message: "no ipmp tool suitable to handle channel protection". Is there any IPMP module missing, or i need to install extra IPMP modules ? If i need to install an extra IPMP module where i can find it ?

    4) Thanks for the information, i am going to test HLS as well and let you know the results as soon i get 3062 revision working;

    5) Are you planning to develop in the future a HLS decrption module for the player ?

    Thanks for your attention,
    Luxian

      i will test it and let you know as soon i get working 3062 rev;
    3) I tried

     
  • lux mark

    lux mark - 2011-05-05

    Hello Cyril,

    Congratulations for your hard work. Finally i got working M3U8 an MPD. This is a great result. I tried on Windows the last revision 3062, and finally got working the MPD and M3U8 playlists playing on Osmo4.

    I also tried to build from SVN using Visual C++ 2010 Express, following the istructions on (http://gpac.wp.institut-telecom.fr/2011/04/18/command-line-gpac-compiling-on-windows-x86-using-free-microsoft-visual-c/ ), but it gives me error while compiling. The error is "Could not load the visual c++ component VCBuild.exe".  I think the istructions on your webpage are not for Visu C++ 2010 express version, as the compiler is still looking for the old vcbuild,exe instead of msbuild.exe.

    The links i used for testing are :

    http://localhost/crypt/bbbiphone_300_dash.mpd
    http://liveips.nasa.gov.edgesuite.net/msfc/Edge.m3u8

    If i try different m3u8 or mpd links it does't work. There is still a problem on the playlist syntax parser ? It does not play all the other m3u8/mpd playlists files formats.

    Regarding the Encryption module i still have the message "no ipmp tool suitable to handle channel protection" while i am playing encryped content.

    Please let me know your feedbacks if possible.

    Kind regards,
    Luxian 

     

     
  • Romain Bouqueau

    Romain Bouqueau - 2011-05-09

    Hello Luxian,

    I've investigated the vc2010 express issue. This version doesn't allow to convert projects containing advanced features from the previous versions so we'll have to wait for some official project file on the repository.

    However you can install msvc2005 or 2008 side by side with 2010, or you can alternately try to install the .NET framework 2.0 SDK which provides vcbuild.exe (http://www.microsoft.com/downloads/en/details.aspx?familyid=fe6f2099-b7b4-4f47-a244-c96d69c35dec&displaylang=en) but I can't guaranty the latter solution works.

    Romain

     
  • Anonymous

    Anonymous - 2011-05-17

    Hy Cyril,
    I'm trying (successfully though) to access your content http://perso.enst.fr/~concolat/DASH/MP4/bbb_dash.mpd. I assume that it only contains a single bitrate and while it is somehow DASH can't adapt it's bitrate, right ?

    I have some issues streaming DASH content myself. Even if I exactly copy your files onto my web server MP4Client will not play it and display after Opening URL…:
    Cannot open service ():  Feature Not Supported

    The only thing I can imagine is a config issue on the http server? Is it about threading or so ? Do you have an idea ?

    Thanks, Tomas

     
  • lux mark

    lux mark - 2011-05-17

    Hello Romain,

    Thanks for your reply. I did follow your instructions to compile GPAC on Windows Vista, using VC2010 express but i still was not able to build the framework. I was successful only on the GPAC external libraries compilation, but not on the main GPAC binaries.
    I then tried on Windows XP, using VC++ 6.0, and the entire project was successfully built. Even if i found a few compilation errors inside the code, i was able to build the entire project.

    Kind regards,
    Luxian7

     
  • Cyril Concolato

    Cyril Concolato - 2011-05-17

    Thomas,

    The DASH standard supports the description of multiple bit rates. MP4Box does not yet allow the creation of multi rate content. MP4Client should support it, not tested yet, at least it does with M3U8 files.

    For the error message, indeed, it's not very clear. I'll try to fix it. I think it's a problem of configuration. MP4Client expects specific MIME types for MPD/M3U8 (e.g. video/vnd.3gpp.mpd) and media segments. You can check:
    http://gpac.svn.sourceforge.net/viewvc/gpac/trunk/gpac/modules/mpd_in/mpd_in.c?revision=3146&view=markup
    You can create a .htaccess file with the following:

    <Files "*.m3u8">
        ForceType application/x-mpegURL
    </Files>
    <Files "*.ts">
        ForceType video/MP2T
    </Files>
    <Files "*.mp4">
        ForceType video/mp4
    </Files>
    <Files "*.m4s">
        ForceType video/mp4
    </Files>
    <Files "*.mpd">
        ForceType video/vnd.3gpp.mpd
    </Files>

    Cyril

     
  • Anonymous

    Anonymous - 2011-05-18

    Hi Cyril and thanks for your answer.
    I've done some tracing and found quite a difference between the working and the non-working case:

    In both cases the initial GET on the .mpd file is answered with 304 Not Modified. The actual answer seems very similar, I couldn't find any relevant difference.

    In the working case the next GET requests again the .mpd using HTTP/1.0, while in the non-working case the GET comes with HTTP/1.1 in the GET-header and the following additional/different headers

    User-Agent: Lavf52.82.0
    Range: bytes=0-
    Connection: close

    The Range header causes the web server to reply with HTTP/1.1 206 Partial Content

    I tried to disable usage of Range-headers on another web server (dont have full admin permissions to the one used inititally) which actually lead to another scenario.

    Second Get (again HTTP/1.1 containing the Range-Header) is now answered with 200 OK containing the actual mpd XML content plus the header:

    Connection: close

    which seems to be not properly processed by GPAC, because it'll send another GET HTTP/1.1 similar so the second one.

    Regarding the MIME Type, in the working case, MIME-Type is video/mp4, in the first non-working case I dont come that far and in the second it wasn't set (application/stream), will do so now.

    BR/Tomas

     
  • Cyril Concolato

    Cyril Concolato - 2011-05-18

    Hi all,

    For the record, the problem of Luxian concerning ISMACrypt playback on Windows is fixed since SVN revision 3149.

    Cyril

     
  • Cyril Concolato

    Cyril Concolato - 2011-05-18

    Hi all,

    Also for the record, revision 3149 also plays the URL http://liveips.nasa.gov.edgesuite.net/msfc/Edge.m3u8. If this is not the case, please report.

    Cyril

     
  • Cyril Concolato

    Cyril Concolato - 2011-05-18

    Tomas,

    Not sure I understand your explanation. Let me try to clarify a point. There are 2 MIME types involved: one for the MPD file, one for the media segments (e.g. MP4 or MPEG-2 TS).

    The problem is currently that if GPAC does not reckognize the MIME type, it passes the URL to FFMPEG which will try to play it. That's what seems to happen in your case. The user-agent Lavf52.82.0 is the FFMPEG plugin within GPAC.

    I think your problem comes from the HTTP cache handling in GPAC. Even if you changed the settings of your web browser, since the MPD file has not changed on the web server, GPAC will use its cache and check the MIME type from the cache. There should be a file called *.mpd.txt in your cache directory. Delete it and retry. Another option is to set the CleanCache option to yes in GPAC configuration file (see http://gpac.svn.sourceforge.net/viewvc/gpac/trunk/gpac/doc/configuration.html#Downloader)

    Let us know if it works.

    Cyril

     
  • Stefan Lederer

    Stefan Lederer - 2011-05-23

    Hi,
    I've a problem with the segmentation of content with video and audio(aac) tracks . I generated a mp4 file containing a video track and an audio track and started the DASH segmentation using -frag, -dash and -rap. But I get an segmentation fault. It works perfectly if there is just a video track, but if I also add an audio track it crashes. It also crashes if I try to segment a mp4 file with just a audio track (and no video track).

    It crashes somewhere in gf_isom_datamap_open in data_map.c …

    Do I have have to consider something special for the audio encoding?

    Thx!
    Stefan

     
  • Romain Bouqueau

    Romain Bouqueau - 2011-05-23

    Hi Stephan,

    Can you send us some files and command-lines to reproduce the crash? Send me a private message if you don't want it to be public.

    Romain

     
  • lux mark

    lux mark - 2011-05-23

    Hello Cyril,

    Thanks for your support. I tested the 3149 revision, on Windows XP, it works, but i have problems to decrypt from IE browser GPAX plugin. The activex control wont install anymore into the browser. On Windows Vista the Osmo4 playback always crashes, and on W7 works only the Osmozilla plugin, and when it works i can play the video with a "blocking effect" (For blocking effect i mean that you see bigger pixels into the video).

    I also found during the decryption playback some syncronization issues between audio and video tracks. Do you think it depends from the decryption system ?

    Please let e know your feedbacks.

    Kind regards,
    Luxian7

     
  • Cyril Concolato

    Cyril Concolato - 2011-05-24

    Luxian,

    XP, IE and GPAX. We will check. What is the version of IE you are using? Do you have admin privileges or not ?
    Vista: we have no Vista installation to test on.
    W7 & blocking effect: what video decoding plugin is GPAC using ? You don't have this problem when you play it with the desktop player ?
    Decryption Sync problem: this should not happen. Can you send an example file by private message?

    Cyril

     
  • lux mark

    lux mark - 2011-05-24

    Hello Cyril,

    - XP, IE, and GPAX : I am using IE9, and have admin privilegies on all Windows OS versions. XP does not requires me to have admin privilegies.
    - W7 & Blocking effect : I tried with all the decoding plugins. It is an issue i have only on osmozilla plugin into all the browsers. On GPAC desktop it is working fine.
    - Decryption and sync : I will send you my example file.

    Luxian7

     
1 2 > >> (Page 1 of 2)