Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
MythTV VDPAU .21 backport patch
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Wed Jan 28, 2009 12:29 pm    Post subject: MythTV VDPAU .21 backport patch Reply with quote

Mythtv vdpau backport to .21 ebuilds for Gentoo

Advantages are much smoother video playback & much much lower CPU utilization.

This is an ebuild for gentoo that adds vpdau support to Mythtv. The patch backport was done by Jean-Yves Avenard and can be found here:
http://www.avenard.org/files/mythtv-vdpau/

Create a local overlay with path media-tv/mythtv, e.g:

Code:

mkdir -p /usr/portage/local/overlay/media-tv/mythtv/
mkdir -p /usr/portage/local/overlay/media-tv/mythtv/files
cp /usr/portage/media-tv/mythtv/files/mythbackend-0.18.2.rc /usr/portage/local/overlay/media-tv/mythtv/files/
echo "PORTDIR_OVERLAY=/usr/portage/local/overlay" >> /etc/make.conf


This patch requires at least nVidia drivers 180.29 (see below)
Download the patch & unzip : http://www.avenard.org/files/media/vdpau/mythtv-fixes-glvdpau20744.patch.gz to /usr/portage/local/overlay/media-tv/mythtv/files
Download the ebuild & unzip : http://www.linuxsystems.com.au/mythtv/mythtv-0.21_p20744.ebuild.gz to /usr/portage/local/overlay/media-tv/mythtv/

Then run these commands to install:

Code:

cd /usr/portage/local/overlay/media-tv/mythtv/
ebuild mythtv-0.21_p20744.ebuild digest
emerge mythtv


Once it is installed open mythfrontend & go to "Setup, TV Settings, Playback & Add a new Playback profile.
Select vdpau for both the decoder & renderer. For the deinterlace method start with Bob 2X which works well on my geforce 8400GS card with 512mb ram.
Depending on your card the other de-interlacers may work as well. Using the patch reduces the CPU load on my AMD sempron 3300 by about 40% when watching HD video.


Last edited by col on Sun Aug 02, 2009 11:12 pm; edited 22 times in total
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Tue Feb 10, 2009 12:50 pm    Post subject: Reply with quote

A new nvidia driver is available so bump your nvidia driver up to 180.29 for this patch. This is how to bump to the current version :

First add x11-drivers/nvidia-drivers to your package.keywords and then bump the driver to 180.29 as follows:

Code:

mkdir -p /usr/portage/local/overlay/x11-drivers/nvidia-drivers/
cd /usr/portage/x11-drivers/nvidia-drivers/
cp /usr/portage/x11-drivers/nvidia-drivers/nvidia-drivers-180.35.ebuild  /usr/portage/local/overlay/x11-drivers/nvidia-drivers/nvidia-drivers-180.35.ebuild
ebuild nvidia-drivers-180.35.ebuild digest
emerge nvidia-drivers


shut down X windows....then:

Code:

rmmod nvidia
startx


This will re-load the newer nivdia module.


Last edited by col on Tue Mar 10, 2009 10:00 pm; edited 4 times in total
Back to top
View user's profile Send private message
fangorn
Veteran
Veteran


Joined: 31 Jul 2004
Posts: 1886

PostPosted: Tue Feb 10, 2009 2:49 pm    Post subject: Reply with quote

One comment:
It is not a good idea to put customized ebuilds in /usr/portage. With the next "emerge --sync" they would be gone. Put them in a seperate overlay.
_________________
Video Encoding scripts collection | Project page
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Tue Feb 10, 2009 10:10 pm    Post subject: Reply with quote

The ebuild will be overwritten only if a newer ebuild is released in portage. Otherwise they remain untouched.

edit....updated the howto for overlay


Last edited by col on Wed Feb 18, 2009 1:40 pm; edited 1 time in total
Back to top
View user's profile Send private message
fangorn
Veteran
Veteran


Joined: 31 Jul 2004
Posts: 1886

PostPosted: Wed Feb 11, 2009 12:45 pm    Post subject: Reply with quote

OK, the package.provided method is new to me, but for me it still makes more sense to keep a seperate overlay containing just the 10-20 ebuilds that I really need.
_________________
Video Encoding scripts collection | Project page
Back to top
View user's profile Send private message
kabage
Guru
Guru


Joined: 31 Jan 2005
Posts: 340

PostPosted: Thu Feb 12, 2009 2:33 am    Post subject: vdpau is use flag Reply with quote

in 19968. Might want to adjust the howto or remind users to adjust config files accordingly
_________________
The solutions are easy. Its finding them that is hard.
Back to top
View user's profile Send private message
kabage
Guru
Guru


Joined: 31 Jan 2005
Posts: 340

PostPosted: Fri Feb 13, 2009 4:20 am    Post subject: Bump Reply with quote

Bump to 19970, if you please

Thank you
_________________
The solutions are easy. Its finding them that is hard.
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Tue Feb 17, 2009 4:16 am    Post subject: Reply with quote

bumped to 19990....several VDPAU fixes:

http://www.avenard.org/media/MythTV_%26_VDPAU/MythTV_%26_VDPAU.html
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Wed Feb 18, 2009 1:31 pm    Post subject: Reply with quote

bumped to 20005....more fixes

Tidy up VDPAU::Decode - handle decoder errors more gracefully and be more tolerant of transient corruption in the video stream.
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Sat Feb 21, 2009 11:05 pm    Post subject: Reply with quote

bumped to 20018....more fixes

http://www.avenard.org/media/MythTV_%26_VDPAU/Entries/2009/2/20_Patch_20018.html


edit: unfortunately some h264 videos still crash my mythfrontend. Hope this gets fixed soon.
Back to top
View user's profile Send private message
woZa
Guru
Guru


Joined: 18 Nov 2003
Posts: 340
Location: The Steel City - UK

PostPosted: Tue Mar 17, 2009 7:12 pm    Post subject: Reply with quote

Not had a chance to try this yet but just emerged it and now have no mythbackend init script...? Will remerge the portage version, save the scripts and then copy them back once merged this version again.
_________________
A few months struggling with gentoo is better than a lifetime struggling with windoze!
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Wed Mar 18, 2009 1:32 am    Post subject: Reply with quote

woZa wrote:
Not had a chance to try this yet but just emerged it and now have no mythbackend init script...? Will remerge the portage version, save the scripts and then copy them back once merged this version again.


Never had this problem myself. Here is the init script:

Code:

#!/sbin/runscript
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-tv/mythtv/files/mythbackend-0.18.2.rc,v 1.8 2007/06/12 15:49:37 cardoe Exp $

depend() {
        # future note for me, backend doesn't have to run on
        # same machine as MySQL so should be use
        need net
        use mysql lircd LCDd
}

start() {
        [ -z "${MYTH_VERBOSE}" ] && MYTH_VERBOSE="important,general"

        export QTDIR=/usr/qt/3
        export HOME=/etc/mythtv

        #fixes for bug #101308
        unset DISPLAY
        unset SESSION_MANAGER

        # Work around any strange permissions that may be on these files.
        chown -R mythtv /var/log/mythtv/
        chown -R mythtv /etc/mythtv/
        rm -rf /etc/mythtv/.qt

        ebegin "Starting MythTV Backend"
        start-stop-daemon --start --quiet --chuid root \
                --exec /usr/bin/mythbackend \
                --make-pidfile --pidfile /var/run/mythbackend.pid \
                --background -- --verbose ${MYTH_VERBOSE} \
                --logfile /var/log/mythtv/mythbackend.log
        eend $?
}

stop () {
        ebegin "Stopping MythTV Backend"
        start-stop-daemon --stop --quiet --pidfile=/var/run/mythbackend.pid
        eend $?
}

Back to top
View user's profile Send private message
woZa
Guru
Guru


Joined: 18 Nov 2003
Posts: 340
Location: The Steel City - UK

PostPosted: Wed Mar 18, 2009 8:50 am    Post subject: Reply with quote

Strange... Thanks for that anyways. Now I need my new TV to arrive so I can try out lots of nice HD stuff. Old one just broke!
_________________
A few months struggling with gentoo is better than a lifetime struggling with windoze!
Back to top
View user's profile Send private message
tld
Veteran
Veteran


Joined: 09 Dec 2003
Posts: 1816

PostPosted: Fri Mar 20, 2009 7:34 pm    Post subject: Reply with quote

woZa wrote:
Not had a chance to try this yet but just emerged it and now have no mythbackend init script...? Will remerge the portage version, save the scripts and then copy them back once merged this version again.


I'm not sure, but this might occur if you fail to copy the files directory under media-tv/mythtv to your portage overlay. The ebuild looks for the init script in ${FILESDIR}"/mythbackend-0.18.2.rc. In any case you could always copy /usr/portage/media-tv/mythtv/files/mythbackend-0.18.2.rc to /etc/init.d/mythbackend.

Tom
Back to top
View user's profile Send private message
woZa
Guru
Guru


Joined: 18 Nov 2003
Posts: 340
Location: The Steel City - UK

PostPosted: Fri Mar 20, 2009 10:58 pm    Post subject: Reply with quote

Ah that was it! Thought I'd done that...

Thanks!
_________________
A few months struggling with gentoo is better than a lifetime struggling with windoze!
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Sat Mar 21, 2009 8:37 pm    Post subject: Reply with quote

Ok I have updated the howto with :

cp /usr/portage/media-tv/mythtv/files/mythbackend-0.18.2.rc /usr/portage/local/overlay/media-tv/mythtv/files/

Also bumped it up to version mythtv-fixes-glvdpau20212.patch which contains a few more bug fixes.
Back to top
View user's profile Send private message
erpalma
n00b
n00b


Joined: 19 Feb 2008
Posts: 17

PostPosted: Fri May 08, 2009 9:37 am    Post subject: Reply with quote

Could you update ebuild to the latest version?

Thanks
Back to top
View user's profile Send private message
woZa
Guru
Guru


Joined: 18 Nov 2003
Posts: 340
Location: The Steel City - UK

PostPosted: Thu May 14, 2009 10:05 am    Post subject: Reply with quote

erpalma wrote:
Could you update ebuild to the latest version?

Thanks


Just rename the ebuild above to mythtv-0.21_p20553.ebuild, digest and emerge.

Worked for me...

<edit>Even better, rename the ebuild as above, download the latest patch from http://www.avenard.org/media/MythTV_%26_VDPAU/MythTV_%26_VDPAU.html, extract it into the files directory, edit the renamed ebuild (line 85) and change the patch name to the one you have just downloaded, then digest and emerge</edit>
_________________
A few months struggling with gentoo is better than a lifetime struggling with windoze!
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Tue Jun 09, 2009 12:29 am    Post subject: Reply with quote

bumped to 20658 patch. Yes you can simply rename the ebuild otherwise I have updated to the latest version which is now very stable on my system. The only problem I have is some mkv videos dont play for me using mythvideo but you can play these with mplayers vdpau.

Make sure you read the FAQ:

http://www.avenard.org/media/MythTV_%26_VDPAU/MythTV_%26_VDPAU.html

important to have this in your xorg.conf

Add to your xorg.conf:
Code:

Section "Extensions"

    Option         "Composite" "Disable"

EndSection
Back to top
View user's profile Send private message
Cypher0117
n00b
n00b


Joined: 24 Dec 2008
Posts: 32

PostPosted: Tue Jun 09, 2009 5:12 am    Post subject: Reply with quote

Hey col just an FYI (at least this happened to me anyways)

This was the 1st time i saw this article and tried it out but it kept failing until i realized that the ebuild was calling for the previous patch. It's not calling for 20658, it's calling for 20549.

Code:

 * Cannot find $EPATCH_SOURCE!  Value for $EPATCH_SOURCE is:
 *
 *   /usr/local/portage/media-tv/mythtv/files/mythtv-fixes-glvdpau20549.patch
 *   ( mythtv-fixes-glvdpau20549.patch )
 *
 * ERROR: media-tv/mythtv-0.21_p20658 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_prepare
 *             environment, line 3587:  Called epatch '/usr/local/portage/media-tv/mythtv/files/mythtv-fixes-glvdpau20549.patch'
 *             environment, line 1710:  Called die
 * The specific snippet of code:
 *                   die "Cannot find \$EPATCH_SOURCE!";
 *  The die message:
 *   Cannot find $EPATCH_SOURCE!
 *
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/media-tv/mythtv-0.21_p20658/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/media-tv/mythtv-0.21_p20658/temp/environment'.
 * This ebuild is from an overlay: '/usr/local/portage/'


That was the error i kept getting, but was fixed when i downloaded and installed the previous (20549) patch.
Back to top
View user's profile Send private message
woZa
Guru
Guru


Joined: 18 Nov 2003
Posts: 340
Location: The Steel City - UK

PostPosted: Tue Jun 09, 2009 9:09 am    Post subject: Reply with quote

Cypher0117 wrote:
Hey col just an FYI (at least this happened to me anyways)

This was the 1st time i saw this article and tried it out but it kept failing until i realized that the ebuild was calling for the previous patch. It's not calling for 20658, it's calling for 20549.

Code:

 * Cannot find $EPATCH_SOURCE!  Value for $EPATCH_SOURCE is:
 *
 *   /usr/local/portage/media-tv/mythtv/files/mythtv-fixes-glvdpau20549.patch
 *   ( mythtv-fixes-glvdpau20549.patch )
 *
 * ERROR: media-tv/mythtv-0.21_p20658 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_prepare
 *             environment, line 3587:  Called epatch '/usr/local/portage/media-tv/mythtv/files/mythtv-fixes-glvdpau20549.patch'
 *             environment, line 1710:  Called die
 * The specific snippet of code:
 *                   die "Cannot find \$EPATCH_SOURCE!";
 *  The die message:
 *   Cannot find $EPATCH_SOURCE!
 *
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/media-tv/mythtv-0.21_p20658/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/media-tv/mythtv-0.21_p20658/temp/environment'.
 * This ebuild is from an overlay: '/usr/local/portage/'


That was the error i kept getting, but was fixed when i downloaded and installed the previous (20549) patch.


Instead of regressing, why don't you download the latest patch (that the ebuild is looking for) from the link given above and edit the ebuild to look for the latest patch (as shown above)?
_________________
A few months struggling with gentoo is better than a lifetime struggling with windoze!
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Tue Jun 09, 2009 10:15 am    Post subject: Reply with quote

Sorry....my mistake. Not only do you need to rename the ebuild you also need to change the patch file name within the ebuild. I have fixed the ebuild for patch #658

you may need to redigest the fixed ebuild:

ebuild mythtv-0.21_p20658.ebuild digest
Back to top
View user's profile Send private message
drescherjm
Advocate
Advocate


Joined: 05 Jun 2004
Posts: 2790
Location: Pittsburgh, PA, USA

PostPosted: Wed Jun 10, 2009 3:26 am    Post subject: Reply with quote

BTW for any who are interested, I have this in my gentoo overlay and I have just commited mythtv-0.21_p20658 with the vdpau, hdpvr and
opengl patches to my overlay. This also includes most if not all of the plugins bumped to 20658 as well.

For vdpau in mythtv I added a vdapu use flag. Without this flag the vdapu patch is not used.

I had to mask sandbox-2.0 for this to install for some reason it got an ACCESS_VIOLATION but showed nothing in the log. Reinstalling sandbox-1.9 did away with this issue.

There is also an ebuild for nvidia-drivers-185.18.14 which I use.

[EDIT]A user pointed out that the hdpvr support needed an additional patch to run successfully

http://cvs.mythtv.org/trac/ticket/5604

I added that here:

http://github.com/drescherjm/jmdgentoooverlay/commit/dd5cecefa589a529a6ba656c40f87d02f4454646

I also added a hdpvr use flag to the ebuild (mythtv-0.21_p20658-r1) that will be needed to activate the hdpvr support.

Thanks Jeremy

[/EDIT]
_________________
John

My gentoo overlay
Instructons for overlay
Back to top
View user's profile Send private message
col
l33t
l33t


Joined: 08 May 2002
Posts: 820
Location: Melbourne - Australia

PostPosted: Sun Aug 02, 2009 11:13 pm    Post subject: Reply with quote

bumped to 20744

working well for me....
Back to top
View user's profile Send private message
drescherjm
Advocate
Advocate


Joined: 05 Jun 2004
Posts: 2790
Location: Pittsburgh, PA, USA

PostPosted: Mon Aug 03, 2009 10:07 am    Post subject: Reply with quote

col wrote:
bumped to 20744

working well for me....


Same here. I think I updated to 20744 about a month ago and I have been using it ever since.
_________________
John

My gentoo overlay
Instructons for overlay
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum