I’m pretty new to iOS programming and I have this problem.
I have a view where the animation is a train rushing past. The frames of the animation are 60ish (1024×768) pngs which I put in an array and then use [myUIImageView startAntimating].
This works beautifully but I have another animation that I want to run later in the same view, which is around 270 pngs of the same resolution, in which the train comes to a stop and the doors open. Adding these images to a UIImageView in the same way unsurprisingly makes the app crash. In fact, not adding the first set of images and only adding these images makes the app crash.
What would be the best way to overcome this problem?
Holding 270 such PNGs should take around 850 mb of memory, so you can’t hold them all at once. I can think of three ways to solve this –
libav‘s FAQ to see how to convert a sequence of images into a movie.