我有一个在模拟器中运行良好但在设备上崩溃的动画。我收到以下错误...
节目接收信号:“0”。由于信号 10 (SIGBUS),调试器已退出
一些调查表明 UIImages 没有被释放并且我有内存泄漏。我是新手,所以有人可以告诉我这是否是可能的原因吗?如果您也可以告诉我如何解决它,那将是惊人的。
图片大小为 480 像素 x 480 像素,每张约 25kb。我的代码如下...
NSArray *rainImages = [NSArray arrayWithObjects:
[UIImage imageNamed:@"rain-loop0001.png"],
[UIImage imageNamed:@"rain-loop0002.png"],
[UIImage imageNamed:@"rain-loop0003.png"],
[UIImage imageNamed:@"rain-loop0004.png"],
[UIImage imageNamed:@"rain-loop0005.png"],
[UIImage imageNamed:@"rain-loop0006.png"],
//more looping images
[UIImage imageNamed:@"rain-loop0045.png"],
[UIImage imageNamed:@"rain-loop0046.png"],
[UIImage imageNamed:@"rain-loop0047.png"],
[UIImage imageNamed:@"rain-loop0048.png"],
[UIImage imageNamed:@"rain-loop0049.png"],
[UIImage imageNamed:@"rain-loop0050.png"],
nil];
rainImage.animationImages = rainImages;
rainImage.animationDuration = 4.15/2;
rainImage.animationRepeatCount = 0;
[rainImage startAnimating];
[rainImage release];
谢谢