PipeWire: Difference between revisions

imported>Scott
m Make it clear that config is for 21.11 and no later, as opposed to "at least 21.11"
imported>Hnry
m correct pipewire conf path, not sure if pipewire understands json, but removed to simplify example with pipewire.conf examples
Line 163: Line 163:
The minimum period size controls how small a buffer can be. The lower it is, the less latency there is. PipeWire has a value of 32/48000 by default, which amounts to 0.667ms. It can be brought lower if needed:
The minimum period size controls how small a buffer can be. The lower it is, the less latency there is. PipeWire has a value of 32/48000 by default, which amounts to 0.667ms. It can be brought lower if needed:
<syntaxHighlight lang="nix">
<syntaxHighlight lang="nix">
environment.etc = let
environment.etc = {
  json = pkgs.formats.json {};
   "pipewire/pipewire.conf.d/92-low-latency.conf".text = ''
in {
   "pipewire/pipewire.d/92-low-latency.conf".source = json.generate "92-low-latency.conf" {
     context.properties = {
     context.properties = {
       default.clock.rate = 48000;
       default.clock.rate = 48000
       default.clock.quantum = 32;
       default.clock.quantum = 32
       default.clock.min-quantum = 32;
       default.clock.min-quantum = 32
       default.clock.max-quantum = 32;
       default.clock.max-quantum = 32
     };
     }
   };
   '';
};
};
</syntaxHighlight>
</syntaxHighlight>