views:

853

answers:

3

I have read several post on both matters but I haven't seen anyone comparing so far.

Suppose I just want full screen animation without any transparency etc, just a couple of seconds animation (1''-2'') when an app starts. Does anyone know how "video" compares to "sequence of images" (320x480 @ 30) on the iPhone, regarding performance etc?

+1  A: 

The video will be a lot more compressed than a sequence of images, because video compression takes previous frame data into account to reduce bitrate. It will take more power to decode, however the iPhone has hardware for that, and the OS has APIs that use this hardware, so I wouldn't feel bad about making use of them.

JeeBee
That's what i think. But I see so many people trying to play animation frame-by-frame so I wonder if there is anything I'm missing.
Dimitris
+2  A: 

I think there are a few points to think about here.

  1. Size of animation as pointed out above. You could try a framerate of 15 images per second so that could be 45 images for 3s. That is quite a lot data.
  2. The video would be compressed as mentioned before in H.264 (Baseline Profile Level 3.0) format or MPEG-4 Part 2 video (Simple Profile) format. Which means its going to be reasonably small.

I think you will need to go for video because, 1. 45 full screen PNG images is going to require a lot of ram. I don't think this is going to work that well.

Lastly you will need to ad the Media Player Framework which will have to be loaded into memory and this going to increase your load times.

MY ADVICE: Sounds like the animation is a bit superfluous to the app, I hate apps that take ages to load and this is only going to increase you app startup times. If you can avoid doing this, then dont do it. Make you app fast. If you could do this at some other time after load then that is cool.

John Ballinger
A: 

do not overlook the possibility of rendering the sequence in real-time.

kent
What do I win if I do it this way?
Dimitris
depending on the complexity of your render: faster load time, lower memory footprint, highest image quality, interactivity. http://www.khronos.org/opengles/
kent