firefox with video acceleration

This commit is contained in:
foosinn 2020-08-29 16:53:14 +02:00
parent b1376304b7
commit 7984da51d3
2 changed files with 26 additions and 10 deletions

View file

@ -4,8 +4,9 @@
{ config, lib, pkgs, ... }:
let
unstable = import <nixos-unstable> {};
unstable = import <nixos-unstable> { config.allowUnfree = true; };
in {
programs.sway = {
enable = true;
extraPackages = with pkgs; [
@ -42,14 +43,26 @@ in {
];
environment.systemPackages = with pkgs; [
# firefox also needs:
#
# gfx.webrenderer.enabled = true
# widget.wayland-dmabuf-vaapi.enabled = true
#
# check in `about:support` that
# * Composing -> Webrenderer
unstable.firefox-bin
libva
libva-utils
mesa
librsvg
unstable.mypaint
unstable.mypaint-brushes
hicolor-icon-theme
numix-icon-theme
alacritty
firefox
mumble
neofetch
inkscape
@ -65,11 +78,12 @@ in {
text = ''
#! ${pkgs.bash}/bin/bash
export MOZ_ENABLE_WAYLAND=1
export QT_QPA_PLATFORM=wayland-egl
export QT_WAYLAND_FORCE_DPI=physical
export SDL_VIDEODRIVER=wayland
export _JAVA_AWT_WM_NOREPARENTING=1
export MOZ_ENABLE_WAYLAND=1
export QT_AUTO_SCREEN_SCALE_FACTOR=0
export QT_WAYLAND_FORCE_DPI=96
export QT_QPA_PLATFORM=wayland-egl
export SDL_VIDEODRIVER=wayland
exec ${pkgs.dbus}/bin/dbus-run-session ${pkgs.sway}/bin/sway
'';
}
@ -85,4 +99,8 @@ in {
};
services.printing.enable = true;
hardware.opengl = {
enable = true;
};
}

View file

@ -5,8 +5,6 @@
let
unstable = import <nixos-unstable> {};
mozilla = import <mozilla> {};
in {
environment.systemPackages = with pkgs; [
emacs