程序接收信号sigterm

时间:2012-05-03 14:17:42

标签: iphone uiimageview

在我的应用程序中有一个图像视图,我在其中执行两个操作: 1.反映图片:

- (无效)reflectImage {

UIImage *alterImage=[[UIImage alloc]init];
alterImage=photoView.image;
UIImageOrientation flippedOrientation = alterImage.imageOrientation;
if (flippedOrientation==UIImageOrientationUp) {
    flippedOrientation = UIImageOrientationDownMirrored;

}
else if (flippedOrientation==UIImageOrientationDown) {
    flippedOrientation = UIImageOrientationUpMirrored;

}
else if (flippedOrientation==UIImageOrientationDownMirrored) {
    flippedOrientation = UIImageOrientationUp;

}
else if (flippedOrientation==UIImageOrientationUpMirrored) {
    flippedOrientation = UIImageOrientationDown;

}
UIImage * flippedImage = [UIImage imageWithCGImage:alterImage.CGImage scale:alterImage.scale orientation:flippedOrientation];
photoView.image=flippedImage;

}

和2. SimpleImage:

-(IBAction)getSimpleImage:(id)sender{


    [photoView setImage:simpleImage];


}

simpleImage是原始图像。 当我反映图像并取回原始图像时,应用程序崩溃。 它显示错误为"程序收到信号sigterm"。

0 个答案:

没有答案