Skip to content

Commit 38cdbbf

Browse files
clainclyicbaker
authored andcommitted
Support encoding square videos.
PiperOrigin-RevId: 422585277
1 parent 123a3c2 commit 38cdbbf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libraries/transformer/src/main/java/androidx/media3/transformer/DefaultCodecFactory.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ public Codec createForVideoEncoding(Format format) throws TransformationExceptio
105105
checkArgument(format.height != Format.NO_VALUE);
106106
// According to interface Javadoc, format.rotationDegrees should be 0. The video should always
107107
// be in landscape orientation.
108-
checkArgument(format.height < format.width);
108+
checkArgument(format.height <= format.width);
109109
checkArgument(format.rotationDegrees == 0);
110110
checkNotNull(format.sampleMimeType);
111111
format = getVideoEncoderSupportedFormat(format);

0 commit comments

Comments
 (0)