import { Disposable } from "../../../../../base/common/lifecycle.js"; import { Event } from "../../../../../base/common/event.js"; import { ILogService } from "../../../../../platform/log/common/log.service.js"; import { ITtsPlaybackService } from "./ttsPlaybackService.service.js"; export declare class TtsPlaybackService extends Disposable implements ITtsPlaybackService { private readonly logService; readonly _serviceBrand: undefined; constructor(logService: ILogService); private _window; private _playbackCtx; private _playbackTurn; private _playbackGen; private _analyserNode; private _isPlaying; private _lastPlayedSamples; private readonly _onPlaybackStarted; readonly onPlaybackStarted: Event; private readonly _onPlaybackStopped; readonly onPlaybackStopped: Event; get isPlaying(): boolean; get analyserNode(): AnalyserNode | undefined; getLastPlayedSamples(): Float32Array | null; ensureContext(window: Window & typeof globalThis): AudioContext; playAudioChunk(audio: string, isFinal: boolean, window: Window & typeof globalThis): void; stopPlayback(): void; /** Close the AudioContext entirely (for full teardown). */ closeContext(): void; private _ensurePlayTurn; private _writeToPlayBuffer; private _startPlayback; private _schedulePlayStop; private _captureSamples; dispose(): void; }