From 812608d1359ab682957640750cfa98eb6f0d8e85 Mon Sep 17 00:00:00 2001 From: Kamal Curi Date: Sat, 15 Jun 2024 21:44:31 -0300 Subject: [PATCH] FIX: arguments --- downloader.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/downloader.py b/downloader.py index 1ed0948..aceae85 100644 --- a/downloader.py +++ b/downloader.py @@ -7,7 +7,7 @@ parser = argparse.ArgumentParser() parser.add_argument("day", help="Day of the year. From 1 to 366") parser.add_argument("--directory", help="Output directory for the images") parser.add_argument("--size", help="Image size to download, defaults to 1808x1808. Available options: 339x339, 678x678, 1808x1808, 5424x5424, 10848x10848, 21696x21696") -parser.add_argument("--animate", help="Animate the download images. Available options: fullsize, compressed, ad-fullsize, ad-compressed") +parser.add_argument("--animate", help="Animate the download images. Available options: fullsize, compressed, fullsize+compressed, ad-fullsize, ad-compressed, ad-fullsize+compressed") parser.add_argument("--framerate", help="Framerate of the animation from the downloaded images, in frames per second, defaults to 8") parser.add_argument("--compress-size", help="Resolution of the compressed video, defaults to 540x540") parser.add_argument("--codec", help="Defines the ffmpeg codec to be used. Defaults to libx264. To see available codecs for ffmpeg run \"ffmpeg -codecs\"") @@ -117,7 +117,7 @@ if animateAction is not None: print(f"CREATING 540x540 COMPRESSED ANIMATION {directory}/compressed.mp4") subprocess.run(["sh", "-c", f"ffmpeg -framerate {framerate} -pattern_type glob -i '{directory}/*.jpg' -c:v {codec} -crf 25 -s {compress_size} {directory}/compressed.mp4"]) exit() - elif animateAction == "ad-fullsized+compressed": + elif animateAction == "ad-fullsize+compressed": print(f"CREATING FULL-SIZED ANIMATION {directory}/fullsize.mp4") subprocess.run(["sh", "-c", f"ffmpeg -framerate {framerate} -pattern_type glob -i '{directory}/*.jpg' -c:v {codec} {directory}/fullsize.mp4"]) print(f"CREATING 540x540 COMPRESSED VERSION FROM FULL-SIZED ANIMATION") @@ -135,7 +135,7 @@ if animateAction is not None: print(f"CREATING 540x540 COMPRESSED ANIMATION {directory}/compressed.mp4") subprocess.run(["sh", "-c", f"ffmpeg -framerate {framerate} -pattern_type glob -i '{directory}/*.jpg' -c:v {codec} -crf 25 -s {compress_size} {directory}/compressed.mp4"]) exit() - elif animateAction == "fullsized+compressed": + elif animateAction == "fullsize+compressed": print(f"CREATING FULL-SIZED ANIMATION {directory}/fullsize.mp4") subprocess.run(["sh", "-c", f"ffmpeg -framerate {framerate} -pattern_type glob -i '{directory}/*.jpg' -c:v {codec} {directory}/fullsize.mp4"]) print(f"CREATING 540x540 COMPRESSED VERSION FROM FULL-SIZED ANIMATION")