Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

bankC

macrumors newbie
Original poster
Jan 23, 2012
1
0
Hi Everyone,

I am getting an iPhone app developed and at the start of the app there is an animation. My developer has told me I have to give him the animation as a quicktime movie and also the first frame of the quicktime movie as a png. I have done this but when he sends me the test version of the app, you see the png and then it flicks to a black screen for maybe half a second and then the animation begins. He has told me it is not possible to start an app with the quicktime movie playing from the very beginning and that there has to be a static image (the png) before the movie can play.

I just want the app to load up and play the animation straight away without any pause and black screen, is this possible?

I was thinking that if I gave him an entire png sequence of each frame of the animation (instead of a quicktime movie) that this would overcome the problem of the pause (black screen) before the quicktime movie starts after the intial png frame. I hope this makes sense!

There is also audio with the animation that need to be exactly in sync with what you see when the animation is played.

Any advice would be appreciated as what he is telling me just doesn't seem right.

Thanks,

BankC!
 

jnoxx

macrumors 65816
Dec 29, 2010
1,343
0
Aartselaar // Antwerp // Belgium
Hm, the thing is like this.
When an iPhone application starts up, it will use a default Image (static), while the application is loading up on the OS. So that's the image he is talking about. Then probably in his code, he will start the movie, but since he doesn't preloaded the movie, that's why you have the black screen for a sec..
So, there's either the choice of coding that bit better OR, give him the sequence of images, since iPhone has a method for that, to display alot of images after each other.. (and you can perfectly play a sound in sync with it with some basic code..).
He isn't lying to you, just need to fine tune a bit :)

Gz, Noxx
 

seepel

macrumors 6502
Dec 22, 2009
471
1
Depending on the length, loading all those images would eat up memory pretty quickly. Especially if you are making retina versions. Is the animation functional, or is it just like a splash screen? Ultimately I would rethink the design decision that leads to needing an animation to be shown right away. You may think the animation is great, and it probably looks cool and flashy, but ultimately users probably don't care. They just want to launch the app. So I would just drop the animation unless it is actually functional and needed.

As mentioned when the app launches iOS displays a default image (which you define). Then when the app has finished launching you gain control. If it were me when I got control I would display the same static image right away. Then start loading up the video. This might get rid of the flicker.
 

PhoneyDeveloper

macrumors 68040
Sep 2, 2008
3,114
93
I have an app that plays a launch video like you describe and it usually runs without seeing the black screen. There's a launch image in an image view that fills the screen. The video player is created and placed behind the launch image. The video starts to play and then after a delay of 1 second the launch image is removed.

The video player does start out black and then the video appears after a short delay.

I did have to mess around with it to get it to play smoothly without the black flash.
 

jnoxx

macrumors 65816
Dec 29, 2010
1,343
0
Aartselaar // Antwerp // Belgium
Really? Do you have some of this basic code handy and are willing to share?

The trick is, or use Cocos2D or Objective-C whatever you want.
You need to preload your sounds, since iOS sucks at sound management, when both are ready. you can just start playing both :)
You can also check the index of the sound vs the seconds of an Video to sync it to your likings. (so nothing like .sync = YES ;) )
Hope that sets you on the way Dejo.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.