Fix streaming majors: PCM-only validation, stream-from-disk, ConcatStream offset, AsyncDisposable, HTTP cancellation, await ensureReady, seekBeyondBuffer offset-0 guard, negative WAV chunk guard

This commit is contained in:
Daniel Harvey
2026-05-17 16:57:20 -04:00
parent fc5b8de81a
commit 02d146ce02
12 changed files with 481 additions and 68 deletions
+2 -2
View File
@@ -39,7 +39,7 @@ const DeepDrftAudio = {
return player.processStreamingChunk(chunk);
},
startStreamingPlayback: (playerId: string): AudioResult => {
startStreamingPlayback: async (playerId: string): Promise<AudioResult> => {
const player = audioPlayers.get(playerId);
if (!player) return { success: false, error: 'Player not found' };
return player.startStreamingPlayback();
@@ -57,7 +57,7 @@ const DeepDrftAudio = {
return player.ensureAudioContextReady();
},
play: (playerId: string): AudioResult => {
play: async (playerId: string): Promise<AudioResult> => {
const player = audioPlayers.get(playerId);
if (!player) return { success: false, error: 'Player not found' };
return player.play();