Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Black screen on launch with iOS 8 (Landscape apps)
Started by ingemar Sep 26 2014 09:15 PM

39 replies to this topic
[TOPIC CONTROLS]
Page 1 of 2 1 2
This topic has been archived. This means that you cannot reply to this topic.
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

Corona SDK 2014.2446

Xcode 6.0.1

OSX Mavericks 10.9.5

 

There's a bug (most likely in Xcode 6 / iOS 8) which prevents landscape only apps from displaying a launch image.

 

Sample project

Attached File  ios8launch.zip   129.71KB   24 downloads

 

Steps to reproduce:

1) Compile sample project above with iOS 8 SDK

2) Run on any device with iOS 8 installed

 

The above sample app (compiled with the iOS 8 SDK) works fine when run on devices with iOS 6 or iOS 7 as Launch images are displayed as expected. Only iOS 8 devices have the issue. The only exception I've seen is the iPhone 6 Plus, which displays the Launch Image (I don't have an iPhone 6 / 6 Plus but I've tested in the Xcode simulator).

 

I filed a bug report last week with Apple about this issue (Apple Radar bug number: 18351823)

 

Note:

The only way around this issue at the moment is to use Xcode's new feature for Launch Screen Files (UILaunchStoryboardName), however that's only possible to use for Enterprise users.

I'm using UILaunchStoryboardName in my apps now and all launch images are showing as expected on iOS 8 as well.



[TOPIC: post.html]
#2

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 24,151 posts
  • Corona Staff

Can you be a little more clear on the bug?  Are you saying you are not getting launch images on iOS 8?  Or does the app black screen after showing the launch image?

 

Rob



[TOPIC: post.html]
#3

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

I'm talking only about the Launch Image not showing when run on devices with iOS 8. (Landscape apps as defined in sample project).

Corona app content behaves correctly.



[TOPIC: post.html]
#4

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 24,151 posts
  • Corona Staff

Actually I think I have the answer.  Brent is going to hate me for making him update the guide again....  Try this:

            UILaunchImages = {
                {  --iPhone 4
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default",
                    ["UILaunchImageOrientation"] = "Portrait",
                    ["UILaunchImageSize"] = "{320, 480}"
                },
                {  --iPhone 4
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default",
                    ["UILaunchImageOrientation"] = "LandscapeLeft",
                    ["UILaunchImageSize"] = "{320, 480}"
                },
                {  --iPhone 4
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default",
                    ["UILaunchImageOrientation"] = "LandscapeRight",
                    ["UILaunchImageSize"] = "{320, 480}"
                },
                {  --iPhone 5
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-568h",
                    ["UILaunchImageOrientation"] = "Portrait",
                    ["UILaunchImageSize"] = "{320, 568}"
                },
                {  --iPhone 5
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-568h",
                    ["UILaunchImageOrientation"] = "LandscapeLeft",
                    ["UILaunchImageSize"] = "{320, 568}"
                },
                {  --iPhone 5
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-568h",
                    ["UILaunchImageOrientation"] = "LandscapeRight",
                    ["UILaunchImageSize"] = "{320, 568}"
                },
                {  --iPad landscape
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-Landscape",
                    ["UILaunchImageOrientation"] = "Landscape",
                    ["UILaunchImageSize"] = "{768, 1024}"
                },
                {  --iPhone 6
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-667h",
                    ["UILaunchImageOrientation"] = "Portrait",
                    ["UILaunchImageSize"] = "{375, 667}"
                },
                {  --iPhone 6
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-667h",
                    ["UILaunchImageOrientation"] = "LandscapeLeft",
                    ["UILaunchImageSize"] = "{375, 667}"
                },
                {  --iPhone 6
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-667h",
                    ["UILaunchImageOrientation"] = "LandscapeRight",
                    ["UILaunchImageSize"] = "{375, 667}"
                },
                { -- iPhone 6 Plus landscape left
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-Landscape-736h",
                    ["UILaunchImageOrientation"] = "LandscapeLeft",
                    ["UILaunchImageSize"] = "{414, 736}"
                },
                { -- iPhone 6 Plus landscape right
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-Landscape-736h",
                    ["UILaunchImageOrientation"] = "LandscapeRight",
                    ["UILaunchImageSize"] = "{414, 736}"
                }
            }

You have to include the options for LandscapeLeft and LandscapeRight for the phones.

 

Rob



[TOPIC: post.html]
#5

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

It's not only the phones, it's the same for the iPads as well. Looks like "landscapeLeft" and "landscapeRight" needs to be added for *every* device.

 

I updated the entries and it does seem to work (sort of). Now the launch screens show, but we have iPhone 5 weirdness. The correct launch image is chosen but it doesn't activate "tall mode".



[TOPIC: post.html]
#6

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

Sorry, I take that back. my config was missing the "Portrait" version of the settings for iPhone 5...

Now the launch images do seem to show correctly. I'll have to do further testing to confirm....

 

Wow... This iOS update really messed things up!



[TOPIC: post.html]
#7

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

I still regard this as an Apple bug though. It shouldn't be like this.

When using Asset Catalogs for Launch Images it's the same black launch issue for landscape apps, and there we can't force settings in Info.plist since the settings are generated by Xcode.

 

It's good though that you've found a work-around for static images.

Thanks.

 

...but I'm going to stick with UILaunchStoryboardName from now on. Only one file to rule them all.



[TOPIC: post.html]
#8

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 24,151 posts
  • Corona Staff

I can already see the grumbling on the blog post Tuesday when we talk about the bazillion launch images you have to provide. 

 

Rob



[TOPIC: post.html]
#9

sbullock

[GLOBAL: userInfoPane.html]
sbullock
  • Contributor

  • 143 posts
  • Corona SDK

Hi Rob;

So . . . . . is there going to be a good blog post Tuesday (Sept. 30th) on iPhone 6s and how to deal with them? I've been holding back on two significant app updates hoping for some clarification and guidance on these (and OS 8) issues. Haven't wanted to bug anyone as I know you have all had your hands full!

 

Steve



[TOPIC: post.html]
#10

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 24,151 posts
  • Corona Staff

It is our intention to run with an iOS8/New iPhone post on Tuesday.  However, there is this guy name Murphy who has a Law.... 

 

Rob



[TOPIC: post.html]
#11

rune7

[GLOBAL: userInfoPane.html]
rune7
  • Contributor

  • 317 posts
  • Corona SDK

If you have a landscape only app, do we need to provide portrait launch images or can we only have the landscape oriented entries?

I have only an iPad to check with and it doesn't seem to work with just the default for ipad landscape specified.



[TOPIC: post.html]
#12

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 24,151 posts
  • Corona Staff

It appears that you can have one image, but you need a landscape reference to it in your build.settings.

 

BTW: Murphy's Law kicked in, there will be a bit of a delay on the iPhone 6 related tutorial.

 

Rob



[TOPIC: post.html]
#13

Richard17

[GLOBAL: userInfoPane.html]
Richard17
  • Enthusiast

  • 89 posts
  • Corona SDK

Actually I think I have the answer.  Brent is going to hate me for making him update the guide again....  Try this:

            UILaunchImages = {
                {  --iPhone 4
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default",
                    ["UILaunchImageOrientation"] = "Portrait",
                    ["UILaunchImageSize"] = "{320, 480}"
                },
                {  --iPhone 4
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default",
                    ["UILaunchImageOrientation"] = "LandscapeLeft",
                    ["UILaunchImageSize"] = "{320, 480}"
                },
                {  --iPhone 4
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default",
                    ["UILaunchImageOrientation"] = "LandscapeRight",
                    ["UILaunchImageSize"] = "{320, 480}"
                },
                {  --iPhone 5
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-568h",
                    ["UILaunchImageOrientation"] = "Portrait",
                    ["UILaunchImageSize"] = "{320, 568}"
                },
                {  --iPhone 5
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-568h",
                    ["UILaunchImageOrientation"] = "LandscapeLeft",
                    ["UILaunchImageSize"] = "{320, 568}"
                },
                {  --iPhone 5
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-568h",
                    ["UILaunchImageOrientation"] = "LandscapeRight",
                    ["UILaunchImageSize"] = "{320, 568}"
                },
                {  --iPad landscape
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-Landscape",
                    ["UILaunchImageOrientation"] = "Landscape",
                    ["UILaunchImageSize"] = "{768, 1024}"
                },
                {  --iPhone 6
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-667h",
                    ["UILaunchImageOrientation"] = "Portrait",
                    ["UILaunchImageSize"] = "{375, 667}"
                },
                {  --iPhone 6
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-667h",
                    ["UILaunchImageOrientation"] = "LandscapeLeft",
                    ["UILaunchImageSize"] = "{375, 667}"
                },
                {  --iPhone 6
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-667h",
                    ["UILaunchImageOrientation"] = "LandscapeRight",
                    ["UILaunchImageSize"] = "{375, 667}"
                },
                { -- iPhone 6 Plus landscape left
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-Landscape-736h",
                    ["UILaunchImageOrientation"] = "LandscapeLeft",
                    ["UILaunchImageSize"] = "{414, 736}"
                },
                { -- iPhone 6 Plus landscape right
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-Landscape-736h",
                    ["UILaunchImageOrientation"] = "LandscapeRight",
                    ["UILaunchImageSize"] = "{414, 736}"
                }
            }

You have to include the options for LandscapeLeft and LandscapeRight for the phones.

 

Rob

 

 

This is still wrong Rob. To work on iPad correctly you need

 

{  --iPad portrait
                                                        ["UILaunchImageMinimumOSVersion"] = "7.0",
                                                        ["UILaunchImageName"] = "Default-Portrait",
                                                        ["UILaunchImageOrientation"] = "Portrait",
                                                        ["UILaunchImageSize"] = "{768, 1024}"
                                                    },
                                                    {  --iPad landscape
                                                        ["UILaunchImageMinimumOSVersion"] = "7.0",
                                                        ["UILaunchImageName"] = "Default-Landscape",
                                                        ["UILaunchImageOrientation"] = "LandscapeLeft",
                                                        ["UILaunchImageSize"] = "{768, 1024}"
                                                    },
                                                    {  --iPad landscape
                                                        ["UILaunchImageMinimumOSVersion"] = "7.0",
                                                        ["UILaunchImageName"] = "Default-Landscape",
                                                        ["UILaunchImageOrientation"] = "LandscapeRight",
                                                        ["UILaunchImageSize"] = "{768, 1024}"
                                                    },


[TOPIC: post.html]
#14

rlowenstein

[GLOBAL: userInfoPane.html]
rlowenstein
  • Observer

  • 15 posts
  • Corona SDK

I seem to have all of the proper launch images showing up on every iOS simulator (thanks to all of the above!!!). One thing I've noticed is that on my iPhone 6, when using the app switcher to look at recently used apps, my landscape launch image shows up squished horizontally instead of being rotated into portrait. Is anyone else having this issue?

 

Incidentally, this is NOT happening on an iPhone 5s running iOS 7....



[TOPIC: post.html]
#15

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

Regarding landscape-only apps:
 
Remember that the actual png should only be in portrait orientation for phone-devices (like the iPhone 5 image).
This goes for the iPhone 4, 5 and 6. For iPad and iPhone 6 Plus the png should be in landscape orientation.
 
My testing has shown the following 8 entries to be sufficient for landscape only apps ("Portrait" and "Landscape" definitions only).

UILaunchImages = {
                {  --iPhone 4
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default",
                    ["UILaunchImageOrientation"] = "Portrait",
                    ["UILaunchImageSize"] = "{320, 480}"
                },
                {  --iPhone 4
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default",
                    ["UILaunchImageOrientation"] = "Landscape",
                    ["UILaunchImageSize"] = "{320, 480}"
                },
                {  --iPhone 5
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-568h",
                    ["UILaunchImageOrientation"] = "Portrait",
                    ["UILaunchImageSize"] = "{320, 568}"
                },
                {  --iPhone 5
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-568h",
                    ["UILaunchImageOrientation"] = "Landscape",
                    ["UILaunchImageSize"] = "{320, 568}"
                },
                {  --iPad landscape
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-Landscape",
                    ["UILaunchImageOrientation"] = "Landscape",
                    ["UILaunchImageSize"] = "{768, 1024}"
                },
                {  --iPhone 6
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-667h",
                    ["UILaunchImageOrientation"] = "Portrait",
                    ["UILaunchImageSize"] = "{375, 667}"
                },
                {  --iPhone 6
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-667h",
                    ["UILaunchImageOrientation"] = "Landscape",
                    ["UILaunchImageSize"] = "{375, 667}"
                },
                { -- iPhone 6 Plus landscape
                    ["UILaunchImageMinimumOSVersion"] = "8.0",
                    ["UILaunchImageName"] = "Default-Landscape-736h",
                    ["UILaunchImageOrientation"] = "Landscape",
                    ["UILaunchImageSize"] = "{414, 736}"
                }
            }

The png filenames and dimensions for landscape apps are:

Default.png                          (320 x 480)
Default@2x.png                       (640 x 960)
Default-568h@2x.png                  (640 x 1136)
Default-667h@2x.png                  (750 x 1334)        
Default-Landscape-736h@3x.png        (2208 x 1242)
Default-Landscape.png                (1024 x 768)
Default-Landscape@2x.png             (2048 x 1536)


[TOPIC: post.html]
#16

rune7

[GLOBAL: userInfoPane.html]
rune7
  • Contributor

  • 317 posts
  • Corona SDK

But, if you're using the same image for both landscape and portrait for the iPhone, then when the user have the phone on landscape orientation before launching the game, the image will be squished. I assume that for each orientation you need a different version.



[TOPIC: post.html]
#17

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

@rune7

 

No, it will not be squished. If you test this on an iPhone 4, 5 or 6 with iOS 7 or 8 you'll see.

The only launch images that need to be in landscape is the iPad and iPhone 6 Plus images.

 

Remember when the iPhone 5 came out with "tall-mode"? We needed to have a Default-568h@2x.png to activate it.

For landscape apps we didn't rotate the image. The launch image was still created in 640 x 1136 portrait. 

 

(Note: All of my testing is done using Xcode 6.0.1)



[TOPIC: post.html]
#18

rune7

[GLOBAL: userInfoPane.html]
rune7
  • Contributor

  • 317 posts
  • Corona SDK

Well, I never tested on iphone5 and my only Default-568h version was always in landscape mode. I guess this was wrong all along.

My launch image is simply my brand name over a white background.

So, if the image orientation should be in portrait, shouldn't we need two different landscape images, one for right and one for left?

it really depends on how the user have his/her phone at the time they launch the game, or does the mechanism assume its always landscape-right to begin with?



[TOPIC: post.html]
#19

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

The phone will launch in the default orientation. For me I always have landscapeRight as default and create a launch image with any text rotated accordingly (something like this:)

Attached File  iphone5.png   5.35KB   0 downloads

 

This does however mean that if the user holds the device in landscapeLeft that the launch image will appear upside down until the corona app starts and rotates the screen into the landscapeLeft orientation.

 

iPads and the iPhone 6 Plus will handle this scenario correctly and display the launch image right-side-up regardless of how the user holds the device, but iPhone 4, 5 and 6 can't. They will display the launch image in the default orientation first.

 



[TOPIC: post.html]
#20

rune7

[GLOBAL: userInfoPane.html]
rune7
  • Contributor

  • 317 posts
  • Corona SDK

But the problem only exist on the 4,5 and 6. since the 6 plus needs the image on landscape orientation anyhow (as the ipad does), or do we need to provide both for the 6 plus?



[TOPIC: post.html]
#21

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

The iPhone 6 Plus is a "landscape aware" device and doesn't need both.

By landscape-aware, I mean that it supports the native UI (Homescreen etc) in landscape.



[TOPIC: post.html]
#22

rune7

[GLOBAL: userInfoPane.html]
rune7
  • Contributor

  • 317 posts
  • Corona SDK

BTW, I could only make tests on my iPad and there you need to provide two entries for right and left to make it behave correctly:

                {  --iPad landscape
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-Landscape",
                    ["UILaunchImageOrientation"] = "LandscapeRight",
                    ["UILaunchImageSize"] = "{768, 1024}"
                },
                {  --iPad landscape
                    ["UILaunchImageMinimumOSVersion"] = "7.0",
                    ["UILaunchImageName"] = "Default-Landscape",
                    ["UILaunchImageOrientation"] = "LandscapeLeft",
                    ["UILaunchImageSize"] = "{768, 1024}"
                },
If I only use the "Landscape" as UILaunchImageOrientation, it doesn't take the image and skips this step entirely.
I assume its the same for the 6 plus.
This is the orientation I always use on my landscape apps:
    orientation =
    {
        default = "landscapeRight",
         supported =
             {
                "landscapeRight", "landscapeLeft"
             },
 
    },
Though I don't know if it has any influence on what launch image the device takes.


[TOPIC: post.html]
#23

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

Strange my testing doesn't show this behavior.

 

What version of Xcode / Corona / iPad are you testing on?

 

I used:

 

Xcode 6.0.1

Corona SDK 2014.2451

iPad mini iOS 8.0.2



[TOPIC: post.html]
#24

rune7

[GLOBAL: userInfoPane.html]
rune7
  • Contributor

  • 317 posts
  • Corona SDK

I run a corona 2439 build on my iPad3, OS 8.0.



[TOPIC: post.html]
#25

ingemar

[GLOBAL: userInfoPane.html]
ingemar
  • Corona Geek

  • 2,733 posts
  • Enterprise

I dug out 2 iPad 3's (both were on iOS 7), I'm upgrading one to iOS 8 now, however the one on iOS 7 is displaying the launch screen just fine with the setup I tested (only "Landscape" in UILaunchImages).

 

I'll report back here once the other one has finished updating, however my iPad mini on iOS 8 shows the launch screen correctly so I expect the big iPad to do the same..




[topic_controls]
Page 1 of 2 1 2
 
[/topic_controls]