Problems with VAAPI playback

Hi all, I'm running 0.25-fixes on Mythbuntu 12.04 x64, and am using an Ivy Bridge (3750K) CPU in an attempt to get VAAPI playback.

Right now, when I play back a recording with VAAPI (no deinterlacing set) the frontend gives me the usual black screen with "Please wait...", but instead of the recording starting I get about a half-second of audio; the screen goes black, then back to the 'Please wait' screen - and this repeats 4-5 times. After that, the machine freezes completely, and I have to hard-boot it. If I'm lucky, I can press escape during the "Please wait" cycle and get back to the Myth menus.

I've seen references to environment variables like LIBVA_DRIVERS_PATH but I don't have these set; do I need these?

I assume the next request is to ask for a backtrace, but from my reading this requires something to actually crash, right? From what I can tell, I'm not getting a crash, I'm getting a freeze (or a recovery back into the frontend menus). I'm more than happy to be wrong, and to put whatever effort needed into debugging. I ran mythfrontend-real > mythdebug.log, contents of which are here: http://pastebin.com/T44DhReU

(thiis is from one of the times I managed to recover with the escape key)

In case it helps, there were several lines which 'escaped' into the terminal window:

No, actually, this (or some Mythbuntu/Ubuntu forum) is likely the best location to talk about it. Developers wouldn't have any more information on how the Ubuntu packages are compiled and how the system is configured for VAAPI, so you're far more likely to find help from a user who's also trying to go down the same road.

> Or is VAAPI just not > really working yet?

It's, er, temperamental--meaning you/your packager/your system configuration has to do everything exactly right (from installing the right VAAPI libs, to installing the right graphics drivers, to configuring everything properly, to ...). (And then, FWIW, once you get it working, you're left with something significantly less useful than VDPAU.)

> On 05/18/2012 10:12 AM, Geoff B wrote: > >> On Wed, May 16, 2012 at 8:56 PM, Geoff B wrote: >> >>> Hi all, >>> I'm running 0.25-fixes on Mythbuntu 12.04 x64, and am using an Ivy Bridge >>> (3750K) CPU in an attempt to get VAAPI playback. >>> >>> Right now, when I play back a recording with VAAPI (no deinterlacing set) >>> the frontend gives me the usual black screen with "Please wait...", but >>> instead of the recording starting I get about a half-second of audio; the >>> screen goes black, then back to the 'Please wait' screen - and this >>> repeats >>> 4-5 times. After that, the machine freezes completely, and I have to >>> hard-boot it. If I'm lucky, I can press escape during the "Please wait" >>> cycle and get back to the Myth menus. >>> >>> vainfo returns: >>> >>> libva: VA-API version 0.32.0 >>> libva: va_getDriverName() returns 0 >>> libva: Trying to open /usr/lib/x86_64-linux-gnu/dri/**i965_drv_video.so >>> libva: va_openDriver() returns 0 >>> vainfo: VA-API version: 0.32 (libva 1.0.15) >>> vainfo: Driver version: Intel i965 driver - 1.0.15 >>> vainfo: Supported profile and entrypoints >>> VAProfileMPEG2Simple : VAEntrypointVLD >>> VAProfileMPEG2Main : VAEntrypointVLD >>> VAProfileH264Baseline : VAEntrypointVLD >>> VAProfileH264Baseline : VAEntrypointEncSlice >>> VAProfileH264Main : VAEntrypointVLD >>> VAProfileH264Main : VAEntrypointEncSlice >>> VAProfileH264High : VAEntrypointVLD >>> VAProfileH264High : VAEntrypointEncSlice >>> VAProfileVC1Simple : VAEntrypointVLD >>> VAProfileVC1Main : VAEntrypointVLD >>> VAProfileVC1Advanced : VAEntrypointVLD >>> >>> I've seen references to environment variables like LIBVA_DRIVERS_PATH but >>> I don't have these set; do I need these? >>> >>> I assume the next request is to ask for a backtrace, but from my reading >>> this requires something to actually crash, right? From what I can tell, >>> I'm not getting a crash, I'm getting a freeze (or a recovery back into >>> the >>> frontend menus). I'm more than happy to be wrong, and to put whatever >>> effort needed into debugging. I ran mythfrontend-real> mythdebug.log, >>> contents of which are here: >>> http://pastebin.com/T44DhReU>>> >>> (thiis is from one of the times I managed to recover with the escape key) >>> >>> In case it helps, there were several lines which 'escaped' into the >>> terminal window: >>> >>> QFont::setPixelSize: Pixel size<= 0 (0) >>> QFont::setPixelSize: Pixel size<= 0 (0) >>> QFont::setPixelSize: Pixel size<= 0 (0) >>> QFont::setPixelSize: Pixel size<= 0 (0) >>> libva: VA-API version 0.32.0 >>> libva: va_getDriverName() returns 0 >>> libva: Trying to open /usr/lib/x86_64-linux-gnu/dri/**i965_drv_video.so >>> libva: va_openDriver() returns 0 >>> libva: VA-API version 0.32.0 >>> libva: va_getDriverName() returns 0 >>> libva: Trying to open /usr/lib/x86_64-linux-gnu/dri/**i965_drv_video.so >>> libva: va_openDriver() returns 0 >>> >>> Note that OpenGL works fine, albeit with 50%-70% CPU usage. Videos work >>> fine too - it's just recordings that fail. >>> Any help greatly appreciated! >>> >> Based on the silence on this one, there's not a simple solution to this; >> is >> this better suited to the developers mailing list? >> > > No, actually, this (or some Mythbuntu/Ubuntu forum) is likely the best > location to talk about it. Developers wouldn't have any more information > on how the Ubuntu packages are compiled and how the system is configured > for VAAPI, so you're far more likely to find help from a user who's also > trying to go down the same road. > > Thanks Mike - the reason I posted here instead of on a more generic Ubuntu forum is that it does appear to run correctly in VLC, and although I haven't tested in MPlayer yet I suspect it will work fine there too (could of course be wrong about this). What you're saying about the devs makes sense, although I was hoping to find out how I could help provide sufficient debugging info to help. I'll maybe also try the Mythbuntu angle, though (I'm new to Mythbuntu after running Fedora for years).

> Or is VAAPI just not >> really working yet? >> > > It's, er, temperamental--meaning you/your packager/your system > configuration has to do everything exactly right (from installing the right > VAAPI libs, to installing the right graphics drivers, to configuring > everything properly, to ...). (And then, FWIW, once you get it working, > you're left with something significantly less useful than VDPAU.) > > That's what I was afraid of! Nirvana (for me) is to have a small box that contains just the CPU and a small SSD. I've successfully managed to migrate my storage out to a NAS, and I use a HD Homerun Prime for my tuners, so the graphics processing is next.

On 05/18/2012 01:40 PM, Geoff B wrote: > On Fri, May 18, 2012 at 12:08 PM, Michael T. Dean wrote: >> On 05/18/2012 10:12 AM, Geoff B wrote: >>> Based on the silence on this one, there's not a simple solution to this; >>> is this better suited to the developers mailing list? >>> >> No, actually, this (or some Mythbuntu/Ubuntu forum) is likely the best >> location to talk about it. Developers wouldn't have any more information >> on how the Ubuntu packages are compiled and how the system is configured >> for VAAPI, so you're far more likely to find help from a user who's also >> trying to go down the same road. > Thanks Mike - the reason I posted here instead of on a more generic Ubuntu > forum is that it does appear to run correctly in VLC, and although I > haven't tested in MPlayer yet I suspect it will work fine there too (could > of course be wrong about this). What you're saying about the devs makes > sense, although I was hoping to find out how I could help provide > sufficient debugging info to help. I'll maybe also try the Mythbuntu > angle, though (I'm new to Mythbuntu after running Fedora for years).

Yeah, here is fine--there are a lot of *buntu users here. I was just trying to say that you probably want *buntu users to help, and you'll find a lot of them around here versus on the -dev list. And, for that matter, many of the devs actually read this list, so you're likely to get similar

>>> Or is VAAPI just not really working yet? >>> >> It's, er, temperamental--meaning you/your packager/your system >> configuration has to do everything exactly right (from installing the right >> VAAPI libs, to installing the right graphics drivers, to configuring >> everything properly, to ...). (And then, FWIW, once you get it working, >> you're left with something significantly less useful than VDPAU.) > That's what I was afraid of! Nirvana (for me) is to have a small box that > contains just the CPU and a small SSD. I've successfully managed to > migrate my storage out to a NAS, and I use a HD Homerun Prime for my > tuners, so the graphics processing is next. >

Yeah, since NVIDIA dropped out of (got strong-armed out of?*) the x86 chipset business, it has limited the options for systems with integrated NVIDIA graphics (where, typically, you end up getting either discrete or mobile/laptop NVIDIA graphics at extra cost). Since "small" generally means you need the mobile graphics, you're then paying premium price (versus just throwing in a PCIe card at a quite reasonable cost). So, if you want small, powerful, and NVIDIA graphics, you could end up paying for something like http://www.asrock.com/nettop/overview.asp?Model=Vision%203D%20Series(though you can actually build a small, quiet, powerful, and quiet system with NVIDIA graphics for less, but that requires some planning).

My approach for dealing with this is to just go with a big, ugly case, but put it in another room (or closet/cabinet/...) with cables run to the TV and speakers--making the MythTV system even better than small. An invisible MythTV system makes for a clean entertainment center, and because it allows me to use big and ugly, I get significant cooling, noise, and price benefits, without having to settle for a toy.

Mike

* But, funny enough, NVIDIA is doing some strong-ARMing, itself, as it has decided there's life after x86, and seems to be proving that theory correct... _______________________________________________ mythtv-users mailing list mythtv-users [at] mythtv http://www.mythtv.org/mailman/listinfo/mythtv-users

I've been watching this thread hoping for some good answers, too, because I don't think my VAAPI setup is working correctly, either. (I'm on Gentoo) When I tested it, the CPU usage was about 35% (with 1 core enabled in the setup), and the sound was stuttering. I made some MTRR fixes and tested again but now it just timed out with an error message. So, I'm currently using the Slim profile (with about 7-10% CPU) but I'd like to get VAAPI working correctly. I'm annoyed that I apparently can't buy a motherboard with integrated nVidia graphics anymore...