How to convert a rectangular image into a circular image that can preserve shape in an automatic layout without setting width and height restrictions? Thus, allowing the imageView to determine its size and size larger and smaller in relation to the objects surrounding it with restrictions on the leading, final, upper and lower.
The other day I asked a similar question, but I think that this can be delivered in a more concise way. Thank!
EDIT
Ok, I started to make it as easy as possible. I have a view called "Cell" and a UIImageView called "dog" inside the cell, and it is. I no longer have the “ability to simultaneously satisfy constraints” in the console, just two simple views using the automatic layout. I'm still trying to use this code to round a UIImageView:
profileImageView.layer.cornerRadius = profileImageView.frame.size.width / 2 profileImageView.clipsToBounds = true
Here is the cell limit setting:

Here is the profile pic limit setting:

Here is the result without code, without rounding, but beautiful and square:

Here is the result with code rounding:

This makes no sense to me, because without a rounding code, the image is square, and with a code - a diamond. If it is square, is this a circle without problems?
EDIT 2
This is what happens when I remove the lower limit and add a factor of .373 for equal height for viewing.

ios xcode swift
CHM 02 Sep '15 at 20:54 2015-09-02 20:54
source share