Kodi Community Forum

Full Version: PVR discarding unknown TS video streams
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

Very long time Kodi (and XBMC) user, but first time poster so if this is in the wrong section my apologies.  I'm having an issue with v18 and the PVR, which might be either a bug or just something still on the roadmap.  Many of the TS streams from my cable provider contain 2 embedded streams, which are classified as type 80 (the video stream) and type 81 (the audio stream).  Type 80 could be either audio or video according the the wiki.  In v18 only the audio plays from these channels, where previous versions it plays audio and video just fine.  I can reproduce the issue across multiple platforms.

It looks like this problem with introduced with https://github.com/xbmc/xbmc/commit/0c2d...a7b0f64380.  There were subsequent commits that looked like they were to address this issue but don't appear to work in my case.  I made a custom patch to remove that section on a current build and video does play, but that was just for test purposes. It seems like it should still be adding the stream if there isn't already a valid video stream based on the newer commits.  I wish I could be of more direct help, but if I can provide any more information I'll do my best.

Here's the stream info from ffmpeg

21:50:04.553 T:3646931776    INFO: ffmpeg[D95FC340]:     Stream #0:0[0x749], 0, 1/90000: Unknown: none ([128][0][0][0] / 0x0080)
21:50:04.553 T:3646931776    INFO: ffmpeg[D95FC340]:     Stream #0:1[0x74a](eng), 0, 1/90000: Audio: ac3 ([129][0][0][0] / 0x0081), 0 channels

Debug log:  https://pastebin.com/jDp87zFy

I tried patching that in to my Libre/CoreELEC builds, but was getting the same result.  I also tried the nightly on windows KodiSetup-20180702-a44e6e26-master-x64.exe and it's discarding the video stream.  I can post another debug log if that would be helpful but they show the same as the initial one.  The Demuxer discards "Unknown : none" type 80.

I did notice something interesting with further testing.  I tried recording a stream with this issue, and then playing that back.  When played back as a recording either from the PVR addon or directly via file I do get video playback.  From the debug log I can see the demuxer probes the stream with ffmpeg, and eventually identifies mpegvideo.  With "Live TV" it doesn't probe and relies on the stream tags, so can't differentiate between audio or video for that type.

Here is a debug log from the above nightly on windows showing playback of a recorded stream:  https://pastebin.com/mBYDRHK7
this log does not help very much. please turn off this log spam caused by ffmpeg and addon

18:56:10.878 T:30060   DEBUG: AddOnLog: NextPVR PVR Client: ReadRecordedStream(16384 bytes from offset 0)
18:56:10.878 T:30060   DEBUG: Previous line repeats 1 times.
18:56:10.878 T:30060   DEBUG: ffmpeg[756C]: [mpegts] pid=72a pes_code=0x1e0
18:56:10.911 T:30060   DEBUG: ffmpeg[756C]: [mpegts] PMT: len 44

post a log of a live channel. I want to see what is not working, not what is working.
Here is a log showing failed playback with only Debug + Video.   https://pastebin.com/qcR1TURV

I can't reduce the noise from the PVR addon any further while still being able to play live TV.  I waited for the EPG to do it's thing before starting playback.

This is from the same logfile as above showing just the demux section for a non-working stream.  https://pastebin.com/7VvZcmht
Works in both Windows and LibreELEC!  Thanks so much for looking at it, as it was the only major issue I've had with v18.