Reputation: 2056
I'm creating a tvOS app and struggle for 2 days now with the launch image. It used to correctly show, then since few days ago the launch image no longer show, instead a blur is showing.
I've checked the image and it doesn't use an alpha canal, though in an other tvOS I work on the launch image do uses an alpha canal and it shows (and is accepted when uploaded to the store). The target is correctly set to use the launchImage.
Out of idea, I ended up creating a new singleview tvOS project, and set the valid project's launch image as launchImage. And it stil doesn't work.
For an unknown reason, the launchImage was showing at some point, but I could not reproduce it. I've then tried to clean the build folder multiple times, changing the deployment target between 9 and 12, setting "not launch image" and switch back, deleting the app from simulator or device before building... none worked.
What is going on?
edit: SO, I've downloaded tvOS 11.4 simulator. First try on the 11.4 simulator and the launch Image does show on it. Switching back on tvOS 12 simulator after and the launch image now also shows. I killed the simulator and retried on both versions: no launch image.
I just don't understand what is going on.
edit 2: It looks like I'e found a pattern: The launch Image only shows if the app is launched on the same session during which the app was installed on the simulator, and is not the first time the app is launched since install. In all other cases, not launch image.
Examples:
run 1 (simulator launch and app installation)
setup: app not installed, simulator not running
result: launchImage is not shown
run 2 (app new launch):
setup: app already installed, simulator already running
result: launchImage is shown
run 3 (app new launch):
setup: app already installed, simulator already running
result: launchImage is shown
Now I close the simulator.
run 4 (app installation):
setup: app already installed, simulator not running
result: launchimage is not shown
run 5 (app new launch):
setup: app already installed, simulator running
result: launchimage is not shown
Now I delete the app
run 6 (app installation):
setup: app not installed, simulator running
result: launch image is not shown
It still never shows on a tvOS 12 device.
edit 3: Additionnal infos
Tested on Xcode 10.1.0. Here is the LaunchImage JSON file:
{
"images" : [
{
"orientation" : "landscape",
"idiom" : "tv",
"filename" : "[email protected]",
"extent" : "full-screen",
"minimum-system-version" : "11.0",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "tv",
"filename" : "13790f74.png",
"extent" : "full-screen",
"minimum-system-version" : "9.0",
"scale" : "1x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Upvotes: 4
Views: 1050
Reputation: 1
While I haven't been able to get the launch image to show at all when building directly from Xcode onto a device, it works fine if I Archive, export and install the IPA manually.
Upvotes: 0
Reputation: 13567
I have faced same issue. Please follow below step it will work you.
Please ensure you have select correct Launch Images Resource. Please below screenshots.
Here You have to give only one resource file either Launch Screen File or Launch Images Source.
If all above step is already upto-date. Then create new asset and add images. Please refer below screenshots.
Now change name of source as per step 1
Clean + Build and run your projects.
Upvotes: 5
Reputation: 7701
Well after trying and investigating a lot, I am afraid that there is not much you can do. I tried to reproduce your problem, and I wasn't able to get the Launch Image working at all.
I even tried to use the following example which must work, since it is code from Apple: https://github.com/insidegui/WWDC-tvOS/tree/master/WWDC/Assets.xcassets/LaunchImage.launchimage
I tried running the app on the TvOS simulator, but it just does not work.
I think the problem is in the TvOS firmware, and not in your app.
Upvotes: 0