Open RaumKraehe opened 10 years ago
You can find the log file (-g) here: https://dl.dropboxusercontent.com/u/6880789/omxplayer.log
Can you record the stream to a file (perhaps using vlc) and then try playing the file on the Pi? If that fails, then it's related to decoder on Pi, and I can analyse the file.
If that works, then it's more likely network packet loss. Are you using ethernet or wifi? Is the rtsp using udp or tcp?
thanks for the answer.
Record on good system (vlc on windows). Then try playing the file on Pi.
atm i got it to dump the stream with mplayer on the rasperry to a pipe or file and then i let omxplayer to player this file. When i did so i have no errors or glitches but the performance is very poor.
I tryed to record but i have to recode the stream using vlc. or i did not see the point. :)
To the network: all my clients are attached to the network. Thats are 1 Ipad, 1 Matrox encoder, 2 Raspberrys und 2 clients with vlc. But only the raspberrys showing the glitches. No other device shows any problems.
I'm guessing rtsp is using udp, and the bandwidth is high enough that the Pi is not keeping up. As it's udp the packets are dropped. If you dump to a file and play it over network it will not drop any packets, but may stop to buffer frequently if bandwidth is not available.
What is the bitrate of the stream? What bandwidth can you get from the PC to to the Pi using iperf? How busy (using top for example) is the Pi when omxplayer is running?
i also guess so. But i read that others was able to play a stream even with higher bandwith.
[ 3] local 192.168.5.94 port 59143 connected with 192.168.5.89 port 5001 [ ID] Interval Transfer Bandwidth [ 3] 0.0-10.0 sec 95.4 MBytes 79.8 Mbits/sec
I think it is ok.
What i am wondering about:
if i record the stream with mplayer and after that playing the dump with omxplayer the result is completly different than streaming directly. The Picture ist much more "clear" and "sharp" but it plays slower and not so smooth. strange.
That would be explained by difference in udp and tcp protocols. udp packets can be dropped if not dealt with in time. tcp packets will be retransmitted, so will always be correct, but may be late.
i got down to 5 Mb\s´again. The picture is now realy crappy and still after 3-5 mins the glitches come up.
What i dont understand: If the performance is so poor that the raspi has to drop packets why this never happend in the first 3-5 Minutes? And why i am getting more glitches over the time? If packets are droped than it should happen randomly from time to time. I am using a constant bitrate. No VBR. And why then two raspis side by side dropping the same packets at the same time? That sounds strange. :)
Are you using --live in these tests? (You should be).
@RaumKraehe is this still an issue?
Hello and sorry for my poor englich.
I have some problems streaming rtsp streams with the raspberry pi and omxplayer. Initially everything works well but after the streaming is running some time (5 Minutes) i get some strange "glitches" on the screen.
Tested with 64/128/256 MB Ram. Makes no differenz.
I am using atm a Matrox Maevex BP52215 hardware encoder witch is able to encode H264 in 1080p@60 FPS. I can watch the stream without any problems on serveral different devices and programms. It runns fine on my Ipad, on the original Matrox reciever and i can watch the stream with vlc. No glitches at all.
Videoproof: http://www.youtube.com/watch?v=rue_Ch0VPno
On the left side you see vlc decoding on the right side you see the rasperry pi is decoding 1080p@60fps with 15 Mb/s very well.
But after some time (about 2-5 min) i get these results:
http://www.youtube.com/watch?v=sGUPgVr-vnw
You can see the glitches on the right side. Raspberry pi is decoding here.
So, what i have tested to get off the glitches:
All these steps can reduce the glitches but dont stopping them to appear. Thy become a bit smaller. All glitches are always on the bottom of the screen, never on top.
I am not shure if this problem is really affected bei omxplayer. Maybe some of the h264 hardware driver is broken? Who knows? I dont. :(
Starting omxplayer gives me this info:
pi@raspberrypi ~ $ omxplayer --live rtsp://192.168.5.96:8554 Invalid framerate 90000, using forced 25fps and just trust timestamps Video codec omx-h264 width 1920 height 1080 profile 66 fps 25.000000 Audio codec aac channels 2 samplerate 32000 bitspersample 16 Subtitle count: 0, state: off, index: 1, delay: 0 V:PortSettingsChanged: 1920x1080@24464.00 interlace:0 deinterlace:0 par:1.00
It looks like there is a problem with the 60fps? But the glitches are still there if i am forcing 30fps. But smaller.
omxplayer stream info:
pi@raspberrypi ~ $ omxplayer -i rtsp://192.168.5.96:8554 [h264 @ 0x1808f50] Missing reference picture, default is 0 [h264 @ 0x1808f50] decode_slice_header error [h264 @ 0x1808f50] RTP: missed 456 packets [h264 @ 0x1808f50] RTP: missed 732 packets [h264 @ 0x1808f50] concealing 2077 DC, 2077 AC, 2077 MV errors in I frame [h264 @ 0x1808f50] RTP: missed 662 packets [h264 @ 0x1808f50] Invalid level prefix [h264 @ 0x1808f50] error while decoding MB 67 33 [h264 @ 0x1808f50] concealing 4182 DC, 4182 AC, 4182 MV errors in I frame [h264 @ 0x1808f50] RTP: missed 398 packets [h264 @ 0x1808f50] RTP: missed 633 packets [h264 @ 0x1808f50] RTP: missed 717 packets [h264 @ 0x1808f50] RTP: missed 428 packets [h264 @ 0x1808f50] RTP: missed 603 packets [h264 @ 0x1808f50] RTP: missed 1 packets [h264 @ 0x1808f50] RTP: missed 21 packets Input #0, rtsp, from 'rtsp://192.168.5.96:8554': Metadata: title : Session streamed with GStreamer comment : rtsp-server Duration: N/A, start: 0.031600, bitrate: N/A Stream #0:0: Video: h264 (Baseline), yuv420p, 1920x1080, 90k tbr, 90k tbn, 180k tbc Stream #0:1: Audio: aac, 32000 Hz, stereo, fltp have a nice day ;)
Missing packets, Errors in I-Frame. All this sounds good. to explain the glitches. But why every other device i had testes shows the stream fine? Why the raspberry is able to play the stream for 5 Minutes without any problems?
Interresting Fact: If i take 2 Raspberrys and these two devices are showing the same stream side by side, both of the devices showing the glitches at the same time!
Please help. :)