A Core Animation layer that can display video as it is being captured.
AVCaptureVideoPreviewLayer is a subclass of CALayer that you use to display video as it is being captured by an input device.
You use this preview layer in conjunction with an AV capture session, as illustrated in the following code fragment:
You use the videoGravity property to influence how content is viewed relative to the layer bounds. On some hardware configurations, you can manipulate the orientation of the layer using orientation and mirrored.