I am receiving the error
Kind of expression is ambiguous with out extra context Swift
let widthDifference = CGFloat((picture?.cgImage!.width)!) - body!.width
let bitMapInfo = CGBitmapInfo(rawValue: (picture?.cgImage?.bitmapInfo.rawValue)!)
let intent = CGColorRenderingIntent(rawValue: (picture?.cgImage?.renderingIntent.rawValue)!)
// I am getting an error right here when creating the brand new cg rect.
let newCGImage: CGImage = CGImage(width: body?.width, top: picture?.cgImage?.top - widthDifference, bitsPerComponent: picture?.cgImage?.bitsPerComponent, bitsPerPixel: 72, bytesPerRow: picture?.cgImage?.bytesPerRow, area: (picture?.cgImage?.colorSpace)!, bitmapInfo: bitMapInfo, supplier: (picture?.cgImage?.dataProvider)!, decode: picture?.cgImage?.decode!, shouldInterpolate: false, intent: intent!)
let newCroppedCGImage = newCGImage.cropping(to: body!)!
let img = UIImage(cgImage: newCroppedCGImage)
I googled round however actually i am unable to discover any comparable points to clarify the error.