iOS view上直接添加图片 UIImage*image = [UIImageimageNamed:@"bg"];view.layer.contents = (__bridge id)image.CGImage;/** 设置对齐模式*/view.layer.contentsGravity = kCAGravityResize; iOS 2024-05-03 34 点赞 0 评论 51 浏览