diff options
| -rw-r--r-- | cogs/compression.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cogs/compression.py b/cogs/compression.py index b684f9f..177f543 100644 --- a/cogs/compression.py +++ b/cogs/compression.py | |||
| @@ -41,9 +41,9 @@ class Compression(commands.Cog): | |||
| 41 | logger.info(f"Compression started for: {file_type}") | 41 | logger.info(f"Compression started for: {file_type}") |
| 42 | 42 | ||
| 43 | if file_type == "Video": | 43 | if file_type == "Video": |
| 44 | command = f"ffmpeg -i {file_path} -c:v libx264 -crf 51 -b:v 100 -vf 'fps=10,scale=trunc(iw*0.5/2)*2:trunc(ih*0.5/2)*2' -preset ultrafast -c:a libopus -b:a 500 {output_path}" | 44 | command = f"ffmpeg -y -i {file_path} -c:v libx264 -crf 51 -b:v 100 -vf 'fps=10,scale=trunc(iw*0.5/2)*2:trunc(ih*0.5/2)*2' -preset ultrafast -c:a libopus -b:a 500 {output_path}" |
| 45 | elif file_type == "Audio": | 45 | elif file_type == "Audio": |
| 46 | command = f"ffmpeg -i {file_path} -ac 1 -b:a 500 -acodec libopus {output_path}" | 46 | command = f"ffmpeg -y -i {file_path} -ac 1 -b:a 500 -acodec libopus {output_path}" |
| 47 | elif file_type == "Image": | 47 | elif file_type == "Image": |
| 48 | ext = os.path.splitext(file_path)[1].lower() | 48 | ext = os.path.splitext(file_path)[1].lower() |
| 49 | if ext in [".jpg", ".jpeg"]: | 49 | if ext in [".jpg", ".jpeg"]: |
