/**
 * Plays automation envelopes through native AudioParam scheduling.
 *
 * Nothing here runs per frame. The envelope is handed to the audio thread once,
 * as ramps and curves, so it stays sample-accurate no matter what the main
 * thread is doing — and the offline render schedules it the same way, which is
 * why preview and render agree by construction rather than by tolerance.
 */
import { type HfAutomation, type HfAutomationLane } from "../audioAutomation.js";
import type { HfAudioFxChain } from "../audioFx.js";
import type { FxNodeHandle, FxParamTarget } from "./audioFxGraph.js";
/** Where the clip sits in context time when its source is scheduled. */
export interface AutomationTiming {
    /** Context time the source was scheduled at. */
    scheduledAt: number;
    /** Clip-local seconds already elapsed at that moment; negative before it starts. */
    elapsed: number;
    /** Playback rate, which compresses clip seconds into context seconds. */
    rate: number;
}
/**
 * Drop every event booked on a parameter, including a curve already under way.
 *
 * Anything landing inside a running curve is refused — a fresh curve, or the
 * plain `.value` write that re-parameterising a chain performs — so the param has
 * to be cancelled first. Measured against Chrome, any cancel frees the span; this
 * takes the strongest form on purpose, because curve-over-curve refusals were
 * reported from the field with a cancel at the new schedule time already in place
 * and have never reproduced. Cancelling from zero cannot leave a stale event
 * behind whatever that mechanism is.
 *
 * Safe on these parameters because this scheduler is their only writer: they
 * belong to effect nodes it built, and the caller re-seeds the value in the same
 * breath, so nothing clicks.
 */
export declare function clearParamLane(targets: readonly FxParamTarget[]): void;
/** Stop an envelope, leaving the parameter wherever it currently sits. */
export declare function cancelParamLane(targets: readonly FxParamTarget[], from: number): void;
/**
 * Schedule one lane onto every AudioParam behind its knob.
 *
 * Existing automation from an earlier schedule is cancelled first, so calling
 * this again after an edit replaces the envelope rather than layering on it.
 */
export declare function scheduleParamLane(targets: readonly FxParamTarget[], lane: HfAutomationLane, scale: "linear" | "log", timing: AutomationTiming): void;
/** One built effect, paired with the chain node id lanes address it by. */
export interface AutomatableNode {
    id?: string;
    handle: FxNodeHandle;
}
/**
 * Schedule every FX lane in an automation set against a built chain.
 *
 * Lanes with nowhere to write are skipped rather than reported: a one-pole
 * filter exposes no frequency param, and a worklet effect exposes none at all.
 * Returns the targets that were scheduled, so they can be cancelled together.
 */
export declare function scheduleChainAutomation(automation: HfAutomation, chain: HfAudioFxChain, nodes: readonly AutomatableNode[], timing: AutomationTiming, 
/** The wet/dry blend around each preset run, from `FxChainHandle.presets`. */
presets?: Record<string, FxParamTarget[]>): FxParamTarget[];
/** The track's volume lane, if it has one. */
export declare function volumeLane(automation: HfAutomation): HfAutomationLane | null;
//# sourceMappingURL=audioFxAutomation.d.ts.map