cleanup and fixes
All checks were successful
Build Images and Deploy / Update-PROD-Stack (push) Successful in 1m15s

This commit is contained in:
2026-02-09 18:50:06 -05:00
parent 2c2bf21c37
commit eab55d2e01
2 changed files with 140 additions and 36 deletions

14
app.py
View File

@@ -114,6 +114,15 @@ def process_video():
# Build filter complex for crop and scale
filters = []
# Add rotation filter if specified
rotation = data.get('rotation', 0)
if rotation == 90:
filters.append('transpose=1')
elif rotation == 180:
filters.append('transpose=2,transpose=2')
elif rotation == 270:
filters.append('transpose=2')
# Add crop filter if specified
crop = data.get('crop')
if crop:
@@ -136,6 +145,11 @@ def process_video():
if filters:
cmd.extend(['-vf', ','.join(filters)])
# Handle audio
mute_audio = data.get('mute_audio', False)
if mute_audio:
cmd.extend(['-an']) # Remove audio
# Output settings for H.264 MP4
cmd.extend([
'-c:v', 'libx264',