# wozt/blackbeard_void_pro architecture

> Architecture diagram of the GitHub repository wozt/blackbeard_void_pro, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/wozt/blackbeard_void_pro
- Repository: https://github.com/wozt/blackbeard_void_pro

## Overview

Blackbeard VOID PRO is a native Linux control app for the Corsair VOID PRO Wireless headset. The user configures surround processing, equalisation, lighting, and microphone gain in the GTK interface; the app persists settings, applies audio processing through PipeWire, and reads battery state over HID for the interface and tray. The README documents additional hot-plug, headless, and autostart behavior. The graph reflects documented capabilities where source excerpts were incomplete; in particular, the device header cautions that replaying the lighting sequence does not yet reliably illuminate the headset.

Main entry points: [`src/main.c`](https://github.com/wozt/blackbeard_void_pro/blob/main/src/main.c) (GTK application), [`src/audio.c`](https://github.com/wozt/blackbeard_void_pro/blob/main/src/audio.c) (Audio chain), [`src/tray.c`](https://github.com/wozt/blackbeard_void_pro/blob/main/src/tray.c) (Battery tray), [`src/device.c`](https://github.com/wozt/blackbeard_void_pro/blob/main/src/device.c) (HID control)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_control["Application control"]
  node_main["GTK application<br/>[main.c]"]
  node_settings["Settings<br/>[config.c]"]
end

subgraph group_audio["Audio processing"]
  node_audio_engine["Audio chain<br/>[audio.c]"]
  node_filters_v1["IR generation 1"]
  node_filters_v2["IR generation 2"]
  node_filters_v3["IR generation 3"]
  node_mic_gain["Microphone gain<br/>[audio.c]"]
end

subgraph group_device["Headset control"]
  node_device_hid["HID control<br/>[device.c]"]
end

subgraph group_integration["Desktop integration"]
  node_desktop["Desktop integration<br/>[desktop.c]"]
  node_tray["Battery tray<br/>[tray.c]"]
  node_icons["Icon artwork<br/>[icons.c]"]
end

node_user(("User"))
node_pipewire["PipeWire"]
node_audio_apps(("Audio applications"))
node_headset["VOID PRO headset"]
node_desktop_shell["Desktop shell"]

node_user -->|"configures"| node_main
node_main -->|"loads and saves"| node_settings
node_main -->|"applies settings"| node_audio_engine
node_filters_v1 -->|"provides responses"| node_audio_engine
node_filters_v2 -->|"provides responses"| node_audio_engine
node_filters_v3 -->|"provides responses"| node_audio_engine
node_audio_apps -->|"sends audio"| node_pipewire
node_audio_engine -->|"loads processing graph"| node_pipewire
node_pipewire -->|"outputs audio"| node_headset
node_main -->|"polls and updates"| node_device_hid
node_device_hid -->|"reads battery; sends lighting"| node_headset
node_main -->|"sets gain"| node_mic_gain
node_mic_gain -->|"controls capture volume"| node_pipewire
node_main -->|"updates status"| node_tray
node_device_hid -->|"provides battery status"| node_tray
node_tray -->|"renders absent-device icon"| node_icons
node_main -->|"manages desktop entries"| node_desktop
node_desktop -->|"writes app icon"| node_icons
node_desktop -->|"publishes launcher and autostart"| node_desktop_shell
node_tray -->|"shows status indicator"| node_desktop_shell

click node_main "https://github.com/wozt/blackbeard_void_pro/blob/main/src/main.c"
click node_settings "https://github.com/wozt/blackbeard_void_pro/blob/main/src/config.c"
click node_audio_engine "https://github.com/wozt/blackbeard_void_pro/blob/main/src/audio.c"
click node_filters_v1 "https://github.com/wozt/blackbeard_void_pro/tree/main/filters/v1"
click node_filters_v2 "https://github.com/wozt/blackbeard_void_pro/tree/main/filters/v2"
click node_filters_v3 "https://github.com/wozt/blackbeard_void_pro/tree/main/filters/v3"
click node_device_hid "https://github.com/wozt/blackbeard_void_pro/blob/main/src/device.c"
click node_mic_gain "https://github.com/wozt/blackbeard_void_pro/blob/main/src/audio.c"
click node_desktop "https://github.com/wozt/blackbeard_void_pro/blob/main/src/desktop.c"
click node_tray "https://github.com/wozt/blackbeard_void_pro/blob/main/src/tray.c"
click node_icons "https://github.com/wozt/blackbeard_void_pro/blob/main/src/icons.c"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_main,node_settings,node_user toneBlue
class node_audio_engine,node_filters_v1,node_filters_v2,node_filters_v3,node_mic_gain toneAmber
class node_device_hid toneMint
class node_desktop,node_tray,node_icons toneRose
class node_pipewire,node_audio_apps,node_headset,node_desktop_shell toneIndigo
```

## Components

### Application control

- [GTK application](https://github.com/wozt/blackbeard_void_pro/blob/main/src/main.c): `src/main.c`
- [Settings](https://github.com/wozt/blackbeard_void_pro/blob/main/src/config.c): `src/config.c`

### Audio processing

- [Audio chain](https://github.com/wozt/blackbeard_void_pro/blob/main/src/audio.c): `src/audio.c`
- [IR generation 1](https://github.com/wozt/blackbeard_void_pro/tree/main/filters/v1): `filters/v1`
- [IR generation 2](https://github.com/wozt/blackbeard_void_pro/tree/main/filters/v2): `filters/v2`
- [IR generation 3](https://github.com/wozt/blackbeard_void_pro/tree/main/filters/v3): `filters/v3`
- [Microphone gain](https://github.com/wozt/blackbeard_void_pro/blob/main/src/audio.c): `src/audio.c`

### Headset control

- [HID control](https://github.com/wozt/blackbeard_void_pro/blob/main/src/device.c): `src/device.c`

### Desktop integration

- [Desktop integration](https://github.com/wozt/blackbeard_void_pro/blob/main/src/desktop.c): `src/desktop.c`
- [Battery tray](https://github.com/wozt/blackbeard_void_pro/blob/main/src/tray.c): `src/tray.c`
- [Icon artwork](https://github.com/wozt/blackbeard_void_pro/blob/main/src/icons.c): `src/icons.c`

### Other components

- **User**
- **PipeWire**
- **Audio applications**
- **VOID PRO headset**
- **Desktop shell**

## Connections

- User → GTK application: configures
- GTK application → Settings: loads and saves
- GTK application → Audio chain: applies settings
- IR generation 1 → Audio chain: provides responses
- IR generation 2 → Audio chain: provides responses
- IR generation 3 → Audio chain: provides responses
- Audio applications → PipeWire: sends audio
- Audio chain → PipeWire: loads processing graph
- PipeWire → VOID PRO headset: outputs audio
- GTK application → HID control: polls and updates
- HID control → VOID PRO headset: reads battery; sends lighting
- GTK application → Microphone gain: sets gain
- Microphone gain → PipeWire: controls capture volume
- GTK application → Battery tray: updates status
- HID control → Battery tray: provides battery status
- Battery tray → Icon artwork: renders absent-device icon
- GTK application → Desktop integration: manages desktop entries
- Desktop integration → Icon artwork: writes app icon
- Desktop integration → Desktop shell: publishes launcher and autostart
- Battery tray → Desktop shell: shows status indicator
