setAspectRatio

fun setAspectRatio(width: Int, height: Int)

Sets the aspect ratio for this view. The size of the view will be measured based on the ratio calculated from the parameters.

Parameters

width

Camera resolution horizontal size

height

Camera resolution vertical size