Kodi Community Forum
New MythTV add-on using libcmyth - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32)
+--- Forum: Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=26)
+---- Forum: PVR (https://forum.kodi.tv/forumdisplay.php?fid=136)
+---- Thread: New MythTV add-on using libcmyth (/showthread.php?tid=110694)



RE: New MythTV add-on using libcmyth - ubuntu-xbmc - 2013-03-05

(2013-03-03, 13:03)janbar Wrote:
(2013-03-03, 07:16)ubuntu-xbmc Wrote: Janbar.

I just tried your update for a while, and it appears that you've resolved the crashing -- however, I am now seeing very bad mpeg distortion. This isn't my photo, but it is similar in image to what I am seeing.

The distortion begins after about 5 to 8 seconds of high-quality image viewing on the analog channels. The distortion is bad enough to make the content unwatchable. XBMC digital channels are ok, Mythfrontend is ok with analog channels.

The log was very large and wouldn't post to xbmclogs.com so I've posted the first 5000 lines (out of 115k) after beginning to select the channel. I also posted just the lines that had the word "Error" in them into a separate paste file. I'm not sure this enough, if not, let me know what you'd like me to "filter in."

Thanks
Hi, the issue is resolved now. But you have other things not linked with addon. First now disable "extra debug log" to avoid to fill you disk.
Also retry to watch the channel for few minutes and then copy the stream file from mythbackend to your xbmc video folder. Then try to read it using xbmc to see what happend. You can also post the file somewhere, then i can get it to test it. Thanks.

Janbar,

Sorry to take so long -- I had some unrelated XBMC problems. But, I have captured some files from live TV and from pre-scheduled recordings. Both types of files behave the same:

- They are mpeg, even if I uncheck transcoding. I assume this because the capture card is MPEG?
- They play fine in MythFrontend
- They will play fine in XBMC "files mode" as a regular mpeg file
- They will play fine in XBMC MythTV add-on as a "recording"
- They will play in mplayer

- They will not play fine in some other SW -- tested VLC and Movie Player
- They will not play fine in XBMC MythTV add-on in "live TV" mode

This is what mplayer reports about the file:

Code:
ID_VIDEO_ID=0
ID_AUDIO_ID=0
MPEG-PS file format detected.
VIDEO:  MPEG2  720x480  (aspect 2)  29.970 fps  6000.0 kbps (750.0 kbyte/s)
ID_FILENAME=/5008_20130304110000.mpg
ID_DEMUXER=mpegps
ID_VIDEO_FORMAT=0x10000002
ID_VIDEO_BITRATE=6000000
ID_VIDEO_WIDTH=720
ID_VIDEO_HEIGHT=480
ID_VIDEO_FPS=29.970
ID_VIDEO_ASPECT=0.0000
ID_START_TIME=unknown
ID_LENGTH=599.03
ID_SEEKABLE=1
ID_CHAPTERS=0
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
libavcodec version 53.35.0 (external)
Mismatching header version 53.32.2
Selected video codec: [ffmpeg2] vfm: ffmpeg (FFmpeg MPEG-2)
==========================================================================
ID_VIDEO_CODEC=ffmpeg2
Audio: no sound
Starting playback...
V:   0.0   0/  0 ??% ??% ??,?% 0 0

Exiting... (End of file)

Mplayer will play the video, with the following output:

Code:
MPlayer svn r34540 (Ubuntu), built with gcc-4.6 (C) 2000-2012 MPlayer Team

Playing //5008_20130304110000.mpg.
libavformat version 53.21.1 (external)
Mismatching header version 53.19.0
MPEG-PS file format detected.
VIDEO:  MPEG2  720x480  (aspect 2)  29.970 fps  6000.0 kbps (750.0 kbyte/s)
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
libavcodec version 53.35.0 (external)
Mismatching header version 53.32.2
Selected video codec: [ffmpeg2] vfm: ffmpeg (FFmpeg MPEG-2)
==========================================================================
Requested audio codec family [mpg123] (afm=mpg123) not available.
Enable it at compilation.
Opening audio decoder: [ffmpeg] FFmpeg/libavcodec audio decoders
AUDIO: 48000 Hz, 2 ch, floatle, 384.0 kbit/12.50% (ratio: 48000->384000)
Selected audio codec: [ffmp2float] afm: ffmpeg (FFmpeg MPEG layer-1 and layer-2 audio)
==========================================================================
AO: [pulse] 48000Hz 2ch floatle (4 bytes per sample)
Starting playback...
[mp2float @ 0x7f408a731380]Header missing
Unsupported PixelFormat 61
Unsupported PixelFormat 53
Unsupported PixelFormat 81
Movie-Aspect is 1.33:1 - prescaling to correct movie aspect.
VO: [vdpau] 720x480 => 720x540 Planar YV12
[mpeg2video @ 0x7f408a731380]warning: first frame is no keyframe
[VD_FFMPEG] DRI failure.
A:   0.3 V:   0.3 A-V: -0.053 ct:  0.000   2/  2 ??% ??% ??,?% 0 0
[mpeg2video @ 0x7f408a731380]warning: first frame is no keyframe
A:  24.3 V:  24.3 A-V: -0.022 ct: -0.143 721/721 11%  2%  0.8% 0 0

Exiting... (Quit)

And here is what VLC says

Code:
VLC media player 2.0.5 Twoflower (revision 2.0.5-0-g1661b7d)
libva: VA-API version 0.32.0
Xlib:  extension "XFree86-DRI" missing on display ":0.0".
libva: va_getDriverName() returns 0
libva: Trying to open /usr/lib/x86_64-linux-gnu/dri/nvidia_drv_video.so
libva: va_openDriver() returns -1
[0x7f7f28000b78] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1000 ms)
[0x7f7f28000b78] main input error: ES_OUT_RESET_PCR called
[mpeg2video @ 0x7f7f04c4e5a0] warning: first frame is no keyframe
[0x7f7f28000b78] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 1138 ms)
[0x7f7f28000b78] main input error: ES_OUT_RESET_PCR called
[mpeg2video @ 0x7f7f04c4e5a0] warning: first frame is no keyframe
[0x7f7f28000b78] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 2122 ms)
[0x7f7f28000b78] main input error: ES_OUT_RESET_PCR called
[mpeg2video @ 0x7f7f04c4e5a0] warning: first frame is no keyframe
[0x7f7f28000b78] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 3356 ms)
[0x7f7f28000b78] main input error: ES_OUT_RESET_PCR called
[mpeg2video @ 0x7f7f04c4e5a0] warning: first frame is no keyframe
[0x7f7f28000b78] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (pts_delay increased to 5513 ms)
[0x7f7f28000b78] main input error: ES_OUT_RESET_PCR called
[mpeg2video @ 0x7f7f04c4e5a0] warning: first frame is no keyframe
[0x7f7f28000b78] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (jitter of 7973 ms ignored)
[0x7f7f28000b78] main input error: ES_OUT_RESET_PCR called
[mpeg2video @ 0x7f7f04c4e5a0] warning: first frame is no keyframe
[0x7f7f28000b78] main input error: ES_OUT_SET_(GROUP_)PCR  is called too late (jitter of 13484 ms ignored)
[0x7f7f28000b78] main input error: ES_OUT_RESET_PCR called
[mpeg2video @ 0x7f7f04c4e5a0] warning: first frame is no keyframe

I currently don't have a place to upload a test video but I'll look for one.

Thanks,


RE: New MythTV add-on using libcmyth - Den4t - 2013-03-05

Hi Janbar !

I cloned last test branch and compile.
Not help. We returned to case, when video play 3-5 sec,
than stop (buffering) and continue play without audio.
ubuntu-xbmc posted some outputs from mplayer and vlc,
in my xbmc log keyframe warnings exists too when use PVR,
but absent in internal myth://

Fresh logs:
http://xbmclogs.com/show.php?id=2417
http://xbmclogs.com/show.php?id=2418
http://xbmclogs.com/show.php?id=2419

Same session mythbackend -v network,socket:
http://xbmclogs.com/show.php?id=2422

Here is log from internal myth://
http://xbmclogs.com/show.php?id=2423


RE: New MythTV add-on using libcmyth - janbar - 2013-03-06

(2013-03-03, 16:19)Den4t Wrote: Rebuid, no help Sad

Here log:
http://xbmclogs.com/show.php?id=1880 part 1
http://xbmclogs.com/show.php?id=1881 part2

cfetzer and me will test the file with a demo tuner to debug the thing. I will let you know.

br.


RE: New MythTV add-on using libcmyth - tdavis - 2013-03-07

Looks like EDL/Commskip just pulled into xbmc v13.


RE: New MythTV add-on using libcmyth - RipT - 2013-03-07

Just tried the commskip in xbmc-20130307-9c1e763-master-x86_64. It works but there are some bugs:

A recording played in the PVR always starts at the end of the first commercial break. It doesn't matter whether you choose to start from the last played position or the beginning.

SD content plays OK in the PVR, but HD buffers every 10 seconds or so. Both LiveTV and recording playback in the PVR do this. The files play fine when the .mpg file is played directly in XBMC outside the PVR. The backend is on the same machine as XBMC, so no network involved. This wasn't happening with yesterday's nightly, xbmc-20130305-6fe7ebc-master-x86_64, but then, neither was commskip.

I haven't had any luck compiling from source. I get a mostly working XBMC app, but the PVR is always broken. So I've been looking forward to getting the commskip working in the nightlies.

Mac Mini core 2 duo, OSX 10.6.8, Myth 0.25.3 from macports, HDMI output for video and sound.


RE: New MythTV add-on using libcmyth - fetzerch - 2013-03-07

http://wiki.xbmc.org/index.php?title=PVR/Backend/MythTV 4.2
Log or it didn't happen ;-P

So that's interesting. For me it starts at the beginning. Did you say HD contend started to stutter now and did play fine in a 2 days older nightly?
Then it must be somehow related to EDL.


RE: New MythTV add-on using libcmyth - sfrooster - 2013-03-07

(2013-03-07, 20:37)cfetzer Wrote: http://wiki.xbmc.org/index.php?title=PVR/Backend/MythTV 4.2
Log or it didn't happen ;-P

So that's interesting. For me it starts at the beginning. Did you say HD contend started to stutter now and did play fine in a 2 days older nightly?
Then it must be somehow related to EDL.

I'd be happy to test this - how do I get it? I'm able to build from git, I just need to know where in git to get from...


RE: New MythTV add-on using libcmyth - RipT - 2013-03-07

@cfetzer -I know I need to log it. I'm running around right now doing other things. I'll work on a logged session later and submit. You are correct about the stuttering happening now and not yesterday (the dates are 2 days apart for some reason, but it was yesterday's nightly). There were a lot of commits yesterday, so it may be EDL or something else. For instance, advancedsettings.xml was broken yesterday but works today.


RE: New MythTV add-on using libcmyth - fetzerch - 2013-03-07

OK. because of EDL and a couple of more PVR API changes, the PVR API version number changed so you need to be careful to get a matching addon for your specific XBMC build.

If your XBMC is from todays nightly or build from yourself (PVR API 1.7.0), it needs the mythtv addon from the branch fetzerch/master.
If you're running XBMC Frodo or and older nightly (PVR API 1.6.0), it needs the mythtv addon from the branch fetzerch/frodo.

Again: if you continue to build the addon from my master branch, you need an up to date XBMC nightly!

We're going to back port changes to the frodo branch if possible.


RE: New MythTV add-on using libcmyth - richardk - 2013-03-07

(2013-03-07, 21:31)cfetzer Wrote: OK. because of EDL and a couple of more PVR API changes, the PVR API version number changed so you need to be careful to get a matching addon for your specific XBMC build.

If your XBMC is from todays nightly or build from yourself (PVR API 1.7.0), it needs the mythtv addon from the branch fetzerch/master.
If you're running XBMC Frodo or and older nightly (PVR API 1.6.0), it needs the mythtv addon from the branch fetzerch/frodo.

Again: if you continue to build the addon from my master branch, you need an up to date XBMC nightly!

We're going to back port changes to the frodo branch if possible.

I tried the latest nightly for Windows, and I'm not seeing any stuttering (in just a short test). The addon version shows as 1.7.9.


RE: New MythTV add-on using libcmyth - apnar - 2013-03-08

(2013-03-03, 16:21)richardk Wrote: I posted this.

http://www.openelec.tv/forum/110-update-openelec/62828-pvr-cmyth-addon-needs-to-be-updated#65538

Don't know if it'll help, but worth a try.

I'm not sure if it was your post or my PM to sraue but it looks like he bumped the xbmc-pvr-addons in OpenELEC to the latest commit fro the Frodo branch earlier today, which means cmyth 1.6.9 should be included in the next OpenELEC rc as well as the 3.0 final. So good news.


RE: New MythTV add-on using libcmyth - richardk - 2013-03-09

(2013-03-08, 23:46)apnar Wrote:
(2013-03-03, 16:21)richardk Wrote: I posted this.

http://www.openelec.tv/forum/110-update-openelec/62828-pvr-cmyth-addon-needs-to-be-updated#65538

Don't know if it'll help, but worth a try.

I'm not sure if it was your post or my PM to sraue but it looks like he bumped the xbmc-pvr-addons in OpenELEC to the latest commit fro the Frodo branch earlier today, which means cmyth 1.6.9 should be included in the next OpenELEC rc as well as the 3.0 final. So good news.

Great!


RE: New MythTV add-on using libcmyth - RipT - 2013-03-09

OK - I finally got some time to look again, and the stuttering was my mythbackend. It was just a coincidence that it started acting up while I was testing the new xbmc daily.

On the file that started at the end of the first commbreak, That file's first commbreak actually started at the beginning of the file, so it was just automatically skipping to the end of the break as it should. Again, it's myth's fault that the beginning of the show was missed by the commflag program.

I do still have all files starting at the beginning even if I select the option to start at the last played position. I gather from cfetzer #1971 that that was to be expected from this build, and I see a commit in odenkamp's addon code (from cfetzer) yesterday referring to iLastPlayedPosition, so I assume it will be fixed in the xbmc nightly soon. I tried building both fetzerch's and odenkamp's latest addons. They build OK, but I always get the "No PVR Client has started yet" notice when I install them and try to do anything with LiveTV. I've been able to get fetzerch's addon (1.6.9) to work with various XBMC versions before, but no dice since the 1.7.x versions started coming out. The stock 1.7.9 cmyth addon in last night's nightly works OK, excpt for the last played position bug, but I can't get any locally compiled ones to work. A log of a failure with odenkamp's 1.7.10 version is at http://pastebin.com/vqCgLxPg. I also get the same "No PVR client has started" error with even the built in PVR manager addons when I build XBMC from git. It seems to be something in my build environment so I'm not sure if the log helps, but if anyone has any suggestions, I'd appreciate them.


RE: New MythTV add-on using libcmyth - ubuntu-xbmc - 2013-03-10

(2013-03-03, 07:16)ubuntu-xbmc Wrote: ... resolved the crashing -- however, I am now seeing very bad mpeg distortion.
(2013-03-03, 13:03)janbar Wrote: Hi, the issue is resolved now. But you have other things not linked with addon.
...
Also retry to watch the channel for few minutes and then copy the stream file from mythbackend to your xbmc video folder. Then try to read it using xbmc to see what happend.
(2013-03-05, 02:50)ubuntu-xbmc Wrote: ...I have captured some files from live TV and from pre-scheduled recordings. Both types of files behave the same:

- They are mpeg, even if I uncheck transcoding. I assume this because the capture card is MPEG?
- They play fine in MythFrontend
- They will play fine in XBMC "files mode" as a regular mpeg file
- They will play fine in XBMC MythTV add-on as a "recording"
- They will play in mplayer

- They will not play fine in some other SW -- tested VLC and Movie Player
- They will not play fine in XBMC MythTV add-on in "live TV" mode

[from Post1966]

Janbar,

I updated my addon, which now shows:
Quote:@@ -1,3 +1,8 @@
+v1.6.9
+- Added Live TV vs. recording conflict handling
but I am running Frodo and I still have my live TV display issue. Should I update any further?

Can you please check your private messages?

Thanks,


RE: New MythTV add-on using libcmyth - sfrooster - 2013-03-11

I tried installing Xbmc yesterday using ppa:team-xbmc/unstable mostly so I could build/use the latest addon.

I had previously installed using Xbmcbuntu and had been compiling the addon from git://github.com/fetzerch/xbmc-pvr-addons.git (and all was working wonderfully (still is on a different, identical, box)), but understood that I needed the latest version of Xbmc to use it now. So, instead of Xbmcbuntu, I installed Ubuntu 12.04 and then:

Code:
sudo add-apt-repository ppa:team-xbmc/unstable
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install xbmc xbmc-bin

And then built the addon - everything detailed here http://wiki.xbmc.org/index.php?title=PVR/Backend/MythTV/BuildFromSource

But when trying to install the addon from zip, I got a "Dependency not met" error. I then tried to just unzip the zip and install manually, placing pvr.mythtv.cmyth
into /home/xbmc/.xbmc/addons/

This did not work.

Maybe that wasn't the right place to put it? Trying to guess where might be, I ran:

Code:
$ sudo find /usr /home/xbmc -name *mythtv*
/usr/lib/xbmc/addons/pvr.mythtv.cmyth
/usr/share/doc/xbmc-pvr-mythtv-cmyth
/usr/share/xbmc/addons/pvr.mythtv.cmyth
/usr/share/app-install/icons/mythtv.png
/usr/share/app-install/desktop/mythtv-backend:mythtv-setup.desktop
/usr/share/app-install/desktop/mythtv-frontend:mythtv.desktop
/home/xbmc/.xbmc/userdata/addon_data/pvr.mythtv.cmyth
/home/xbmc/.xbmc/addons/plugin.image.flickr/pvr.mythtv.cmyth
/home/xbmc/.xbmc/addons/packages/pvr.mythtv.cmyth-linux-i486.zip
/home/xbmc/.xbmc/addons/packages/pvr.mythtv.cmyth-linux-i486.2.zip
/home/xbmc/pvr.mythtv.cmyth-linux-x86_64.zip

The last line showing the result of the addon build I did. It's x86_64, whereas the addons that came bundled are i486 (the two lines above it?).

I am confused. What do I need to do to be able to run the latest (possibly wildly unstable) version of this plugin? Have I built it already and just need to install it in a different directory (maybe /usr/lib/xbmc/addons/)?

Or maybe I need to install Xbmc in a different way altogether (v13 alpha - where do I get that)?

Any help is greatly appreciated.