What is the definitive iPhone X corner radius?

Solution 1:

iPhone X corners do not have a conclusive corner radius. They're not normal arcs, they are ‘continuous corners’.

You can't replicate these with a simple .cornerRadius, and you also can't use Apple's own continuous corners, since that's a private API.

CALayer on iOS 11 has a private "continuousCorners" property, which is what powers many rounded corners in SpringBoard – and likely more! Now I'm jealous.

https://twitter.com/argentumko/status/955773459463790592

The closest you can get without your own implementation is UIBezierPath's rounded rectangle drawing, which uses _continuousRoundedRectBezierPath.

Solution 2:

Brad Ellis has an article detailing the curves on the iPhone X.

[..] iPhone X rounded screen corners don’t use the classic rounding method where you move in a straight line and then arc using a single quadrant of a circle. Instead, the math is a bit more complicated. Commonly called a squircle, the slope starts sooner, but is more gentle.

You can see the difference here:

enter image description here