public void setResolution(Size resolution) {
            this.resolution = resolution;
        }
Wrapper to manage the Camera. This is not thread-safe, and the methods must always be called
from the same thread.


Call order:

1. setCameraSettings()
2. open(), set desired preview size (any order)
3. configure(), setPreviewDisplay(holder) (any order)
4. startPreview()
5. requestPreviewFrame (repeat)
6. stopPreview()
7. close()
zxing-android-embedded/src/com/journeyapps/barcodescanner/camera/CameraManager.java