             guard let backgroundPicture = backgroundPicture else { return }
             
             let size = AVMakeRectWithAspectRatioInsideRect(backgroundPicture.size,
-                CGRect(x: 0, y: 0, width: CGFloat.max, height: frame.height)).size
+                CGRect(x: 0.0, y: 0.0, width: CGFloat.max, height: frame.height)).size
             UIGraphicsBeginImageContextWithOptions(size, false, 0.0)
             backgroundPicture.drawInRect(CGRect(x: 0.0, y: 0.0, width: size.width, height: size.height))
             let image = UIGraphicsGetImageFromCurrentImageContext()

                    width: self.background.layer.frame.width,
                    height: self.background.layer.frame.height)
            }
            self.background.layer.frame = CGRect(x: self.backgroundLayerFrameOrigin!.x + (CGFloat(differenceInTouchXAxis) / self.frame.width) * CGFloat(self.offsetPerPage), y: 0.0, width: self.background.layer.frame.width, height: self.background.layer.frame.height)
        }
    }
    

        
        let duration = (index == currentViewIndex) ? 0.3 : 0.2
        UIView.animateWithDuration(duration) {
            self.background.layer.frame = CGRect(x: self.backgroundLayerFrameOrigin!.x,
                y: 0.0,
                width: self.background.layer.frame.width,
                height: self.background.layer.frame.height)
        }
        
        // Views
