從 playground 調色去背圖片-Cloud Pool

import UIKit// 叫出位在上面去背的圖let image = UIImage (named: “pool.png”)let poolImageView = UIImageView (image: image)// 控制兩張圖大小一樣let cloudImageView = UIImageView (frame: poolImageView.frame)// 叫出位在下面當底的圖cloudImageView.image = UIImage (named: “cloud.jpg”)// 在pool.png這張圖上面疊上一個半透明單色poolImageView.backgroundColor = UIColor (red: 2/255, green: 45/255, blue: 100/255, alpha: 0.8)// 在cloudimageView上面放上addSubview的pool.pngcloudImageView.addSubview(poolImageView)cloudImageView

--

--