From ef04ae20fe4155f516ab41959e312de093f98d0e Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 17 Jan 2019 14:03:32 +0100 Subject: [PATCH] Prefer avg_frame_rate to fetch video FPS --- server/helpers/ffmpeg-utils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/helpers/ffmpeg-utils.ts b/server/helpers/ffmpeg-utils.ts index c7296054d..132f4690e 100644 --- a/server/helpers/ffmpeg-utils.ts +++ b/server/helpers/ffmpeg-utils.ts @@ -41,7 +41,7 @@ async function getVideoFileResolution (path: string) { async function getVideoFileFPS (path: string) { const videoStream = await getVideoFileStream(path) - for (const key of [ 'r_frame_rate' , 'avg_frame_rate' ]) { + for (const key of [ 'avg_frame_rate', 'r_frame_rate' ]) { const valuesText: string = videoStream[key] if (!valuesText) continue -- 2.25.1