Skip to content
A CALayer subclass for indicating Pulsing Halo.
Pull request Compare This branch is 50 commits behind shu223:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
PulsingHalo
PulsingHaloDemo.xcodeproj
PulsingHaloDemo
PulsingHaloDemoTests
.gitignore
LICENSE
README.md

README.md

PulsingHalo

A CALayer subclass for indicating Pulsing Halo.

It's useful for:

  • iBeacon
  • annotions in MapKit

How to use

  1. Add PulsingHaloLayer.h,m into your project
  2. Initiate and add to your view.
PulsingHaloLayer *halo = [PulsingHaloLayer layer];
halo.position = self.view.center;
[self.view.layer addSublayer:halo];

Customization

radius

Use radius property.

self.halo.radius = 240.0;

color

Use backgroundColor property.

UIColor *color = [UIColor colorWithRed:0.7
                                 green:0.9
                                  blue:0.3
                                 alpha:1.0];

self.halo.backgroundColor = color.CGColor;

animation duration

Use animationDuration or pulseInterval property.

Demo

You can try to change radius and color properties with demo app.

Special Thanks

It's inspired by SVPulsingAnnotationView.

Something went wrong with that request. Please try again.