Caramelldansen in Terminal 🍭✨
High-performance, flicker-free, 24-bit TrueColor Caramelldansen terminal player!
Built with a modular Platform Abstraction Layer (PAL) and Audio Master Clock architecture, providing zero-configuration, cross-platform audio and rendering on macOS, Windows, and Linux.
Features
- 24-bit TrueColor Rendering:
halfblock(Default): Uses half-block characters (▀,▄) with 24-bit TrueColor for near-square pixels and stunning visual fidelity.color-ascii: Classic ASCII character brightness ramp combined with full RGB color.braille: High-resolution Unicode Braille (2x4 dot matrix) with 24-bit TrueColor rendering.
- Audio Master Clock Engine:
- Video rendering is strictly synchronized to hardware audio playback time for flawless rhythm alignment and zero audio-video drift.
- Zero-CPU Binary Cache Engine (CDBP v1):
- Streams from a pre-rendered, zlib-compressed RGB binary container (
caramell_dansen.bin) for <1% CPU consumption and instantaneous seek times.
- Streams from a pre-rendered, zlib-compressed RGB binary container (
- Automatic Asset Provisioning:
- Installs in seconds as a featherlight (<40 KB) PyPI wheel! Video and audio assets are automatically downloaded on first launch with live progress bar and MD5 verification.
- Flicker-Free Terminal Experience:
- Uses Alternate Screen Buffer (
\033[?1049h), cursor hiding, Win32 VT100 processing, and non-blocking I/O.
- Uses Alternate Screen Buffer (
- Responsive Sizing & Interactive Scrubber:
- Automatically respects 16:9 aspect ratio, centers video in any terminal window, and renders an adaptive live HUD status bar.
Controls
| Key | Action |
|---|---|
| Space | Pause / Resume |
| M | Cycle Render Mode (halfblock → color-ascii → braille) |
| Right Arrow ($\rightarrow$) | Seek forward 5 seconds |
| Left Arrow ($\leftarrow$) | Seek backward 5 seconds |
| R | Restart playback from beginning |
| Q / Esc | Quit cleanly |
Installation & Quick Start
Option 1: Install from PyPI (Recommended)
pip install caramelldansen
Run directly from any terminal:
caramelldansen
Or execute as a module:
python -m caramelldansen
Option 2: Run from Source
# Clone the repository
git clone https://github.com/Ohualtex/caramelldansen.git
cd caramelldansen
# Install dependencies
pip install -r requirements.txt
# Start playback (plays full music video from 00:00)
python main.py
# Select rendering mode
python main.py --mode color-ascii
CLI Options
usage: caramelldansen [-h] [--mode {halfblock,color-ascii,braille}] [--no-audio] [--build-cache]
options:
-h, --help show this help message and exit
--mode {halfblock,color-ascii,braille}
Rendering mode (default: halfblock)
--no-audio Mute audio and run on internal clock
--build-cache Force rebuild CDBP binary cache
Terminal Display Tips
macOS Terminal.app (Gapless Half-Block Display)
The default macOS Terminal.app adds vertical line leading (font spacing) between character rows. For a gapless, seamless display:
- Open Terminal → Settings (
Cmd + ,) → Profiles → Text. - Click Change... under Font.
- Set the Line Spacing slider to
0.80. - Alternatively, press
Min-player to switch to Braille mode (which is naturally immune to line spacing), or use modern GPU-accelerated terminals like Ghostty, iTerm2, or Kitty.
Windows Terminal
Runs out of the box in Windows Terminal, PowerShell, and Command Prompt with 24-bit TrueColor enabled via Win32 Virtual Terminal Processing.
License
MIT License. See LICENSE for details.
Metadata
Release files for caramelldansen 1.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| caramelldansen-1.3.1.tar.gz | 25.5 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| caramelldansen-1.3.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 60.3 kB
Release files / caramelldansen-1.3.1.tar.gz
| Download URL | caramelldansen-1.3.1.tar.gz |
|---|---|
| Size | 25.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6b170e4f5e2d50ac89b5f62a0cc10b2e289aebd07a4ac61c6bec58170957201c
|
|
BLAKE2b-256 checksum How to use checksums |
14e94199ca7ab2dd30f6217712fb1722bc945fcf893efbefb634740236df1603
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Release files / caramelldansen-1.3.1-py3-none-any.whl
| Download URL | caramelldansen-1.3.1-py3-none-any.whl |
|---|---|
| Size | 34.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
57e84746ac39a5885c635c7489b59044c51a8f49f2c4af0f7a7abd235f7f5c14
|
|
BLAKE2b-256 checksum How to use checksums |
a762a78a625f08fc24729c39028720ca0a7f9088cc42740b6c743872d6e0ab67
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Security for caramelldansen 1.3.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.