Bug Buffer Issues with MPEG2 cards and line in
#1
"I have multiple computers that all suffer from the same issue. If I setup mythtv to use a line in as a channel. XBMC will have buffer issues playing back the video. Though if I pause the video in XBMC and wait 5 seconds and let it play it will play perfectly. Each one of these PCs are a master backend with the XBMC client installed on the same computer. The 3 pcs I have replicated this issue on are:

-2 Pentium 4 HT 3 GHZ PCs, one with a AMD HD 3650, and the other with a Geforce 4 MX
-1 AMD Athlon x2, with a nvidia GT630 video card.

All other dvd quality mpeg2s play fine on these computers and mythtv will playback the video just fine. Only livetv in xbmc has this buffer issue. Also the importance of this is many people like myself setup directv via the line in. Then a script is used for the channel change. In this setup the buffering makes the setup unusable. Though recorded video plays back fine.

On a side note mythtv 0.25 or 0.26 have the exact same issue, no difference. (I also can not test DVB, no digital signals out in my area)."

quoted from:

https://github.com/fetzerch/xbmc-pvr-addons/issues/119


I originally posted the above issue and was told to post this to the forums to see if anyone else has a similar setup with similar issues. Either way this is annoying to say the least and keeps xbmc from being my main frontend for mythbackend.
Reply
#2
You don't say what capture card you have, where you are getting your stream from, or what your logs say. You don't even say which versions of mythtv you are using (0.25 and 0.26 both have fixes branches with fairly constant updates as things are fixed).

There was at some point a mythtv bug where the size of the buffer between live tv recording point and livetv playback point was out by a factor of about 1000 and playback was constantly being starved of data, but I am pretty sure it was resolved before 0.26. Your pausing for 5 sec would point to some error like that and is a reasonable workaround until a fix is found for you.

Does it work on mythfrontend?
If I have helped you or increased your knowledge, click the 'thumbs up' button to give thanks :) (People with less than 20 posts won't see the "thumbs up" button.)
Reply
#3
Good points, the caputer cards are:

-PVR150, with mythtv 0.26 on a Pentium 4 HT
-HVR1600, with mythtv 0.25 on a Pentium 4 HT
-HVR2250, with mythtv 0.26 on a AMD Athlon x2

The stream is coming from the line in (Svideo or composite with analog audio). I've used both versions of mythtv which I listed what there currently using above. All of the mythtv versions come from there respective mythbuntu ppas and are running Mythbuntu or Kubuntu. Mythfrontend works great for each pc, except the HVR2250 has some tuning issues for analog. Which seem to be well known in mythfrontend, though XBMC does not have that particular issue. My fix is acceptable for myself but the WAF is low so I'd rather find a elegant solution. I don't have access to the logs at this time, but will post them later.
Reply
#4
You still haven't given the exact versions, but the logs will probably be the key.
If I have helped you or increased your knowledge, click the 'thumbs up' button to give thanks :) (People with less than 20 posts won't see the "thumbs up" button.)
Reply
#5
Sorry for the long delay, but are area was hit by the heavy rains in New York. Getting back to the thread, too make this issue easier I'm going to focus on my main machine.

Hardware

-Kubuntu 13.04 with backports from Kubuntu enabled
-Nvidia GT630 2 GB with 319.32 driver
-10 GB of Ram with a AMD Athlon 3.3 ghz x2
-7200 rpm Hitachi Drive
-Creative Audigy 2 ZS with live drive
-Hampuage HVR-2250 with latest firmware I could find.

Software

-XBMC from Stable PPA, current overall Version 12.2
-XBMC Mythtv Plugin Version 1.6.10 (pulled from https://github.com/fetzerch/xbmc-pvr-addons , looks like I maybe able to update again)
-Mythtv 2:0.26.0+fixes.20130707.28128e3-0ubuntu0mythbuntu3 from mythbuntu 0.26 PPA
-KDE 4.10.4

Logs
-XBMC
-Mythbackend

To recap the issue still happens but is fixed by pausing the stream for about 5 seconds. The problem with this is the future when I try to impliment this for dear old mom and dad. This wont make them very happy.
Reply
#6
Could you post a full XBMC debug log with addon setting 'enable more information in the log' enabled?

Looks like this issue is similar to http://forum.xbmc.org/showthread.php?tid=170163
Reply
#7
Yes, it is similar, but pausing doesn't alter my symptoms. Its like whatever is being lost is being lost before it gets sent to the playback side of things, implying a networking issue of some kind (though it appears over both two wired connections and a wireless, but does not appear when mythtv frontend is used).
Reply
#8
Just wanted to let you know I will post the log by the weekend. Though I have seen improvements with updates in Mythtv 0.26, so this might be on that side more than anything. I don't see much of a similarity between the issues. His seems to be more that the video is never displayed, while mine is displayed, but choppy (though again this has improved, and may be a non issue. More testing is needed).
Reply
#9
Below is the log with the debug option enabled for the MythPVR Plugin:

Log

Though this issue seems to be better with updates from the mythbuntu PPA, but is still persistant.
Reply
#10
(2013-06-26, 22:56)electrobs Wrote: "I have multiple computers that all suffer from the same issue. If I setup mythtv to use a line in as a channel. XBMC will have buffer issues playing back the video. Though if I pause the video in XBMC and wait 5 seconds and let it play it will play perfectly. Each one of these PCs are a master backend with the XBMC client installed on the same computer. The 3 pcs I have replicated this issue on are:

-2 Pentium 4 HT 3 GHZ PCs, one with a AMD HD 3650, and the other with a Geforce 4 MX
-1 AMD Athlon x2, with a nvidia GT630 video card.

All other dvd quality mpeg2s play fine on these computers and mythtv will playback the video just fine. Only livetv in xbmc has this buffer issue. Also the importance of this is many people like myself setup directv via the line in. Then a script is used for the channel change. In this setup the buffering makes the setup unusable. Though recorded video plays back fine.

On a side note mythtv 0.25 or 0.26 have the exact same issue, no difference. (I also can not test DVB, no digital signals out in my area)."

quoted from:

https://github.com/fetzerch/xbmc-pvr-addons/issues/119


I originally posted the above issue and was told to post this to the forums to see if anyone else has a similar setup with similar issues. Either way this is annoying to say the least and keeps xbmc from being my main frontend for mythbackend.

Hi, your remarks are great for me. Because i haven't any analog tuner since 3 years ago and so i cannot test addon code with them. With DVB it runs without problems. Few months ago i suggested to try pause the playback, but i never have a feedback about. Guys using analog external tuner with buffering haven't your issue also. I think to add possibility to take account of xbmc setting "Delay channel switch" to wait before starting the playback. But i need guys to test it with analog tuner. Are you free to help ? Can build the addon from our git repository ?
Reply
#11
I'm all set to build from your git, just built the frodo branch the other day. I have a PC setup for testing, though response will be slow due to college starting next week. I'm more than able and happy to help.
Reply
#12
(2013-08-21, 04:01)electrobs Wrote: I'm all set to build from your git, just built the frodo branch the other day. I have a PC setup for testing, though response will be slow due to college starting next week. I'm more than able and happy to help.

Hi,

So i pushed an update including a setting "Buffering time after tuning a channel (s)" in the new tab "Playback" of addon settings screen.

Get it from my repos: git clone -b frodo_local_buffering https://github.com/janbar/xbmc-pvr-addons.git addon-test
Goto folder addon-test and if you use Linux
./bootstrap
./configure --enable-addons-with-dependencies
make clean zip

Once done unzip the "addon.zip" ( pvr.mythtv.cmyth-linux-Huh??.zip ) into your xbmc addons folder ( look like ~/.xbmc/addons/ ) replacing your old.

You could start with 0s to check if last improvements help... maybe. If not stop playback then go to addon setting -> tab "Playback" and increase the value as you want. I recommend 20s for the first try to confirm that close the issue for you. Here no need to restart XBMC because the setting is reloaded when you'll restart the playback. Before changing the setting think to stop playback to avoid any crash.

Have a good testing
Reply
#13
Testing this at 0 seconds the issue was still there, but much better than it has been. 5 seconds was about the same. 10 Seconds was almost perfect. 15 seemed to clear up any issue. Switched between channels and had no issue there at 15 seconds. This is great, seeing that XBMC is buffering and a percentage of whats buffered is perfect, Great job.
Reply
#14
Hm... If this works, I'm wondering why tweaking XBMC's advancedsetting's shouldn't work.

@electrobs: Could you test setting the value back to 0 and try adding this to your advanced settings file?
(http://wiki.xbmc.org/index.php?title=Adv...ttings.xml)

Code:
<advancedsettings>
...
    <pvr>
        <minvideocachelevel>20</minvideocachelevel>
        <minaudiocachelevel>20</minaudiocachelevel>
    </pvr>
...
</advancedsettings>

Also please check the log if the values were loaded.
Reply
#15
Quote:12:04:52 T:140670842423168 NOTICE: Loaded settings file from special://profile/advancedsettings.xml
12:04:52 T:140670842423168 NOTICE: Contents of special://profile/advancedsettings.xml are...
<advancedsettings>
<pvr>
<minvideocachelevel>20</minvideocachelevel>
<minaudiocachelevel>20</minaudiocachelevel>
</pvr>
</advancedsettings>
12:04:52 T:140670842423168 NOTICE: Getting hardware information now...

The quote above from my log shows the advanced settings loaded, but make no difference when the playback buffer is set to 0. Setting the buffer back to 15 to 20 seconds again fixes any issues.
Reply

Logout Mark Read Team Forum Stats Members Help
Buffer Issues with MPEG2 cards and line in0