IFTTT / FastttCamera

Fasttt and easy camera framework for iOS with customizable filters
http://ifttt.github.io
MIT License
1.86k stars 189 forks source link

`AVCaptureSession` `startRunning` and `stopRunning` performed on Main queue #5

Open DimaVartanian opened 9 years ago

DimaVartanian commented 9 years ago

The Apple docs state:

(startRunning)The startRunning method is a blocking call which can take some time, therefore you should perform session setup on a serial queue so that the main queue isn't blocked (which keeps the UI responsive). See AVCam for iOS for an implementation example.

(stopRunning)This method is synchronous and blocks until the receiver has completely stopped running.

I think this project is great and can be improved even more by moving some of the session setup into a dedicated NSOperationQueue for better performance. Keep it up! :)

lauraskelton commented 9 years ago

Thanks! I'm working on switching all of the device communications over to a dedicated serial NSOperationQueue, with delegate methods called on the main queue to update the UI as necessary after changes to the device complete.