mirror of
https://github.com/mastodon/mastodon.git
synced 2024-12-21 08:39:44 +00:00
Fix some video encoding failing due to uneven dimensions (#26766)
This commit is contained in:
parent
16681e0f20
commit
05093266e6
|
@ -102,6 +102,7 @@ class MediaAttachment < ApplicationRecord
|
|||
'preset' => 'veryfast',
|
||||
'movflags' => 'faststart', # Move metadata to start of file so playback can begin before download finishes
|
||||
'pix_fmt' => 'yuv420p', # Ensure color space for cross-browser compatibility
|
||||
'vf' => 'crop=floor(iw/2)*2:floor(ih/2)*2', # h264 requires width and height to be even. Crop instead of scale to avoid blurring
|
||||
'c:v' => 'h264',
|
||||
'c:a' => 'aac',
|
||||
'b:a' => '192k',
|
||||
|
|
Loading…
Reference in a new issue