ImageView を ScrollView に配置して、画像をズームするだけです。imageView(ズーム後)に表示される画像部分をトリミングし、新しい画像として保存したい。
ありがとう
コードはこちら
CGRect frame = CGRectMake(0,0,190,210);
scroll = [[UIScrollView alloc] initWithFrame:frame];
scroll.contentSize = CGSizeMake(240, 260);
scroll.showsHorizontalScrollIndicator = YES;
scroll.showsVerticalScrollIndicator = YES;
[scroll addSubview:imageView];
そしてスクロールビューデリゲートメソッドは
- (UIView *)viewForZoomingInScrollView:(UIScrollView *)scrollView{
return self.imageView;
}