From 1fe1b5ba61854f2e37f83f412b00510446386f52 Mon Sep 17 00:00:00 2001 From: Willy-JL Date: Thu, 25 Aug 2022 00:37:58 +0200 Subject: [PATCH] Support fractional fps --- src/createFFmpeg.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/createFFmpeg.js b/src/createFFmpeg.js index 0b805f4..e7b6f7f 100644 --- a/src/createFFmpeg.js +++ b/src/createFFmpeg.js @@ -58,7 +58,7 @@ module.exports = (_options = {}) => { readFrames = true; } } else if (readFrames && message.startsWith(' Stream')) { - const match = message.match(/(\d+) fps/); + const match = message.match(/([\d\.]+) fps/); if (match) { const fps = parseFloat(match[1]); frames = duration * fps;