我面對奇怪的問題,而在iOS 10
翻轉圖像不工作在iOS上10
翻轉的形象在這裏是我的代碼。
uiImage = [[UIImage alloc] initWithCIImage:ciImage];
flippedImg = [UIImage imageWithCIImage:ciImage scale:uiImage.scale orientation:UIImageOrientationDownMirrored];
captureImgView.image = flippedImg;
我正在一個ciImage
和得到成uiImage
。 然後翻轉那UIImage
。 此代碼適用於所有iOS版本,低於10. 但在10及以上版本無效。
我嘗試了所有取向,
UIImageOrientationUpMirrored
UIImageOrientationLeftMirrored
UIImageOrientationUp
UIImageOrientationRight
UIImageOrientationDown
UIImageOrientationLeft
UIImageOrientationDownMirrored
UIImageOrientationRightMirrored
但沒有什麼工作。
我正在從前置攝像頭拍攝自拍照並將該自拍照附加到UIImageView
。 我不想附上從前置攝像頭拍攝的翻轉圖像。 這裏我想要原始圖像。
請指導我一樣。
在此先感謝。
是的,我只得到這一個。但我不想翻轉圖像。我想要表現出來。並從前置攝像頭拍攝。圖像直接放在UIImageView上工作在我的末端... – Sagar
然後直接使用原始圖像.... 'UIImage * uiImage = [UIImage imageNamed:@「wall1.png」]; _imgOriginal.image = uiImage;' – VRAwesome
我從前置攝像頭捕獲圖像。 not direct image – Sagar