Skip to content

KorsarOfficial/Korscord

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Korscord

Dynamic Discord theme synchronization via desktop color extraction.

Model

S: Screen → R^(W×H×3)  (GDI BitBlt, BGRA → RGB)
D: R^(W×H×3) → R^(N×3)  (stride-skip downsampling, N ≈ 90000)
K: R^(N×3) → R^(k×3)  (K-Means++, k=3, Lloyd's iteration)
B: R^(k×3) → R^(k×3)  (sort by 0.299R + 0.587G + 0.114B)
T: R^3 → {#000000, #1a1a1a, #e0e0e0, #ffffff}  (BT.601 threshold mapping)
C: R^(k×3) × T → CSS  (14 custom properties, 3 @keyframes, 11 selectors)

Pipeline: S → D → K → B → T → C → fs.watchFile → Discord DOM

Build

pacman -S mingw-w64-x86_64-gcc mingw-w64-x86_64-cmake
mkdir build && cd build && cmake .. -G "MinGW Makefiles" && cmake --build .

Usage

Run korscord.exe as Administrator. Patches Discord's index.js with CSS file watcher, then polls desktop every 2 seconds.

Requirements

  • Windows 10+
  • Discord Desktop (stable)
  • MSYS2 MinGW64
  • Administrator privileges (auto-elevation via UAC)

Dependencies

None. Win32 SDK only (gdi32, shell32, shlobj).