自動変更画像ギャラリーを実装したい。これがコントローラーの私のコードです。image という名前の uiimageview があります。画像の配列を画像ビューにリンクして、数秒後に自動変更したいと考えています。私は何をすべきか??
- (void)viewDidLoad{
[super viewDidLoad];
[self performSelector:@selector(changeImage) withObject:nil afterDelay:2];
}
-(void)changeImage {
NSArray *images = [NSArray arrayWithObjects:[UIImage imageNamed:@"animated-fish-1.jpg"], [UIImage imageNamed:@"tumblr_7"], [UIImage imageNamed:@"th_nature_4.jpg"],nil];
image.animationImages = images;
// how to let the array of image load and link to the perform selector??
// what should i continue from here?
}