/// <reference path="../../../../src/@types/@kano/common/index.d.ts" />
export interface ISamplePlayerOptions {
    loop: boolean;
}
export declare class SamplePlayer {
    private ctx;
    private opts;
    private buffer;
    private gainControl;
    output: AudioNode;
    private _volume;
    private paused;
    private playing;
    source: AudioBufferSourceNode | null;
    private pausedAt;
    private startedAt;
    private _onDidEnd;
    private _onDidStart;
    private _onDidPause;
    readonly onDidEnd: import("@kano/common/index.js").IEvent<void>;
    readonly onDidStart: import("@kano/common/index.js").IEvent<void>;
    readonly onDidPause: import("@kano/common/index.js").IEvent<void>;
    constructor(ctx: AudioContext, buffer: AudioBuffer, destination: AudioNode, opts: ISamplePlayerOptions);
    volume: number;
    play(time?: number): void;
    pause(): void;
    stop(): void;
    toggle(): void;
}
