You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Player crops portrait videos on default configs #79
Our default configuration options on the player currently use:
Aspect ratio: 16:9 (this enforces the aspect ratio of the player, even if the video is in a different ratio)
Object fit: cover (which means "fill" instead of "fit" to area)
While this works well for landscape videos. If they are not exactly on 16:9 aspect ratio, they will be cropped on the sides to fill the player area, which can look better than adding black bars to them.
With portrait videos tho, this effectively means that we crop around ~70% of the video, displaying only the very center of it. This means that applications that want to show portrait videos will need to make custom configurations on the player to get minimum functionality working.
IMO the best fix for this would be defaulting the Object Fit to contain, which means to fit the video on the player area adding black bars to the sides. This will work well on all cases instead, by also adding black bars to landscape videos not exactly 16:9, which is a fine compromise to me. This is not the consensus tho, so let's talk about it to decide.
Activity
0xcadams commentedon Oct 5, 2022
See here for details. Moving this to a discussion. https://livepeerjs.org/react/Player#objectfit