Tuesday, July 5, 2016

Make VLC Use Less Battery

How to Make VLC Use Less Battery by Enabling Hardware Acceleration



Various tests–like this one at PCWorld–show Windows 10’s Movies & TV app offering more than double the battery life of VLC and other video players. This is because Movies & TV uses hardware acceleration, though, and VLC can too–you just have to enable it first. Then, you’ll be able to enjoy the advanced features of your favorite video player without the battery hit.

This is also why you’ll see new laptops and tablets advertised with long “video playback” battery life measured while playing videos in Windows 10’s integrated Movies & TV application. It’s all about hardware acceleration–Movies & TV uses hardware acceleration by default, but many other applications don’t.

What Is Hardware Acceleration?


There are several different ways to play back a video. One is through “software decoding”. A video player reads the video file and decodes the information using your computer’s processor, or CPU. Modern CPUs can handle this and provide smooth video just fine, but the CPU isn’t really optimized for doing this type of math.

Hardware accelerated decoding, however, is much more efficient. With hardware acceleration, the CPU hands off the decoding work to the graphics processor (GPU), which is designed to accelerate the decoding (and encoding) of certain types of videos. In a nutshell, the GPU can do certain types of math faster and with less electricity required. That translates to longer battery life, less heat, and smoother playback on slow computers.

The only catch? Hardware acceleration is only available for certain video codecs. In general, when you rip or download videos, you should use H.264 (which is pretty popular these days, so it shouldn’t be hard to find). These often have the .mp4 file extension. Hardware acceleration is most widely available for this type of video.

Unfortunately, many modern video players–VLC included–don’t bother using hardware acceleration by default, even if they support it. So you need to turn it on yourself.

How to Enable Hardware Acceleration in VLC


You should definitely enable hardware acceleration if you’re using VLC on a laptop or tablet. The only reason not to do so is that this may cause compatibility problems on some systems, particularly older computers with buggy hardware drivers. If you encounter a problem with playing video in VLC, you can always disable this option later.

To enable hardware acceleration in VLC, head to Tools > Preferences.



Click the “Input / Codecs” tab, click the “Hardware-accelerated Decoding” box under Codecs, and set it to “Automatic”.



VLC’s wiki lists the video codecs it can accelerate. On Windows, H.264, MPEG-1, MPEG-2, WMV3, and VC-1 are all hardware accelerated. On a Mac, only H.264 is hardware accelerated. Videos that aren’t hardware accelerated will play normally; VLC will just use your CPU and you won’t get any battery life improvement.

Movies & TV is a Solid Video Player Too, Though


If you want to save battery life, you can always use the “Movies & TV” application included with Windows 10. Despite its name, it’s not just for playing movies and TV episodes you pay to rent or download from Microsoft. It’s the default video player on Windows 10, so just double-clicking a video will open it in Movies & TV, assuming you haven’t gone out of your way to install a different video player and set it as your default video player.

While you might assume that, as a new “Universal Windows Platform” application, Movies & TV would be slower and heavier than a traditional desktop application like VLC, you’d be wrong. It’s designed to provide properly hardware accelerated playback for optimal battery life on laptops and tablets, while VLC isn’t.



Enable Hardware Acceleration in Other Video Players


If you have another preferred video player, be sure to poke around in its options–or perform a web search for the name of the video player and “hardware acceleration”–to ensure you’ve enabled the hardware acceleration option. If the video player doesn’t offer hardware acceleration, you probably shouldn’t use it while your laptop is on battery power.

YouTube actually has a similar problem in Google Chrome and Mozilla Firefox. YouTube can provide videos in either the standard H.264 video format that many hardware chipsets can provide hardware acceleration for, or Google’s own VP8 and VP9 codecs. YouTube serves VP8 and VP9 video to Chrome and Firefox by default, but there’s a big problem with that–hardware acceleration for VP8 and VP9 isn’t available in any hardware yet. This means that YouTube will drain your battery faster in Chrome and Firefox than in browsers that only support H.264, such as Microsoft Edge and Apple Safari. To make YouTube use less battery life in Chrome or Firefox, you can install the h264ify extension, which will force YouTube to serve your browser H.264 video.

None of this really matters unless you’re using a laptop on battery power–or a very old, slow computer that doesn’t have enough CPU power to play a video smoothly. When you’re just using VLC or another video player on your desktop, the only benefit to hardware acceleration is reduced CPU usage. This will save a bit of power and keep your computer running a bit cooler, but it doesn’t matter if you’re just watching a video in VLC on a powerful desktop PC.

That’s probably why VLC hasn’t enabled this option by default. It could cause problems on some older desktop PCs while only providing a noticeable benefit on battery-powered laptops and tablets.

By How to Geek

No comments:

Post a Comment