これが私のコードです:
-(void) takePhoto
{
UIImagePickerController *imagePickerController = [[UIImagePickerController alloc] init];
imagePickerController.sourceType = UIImagePickerControllerSourceTypeCamera;
//imagePickerController.editing = YES;
imagePickerController.allowsEditing=YES;
imagePickerController.delegate = self;
[self presentViewController:imagePickerController animated:YES completion:NULL];
}
#pragma mark - Image picker delegate methods
-(void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info {
[picker dismissViewControllerAnimated:NO completion:nil];
[self.Picture setImage:[info objectForKey:UIImagePickerControllerOriginalImage]];
}
デリゲートを実装しました
UINavigationControllerDelegate,UIImagePickerControllerDelegate
画像が撮影され、ボックスの移動とスケールが表示されますが、移動するとボックスが元の位置に戻ります。
何故ですか?