Project-DJ-Engine

Project-DJ-Engine (PDJE) is a soft real-time C++ engine for rhythm games, DJ performance, and audio-production workflows. It combines synchronized audio, live music and FX control, chart judgment, low-latency input, editor APIs, and music-analysis utilities. PDJE-Godot-Plugin exposes the supported game-facing surface as a Godot GDExtension.

What You Can Build

  • rhythm games with synchronized charts and high-resolution judgment

  • real-time or pre-authored DJ performances

  • in-game mix, music-metadata, and note-chart editors

  • low-latency keyboard, mouse, and MIDI interaction

  • music search, waveform/STFT analysis, similarity search, and beat detection

Start Here

Godot users

Begin with Getting Started, then use the workflow page for the feature you need:

  • Core_Engine — initialize PDJE, search content, play, and control music/FX

  • Editor_Workflows — author, revise, preview, render, and publish data

  • Input_Engine — discover devices and receive input signals

  • Judge_Engine — connect timing/input data and emit judgments

  • Util_Engine — databases, fuzzy search, MIR/waveforms, and Beat This

  • Data_Lines — live playback/input bridges and their lifetimes

  • Editor_Format and FX_ARGS — exact authoring data references

Public usage examples are GDScript-first and are verified against the current PDJE-Godot-Plugin wrapper surface.

Contributors

Read Developer_Onboarding for source layout, build boundaries, and change workflow. The generated API Reference is secondary exact-symbol reference material.

For AI Agents

AI assistants and human reviewers should read PDJE For AI Agents for retrieval order, subsystem invariants, units, ownership, and claim-verification rules before making source-backed claims.

System Architecture

Core Engine

Core owns the root database, music and FX search, playback, manual control, and the integrated editor. Mixsets are translated into runtime data and can be pre-rendered, streamed, or combined with live DJ control depending on player mode. MusicPanel and FXPanel provide supported runtime mutation boundaries.

Editor changes music metadata, mixsets, and note charts in an isolated working area. Its history support records changes through Git-backed operations, and explicit render/push steps translate editable JSON into runtime binary/root-DB payloads.

Input Engine

Input captures keyboard/mouse and MIDI through platform-specific backends. The current source tree supports Linux and Windows; macOS remains planned. Standard input and MIDI use distinct internal transports and are projected into Godot as signals through InputLine.

Judge Engine

Judge aligns expected note positions with input events using Core audio timing and Input timestamps from a shared monotonic high-resolution timebase. Audio sample rate and buffer size still influence scheduling and latency, but do not define the finest judgment resolution. Rail ordering, timing options, and producer lifetime are explicit setup contracts.

Utility Engine

Util is active code. It provides RocksDB key/value storage, SQLite relational storage, Annoy nearest-neighbor search, in-memory fuzzy search, scalar/text helpers, STFT and waveform/WebP processing, and ONNX Runtime/Beat This support. Current native utility APIs use family-specific direct values and exceptions; the removed shared result/status model is not part of the current contract.

Shared Data Lines

Core and Input expose non-owning live-state bridges consumed by wrappers and Judge. Producers retain ownership, consumers copy what they need, and lines must be reacquired whenever a player or input module is reset.

Project Direction

        ---
config:
  theme: forest
  themeVariables:
    fontSize: 25px

---
timeline
  section DJ + DAW Rhythm Engine
    0.5.0 : Core module
    0.6.0 : Windows input
    0.7.0 : Judge module
    0.8.0 : Linux input and MIDI
    0.9.0 : Utility module and accelerated processing
    1.0.0 : macOS input (planned) and stable release goal
  section HPC + AI Expansion
    1.2.0 : Utility expansion
    1.5.0 : ONNX Runtime integration
    2.0.0 : Integrated accelerated AI/utility workflows
    

Contributor Build Route

Project-DJ-Engine uses C++20, CMake, and Conan. Build options and exact platform commands change with repository state, so contributors should follow Developer_Onboarding and the checked-out native repository’s current build scripts rather than copy an old public-site command. Godot application developers normally install a prebuilt plugin and do not build the native engine directly.

Development Flow

        %%{init: {'flowchart': {'curve': 'stepAfter'}}}%%

flowchart TD
subgraph CORE_DEVELOP
  push_to_core/dev --> core/dev
  core/dev --> core/dev_build_test
  core/dev_build_test --> core/main
  core/main --> core/main_build_test
end
subgraph WRAPPER_DEVELOP
  push_to_wrapper/dev --> wrapper/dev
  wrapper/dev --> wrapper/dev_build_test
  core/dev --> wrapper/dev_build_test
  wrapper/dev_build_test --> wrapper/main
  wrapper/main --> wrapper/main_build_test
  core/main --> wrapper/main_build_test
end
subgraph VALID_CHECK
  RELEASE --> self_clone/git_lfs_test
  self_clone/git_lfs_test --> PASS
  self_clone/git_lfs_test --> FAIL
  FAIL --> revert_commit
end
CORE_DEVELOP --> Project_DJ_Engine
WRAPPER_DEVELOP --> PDJE_Godot_Plugin
Project_DJ_Engine -->|TRIG_CICD| PDJE_Godot_Plugin
PDJE_Godot_Plugin -->|RELEASE| Project_DJ_Godot
Project_DJ_Godot --> VALID_CHECK
    

Resources