{"id":73870,"date":"2019-01-07T09:00:35","date_gmt":"2019-01-07T09:00:35","guid":{"rendered":"https:\/\/fedoramagazine.org\/?p=23894"},"modified":"2019-01-07T09:00:35","modified_gmt":"2019-01-07T09:00:35","slug":"chromium-on-fedora-finally-gets-vaapi-support","status":"publish","type":"post","link":"https:\/\/sickgaming.net\/blog\/2019\/01\/07\/chromium-on-fedora-finally-gets-vaapi-support\/","title":{"rendered":"Chromium on Fedora finally gets VAAPI support!"},"content":{"rendered":"<p>Do you like playing videos in your web browser? Well, good news, the Chromium web browser available in Fedora gets a Video Acceleration API support. That makes video playback much smoother while using significantly less resources.<\/p>\n<h2>A little bit of history<\/h2>\n<p>Chromium with a VAAPI patch was already available on other distributions. But this was not the case with Fedora. I really want hardware acceleration. But my love for Fedora was holding me back. Then with sheer willpower, I joined Fedora and started maintaining a package in COPR.<\/p>\n<p>I am not really a distro hopper but a DE hopper. I usually jump from Gnome to KDE and vice versa depending upon my mood. Then I started maintaining Chromium with vaapi patch on COPR. I was using the official patch which was submitted <a href=\"https:\/\/chromium-review.googlesource.com\/c\/chromium\/src\/+\/532294\">upstream<\/a> for code review. I had very little hope that it will get merge. The patch is outdated and and try jobs were failing at that time.<\/p>\n<p>After six months, the Chromium upstream maintainers made a statement that they are <a href=\"https:\/\/bugs.chromium.org\/p\/chromium\/issues\/detail?id=463440#c65\">not interested to include this patch<\/a>. So after that I\u00a0started working on my own patch with referenced from the official patch. My patch is about using the existing flags that other operating system uses instead of creating a new flag just for experimentation.<\/p>\n<div id=\"attachment_23898\" style=\"width: 584px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-23898 \" src=\"http:\/\/www.sickgaming.net\/blog\/wp-content\/uploads\/2019\/01\/chromium-on-fedora-finally-gets-vaapi-support.png\" alt=\"screenshot showing chromium uses video engine\" width=\"574\" height=\"262\" \/><\/p>\n<p class=\"wp-caption-text\">Chromium uses AMDGPU&#8217;s UVD engine while playing a video<\/p>\n<\/div>\n<div id=\"attachment_23896\" style=\"width: 636px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-23896\" src=\"http:\/\/www.sickgaming.net\/blog\/wp-content\/uploads\/2019\/01\/chromium-on-fedora-finally-gets-vaapi-support-1.png\" alt=\"chromium's flag screenshot\" width=\"626\" height=\"213\" \/><\/p>\n<p class=\"wp-caption-text\">Chromium uses Existing flags on Fedora<\/p>\n<\/div>\n<h2>Effects of the VAAPI patch<\/h2>\n<p>Chromium with this patch was extremely stable on both of my machines. They both have AMD GPU. The video playback is smooth. This improved overall power savings as well.<\/p>\n<div id=\"attachment_23897\" style=\"width: 597px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-23897\" src=\"http:\/\/www.sickgaming.net\/blog\/wp-content\/uploads\/2019\/01\/chromium-on-fedora-finally-gets-vaapi-support.jpg\" alt=\"Comparision with\/without vaapi\" width=\"587\" height=\"282\" \/><\/p>\n<p class=\"wp-caption-text\">Credits: Tobias Wolfshappen<\/p>\n<\/div>\n<p>As you can see, chromium with the vaapi patch takes up significantly less resources in comparison to chromium without the patch and Firefox.\u00a0 The CPU usage went down from 120% to 10%. The playback is smooth with no shuttering.<\/p>\n<h2>VA-API patch in chromium for Fedora<\/h2>\n<p>It was then\u00a0Fedora&#8217;s Engineering Manager @ Red Hat and Chromium maintainer, <a href=\"https:\/\/fedoraproject.org\/wiki\/User:Spot\">Tom Callaway, <\/a>finally recognises the VAAPI patch and <a href=\"https:\/\/src.fedoraproject.org\/rpms\/chromium\/c\/278c62709d1dba5883c3b69047706837bb402bd7?branch=master\">decides<\/a> to include in Fedora&#8217;s Chromium browser. Fedora becomes the second distribution to include the VAAPI patch in their official Chromium package.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Do you like playing videos in your web browser? Well, good news, the Chromium web browser available in Fedora gets a Video Acceleration API support. That makes video playback much smoother while using significantly less resources. A little bit of history Chromium with a VAAPI patch was already available on other distributions. But this was [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":73871,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[48],"tags":[341,441,45,46,75,47,44],"class_list":["post-73870","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-fedora-os","tag-browser","tag-chrome","tag-fedora","tag-magazine","tag-new-in-fedora","tag-news","tag-using-software"],"_links":{"self":[{"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/posts\/73870","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/comments?post=73870"}],"version-history":[{"count":0,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/posts\/73870\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/media\/73871"}],"wp:attachment":[{"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/media?parent=73870"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/categories?post=73870"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/tags?post=73870"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}