简体   繁体   中英

Custom camera in iOS like Snapchat

How does Snapchat make a custom UI for the camera, and how do they put a blur over it? I tried to accomplish the blur by putting a BlurView on top of the ImageView that I make into the camera with UIImagePicker, in

override func viewWillAppear(bool {
super.viewWillAppear(true)
'UIImagePicker logic'
}

But the imagepicker is not working until I remove the BlurView from the super view

CustomUI模糊

UIImagePicker will not work in this situation. Have to use AVFoundation and CALayer. This allows me to make a custom camera with a custom UI, and custom functionality. See this tutorial for basic introduction

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