2026-08-11 00:51:40 +02:00
2026-11-18 00:52:52 +01:00
2026-11-18 00:52:52 +01:00
2026-08-09 20:51:13 +02:00

Viz Logo

Viz

High-performance audio visualizer studio with GPU-accelerated offline rendering and true alpha-channel video export.

🇬🇧 English · 🇩🇪 Deutsch


Overview

Orfel Viz is a web-based audio visualizer studio and automated rendering pipeline tailored for video editors and music creators using DaVinci Resolve, Adobe Premiere Pro, YouTube, TikTok, Instagram Reels, and YouTube Shorts.

It combines a real-time 60 FPS HTML5 Canvas visualizer in the browser with a deterministic frame-by-frame offline export engine. Using a hybrid WebCodecs GPU + Server FFmpeg Mezzanine pipeline, it renders multi-format broadcast masters—including true straight alpha transparency—at 60–120+ FPS, and also includes a headless Puppeteer batch worker (worker.mjs) for automated song-folder rendering.

┌─────────────────────────────────────────┐       Mezzanine Upload        ┌───────────────────────────────────┐
│   Browser Studio (WebCodecs + Canvas)   │  (MP4 Top-Bottom / WebM VP9)  │   Express Backend (server.mjs)    │
│   public/js/ (Audio, FFT, Geometry, FX) │ ────────────────────────────► │   FFmpeg Sequential Transcoder    │
└─────────────────────────────────────────┘                               └────────┬──────────────────────────┘
                                                                                   │
                    ┌──────────────────────────────┬───────────────────────────────┼───────────────────────┐
                    ▼                              ▼                               ▼                       ▼
        ProRes 4444 (.mov)              QuickTime RLE (.mov)              WebM VP9 Alpha (.webm)      MP4 H.264 (.mp4)
     10-bit yuva444p10le + PCM           Lossless ARGB + PCM               yuva420p + Opus 320k     CRF 14 + AAC 320k

Features

  • Broadcast Export Formats & True Alpha Transparency:
    • Apple ProRes 4444 (.mov): 10-bit prores_ks (yuva444p10le, 16 alpha bits, apl0 vendor tag) with uncompressed pcm_s16le audio for DaVinci Resolve and Premiere Pro.
    • QuickTime Animation RLE (.mov): Lossless qtrle (argb) RGB+Alpha with pcm_s16le audio.
    • WebM VP9 Alpha (.webm): Compact transparent libvpx-vp9 (yuva420p) stream with libopus 320 kbps audio for web overlays and NLEs (also supports direct client-side WebCodecs export).
    • MP4 H.264 (.mp4): High-quality libx264 CRF 14 (yuv420p, aac 320 kbps) master for direct YouTube and social media upload.
  • Rich Shapes, Topologies & Hardware Instruments:
    • Geometric & Organic Shapes: circle, linear, hexagon, diamond, triangle, octagon, square, pentagon, heptagon, oscilloscope, tunnel (3D Tunnel), blob (Fluid Blob), star (5-star), star8 (8-star), heart, cross, flower, lightning, flame, skull, crown, infinity, eye, gem, pick, sun, droplet, hourglass, butterfly, hexagram, speaker, invader, gamepad, saturn, rocket, snowflake, leaf, bat, wolf, anchor, cat.
    • 10 Specialized Studio Hardware Instruments: Analog Stereo VU-Meter (vumeter), Stereo Goniometer / Lissajous Scope with Phase Correlation (goniometer), Dual LED-Segment Peak Meter Towers (led_meter), Vintage EM84 Magic Eye Tube (magic_eye), Studer A800 Reel-to-Reel Tape Deck (reel_to_reel), Transparent Retro Cassette Deck (cassette_deck), Vinyl DJ Turntable (vinyl_turntable), CRT Waterfall Sonogram (waterfall), Holo-Sonar Radar (radar_sweep), and Tesla Plasma Sphere (plasma_sphere).
  • Spectrum & Audio Analysis:
    • 5 Spectrum Modes: radial_bars, smooth_wave, floating_dots, dual_ring, block_matrix, plus 4 linear alignments (center_mirrored, bottom_up, top_down, floating_wave).
    • Stereo L/R Dual-Channel Split: split_hemisphere, interleaved, and dual_ring.
    • 3-Band Element Routing: Independently route sub_bass, mids, treble, or full_mix to Center-Pulse, Particle Explosions, and Bass-Shake.
    • BPM & Beat Synchronization: Auto-detect BPM, manual tempo input (40–260 BPM), Tap Tempo button, and optional sync for vinyl rotation and 3D grid flight.
  • FX, 3D & Color Grading:
    • 8 Particle Systems: starfield (3D Warp), dust, sparks, vortex, bubbles, embers, digital_rain, shockwave_blast.
    • Camera & Retro Effects: 3D Synthwave Grid Floor, Bass-Shake, RGB-Split / Glitch, Beat-Flash strobe, Camera Bass-Zoom, Retro VHS & Scanlines (with CRT curvature), and Phosphor Afterglow trails (original, green_p1, amber_p4, cyan_neon).
    • 20 Curated Color Palettes & Neon Bloom: 2-color / 3-color gradients, rainbow chroma beat-loop, solid colors, angular/radial/linear gradients, Neon Glow + Double Laser Core, and 4 background modes (transparent, blurred_cover, dark_vignette, solid_black).
  • Typography, Aspect Ratios & 60 Built-in Presets:
    • Aspect Ratios & Resolutions: 16:9 (1920×1080), 9:16 (1080×1920 with toggleable TikTok/Shorts Safe-Zone overlay), 1:1 (1080×1080), exportable at 720p, 1080p, or 4K (2160p) at 30 or 60 FPS.
    • Typography: 7 fonts (Outfit, Orbitron, Syncopate, Montserrat, Russo One, Inter, Cinzel), independent controls for Title, Artist, Timecode (elapsed_and_total, elapsed_only, remaining), and Progress Ring / Bar.
    • 60 JSON Presets + AWN Mode: Served dynamically from public/presets/*.json via /api/presets (including Trap Nation, NCS Electro, Synthwave Horizon, Cyberpunk City, Studio Mastering Suite, Vinyl DJ Deck, CRT Waterfall, plus official AIWentNonsense brand presets), with browser localStorage saving and JSON import/export.
  • Render History & Batch Worker: Persistent session history (data/history.json, retains up to 3 latest sessions with 7-day auto-cleanup), 1-click Re-Render config restore, and worker.mjs + Run-AutoRender.ps1 for headless automated batch rendering.

How It Works & Tech Stack

Export Pipeline

  1. Non-transparent MP4 / WebM: If WebCodecs is available and transparency is disabled, public/js/export/video-export.js encodes directly in the browser using VideoEncoder, AudioEncoder, mp4-muxer.js, or webm-muxer.js and downloads immediately.
  2. Transparent Alpha / Studio Master Export:
    • GPU Mezzanine Path (WebCodecs): The browser renders RGBA frames on an offscreen canvas (mp4_topbottom stacks RGB on top and the grayscale alpha mask on the bottom, or webm_alpha for direct VP9 alpha) and uploads the mezzanine video + original audio to POST /api/export/transcode.
    • Legacy Frame-Streaming Fallback: If WebCodecs is unavailable, the browser streams raw RGBA 15-frame batches via POST /api/export/frame-batch/:id to an FFmpeg pipe (POST /api/export/start, finalized via POST /api/export/finish/:id).
    • Server FFmpeg Sequential Queue: server.mjs sequentially transcodes prores, webm_alpha, and mp4 (and supports qtrle downloads) into data/temp/.

Tech Stack

Component Technology
Backend Node.js 22 (ESM), Express (^4.21.2), Multer (^1.4.5-lts.1, 1 GB upload limit), CORS
Transcoding System FFmpeg (prores_ks, qtrle, libvpx-vp9, libx264, pcm_s16le, libopus, aac)
Frontend Vanilla ES Modules (public/js/), HTML5 Canvas 2D, Web Audio API, custom Radix-2 FFT (fft.js), WebCodecs API
In-Browser Muxing mp4-muxer (^5.2.2), webm-muxer (^5.1.4)
Automation Worker Puppeteer (^25.10.0), node-fetch (^3.3.2), Chokidar (^5.0.0), PowerShell runner (Run-AutoRender.ps1)
Deployment Docker (node:22-bookworm-slim + ffmpeg + fonts-dejavu-core) & Docker Compose
Default Port 3000 (849 in Start-Local.bat, 3001 in worker.mjs)

Prerequisites & Installation

Prerequisites

  • Node.js 18+ (Node 22 used in Docker)
  • FFmpeg installed and available on the system PATH (included in Docker image)
  • Modern Chromium-based browser (Chrome / Edge) recommended for WebCodecs GPU acceleration

Option 1: Local Installation

git clone https://git.orfel.de/Jannik/Viz.git
cd Viz
npm install
npm start

Open http://localhost:3000 in your browser. On Windows, you can also double-click Start-Local.bat, which installs dependencies if needed and starts the server on http://localhost:849.

git clone https://git.orfel.de/Jannik/Viz.git
cd Viz
docker compose up -d

Viz will be available at http://localhost:3000 (persisting renders and history in ./data:/app/data).

Option 3: Linux Deployment Script / PM2

chmod +x deploy.sh
./deploy.sh

If Docker is installed, deploy.sh pulls and starts the Docker Compose stack; otherwise it installs FFmpeg/dependencies and runs server.mjs via pm2 (orfel-viz) or nohup.

Optional: Nginx Reverse Proxy & SSL

server {
    server_name viz.yourdomain.com;

    # Allow large audio and mezzanine video uploads
    client_max_body_size 500M;

    location / {
        proxy_pass http://127.0.0.1:3000;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection 'upgrade';
        proxy_set_header Host $host;
        proxy_cache_bypass $http_upgrade;
        proxy_read_timeout 600s;
        proxy_send_timeout 600s;
    }
}
sudo certbot --nginx -d viz.yourdomain.com

Configuration

Environment Variables

Variable Default Description
PORT 3000 HTTP server port (849 in Start-Local.bat, 3001 inside worker.mjs)
DATA_DIR ./data Directory for history.json, uploads/, and temp/
NODE_ENV production Node runtime environment (set in Dockerfile / Compose)

Server & Retention Behavior (server.mjs)

  • Request Timeouts: HTTP socket, request, and keep-alive timeouts are extended/disabled (server.timeout = 0, server.requestTimeout = 0, keepAliveTimeout = 1800000) to prevent HTTP 408 errors on large mezzanine uploads.
  • Upload Limit: 1 GB via Multer (50 MB JSON/URL-encoded, 500 MB raw frame batches).
  • Retention: Keeps the 3 most recent render sessions (MAX_HISTORY = 3) and automatically cleans up files older than 7 days hourly.

Headless Batch Worker (worker.mjs)

worker.mjs scans BASE_DIR (D:/Google Drive/Videos/AIWentNonsense) for <SongFolder>/Viz/*.json job files that do not yet have a rendered video, spawns a temporary local server on port 3001, drives the browser UI via Puppeteer (window.VIZ_API), downloads the finished format, and sends failure alerts to NTFY_URL (https://ntfy.orfel.de/viz_errors).


Usage

Interactive Studio Workflow

  1. Media Tab: Drag and drop an audio file (WAV, MP3, FLAC, M4A, OGG), optionally upload a cover image/logo (or load the built-in AIWentNonsense watermark), and enter Track Title and Artist.
  2. Shape, Spectrum, FX & 3D, Colors, Text: Pick any topology or hardware instrument, configure 3-band routing, BPM sync, particles, 3D synthwave grid, VHS/afterglow shaders, neon bloom, and typography.
  3. Toolbar: Switch between 16:9, 9:16, and 1:1, toggle Alpha Grid, and toggle the Safe-Zone overlay for TikTok/Shorts.
  4. Presets Tab: Choose from 60 built-in presets, toggle AWN Mode, or save/export/import presets as .json.
  5. Export Tab: Choose resolution (720p, 1080p, 4K) and frame rate (30/60 FPS), click Render & Download, and download your rendered formats from Render History.

Keyboard Shortcuts

Key Action
Space Play / Pause audio preview (when not focused in an <input>)

DaVinci Resolve Alpha Workflow

  1. Render your visualizer with Transparent background mode (backgroundMode: "transparent").
  2. Download Apple ProRes 4444 (.mov) or QuickTime Animation RLE (.mov) from the Render History.
  3. Import the .mov file into the DaVinci Resolve Media Pool.
  4. Place your background video on track V1 and the exported .mov on track V2.
  5. DaVinci Resolve automatically detects the straight alpha channel—the visualizer overlays cleanly on top of your footage.

Automated Batch Rendering (Windows)

npm run worker
# or on Windows:
.\Run-AutoRender.ps1

API Endpoints

Method & Path Description
GET /health Server health, port, and uptime JSON
GET /api/presets Returns all JSON presets from public/presets/
POST /api/export/transcode Upload mezzanine video + audio to transcode prores, webm_alpha, mp4
POST /api/export/start Start raw RGBA frame-streaming ProRes render session
POST /api/export/frame/:id / frame-batch/:id Stream raw RGBA frame bytes to active FFmpeg stdin
POST /api/export/finish/:id Close FFmpeg stdin and run sequential format queue
GET /api/export/status/:id Poll render progress/status
GET /api/export/history List stored render sessions
GET /api/export/download/:id/:formatId Download rendered output (prores, qtrle, webm_alpha, mp4)
DELETE /api/export/history/:id Delete a session and its output files
POST /api/export/cancel/:id Cancel an active render session

Project Structure

Viz/
├── data/                    # Runtime history.json, uploads/, temp/
├── public/
│   ├── assets/              # Brand watermark asset
│   ├── js/
│   │   ├── audio/           # engine.js (Web Audio), fft.js (Radix-2 FFT)
│   │   ├── export/          # video-export.js (WebCodecs + FFmpeg batching)
│   │   ├── geometry/        # shapes.js (40+ shapes), instruments.js (10 hardware meters)
│   │   ├── rendering/       # pipeline.js, fx.js, gradients.js, particles.js
│   │   ├── ui/              # controls.js, presets.js
│   │   ├── app.js           # Real-time 60 FPS loop & window.VIZ_API
│   │   ├── state.js         # Central application state
│   │   └── utils.js         # Helpers & time formatting
│   ├── presets/             # 60 curated JSON preset files
│   ├── favicon.svg / .ico   # App icon
│   ├── index.html           # Studio UI shell
│   ├── style.css            # Studio dark styling
│   ├── mp4-muxer.js         # Client-side MP4 muxer
│   └── webm-muxer.js        # Client-side WebM muxer
├── server.mjs               # Express server & FFmpeg sequential transcoder
├── worker.mjs               # Puppeteer headless batch render worker
├── Run-AutoRender.ps1       # PowerShell launcher for worker.mjs
├── Start-Local.bat          # Windows quick launcher (port 849)
├── deploy.sh                # VPS deployment script (Docker / PM2)
├── Dockerfile               # Node 22 + FFmpeg container
├── docker-compose.yml       # Docker Compose configuration
└── package.json

License

MIT License — see package.json.

S
Description
Studio Audio Visualizer Web-App mit Offline-Render-Pipeline und echtem Alphakanal-Export (ProRes 4444, WebM VP9, MP4) für DaVinci Resolve.
Readme CC0-1.0
7.7 MiB
0 Stars 1 Watchers 0 Forks
Languages
JavaScript 77.8%
HTML 15.2%
CSS 5.2%
Python 1.3%
Shell 0.3%
Other 0.1%