Install MPlayer With VA-API (Hardware Acceleration For Intel / AMD GPUs) Support In Ubuntu

VA-API is an open source library/API which enables hardware accelerated video processing. It uses the GPU to accelerate video processing in order to offload the CPU.

Supported hardware includes Intel HD Graphics and G45 chipsets and newer as well as AMD Radeon GPUs (there's also a Nvidia VDPAU backend for VA-API).

Here's an example: on my laptop, the CPU usage is around 40-50% when watching an 1080p H.264 video using MPlayer without VA-API and around 2-5% when watching the same 1080p video using MPlayer with VA-API. You can see some screenshots below: