Fix: use wav-stream-live for train arrivals and departures to fix CC client audio playback
This commit is contained in:
@@ -1288,7 +1288,8 @@ function buildSequenceWavFile(seq) {
|
||||
try { fs.unlinkSync(outWavPath); } catch {}
|
||||
}, Math.max(10 * 60 * 1000, Math.ceil(durationSec * 2000)));
|
||||
return {
|
||||
audioFormat: 'stream',
|
||||
audioFormat: 'wav-stream-live',
|
||||
sourcePath: outWavPath,
|
||||
streamUrl: getManagedMediaUrl('temp', fileName),
|
||||
durationSec
|
||||
};
|
||||
@@ -1875,6 +1876,7 @@ function handleTrainArrival(ws, data) {
|
||||
if (built) {
|
||||
enqueueStationAudioTask(stationName, ws, {
|
||||
audioFormat: built.audioFormat,
|
||||
sourcePath: built.sourcePath,
|
||||
streamUrl: built.streamUrl,
|
||||
durationSec: built.durationSec,
|
||||
priority: 1,
|
||||
@@ -1923,6 +1925,7 @@ function handleTrainDeparture(ws, data) {
|
||||
if (built) {
|
||||
enqueueStationAudioTask(stationName, ws, {
|
||||
audioFormat: built.audioFormat,
|
||||
sourcePath: built.sourcePath,
|
||||
streamUrl: built.streamUrl,
|
||||
durationSec: built.durationSec,
|
||||
priority: 1,
|
||||
|
||||
Reference in New Issue
Block a user