romaonthego / REFrostedViewController

iOS 7/8 style blurred view controller that appears on top of your view controller.
MIT License
2.97k stars 494 forks source link

Specify an opaque background for or FrostedContainer #132

Open bill350 opened 9 years ago

bill350 commented 9 years ago

We have a problem if we don't want the blur management.

I added a backgroundContainerColor property to set an UIColor to the FrostedContainer. Typically, if we want liveBlur we have to specify it. The backgroundContainerColor takes the priority to the liveBlur if the color is different to nil

Moreover, if we don't want blur, it doesn't call re_applyBlurWithRadius function which costs a lot of CPU in... Main thread :-1: (before my request, the code test was if !liveBlur => call re_applyBlurWithRadius , it doesn't make sense ! Just let an opaque background.)

Open to discuss to improve my quick feature to be sure that it doesn't break other blur management.

So, the other issue which have to be fixed is to manage efficiently the GraphicBlur processing to a background queue or whatever.