Slashdot Log In
Hardware-Based Video Acceleration Coming To Linux
Posted by
kdawson
on Fri Jul 11, 2008 07:13 AM
from the buh-bye-frame-skipping dept.
from the buh-bye-frame-skipping dept.
sammydee writes "Phoronix reports that GPU based video decoding acceleration will be implemented in Gallium3d sometime this year. Drivers currently using Gallium3d include the open source nouveau driver for NVIDIA cards and experimental Intel GMA drivers. This is definitely good news for anybody who has ever tried to play high-definition 1080p content on any CPU older than about a year."
Related Stories
This discussion has been archived.
No new comments can be posted.
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
Full
Abbreviated
Hidden
Loading... please wait.
Extremely stupid (Score:3, Interesting)
Re:Extremely stupid (Score:5, Informative)
Parent
Not 1 year (Score:2)
My thoughts on this are that if you want to watch 1080p on your computer, you probably have a fast enough processor by now anyway. If its an HTPC, the power you save on the CPU is just going to be redistributed to the GPU. If you want to play HD content on
Re:Not 1 year (Score:5, Informative)
Parent
Re:Not 1 year (Score:5, Funny)
Uhm ... just read through that wiki entry a few times, and it gave me absolutely no information about the quality of the playback. Two of the comments in the "report" are usefull - the rest are quite literally useless when it comes to judging the playback ability. I.e
Wauw. How about ... video frame rate vs playback frame rate? The above comment just tells me that the guy ripped Casino Royale. However, if the video frame rate is 29.97 fps, but only plays back at 19.87, the CPU isn't usefull for that particular application.
Parent
Re: (Score:3, Insightful)
MythTV uses mplayer to play the videos. So really, your solution is exactly what MythTV uses, except MythTV gives you a nice interface for a TV set.
And 1080i is about half the bandwidth of 1080p. There's a big difference between decoding the two.
Re: (Score:3, Informative)
Don't know if I've missed something, but it seems your video decoding is GPU accelerated.
Re:Not 1 year (Score:4, Interesting)
Dual-core 2.5Ghz AMD. In the same boat.
720p x264 works, though. I'm told there are MAJOR improvements in the new versions of ffmpeg that allow multi-threaded playback. I've been to chicken to upgrade my MythTV box to find out.
Parent
Re: (Score:3, Interesting)
Actually, there's an extra flip-flop step in there. When DVD's FIRST came out, hardware decoders were quite common. I remember DVD drives commonly coming with PCI hardware decoders (the RealMagic Hollywood+ was common) because at the time, many home computers simply didn't have the horsepower to pull off real-time MPEG2 decoding. My computer system when I got my first DVD drive was an AMD K6-2 450Mhz and software encoders couldn't keep up and I'd get occasional video stuttering. My hardware DVD decoder c
Re: (Score:3, Informative)
Actually, there's an extra flip-flop step in there. When DVD's FIRST came out, hardware decoders were quite common. I remember DVD drives commonly coming with PCI hardware decoders (the RealMagic Hollywood+ was common) because at the time, many home computers simply didn't have the horsepower to pull off real-time MPEG2 decoding. My computer system when I got my first DVD drive was an AMD K6-2 450Mhz and software encoders couldn't keep up and I'd get occasional video stuttering. My hardware DVD decoder card
Re:Extremely stupid (Score:5, Informative)
I think the point is that it is CPU dependent if you don't have any assistance from video hardware acceleration, as is the case if your video drivers are incomplete.
Parent
Re: (Score:3, Informative)
That the hardware supports it does not mean that the driver supports it.
Re:Extremely stupid (Score:5, Interesting)
Part of the problem with hardware accelerated video decoding on Linux is that because Windows uses the accelerated video decoding to play back DRM protected media, the hardware companies cannot reveal how the video decoding part works (since it would presumably allow someone to grab the unencrypted-but-compressed video for various DRM protected video files by writing a windows driver or something)
Parent
Don't know what to say ... (Score:4, Interesting)
Wow, wish I'd known.
Re:Don't know what to say ... (Score:4, Informative)
If it's any consolation, GPU accelerated playback on Windows doesn't work all that often, and open source codecs/players tend to be the better ones there speed and support wise, acceleration or no.
Parent
Re:Don't know what to say ... (Score:4, Insightful)
Your post,with the allegedly,and supposed to,kinda makes me think of a good point: How are we supposed to know whether or not these things actually do what they say they do? What I mean is,tomorrow they could say this thing can decode format X,Y,Z,but when you actually TRY to find a way of getting to decode X-Z,you get this maze of "allegedly" and "supposed to" and this endless hunt through forums where we are told to buy this or that programs that "should" do it,maybe.
These things are such black box hardware that short of someone actually getting it to work through CUDA I have no way of knowing without shelling out a bunch of cash and hoping my configuration works with their voodoo that the thing actually works. They can claim it'll render every codec known to man but if the only way to do it is some special driver that they don't offer to the public,how can that count? We can test for framerate,render quality,etc,but how do we accurately test for this? All Nvidia offers is a single Mpeg 2 codec for $20. I could not find anywhere where they would sell me an .mp4 codec for the card. And why are they allowed to tout this "feature" if there is no way to actually get the feature without shelling out more money to some third party that they don't even guarantee will work?
Everyone else has to put disclaimers like "batteries not included",but while I can go to the corner store for batteries,I am supposed to...what.write my own driver? Shell out a bunch of cash playing "guess which codec might work"? It seems like a total scam to me,because they are touting a "feature" that 90% of their audience will never be able to use for lack of a freakin' driver.But as always this is my 02c,YMMV
Parent
Re:Don't know what to say ... (Score:5, Informative)
Playing a video is no problem.
The problem is that a high-bitrate 1080p video stream requires a lot of CPU time to decode, and then you have to transfer the whole uncompressed frame out to the video card.
Unless you have a really high-end CPU, there are no Windows-based video players capable of doing this with just software. They all require some kind of hardware acceleration. The specs for all this are nicely closed up, and are known only to Microsoft, video card manufacturers, and the few companies that implement video decoders (which is probably Microsoft again).
Video card manufacturers like nVidia have refused to implement any kind of video decoding in their Linux drivers until there's an appropriate spec. They won't tell anyone what they're hardware is actually capable of, so nobody else can write a spec. We can't even reference Microsoft's basic design, because it's all closed off and secret.
Oh, and most of it doesn't even work properly in Windows either. I've never managed to get it to work at all, and benchmarks I've seen seem to suggest that it's really only offloading 10% or so of the workload. Just enough to make the difference between working and not working, but not as much as it could be.
The Gallium guys are planning to implement the entire thing in their video drivers, using only the 3D capabilities that video cards are known to have. That neatly bypasses the whole thing, but required that we have a single base driver to work with (which Gallium provides), and one or more video drivers actually using it (which, again, Gallium provides).
I kind of hope that Gallium implements something similar to nVidia's CUDA - a programming model for running stuff on graphics cards that doesn't rely on graphics-related stuff like textures or polygons. That way, we'd have a way to implement different kinds of video decoders, encoders, or even things like physics simulations. Bonus points if it can be made compatible with something available on Windows...
That said... Linux video players tend to be a hell of a lot quicker than Windows video players. I've played videos in Linux that were impossible to play in Linux.
Parent
Re:Don't know what to say ... (Score:5, Funny)
I've played videos in Linux that were impossible to play in Linux.
You should try Linux next time.
Parent
Re:Don't know what to say ... (Score:4, Funny)
That said... Linux video players tend to be a hell of a lot quicker than Windows video players. I've played videos in Linux that were impossible to play in Linux.
Quite an accomplishment!
Parent
1080p? (Score:2, Funny)
first 1080p post?
Re:1080p? (Score:5, Funny)
What does this message say? It doesn't display on my computer.
Parent
Already there (Score:5, Informative)
nVidia's binary drivers and X.org's Intel drivers have had XvMC support for well over a year. I've been using both card successfully with Xine and accelerated 1080p video. I think the news here is that the nouveau project is catching up, but that's hardly clear from the article.
Speaking of Xine (Score:5, Informative)
Xine has supported hardware accelerated DVD video (MPEG1/2) decoding using EM8300 based cards [sourceforge.net] like Sigma Design's Holywood+ and Creative's DXR3, since about 2000.
(But that was done using an ad-hoc module inside Xine, not using generic APIs like XvMC or the future Gallium3d video)
The Gallium3D Video API is a good news, because it'll probably be able to address shortcommings that XvMC has [wikipedia.org].
Parent
Re: (Score:3, Informative)
I copied this from Wikipedia:
Re: (Score:3, Interesting)
The LLVM approach is interesting. They're basically following Apple's lead here, whose drivers use LLVM intermediate bytecode to compile shaders to either a GPU or CPU depending on hardware availability and heuristics. It basically makes it easier to support new hardware and provide relatively high-performance fallbacks in the case specific hardware capabilities are not present. All using a common architecture instead of one-off development.
Re: (Score:3, Interesting)
1080p with XvMC and which codec? I thought XvMC didn't do x264, for instance.
Was there, nearly gone (Score:4, Informative)
XvMC does only accelerate MPEG-2, and not many use it, because the de-interlacing you can get sucks. And for MPEG-2, you usually don't need hardware acceleration anyway.
nVidia, like ATI, are moving away from video overlays and have some pretty nice GPU-based video decoding built into their cards using the GPU (most of it probably implemented as shader programs).
But you can't use any of that with linux, you are basically down to hardware video scaling, which the newest cards no longer really support.
It is high time for a new, industry standard API for video. I hope that's what they are doing.
Parent
Re: (Score:3, Interesting)
I'm confused - what happened a year ago? nVidia's binary drivers have had XvMC support for their older cards for many years, whereas for the 8xxx series of cards their drivers lack XvMC support *still* (at least as of the version 173.14.05 I installed a couple months ago).
Re: (Score:2)
MEPG2 might be a little outdated on the internet, as most things older than about 5 minutes are. But it's still the standard for OTA HDTV. If you use an antenna for HDTV, you use MPEG2. And many people still do it for local channels as Cable and Sat operators are starting to re-compress the data enough that people with large sets are noticing a quality difference.
And it's free, so why not use it? :) Not that I have a problem with supporting more codecs with hardware accelerated decode. May as well have that
Google summer of code... (Score:5, Informative)
This is apparently a google summer of code project.
While I am hopeful, let's not write this one on stone until it's released.
Not really (Score:5, Interesting)
This is definitely good news for anybody who has ever tried to play high definition 1080p content on any CPU older than about a year.
Actually, one of the most preeminent examples of HW decoding of video nowadays is the Intel Atom processor, not really old processors.
Video accel. is inside the chipset for this one.
And yes, it is available in Linux, you will probably be able to watch h264 movies in your new EEEPC
Re: (Score:2)
If you actually could read, you'd notice that it says "on any CPU older than about a year", i.e. not Atom or any other CPU fast enough to decode 1080p h264. You know, Celerons and stuff.
Re:Not really (Score:4, Funny)
And yes, it is available in Linux, you will probably be able to watch h264 movies in your new EEEPC
Yay, 1080p movies on my seven inch screen! Plus I can even hook it up to my newly acquired 35:000 contrast ratio, 24p capable, 1080p fifty-two inch flat TV through a VGA connexion! HURRAY!
;)
Relax, I'm just poking fun.
Parent
What about software? (Score:2, Interesting)
Last time I was trying to play HD video on my Ubuntu - with both Xine and Mplayer - I hadn't noticed that there was performance problem related to lack of HW acceleration. (I didn't tried VLC - it can't even playback smoothly HD video on Windows where such acceleration is already available.)
While CPU load was remaining low (~25% on dual core CPU), 720p video still was playing with terrible jitter. In Mplayer few minutes later A/V sync (as usually) went south. Xine started dropping frames. All that while
Re:What about software? (Score:5, Informative)
VLC works great for me on the windows boxes I use for my home media system. Plays HD contect fine.
The one in the living room is a Core2 1.8 with 1.5 of ram with an ATI 2400 HD card and no problems with HD acceleration in XP.
I do not game much, so this 59 dollar HD card has been great.
Workstation is same setup, with two gigs of ram and vista, no problems with HD video.
Server side is a linux box which runs headless. /all rooms have a pc attached to the tv /my guests can surf the web, watch movies, videos /or grab a wireless rumblepad and play any mame game of their choosing.
Parent
Re: (Score:3, Informative)
It may be with your filesystem, drives or possibly just NVidia. An Athlon X2 4600+ drives 1080p video for me fine, but I use an RS690 embedded chip (AMD x1250).
When for Gallium3D or Nouveau (Score:2)
Both of these are relatively new projects. From what I've seen, neither has any sort of releases or snapshots, you build from a checkout.
Any idea when I might be able to get a Jocular Jaguar (or Kooky Kangaroo or Languid Lemur) LiveCD and have them part of the base install? Or for that matter, have 'emerge --sync && ARCH="x86" USE="gallium3d" emerge nouveau' install them as "stable".
PS3 and future possibilites (Score:2, Interesting)
Re: (Score:3, Informative)
PS3 Linux has slow video because Sony blocks access to 2D and 3D acceleration on the Nvidia chipset. This project uses 3D shaders to accelerate video decoding. So I'm struggling to see how using advanced 3D functionality that PS3 Linux doesn't have to replace basic 2D functionality that PS3 Linux doesn't have is going to help.
Gallium running out (Score:5, Funny)
Have some respect for Mother Earth...
And (Score:2)
Nearly-as-important things like Folding!
Re: (Score:2)
That would be the crushing blow to all gaming for windows if it works as you are suggesting. I don't know enough about software to make a statement on it.
Also though, doesn't VLC linux handle H.232 or whatever it's called and other 1080p stuff?
Re: (Score:3, Insightful)
The point isn't that Linux doesn't have codecs to play play hi-def content, the point is that there apparently are no Linux drivers out there that make use of the HD video acceleration hardware that is currently available.
As for having yet another API to go through, I fail to see how it would be a 'crushing blow to all gaming for Windows', since even if it did have perfect Direct3D compatibility, it would simply make it easier to port Windows games to Linux. We already have Direct3D support through WINE, an
Re: (Score:2)
Does Gallium then have to have appropriate interfaces to nVidia/ATI's version of OpenGL? It seems like this is a case of improper implementation of specifications, like people having to write websites directly to work with IE, rather than writing them to comply with web standards..
Re: (Score:3, Informative)
And yes, VLC Linux does support h.264 playback, but 1080p videos are likely to display stuttering if not GPU-accelerated: I tested it on my machine, CPU is an Athlon X2 5600+ and GPU is a Geforce 8800GTS; anything up to 720p was fine, but 1080p was unwatchable prior to installing nVidia Purevideo [wikipedia.org].
P.S.: Seems 1080i is fine too if not GPU-accelerated.
Re: (Score:2, Funny)
Hardware Accelerated High Definition Pr0n vids Coming To Linux
Re: (Score:3, Insightful)
Re: (Score:2)
VGA was probably the most open video standard for hardware programming. Once you know what all the different registers were for, you could do all sorts of fun things, like having paged framebuffers, one super big 256-color framebuffer larger than the actual screen size, or reprogram the hardware video font.
That's probably what they fear - having lots of people trying out different ideas, rather than having one company (Microsoft) deciding their future for them.
Re: (Score:2)
There, fixed that for you. nVidia not releasing specs means you have to use their drivers. Intel not releasing specs for x86 would mean you can't do anything with it, fullstop. Yes, some OSes end up in a similar situation, but I don't see the Amiga OS crew complaini
Re: (Score:2, Informative)
IIRC XvMC is only MPEG2 and not AVC (=x264?), VC-1, more common HD codecs.