Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/youxianming/uiimageblur

Add the blur effect to UIImage.
https://github.com/youxianming/uiimageblur

Last synced: about 2 months ago
JSON representation

Add the blur effect to UIImage.

Awesome Lists containing this project

README

        

# UIImageBlur

> Used to blur UIImage

* Normal Image

![normal图片](/normal.png)

* Half-Blured Image

![half-blur图片](/half-blur.png)

```
// get Image
UIImage *image = [UIImage imageNamed:@"people"];

// init UIImageView
UIImageView *imageView = [[UIImageView alloc] initWithImage:image];
imageView.center = self.view.center;
[self.view addSubview:imageView];

// blur Image at specified frame
imageView.image = [image blurImageAtFrame:CGRectMake(0, 0, image.size.width, image.size.height / 2.f)];

```

* Blured Image

![blur图片](/blur.png)

```
// get Image
UIImage *image = [UIImage imageNamed:@"people"];

// init UIImageView
UIImageView *imageView = [[UIImageView alloc] initWithImage:image];
imageView.center = self.view.center;
[self.view addSubview:imageView];

// blur Image
imageView.image = [image blurImage];

```