IOS 10 Blur Effects Known and Regular Disabled

I did not find any related question on the Internet and I am trying to get a blurry view to display new blur effects. Advanced and. Regular, but they are not displayed. When I change the blur effect to .light, .extraLight or.dark, it works fine. The description says that the new blur effects adapt to the user interface. What does this mean and why are these two new blur effects not working?

I have iOS 10 both in the simulator and on my iPhone, and none of them show a new blur effect. Print statements say that the if statement (instead of else) is called as expected.

let blurEffect : UIBlurEffect!
if #available(iOS 10.0, *) {
   blurEffect = UIBlurEffect(style: .prominent )
} else {
   // Fallback on earlier versions
   blurEffect = UIBlurEffect(style: .light )
}
let blurView = UIVisualEffectView(effect: blurEffect)
blurView.frame = CGRect(x: 100, y: 100, width: 200, height: 300)
+4
1

?

WWDC 2016 206: tvOS:

API.
UIBlurEffectStyleRegular UIBlurEffectStyleProminent.
.
, , .
, UIBlurEffectStyleRegular , UIBlurEffectStyle.light.
, .
, .extraLight .extraDark.
.extraDark

: http://asciiwwdc.com/2016/sessions/206

tvOS. . iOS .

+8

Source: https://habr.com/ru/post/1660581/


All Articles