Sample code for scanning barcodes with AVFoundation.