From 9881d543044c19cd69e6a4b753bba2722084fc25 Mon Sep 17 00:00:00 2001 From: Akash Kava <39438041+ackava@users.noreply.github.com> Date: Fri, 3 Mar 2023 17:06:21 +0530 Subject: [PATCH] Added less than 780p requirement for mobile Ready --- src/commands/probe.ts | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/src/commands/probe.ts b/src/commands/probe.ts index cf1d643..37193f9 100644 --- a/src/commands/probe.ts +++ b/src/commands/probe.ts @@ -66,12 +66,25 @@ export default class FFProbe extends Command { } } - const isMobileReady = isAAC && isH264 && fastStart && isBelow30FPS; - - const needsFastStart = isAAC && isH264 && isBelow30FPS && !fastStart; + const lessThan780p = + (videoStream?.height && videoStream.height <= 780) + || (videoStream?.coded_height && videoStream.coded_height <= 780); + + const isMobileReady = isAAC + && isH264 + && fastStart + && isBelow30FPS + && lessThan780p; + + const needsFastStart = isAAC + && isH264 + && isBelow30FPS + && lessThan780p + && !fastStart; return { ... metadata, + lessThan780p, hasAudio, hasVideo, isAAC,