iphone image captured from camera rotate -90 degree automatically

后端 未结 7 1533
后悔当初
后悔当初 2020-12-01 04:57

Programatically I have fetched image from my camera in my app. It has been fetched nicely but when I shift to another view and dismiss that view at that time my image automa

7条回答
  •  Happy的楠姐
    2020-12-01 05:30

    The most simplest way to overcome this problem is by scaling the image inside didFinishPickingImage delegate. You can use the following code to scale by importing a class "UIImage+ImageScaling.h".

    theImage =[UIImage imageWithImage:image scaledToSizeWithSameAspectRatio:CGSizeMake(400, 300)]; // for iphone.

提交回复
热议问题