# sharior13/luvista architecture

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

- Interactive diagram: https://gitdiagram.com/sharior13/luvista
- Repository: https://github.com/sharior13/luvista

## Overview

Luvista is a small music-player application. Its intended workflow is to present playback controls, let a controller coordinate track selection and audio playback, and send audio operations to a Miniaudio backend. The entry point also creates and runs a Slint window, though the referenced app header is absent from the tree. Source excerpts are limited; favorites and several runtime connections are therefore shown without inferred links.

Main entry points: [`src/main.cpp`](https://github.com/sharior13/luvista/blob/main/src/main.cpp) (Application entry), [`src/core/playerController.cpp`](https://github.com/sharior13/luvista/blob/main/src/core/playerController.cpp) (Player controller), [`src/app/consoleUI.cpp`](https://github.com/sharior13/luvista/blob/main/src/app/consoleUI.cpp) (Console UI), [`src/audio/audioBackend.h`](https://github.com/sharior13/luvista/blob/main/src/audio/audioBackend.h) (Audio backend interface)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_interface["User interface"]
  node_entry["Application entry<br/>[main.cpp]"]
  node_console["Console UI<br/>[consoleUI.cpp]"]
  node_slint["Slint window API<br/>[slint.h]"]
end

subgraph group_playback["Playback"]
  node_controller["Player controller"]
  node_tracks["Track list<br/>[trackList.cpp]"]
  node_favorites["Favorites<br/>[favorites.cpp]"]
end

subgraph group_audio["Audio output"]
  node_audio_backend["Audio backend interface<br/>[audioBackend.h]"]
  node_miniaudio["Miniaudio backend"]
  node_miniaudio_lib["Miniaudio library<br/>[miniaudio.h]"]
end

node_user(("User"))

node_user -.->|"uses controls"| node_console
node_entry -->|"constructs"| node_console
node_entry -->|"constructs"| node_controller
node_entry -->|"constructs"| node_tracks
node_entry -.->|"provides audio"| node_audio_backend
node_entry -.->|"creates and runs window"| node_slint
node_console -.->|"delegates controls"| node_controller
node_controller -.->|"queries tracks"| node_tracks
node_controller -.->|"controls playback"| node_audio_backend
node_miniaudio -->|"implements"| node_audio_backend
node_miniaudio -->|"uses audio engine"| node_miniaudio_lib

click node_entry "https://github.com/sharior13/luvista/blob/main/src/main.cpp"
click node_console "https://github.com/sharior13/luvista/blob/main/src/app/consoleUI.cpp"
click node_slint "https://github.com/sharior13/luvista/blob/main/external/slint/include/slint/slint.h"
click node_controller "https://github.com/sharior13/luvista/blob/main/src/core/playerController.cpp"
click node_tracks "https://github.com/sharior13/luvista/blob/main/src/core/trackList.cpp"
click node_favorites "https://github.com/sharior13/luvista/blob/main/src/core/favorites.cpp"
click node_audio_backend "https://github.com/sharior13/luvista/blob/main/src/audio/audioBackend.h"
click node_miniaudio "https://github.com/sharior13/luvista/blob/main/src/audio/miniaudioBackend.cpp"
click node_miniaudio_lib "https://github.com/sharior13/luvista/blob/main/external/miniaudio/miniaudio.h"

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_entry,node_console,node_slint,node_user toneBlue
class node_controller,node_tracks,node_favorites toneAmber
class node_audio_backend,node_miniaudio,node_miniaudio_lib toneMint
```

## Components

### User interface

- [Application entry](https://github.com/sharior13/luvista/blob/main/src/main.cpp): `src/main.cpp`
- [Console UI](https://github.com/sharior13/luvista/blob/main/src/app/consoleUI.cpp): `src/app/consoleUI.cpp`
- [Slint window API](https://github.com/sharior13/luvista/blob/main/external/slint/include/slint/slint.h): `external/slint/include/slint/slint.h`

### Playback

- [Player controller](https://github.com/sharior13/luvista/blob/main/src/core/playerController.cpp): `src/core/playerController.cpp`
- [Track list](https://github.com/sharior13/luvista/blob/main/src/core/trackList.cpp): `src/core/trackList.cpp`
- [Favorites](https://github.com/sharior13/luvista/blob/main/src/core/favorites.cpp): `src/core/favorites.cpp`

### Audio output

- [Audio backend interface](https://github.com/sharior13/luvista/blob/main/src/audio/audioBackend.h): `src/audio/audioBackend.h`
- [Miniaudio backend](https://github.com/sharior13/luvista/blob/main/src/audio/miniaudioBackend.cpp): `src/audio/miniaudioBackend.cpp`
- [Miniaudio library](https://github.com/sharior13/luvista/blob/main/external/miniaudio/miniaudio.h): `external/miniaudio/miniaudio.h`

### Other components

- **User**

## Connections

- User → Console UI: uses controls
- Application entry → Console UI: constructs (evidence: `src/main.cpp`)
- Application entry → Player controller: constructs (evidence: `src/main.cpp`)
- Application entry → Track list: constructs (evidence: `src/main.cpp`)
- Application entry → Audio backend interface: provides audio
- Application entry → Slint window API: creates and runs window
- Console UI → Player controller: delegates controls
- Player controller → Track list: queries tracks
- Player controller → Audio backend interface: controls playback
- Miniaudio backend → Audio backend interface: implements
- Miniaudio backend → Miniaudio library: uses audio engine (evidence: `src/audio/miniaudioBackend.cpp`)
