iPad アプリを開発していますが、アニメーションに問題があります。IBAction でアニメーションとオーディオを同時に開始し、iPad2 を使用して同期していますが、iPad 3 とシミュレーター 64 ビットでアプリを実行すると、画像に遅延があるため、オーディオと画像が同期されません。
これは私のコードです:
-(IBAction)Action:(id)sender {
UIButton *Namebutton = (UIButton*) sender;
Namebutton.enabled = NO;
animation.animationImages = [NSArray arrayWithObjects:
GetImgWithoutCachingP6(@“image1.png"),
GetImgWithoutCachingP6(@"image2.png"),
GetImgWithoutCachingP6(@"image3.png"),
GetImgWithoutCachingP6(@"image4.png"),
GetImgWithoutCachingP6(@"image5.png"),
GetImgWithoutCachingP6(@"image6.png"),
GetImgWithoutCachingP6(@"image7.png"),
GetImgWithoutCachingP6(@"image8.png"),
GetImgWithoutCachingP6(@"image9.png"),
GetImgWithoutCachingP6(@"image10.png"),
GetImgWithoutCachingP6(@"image11.png"),
GetImgWithoutCachingP6(@"image12.png"),
GetImgWithoutCachingP6(@"image13.png"),
GetImgWithoutCachingP6(@"image14.png"),
GetImgWithoutCachingP6(@"image15.png"),
GetImgWithoutCachingP6(@"image16.png"),
nil];
animation.animationRepeatCount = 2;
animation.animationDuration = 4.0;
[animation startAnimating];
NSString *Sound = [[NSBundle mainBundle] pathForResource:@“NameSound" ofType:@"wav"];
Scenesound=[[AVAudioPlayer alloc] initWithContentsOfURL:[NSURL fileURLWithPath: Sound] error:NULL];
Scenesound.volume = 4.0;
Scenesound.numberOfLoops = 1;
[Scenesound play];
問題はどれですか?
ご協力ありがとうございました