Avatar
override func viewDidAppear(_ animated: Bool) { super.viewDidAppear(animated) // Makes `image` negative camera.start { [weak self] image in image.update { pixel in pixel.red = 255 - pixel.red pixel.green = 255 - pixel.green pixel.blue = 255 - pixel.blue } self?.imageView.image = UIImage(cgImage: image.cgImage, scale: 1.0, orientation: .right) } } @koher さんがご懸念されてたコールバックの度に回転させちゃうコードだとこんな感じでしょうか😅 (edited)