更新时间:2023-11-11 23:14:22
我刚刚处理了这个问题。不要在 CGLayer
上绘制背景,然后将 UIView
的背景设置为:
I just dealt with this. Don't draw a background on the CGLayer
and then set the background of the UIView
to:
self.backgroundColor = [UIColor clearColor];
应该这样做,您的png将具有透明背景。
That should do it and your png will have a transparent background.