PcoWSkbVqDnWTu_dm2ix
We use cookies on this site to enhance your user experience
Collapse Sidebar

AspectRatio

UIAspectRatioConstraint

float

AspectRatio determines the width-to-height ratio to maintain. To flip the ratio to height-to-width, take the inverse (divide 1 by the number or raise to the -1st power). This value must be greater than zero. Below, a white Frame is placed within the a black Frame with two different width-to-height ratios.

A width-to-height ratio of 0.8A width-to-height ratio of 1.25