Skip to main content

VideoAspectRatio

Methods used to fit a video in the target area.

Elements

ElementDescription
VideoAspectRatio.FitHorizontallyResize proportionally so that width fits the target area, cropping or adding black bars above and below if needed.
VideoAspectRatio.FitInsideResize proportionally so that content fits the target area, adding black bars if needed.
VideoAspectRatio.FitOutsideResize proportionally so that content fits the target area, cropping if needed.
VideoAspectRatio.FitVerticallyResize proportionally so that height fits the target area, cropping or adding black bars on each side if needed.
VideoAspectRatio.NoScalingPreserve the pixel size without adjusting for target area.
VideoAspectRatio.StretchResize non-proportionally to fit the target area.