切某个位置圆角

切某个位置圆角

    //切圆角
    CAShapeLayer *shapeLayer = [CAShapeLayer layer];
    shapeLayer.path = [UIBezierPath bezierPathWithRoundedRect:backgroundImage.frame byRoundingCorners:UIRectCornerTopLeft | UIRectCornerTopRight cornerRadii:CGSizeMake(5, 5)].CGPath;
    backgroundImage.layer.mask = shapeLayer;
    [self addSubview:backgroundImage];

你可能感兴趣的:(切某个位置圆角)