简体   繁体   中英

Black bar appears on top when running on iPhone 6 & iPad Pro Simulator

When I run my game on the simulator, specifically on iPhone 6 and iPad Pro, it shows black bar on top of the screen. I have looked the answer up online and have literally tried every single thing and have went through all the answers, but none have worked. My deployment is set to 7.0 and have tried running with setting just set to LaunchImage from asset folder and LaunchImage & LaunchScreen.xib combined. I also do have the right size pictures required in asset including iPhone Retina 4 , as well, and that doesn't fix the problem either. Is this just a glitch on the simulator or there is a way around this?

I got it working. For some reason my 2x images were short for the screen size, and had to extend them more. Even though height wise, my images had more length than the screen size.

Hope this helps people. I came across several people who had done everthing right, but still couldn't get it working. I believe it is because image isn't large enough to cover the whole screen

Stretched mode?

Are you providing Default screens in all sizes as suggested in:

Images clipped?

If not running in stretched mode, pick a View Mode best suited for your images, such as Aspect Fill and Scale to Fill , both of which will cover your UIImageView in LaunchScreen.storyboard .

模式和方面

Add Default-568h@2x.png Image with resolution 640x1136.

Make sure ' App Icons and Launch Images ' look like below image:

在此处输入图片说明

it worked in simulator with iOS 9.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM