Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Setting a background image/view to live camera view?

Is it possible to set a background for a particular view controller to show a live camera view? If so, could one lead me in the right direction to make this possible?

like image 465
jab Avatar asked Feb 10 '13 01:02

jab


People also ask

How do I change the background on my Microsoft camera?

Here's how to do it. Note: you have to be in an ongoing meeting to be able to access these options. To use a Microsoft Teams background in a meeting, click the three dots menu button and go to Show background effects. After you've clicked the option, a sidebar will show up on the right side of your screen.


1 Answers

Yes, definitely possible. You can embed live camera feed in UIView, which you can place anywhere you like.

Start by reading here: AVFoundation Reference - this is your framework

Particular class that you are looking for is AVCaptureVideoPreviewLayer

Which works in unison with AVCaptureSession

And this is an example project that covers everything you need: AVCam

like image 51
Andrei G. Avatar answered Sep 30 '22 17:09

Andrei G.