diff options
Diffstat (limited to 'includes')
-rwxr-xr-x | includes/inc_files.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/includes/inc_files.php b/includes/inc_files.php index 3215493..abbbb3d 100755 --- a/includes/inc_files.php +++ b/includes/inc_files.php @@ -45,23 +45,23 @@ function mediagetinfostream($stream = "") if ($fileinfo['video']['resolution_y'] && $fileinfo['video']['resolution_x']) { - if ($$fileinfo['video']['resolution_y'] < $fileinfo['video']['resolution_x']) + if ($fileinfo['video']['resolution_y'] < $fileinfo['video']['resolution_x']) { $resx = 180; - $resy = ($fileinfo['video']['resolution_y'] * 180) / $fileinfo['video']['resolution_x']; + $resy = round(($fileinfo['video']['resolution_y'] * 180) / $fileinfo['video']['resolution_x']); } else { - $resx = ($fileinfo['video']['resolution_x'] * 100) / $fileinfo['video']['resolution_y']; + $resx = round (($fileinfo['video']['resolution_x'] * 100) / $fileinfo['video']['resolution_y']); $resy = 100; } } if ($file) - exec("cp \"" .$file ."\" ram/stream-tb-tmp.jpg; " .$ffmpegpath ." -y -i ram/stream-tb-tmp.jpg -s 180x" .$resy ." ram/stream-tb.jpg"); + exec("cp \"" .$file ."\" ram/stream-tb-tmp.jpg; " .$ffmpegpath ." -y -i ram/stream-tb-tmp.jpg -s " .$resx ."x" .$resy ." ram/stream-tb.jpg"); else - exec($ffmpegpath ." -y -i \"" .$stream ."\" -an -ss 00:00:05.00 -r 1 -vframes 1 -s 180x" .$resy ." -f mjpeg ram/stream-tb.png"); + exec($ffmpegpath ." -y -i \"" .$stream ."\" -an -ss 00:00:05.00 -r 1 -vframes 1 -s " .$resx ."x" .$resy ." -f mjpeg ram/stream-tb.png"); return array($title, $info); } |