From 9c0e598ce2e559542b6bb6f5dd27c3c0288236af Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Wed, 17 May 2023 09:53:50 -0700 Subject: [PATCH] use the old logic for sizing --- pack-vid | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pack-vid b/pack-vid index eac968d..1c18e4b 100755 --- a/pack-vid +++ b/pack-vid @@ -169,7 +169,6 @@ function convert( $src, $dest, $options ) { $mbits = 1000 * 1000; $base = intval( $mbits * floatval( $options['quality'] ) ); - /* if ( $bitrate < 1 * $base || $height < 480 ) { $frameWidth = 640; $frameHeight = 360; @@ -191,7 +190,6 @@ function convert( $src, $dest, $options ) { $frameHeight = 1080; $bitrate = min( $bitrate, $base * 8 ); } - */ $aspect = $width / $height; $pixels = $width * $height; @@ -199,6 +197,7 @@ function convert( $src, $dest, $options ) { // canonical base rate is 1 megabit at 480p $bitrate = min( $bitrate, 4 * $base ); + /* $minWidth = 640; $minHeight = 360; @@ -233,6 +232,7 @@ function convert( $src, $dest, $options ) { $bitrate = min( $bitrate, $maxrate ); } } + */ $wide = $aspect > ( $frameWidth / $frameHeight ); $crop = boolval( $options['crop'] );