This demo mimics the effect of the drop of water, in Objective-c
Objective-C
Latest commit f458fb9 Nov 24, 2015 PandaraWen update read
Permalink
Failed to load latest commit information.
WaterDropViewDemo.xcodeproj init Nov 24, 2015
WaterDropViewDemo init Nov 24, 2015
WaterDropViewDemoTests init Nov 24, 2015
.gitignore init Nov 24, 2015
README.md update read Nov 24, 2015

README.md

WaterDropViewDemo


This code mimics the effect of the drop of water:

image

And the origin design is from designer Vadim Gromov, here is Gromov's dribbble. The original design is as follows:

image

How to use the demo?

The main functions are implemented in the file WaterDropView.m inside. You can also see some interesting things in another file ViewController.m.

If you want to use the effect in your own code, you can do the following (suppose you add the following code in a controller.):

WaterDropView *waterDropView = [[WaterDropView alloc] initWithFrame:self.view.bounds];
[self.view addSubview:waterDropView];
[waterDropView play];

Here's a more deailed tutorial: click me

License

WaterDropViewDemo is published under MIT License. See the LICENSE file for more.