         var mask = CAShapeLayer()
         
         mask.frame = self.frame
-        let path = drawSlice(start, end: end)
+        let path = computeTrioPath(start, end: end)
         mask.path = path.animationBezierPath.CGPath
-        mask.lineWidth = properties.bigRadius-properties.smallRadius
+        mask.lineWidth = properties.bigRadius - properties.smallRadius
         mask.strokeColor = color.CGColor
         mask.fillColor = color.CGColor
         

    var originalTransform:CGAffineTransform!

    var pieChartCenter:CGPoint = CGPointZero
  
    override init(frame: CGRect) {
        super.init(frame: frame)


        return toRet;
    }
    
    
    
    func computePath(start:CGFloat, end:CGFloat, isSelection:Bool) -> UIBezierPath {
    
        var path = UIBezierPath()
        
        let startPointX = pieChartCenter.x + properties.smallRadius * cos(start)
        let startPointY = pieChartCenter.y + properties.smallRadius * sin(start)
        
        let startPoint = CGPointMake(startPointX, startPointY)
        
        var delta = (isSelection) ? properties.expand : 0
        
        path.moveToPoint(startPoint)
        
        path.addArcWithCenter(pieChartCenter, radius: properties.smallRadius, startAngle: start, endAngle: end, clockwise: false)
        
        
        var helperPath = UIBezierPath()
        helperPath.moveToPoint(CGPointMake(startPointX, pieChartCenter.y))
        
        helperPath.addArcWithCenter(pieChartCenter, radius: (properties.bigRadius + delta), startAngle: start, endAngle: end, clockwise: false)
        
        path.addLineToPoint(helperPath.currentPoint)
        
        path.addArcWithCenter(pieChartCenter, radius: (properties.bigRadius + delta), startAngle: end, endAngle: start, clockwise: true)
        
        path.addLineToPoint(startPoint)
        
        
        
        return path;
    }
    
    func computeAnimationPath(start:CGFloat, end:CGFloat) -> UIBezierPath {
        var animationPath = UIBezierPath()
        
        animationPath.moveToPoint(getMiddlePoint(start))
        
        animationPath.addArcWithCenter(pieChartCenter, radius: (properties.smallRadius + (properties.bigRadius-properties.smallRadius)/2), startAngle: start, endAngle: end, clockwise: false)
        
        animationPath.addArcWithCenter(pieChartCenter, radius: (properties.smallRadius + (properties.bigRadius-properties.smallRadius)/2), startAngle: end, endAngle: start, clockwise: true)
        
        
        
        
        return animationPath;
    }

    /**
    Computes and returns a triplet of UIBezierPaths
    
    :param: start start angle
    :param: end   end angle
    
    :returns: the triplet
    */
    func computeTrioPath(start:CGFloat, end:CGFloat) -> TrioPath {
        
        
        let pathRef = computeAnimationPath(start, end: end)
        
        
        let other = CGPathCreateCopyByStrokingPath(pathRef.CGPath, nil, properties.bigRadius-properties.smallRadius, kCGLineCapButt, kCGLineJoinMiter, 1)
        
        let other2 = CGPathCreateCopyByStrokingPath(pathRef.CGPath, nil, 30, kCGLineCapButt, kCGLineJoinMiter, 1)
        
        let ok = UIBezierPath(CGPath: other)
        let ok2 = UIBezierPath(CGPath: other2)
        
        return TrioPath(myBezierPath: ok, myAnimationBezierPath: pathRef, mySelectionBezierPath: ok2)
    }
    
    
