IOS 8 system comes with blureffect frosted glass effect

Source: Internet
Author: User

The UI design of the frosted glass has been very popular in the development of mobile phones, and in the previous development it was generally used in a Fxblurview packaged view class on GitHub, which can be applied directly to the control, and the updated Uiblureffect class and UIVISUALEFFEC after IOS 8 The Tview class makes this special effect application more convenient and efficient.

It is also very easy to use, Uiblureffect class is to set the type of glass special effect, the Uivisualeffectview class is created with the last class object, the rest is the same as the normal view control, such as the use of the same, with the code case:

Create the desired type of frosted glass effect

Uiblureffect *blureffect = [Uiblureffect effectwithstyle:uiblureffectstylelight];

Frosted Glass View

Uivisualeffectview *effectview = [[Uivisualeffectview alloc] initwitheffect:blureffect];

Add to a control that will have a frosted glass effect

Effectview.frame = Self.imageV.bounds;

[Self.imagev Addsubview:effectview];

Set Blur transparency

Effectview.alpha =. 8f;

If you want to use the Fxblurview on GitHub, it's download path: Https://github.com/nicklockwood/FXBlurView.

IOS 8 system comes with blureffect frosted glass effect

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.