diff --git a/nodejs/demo/test_srt.js b/nodejs/demo/test_srt.js index 9c297623..8a5b9528 100644 --- a/nodejs/demo/test_srt.js +++ b/nodejs/demo/test_srt.js @@ -46,8 +46,8 @@ ffmpeg_run.on('exit', code => { subs.push({ type: 'cue', data: { - start: words[0].start, - end: words[0].end, + start: words[0].start * 1000, + end: words[0].end * 1000, text: words[0].word } }); @@ -61,8 +61,8 @@ ffmpeg_run.on('exit', code => { subs.push({ type: 'cue', data: { - start: words[start_index].start, - end: words[i].end, + start: words[start_index].start * 1000, + end: words[i].end * 1000, text: text.slice(0, text.length-1) } }); @@ -74,8 +74,8 @@ ffmpeg_run.on('exit', code => { subs.push({ type: 'cue', data: { - start: words[start_index].start, - end: words[words.length-1].end, + start: words[start_index].start * 1000, + end: words[words.length-1].end * 1000, text: text } });