From 8bf9a06597edc88fbf241c2c553ddb7a924ebf9c Mon Sep 17 00:00:00 2001 From: Mylloon Date: Mon, 1 May 2023 14:24:18 +0200 Subject: [PATCH] add hw acc for firefox on arch --- .mozilla/firefox/user-arch.js | 2 ++ Makefile | 1 + arch.sh | 3 +++ 3 files changed, 6 insertions(+) create mode 100644 .mozilla/firefox/user-arch.js diff --git a/.mozilla/firefox/user-arch.js b/.mozilla/firefox/user-arch.js new file mode 100644 index 0000000..314da61 --- /dev/null +++ b/.mozilla/firefox/user-arch.js @@ -0,0 +1,2 @@ +user_pref("gfx.webrender.all", true); // Composition => WebRender (hardware) +user_pref("media.ffmpeg.vaapi.enabled", true); // VA-API (hardware acceleration) diff --git a/Makefile b/Makefile index 721f6a4..2f94ef3 100644 --- a/Makefile +++ b/Makefile @@ -100,6 +100,7 @@ sync-arch: # Firefox -@$(RM) $(HOME)/.mozilla/firefox/*.default-release/user.js @$(WGET) $(REPO_SRC)/.mozilla/firefox/user.js -P $(HOME)/.mozilla/firefox/*.default-release + @$(CURL) $(REPO_SRC)/.mozilla/firefox/user-arch.js >> $(HOME)/.mozilla/firefox/*.default-release/user.js # VSCodium @$(WGET) $(REPO_SRC)/.config/VSCodium/product.json -O $(HOME)/.config/VSCodium/product.json diff --git a/arch.sh b/arch.sh index d69945e..0228720 100644 --- a/arch.sh +++ b/arch.sh @@ -313,8 +313,11 @@ main() { sleep 2 pkill firefox wget -q --show-progress https://git.mylloon.fr/Anri/confOS/raw/branch/main/.mozilla/firefox/user.js -P "$HOME"/.mozilla/firefox/*.default-release + curl -s https://git.mylloon.fr/Anri/confOS/raw/branch/main/.mozilla/firefox/user-arch.js >> "$HOME"/.mozilla/firefox/*.default-release/user.js # 2 fingers history control echo "export MOZ_USE_XINPUT2=1" >> "$HOME"/.profile + # Hardware acceleration + echo "export MOZ_DRM_DEVICE=/dev/dri/renderD128" >> "$HOME"/.profile # Download extension configuration (TODO: Check Download Folder's Name) #wget -q --show-progress https://git.mylloon.fr/Anri/confOS/raw/branch/main/.mozilla/firefox/extensions/Dark-Reader-Settings.json -P "$HOME"/Téléchargements #wget -q --show-progress https://git.mylloon.fr/Anri/confOS/raw/branch/main/.mozilla/firefox/extensions/SponsorBlockConfig.json -P "$HOME"/Téléchargements