Hi all,
I'm working on an application to play back live DVB streams (H264 and MPEG-2) and am having problems with H264 playback that I have been unable to resolve.
My application acts as a client for https://www.lonelycoder.com/tvheadend/ and communication is done via tvheadend's own "htsp" protocol. tvheadend demuxes the video and audio streams and sends complete packets in htsp messages.
My problem is that H264 streams sometimes fail to start at all or sometimes start after a few seconds (the longest wait can be up to about 5-10 seconds).
The playback code is currently just the hello_video sample with the file reading replaced by code to read from the htsp ringbuffer in my application. As I said, this works fine for some H264 streams and (thanks again!) for all MPEG-2 streams.
The following links are to two dumps I've made from my application of the received H264 streams. The first (bbchd-sat.h264 - the satellite DVB-S2 version of BBC HD) fails to play with the hello_video sample, and the second (bbchd-terr.h264 - the terrestrial DVB-T2 version of BBC HD) plays fine.
I don't have any tools to analyse these streams in detail (anyone recommend any Linux tools for this?), but I can see that they both start with SPS and PPS packets, which I first suspected may be the issue.
Trying both files with omxplayer, the "terr" version plays fine. The "sat" version plays, but very stuttery, and perhaps at half the real framerate.
Can anyone see what the difference is between these two samples, or advise how I can fix playback in the hello_video sample?
Thanks.
Links:
http://linuxstb.cream.org/bbchd-sat.h264
http://linuxstb.cream.org/bbchd-terr.h264