Sign up here and you can log into the forum!

Problem with UMSP flv streaming (blank picture on playback)

Discussion, features, plugins--everything about zoster's UMSP UPnP Media Server software

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby Martor » Wed Oct 03, 2012 11:02 am

Hi aenbacka,

I was just wondering, if you found solution for your issue described here?
I have completely same problem, not able to solve it :( tried already almost all what is possible.

I thought the transcode is necessary, but the most suitable solution is not working for me :(
proxy file is completely the same:
Code: Select all
header('Content-type: video/x-flv');
   header('Content-Disposition: attachment; filename="wdlxtv.flv"');
   header('Accept-Ranges: bytes');
   header('Content-Length: 1073741823');
   header('Cache-control: no-cache');
   header('Connection: close');

     
   $cmd = "rtmpdump -r " . urldecode($_GET['r']) . " -q | ffmpeg -i pipe:0 -vcodec copy -acodec copy -f flv pipe:1 | cat";


   set_time_limit(0);
   passthru($cmd);


Same as for your, when storing rtmpdump to -o file, stored FLV is fully playable!

Martin

P.S. I have tried MediaLogic debug, and found this: Content-Type: text/html, which sounds to me, that the headers are not properly setup?
1.02.21_V_WDLXTV.COM_WDLXTV_LIVE-0.5.1.1
Martor
DLX'er
 
Posts: 98
Joined: Sat Apr 10, 2010 9:58 pm
Location: Czech Republic

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby KAD » Wed Oct 03, 2012 12:02 pm

agreed, sounds like problem is with the headers

i.e
Code: Select all
get header timeout
and while it does switch to head
you still end up with
Code: Select all
get server property failed
If you like my work please consider a Donation. Donate
Please read the appropriate documentation before posting questions! READ ME FAQ WIKI
PM's are for private matters. Post support questions to the appropriate forum, or they will be ignored.
User avatar
KAD
Global Moderator
 
Posts: 5103
Joined: Mon Apr 12, 2010 4:59 pm
Location: Seattle, WA USA

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby Martor » Wed Oct 03, 2012 12:10 pm

Hi KAD,

yes, found the issue, in proxy file, there need to be NO BLANKS before and after <PHP> tag.
Now the headers works for me!

I am doing final transcode tests, but it looks like I found solution, no MediaFormat problem, streaming is coming, can see part of video on screen.

Update you all in few minutes ;)

Martin
1.02.21_V_WDLXTV.COM_WDLXTV_LIVE-0.5.1.1
Martor
DLX'er
 
Posts: 98
Joined: Sat Apr 10, 2010 9:58 pm
Location: Czech Republic

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby Martor » Wed Oct 03, 2012 12:18 pm

Hi all,

BINGO! I got it! Got the stream when playback FLV streaming BUT :( it stops after few seconds and freeze!!! :(((

Here is my proxy (make sure that no blanks are before and after <PHP> tags):

Code: Select all
<?php
   header('Content-type: video/x-flv');
   header('Content-Disposition: attachment; filename="wdlxtv.flv"');
   header('Accept-Ranges: bytes');
   header('Connection: close');


   $cmd = "rtmpdump -r " . urldecode($_GET['r']) . " -q | ffmpeg -y -i pipe:0 -vcodec copy -acodec copy -f flv pipe:1 | cat";

   passthru($cmd);
?>


in umsp got this:
Code: Select all
$myMediaItems[] = array(   
      'id'         => strval(count($myMediaItems)+1),
      'parentID'      => '0',
      'dc:title'      => 'iVysilani',
      'upnp:class'   => 'object.item.videoItem',
      'res'         => 'http://127.0.0.1/umsp/plugins/rtmp-proxy.php?r=rtmp%253A%252F%252Fwcdn20.nacevi.cz%252Fct-vod%252F_definst_%253Fid%253DHRv9r7WABFoAOP81%252Fmp4%253AiVysilani%252F2012%252F09%252F13%252FVypravejCT-130912-MP4_576p.1.mp4&format=flv&title=iVysilani&content-type=%2522video%252Fx-flv%2522',
      'protocolInfo'   => 'http-get:*:video/x-flv:*',
   );
1.02.21_V_WDLXTV.COM_WDLXTV_LIVE-0.5.1.1
Martor
DLX'er
 
Posts: 98
Joined: Sat Apr 10, 2010 9:58 pm
Location: Czech Republic

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby aenbacka » Wed Oct 03, 2012 12:36 pm

Thanks a lot for this info, will try it out also with the Yle Areena plugin.:)
aenbacka
n00b
 
Posts: 17
Joined: Sun Jan 23, 2011 10:48 pm

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby Martor » Wed Oct 03, 2012 1:12 pm

Hi aenbacka,

found some more interesting things.

Not sure if you are also using RTMP, but it looks like that the FFMPEG is killing the stream.
So I tried no transcoding, and this works much better, but from time to time, the video and audio are not aligned properly.

Please try also:
Code: Select all
$cmd = "rtmpdump -r " . urldecode($_GET['r']) . " -q ";


Let me know your investigation, looks like there will be still some issues :(

Thanks, Martin
1.02.21_V_WDLXTV.COM_WDLXTV_LIVE-0.5.1.1
Martor
DLX'er
 
Posts: 98
Joined: Sat Apr 10, 2010 9:58 pm
Location: Czech Republic

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby Martor » Wed Oct 03, 2012 1:34 pm

HEH, found out the problem!
Code: Select all
set_time_limit(xx);

If not specified in proxy script only 30seconds is streamed :(

Before passthru(cmd) we need to set enough time the script is keeping running rtmpdump :(

Tried to use set_time_limit(0) to disable, but this is not working and only 30secs of stream passed.

Does anyone have a experience with this please? Looking also to other proxies.

Keep you updated if found something.

Martin
1.02.21_V_WDLXTV.COM_WDLXTV_LIVE-0.5.1.1
Martor
DLX'er
 
Posts: 98
Joined: Sat Apr 10, 2010 9:58 pm
Location: Czech Republic

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby aenbacka » Wed Oct 03, 2012 9:46 pm

Seems that there are some issues; I know that I have had this proxy thing working before with essentially the same code (was able to stream ffmpeg transcoded video shows without problems).
I will try out your suggestions tonight when I get home from work, hopefully we can work out something :) Thanks anyway for all the info and help.
aenbacka
n00b
 
Posts: 17
Joined: Sun Jan 23, 2011 10:48 pm

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby aenbacka » Thu Oct 04, 2012 8:26 am

Now I got the FLV stream working (by removing unnecessary space after php tag, and setting set_time_limit(0)). I still have problem with audio and video not being in sync, is this related to playing back FLV (e.g., could changing container using ffmpeg help this)?
aenbacka
n00b
 
Posts: 17
Joined: Sun Jan 23, 2011 10:48 pm

Re: Problem with UMSP flv streaming (blank picture on playba   

Postby Martor » Thu Oct 04, 2012 9:56 am

Hi aenbacka,

thats great, regarding the issues with sync of video/audio, you should add the ffmpeg as showed in my previous message.
I am just wondering how did you make the set_time_limit(0) properly running, to get unlimited stream, I set this also up, but have still 30secs of stream only :( please can you share with me the proxy file?

Thanks! Martin
1.02.21_V_WDLXTV.COM_WDLXTV_LIVE-0.5.1.1
Martor
DLX'er
 
Posts: 98
Joined: Sat Apr 10, 2010 9:58 pm
Location: Czech Republic

PreviousNext

Return to UMSP Media Server

Who is online

Users browsing this forum: No registered users and 2 guests