preResolveReactive abstract method
Future<void>
preResolveReactive(
- Iterable<
AudioSource> sources, { - required BeatDetectionService beatDetector,
- required FrequencyAnalyzer analyzer,
- required int fps,
- required int totalFrames,
Analyses every reactive audio source in sources into a BeatGrid and a
BandTable before the frame loop.
Kept separate from preResolveAudio so the encoder-file-materialize
concern (which the encoder -is) and the reactive analysis concern (which
the ReactiveScope and Trigger.beat read) stay independent. Each source
is decoded once and run through beatDetector / analyzer at fps over
totalFrames; the results feed beatGridFor / bandTableFor
synchronously during the frame loop, so no frame ever awaits audio
analysis. Idempotent: an already-analysed source is skipped. The reactive
inputs are precomputed before frame 0 exactly like media.
Implementation
Future<void> preResolveReactive(
Iterable<AudioSource> sources, {
required BeatDetectionService beatDetector,
required FrequencyAnalyzer analyzer,
required int fps,
required int totalFrames,
});