"landscape" splash screen is displayed as portrait in iOS

Hi,

How can I display a landscaped oriented splash screen using default.png and default@2x.png files?

I’m following the guide defined at https://docs.coronalabs.com/guide/distribution/buildSettings/index.html

but my splash screen is shown in a portrayed style despite default,png/default@2x.png contains a landscaped version of the splash.

build.settings

orientation =

  {

default = “landscapeRight”,

supported =

  {

“landscapeLeft”, “landscapeRight”

},

},

           --launch image files table

            UILaunchImages = {

                {  – iPhone 4 Portrait

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{320, 480}”

                },

                {  – iPhone 4 LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{320, 480}”

                },

                {  – iPhone 4 LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{320, 480}”

                },

                {  – iPhone 5 Portrait

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-568h”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{320, 568}”

                },

                {  – iPhone 5 LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-568h”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{568, 320}”

                },

                {  – iPhone 5 LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-568h”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{568, 320}”

                },

                {  – iPad Portrait

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-Portrait”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{768, 1024}”

                },

                {  – iPad LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-Landscape”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{1024, 768}”

                },

                {  – iPad LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-Landscape”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{1024, 768}”

                },

                {  – iPhone 6 Portrait

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-667h”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{375, 667}”

                },

                {  – iPhone 6 LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-667h”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{667, 375}”

                },

                {  – iPhone 6 LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-667h”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{667, 375}”

                },

                {  – iPhone 6 Plus Portrait

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-736h”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{414, 736}”

                },

                {  – iPhone 6 Plus LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-Landscape-736h”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{736, 414}”

                },

                {  – iPhone 6 Plus LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-Landscape-736h”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{736, 414}”

                },

            },              

Hi @oquesada,

Since this is a landscape-only setup, have you tried just omitting the “portrait” definitions in the table?

Also, did you properly nest that entire launch image table within “iphone” --> “plist” ? If it’s not there, iOS won’t recognize it.

Brent

Thanks for your responses. I removed default.png and default@2x.png and all other portrayed files from the definitions table. but now when i launch the game from a iPhone 4S, no Splash screen is shown.

My default.png is a landscaped version of my splash screen (in a 320x480 dimensions), but when it’s displayed in device, the image is stretched and displayed as portrayed.

Next image shows how default.png is defined:

https://dl.dropboxusercontent.com/u/23208869/CoronaIPhoneLandScapeIssue1.png

This other image shows how it’s shown in device:

https://dl.dropboxusercontent.com/u/23208869/CoronaIPhoneLandScapeIssue2.png

Please notice how the image is turn right 90 degress and streched to fit in 320x480.

My game app is landscaped-only setup. Any idea?

iPhones other than the iPhone 6 plus only support portrait launcher images. There was an earlier bug that required landscape versions that pointed to the portrait files to be in build.settings. I am unsure if Apple has fixed that or not.

If you want a landscape only app, make a portrait launch image, but rotate all the art work so it’s landscape and you have to turn your head to see it. Since your app is landscape only the sideways but portrait shaped image will display properly on the device since its only going to use a portrait version.

Rob

Hi Rob,

I’m following the approach of creating a portrait launch image but rotating the art-work.

default.png and default@2x.png loos like:

https://dl.dropboxusercontent.com/u/23208869/Default.png 

https://dl.dropboxusercontent.com/u/23208869/Default%402x.png

But when I deploy the app in device (iPhone 4s. iOS 9.2.1 the splash looks like this: 

https://dl.dropboxusercontent.com/u/23208869/0.PNG

It’s similar to the  default@2x.png image but 960x640 instead of 640x960. Shouldn’t it show the default@2x.png with our rotating the entire image?

Am I doing something wrong in my settings?

orientation =

  {

default = “landscapeRight”,

supported =

  {

“landscapeLeft”, “landscapeRight”

},

           --launch image files table

            UILaunchImages = {

                {  – iPhone 4 Portrait

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{320, 480}”

                },

                {  – iPhone 4 LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{320, 480}”

                },

                {  – iPhone 4 LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{320, 480}”

                },

                {  – iPhone 5 Portrait

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-568h”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{320, 568}”

                },

                {  – iPhone 5 LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-568h”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{568, 320}”

                },

                {  – iPhone 5 LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-568h”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{568, 320}”

                },

                {  – iPad Portrait

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-Portrait”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{768, 1024}”

                },

                {  – iPad LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-Landscape”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{1024, 768}”

                },

                {  – iPad LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-Landscape”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{1024, 768}”

                },

                {  – iPhone 6 Portrait

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-667h”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{375, 667}”

                },

                {  – iPhone 6 LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-667h”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{667, 375}”

                },

                {  – iPhone 6 LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-667h”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{667, 375}”

                },

                {  – iPhone 6 Plus Portrait

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-736h”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{414, 736}”

                },

                {  – iPhone 6 Plus LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-Landscape-736h”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{736, 414}”

                },

                {  – iPhone 6 Plus LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-Landscape-736h”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{736, 414}”

                },

            },              

Maybe try taking out the landscape options. Perhaps Apple fixed it.

Rob

Thanks. I removed the landscape options from the build-settings and it worked.

Hi @oquesada,

Since this is a landscape-only setup, have you tried just omitting the “portrait” definitions in the table?

Also, did you properly nest that entire launch image table within “iphone” --> “plist” ? If it’s not there, iOS won’t recognize it.

Brent

Thanks for your responses. I removed default.png and default@2x.png and all other portrayed files from the definitions table. but now when i launch the game from a iPhone 4S, no Splash screen is shown.

My default.png is a landscaped version of my splash screen (in a 320x480 dimensions), but when it’s displayed in device, the image is stretched and displayed as portrayed.

Next image shows how default.png is defined:

https://dl.dropboxusercontent.com/u/23208869/CoronaIPhoneLandScapeIssue1.png

This other image shows how it’s shown in device:

https://dl.dropboxusercontent.com/u/23208869/CoronaIPhoneLandScapeIssue2.png

Please notice how the image is turn right 90 degress and streched to fit in 320x480.

My game app is landscaped-only setup. Any idea?

iPhones other than the iPhone 6 plus only support portrait launcher images. There was an earlier bug that required landscape versions that pointed to the portrait files to be in build.settings. I am unsure if Apple has fixed that or not.

If you want a landscape only app, make a portrait launch image, but rotate all the art work so it’s landscape and you have to turn your head to see it. Since your app is landscape only the sideways but portrait shaped image will display properly on the device since its only going to use a portrait version.

Rob

Hi Rob,

I’m following the approach of creating a portrait launch image but rotating the art-work.

default.png and default@2x.png loos like:

https://dl.dropboxusercontent.com/u/23208869/Default.png 

https://dl.dropboxusercontent.com/u/23208869/Default%402x.png

But when I deploy the app in device (iPhone 4s. iOS 9.2.1 the splash looks like this: 

https://dl.dropboxusercontent.com/u/23208869/0.PNG

It’s similar to the  default@2x.png image but 960x640 instead of 640x960. Shouldn’t it show the default@2x.png with our rotating the entire image?

Am I doing something wrong in my settings?

orientation =

  {

default = “landscapeRight”,

supported =

  {

“landscapeLeft”, “landscapeRight”

},

           --launch image files table

            UILaunchImages = {

                {  – iPhone 4 Portrait

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{320, 480}”

                },

                {  – iPhone 4 LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{320, 480}”

                },

                {  – iPhone 4 LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{320, 480}”

                },

                {  – iPhone 5 Portrait

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-568h”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{320, 568}”

                },

                {  – iPhone 5 LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-568h”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{568, 320}”

                },

                {  – iPhone 5 LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-568h”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{568, 320}”

                },

                {  – iPad Portrait

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-Portrait”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{768, 1024}”

                },

                {  – iPad LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-Landscape”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{1024, 768}”

                },

                {  – iPad LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “6.0”,

                    [“UILaunchImageName”] = “Default-Landscape”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{1024, 768}”

                },

                {  – iPhone 6 Portrait

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-667h”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{375, 667}”

                },

                {  – iPhone 6 LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-667h”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{667, 375}”

                },

                {  – iPhone 6 LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-667h”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{667, 375}”

                },

                {  – iPhone 6 Plus Portrait

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-736h”,

                    [“UILaunchImageOrientation”] = “Portrait”,

                    [“UILaunchImageSize”] = “{414, 736}”

                },

                {  – iPhone 6 Plus LandscapeLeft

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-Landscape-736h”,

                    [“UILaunchImageOrientation”] = “LandscapeLeft”,

                    [“UILaunchImageSize”] = “{736, 414}”

                },

                {  – iPhone 6 Plus LandscapeRight

                    [“UILaunchImageMinimumOSVersion”] = “8.0”,

                    [“UILaunchImageName”] = “Default-Landscape-736h”,

                    [“UILaunchImageOrientation”] = “LandscapeRight”,

                    [“UILaunchImageSize”] = “{736, 414}”

                },

            },              

Maybe try taking out the landscape options. Perhaps Apple fixed it.

Rob

Thanks. I removed the landscape options from the build-settings and it worked.