This is a companion to the http://karmadust.com/animating-a-gradient-in-a-uiview/
There is just one file of interest GradientView.swift so include that in the project and link it to a UIView from the Interface Builder or instantiate it in code.
The code base uses the CADisplayLink instead of an NSTimer to keep up with screen updates.