Quote:
Originally Posted by Johanovski
Code:
UIImage* img = [UIImage imageWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"sangnormal01" ofType:@"png"]];
texMoscaNormal[0][0] = [[Image alloc] initWithImage:img];
[img release]; // <-- You don't want this
|
I haven't read the whole thread, but just commenting on this last post...
+[UIImage imageWithContentsOfFile] will return a UIImage that has been autoreleased.
So you don't want to release it again.
And then of course you want to make sure that -[Image initWithImage:] is retaining the UIImage and releasing it in -[Image dealloc].
Hope that helps.