Dynamic splash screen for iPhone or iPad application
Question: I want to create a dynamically changeable launch image (Default.png) for both the iPad and the iPhone platforms in my application. The image should be downloaded from a web site or from the app’s sqLite database when the device is offline. How can I do that?
Answer: Forget it. iOS needs access to the iPhone and iPad static launch images before any of your app’s code executes. The launch image idea is nothing else than give the users the impression that iOS launches and quits applications pretty fast. The launch images – Default.png, Default-iPad.png, Default@2x.png or whatever you declared – are loaded automatically and animated to full screen as the “face” of your application while your code is loading. This process demands a minimum CPU cycle in order to present the illusion of state persistence before handing control over to your application. Your splash screen images like your app icons are bundled into your application.
You can build an app that simulates what you want to accomplish though. Insert your splash video, dynamic welcome image etc. into the very first view you present. You can even play a full screen video.
Notes:
1. The applicationDidFinishLaunching is too late to copy a default splash screen to Documents folder.
2. Yes, you are on the right track…
Icons and launch images for iPhone and iPad apps
“@2x” suffix for image files in iPhone projects
iPhone picture gallery
IBOutlet UIView *splashView; // Your splash view containing dynamic info, video, text, images
UIViewController *splashViewController;
// In the first view controller [self showSplash] is called
- (void) showSplash
{
self.splashViewController = [[UIViewController alloc] init];
splashViewController.view = self.splashView;
[self presentModalViewController: splashViewController animated:NO];
// Auto dismiss...
[self performSelector:@selector(hideSplash) withObject:nil afterDelay: SPLASH_HIDE_DELAY];
}
//hide splash screen
- (void) hideSplash{
[[self splashViewController] dismissModalViewControllerAnimated: YES];
}