Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/kepabilbao67-bot/musicplayer2/llms.txt

Use this file to discover all available pages before exploring further.

NEON DJ comes loaded with 18 genre tracks that are ready to mix the moment the page finishes loading — no downloads, no streaming, no licensing fees. Every track is assembled note-by-note in JavaScript and rendered into an AudioBuffer before you touch a single control. Because the audio is generated entirely in code, every loop is 100 % copyright-free and will never trigger a content-ID claim or DMCA takedown.
All built-in tracks are synthesized programmatically — they are not recordings of real instruments or pre-existing songs. Each note, kick, snare, and bass line is constructed from Web Audio API oscillators and noise sources at the exact moment the page loads. You can mix, record, and redistribute mixes made with these tracks without any copyright restrictions.

How Track Generation Works

When the page loads, the init() function iterates over every key in the TRACKS object and calls generateTrack(def) for each one. Under the hood, generateTrack spins up an OfflineAudioContext (stereo, 44 100 Hz sample rate) sized to hold exactly the number of bars defined by the track, then schedules every percussion hit and melodic phrase into it using a 16-step sequencer loop:
async function generateTrack(def) {
  const sr = 44100;
  const beat = 60 / def.bpm;
  const stepDur = beat / 4;               // sixteenth-note duration
  const totalSteps = def.bars * 16;
  const length = Math.ceil(totalSteps * stepDur * sr);

  const ctx = new (window.OfflineAudioContext ||
                   window.webkitOfflineAudioContext)(2, length, sr);
  const noise = makeNoise(ctx, 1.5);
  const master = ctx.createGain();
  master.gain.value = 0.85;
  master.connect(ctx.destination);

  for (let step = 0; step < totalSteps; step++) {
    const t   = step * stepDur;
    const s   = step % 16;
    const bar = Math.floor(step / 16);

    if (def.kick.includes(s))  synthKick(ctx, master, t);
    if (def.clap.includes(s))  synthClap(ctx, noise, master, t);
    if (def.ohat.includes(s))  synthHat(ctx, noise, master, t, true);
    if (def.chat.includes(s))  synthHat(ctx, noise, master, t, false);
    def.build(ctx, master, noise, bar, s, t);
  }

  const rendered = await ctx.startRendering();
  rendered._bpm  = def.bpm;   // BPM is stored on the AudioBuffer for sync
  rendered._loop = true;
  return rendered;
}
ctx.startRendering() renders the entire buffer faster than real-time (typically in under a second per track on a modern device). The finished AudioBuffer is stored in the DEMO_BUFFERS dictionary, keyed by genre slug (e.g. DEMO_BUFFERS.house), and made immediately available in the deck select menus.

First-Load Rendering Delay

Because all 18 tracks are rendered sequentially during init(), you will see a loading screen with a progress bar for a few seconds before the mixer UI appears. The status text updates to "Creando: <track name>" as each track is processed, and the bar fills to 100 % when all AudioBuffers are ready. This is a one-time cost per page load — no rendering happens during mixing.

Internal Synthesis Functions

Each build() method inside a track definition calls a set of shared synthesis helpers:
FunctionWhat it produces
synthKick(ctx, dest, t)Sine oscillator with exponential pitch drop (160 Hz → 48 Hz) — punchy kick drum
synthSnare(ctx, noise, dest, t)Highpass-filtered noise burst + triangle body tone
synthClap(ctx, noise, dest, t)Three rapid bandpass noise bursts offset by 12 ms each
synthHat(ctx, noise, dest, t, open)Highpass noise (7 500 Hz cutoff); open=true gives 280 ms decay, false gives 45 ms
synthBass(ctx, dest, t, freq, dur)Sawtooth through a resonant lowpass (520 Hz, Q 6) — sub bass with a sharp pluck
synthLead(ctx, dest, t, freq, dur, type, vol)Single oscillator (square/sawtooth/triangle) with a short attack envelope
synthChord(ctx, dest, t, rootMidi, dur, vol, drive)Three sawtooth oscillators (root + fifth + octave) through a WaveShaper distortion curve — simulates a power chord
synthWobble(ctx, dest, t, freq, dur, lfoRate)Dual detuned sawtooth + square into a resonant lowpass modulated by a sine LFO — dubstep wobble bass

Track Library

All 18 tracks are 8-bar loops rendered at 44 100 Hz stereo. BPM values are exact — they are stored on the AudioBuffer as _bpm and used by the SYNC button to align playback rates across decks.
Track NameKeyBPMCharacter / Style
Househouse124Four-on-the-floor kick (steps 0, 4, 8, 12), clap on 2 & 4, open/closed hi-hats, sawtooth bass line, chord stabs every other bar
Hip-Hophiphop88Boom-bap kick (steps 0, 7, 10), clap on 2 & 4, open hat on step 14, deep sub bass, triangle-wave synth lead
Technotechno130Four-on-the-floor kick, single clap on step 12, dense closed hats on off-beats, off-beat acid bass line, sawtooth lead every 4 bars
Synthwavesynthwave110Four-on-the-floor kick, gated clap on 2 & 4, arpeggiated square-wave lead running every two steps through an 8-note sequence
Reggaetonreggaeton96Dembow kick pattern (steps 0, 8, 10), clap on the off-beats, syncopated closed hats, square-wave piano stabs
Drum & Bassdnb174Sparse kick on steps 0 & 10, Amen-style clap placement, deep sub bass hit on beat 1, sawtooth chord hit every 4 bars
Traptrap140Open 808-style kick on steps 0, 6, 10, snare on step 8, dense hi-hat rolls, deep sub bass, triangle lead on odd bars
Funkfunk108Syncopated kick on steps 0 & 10, clap on 2 & 4, open hats on 6 & 14, slap-style sawtooth bass with octave jump on step 6, square lead
Rock Español 80/90rockesp132Half-time kick on beats 1 & 3, clap on 2 & 4, distorted power-chord guitar (synthChord with drive=16), quarter-note root bass
Heavy Metal 80/90metal160Double bass drum across 12 of 16 steps, dense distorted power chords (drive=26) on every hit, octave chord accent on beat 1, palm-muted bass
Pop Español 80/90popesp118Four-on-the-floor kick, clap on 2 & 4, eighth-note bass line, sawtooth three-note chord voicing on beat 1, square melody fill every 4 steps
Punk 80/90punk172Four-on-the-floor kick and clap, quarter-note distorted chord strums (synthChord), driving eighth-note bass
Ska 80/90ska150Half-time kick on beats 1 & 3, clap on 2 & 4, synthChord “chink” stabs on the off-beats (steps 2, 6, 10, 14), quarter-note bass
Grunge 90grunge115Kick on steps 0, 8, 10, clap on 2 & 4, half-bar distorted chord hits (drive=24), syncopated bass
Salsasalsa95Clave-like kick placement (steps 3, 11), triangle-wave montuno melody line running every two steps, syncopated bass
Cumbiacumbia92Half-time kick, clap on 2 & 4, off-beat sawtooth lead, triangle counter-melody, driving bass
Jungle / DnBdnbjungle165Syncopated kick (steps 0, 6, 10), broken clap/snare (steps 4, 7, 12), deep sub bass on beat 1, mid-bass on beat 3
Dubstepdubstep140Sparse kick on beat 1, clap on beat 3, synthWobble LFO bass on beats 1 and 3 with different LFO rates (5 Hz / 8 Hz)
Explore the related guides below to bring your own audio files into the mixer or to understand how each track is generated under the hood.

Load Your Own Audio Files

Bring your own MP3, WAV, OGG, or any browser-supported format into either deck alongside the built-in tracks.

Track Generation Reference

Deep-dive into the generateTrack function, the TRACKS definition object, and the synthesis helpers used to build each loop.

Build docs developers (and LLMs) love