1.设置Launch Screen Image
![](https://img.haomeiwen.com/i2150869/cdaa2b9dfbcc6350.png)
2.检查Build Setting
![](https://img.haomeiwen.com/i2150869/58786df1468cd538.png)
3.设置 launchscreen.storyboard,在view上添加一个UIImageView,设置约束上下左右间距为0。添加启动图片。(first是我的启动图片的名字,因为图片first被删除了才变成蓝色了)
![](https://img.haomeiwen.com/i2150869/083b38df8a3b590b.png)
一定要勾选Use as Launch Screen
![](https://img.haomeiwen.com/i2150869/1da7de0d5470a607.png)
4.图片的Content Mode设置Aspect fill
![](https://img.haomeiwen.com/i2150869/fc6a366b412ea2ce.png)
5.启动图片依然放在Assets.xcassets中
![](https://img.haomeiwen.com/i2150869/814c70115b4293c6.png)
如果遇到其他黑屏问题可以参考https://www.jianshu.com/p/d2b0f20e2e96
网友评论