SVBSoundBars is a UIView
subclass which displays a custom amount of moving bars which indicate that your app is currently playing some kind of music like in the iOS 7-8 Music.app.
SVBSoundBars is implemented by using CAShapeLayer
.
- iOS 9
- Swift 2.0
Clone this repo and copy SVBSoundBars.swift
into your project
- Add
SVBSoundBars
to your view either by adding it in your Storyboard or directly in code - Customize
SVBSoundBars
for your needs (see Attributes) - Call
startProgressAnimation()
to start the animation
numberOfBars
: The number of bars displayed in yourSVBSoundBars
viewmargin
: the spacing between each barduration
: the duration for a complete animation cycle (animating the bars from their initial position the their complete state and back to the initial position).barColor
: the fill color of the bars
SVBSoundbars
is released under an MIT License.