如图效果
- 周围扩散阴影
代码
self.bg2.layer.shadowColor = color.CGColor;
self.bg2.layer.shadowOffset = CGSizeMake(0,8);//阴影扩散范围
self.bg2.layer.shadowOpacity = 1.0;
self.bg2.layer.shadowRadius = 29;
self.bg2.layer.cornerRadius = 25;
self.bg2.backgroundColor = [UIColor whiteColor];
self.bg2.clipsToBounds = NO;