@TargetApi(Build.VERSION_CODES.ICE_CREAM_SANDWICH_MR1)
    public static void setMetering(Camera.Parameters parameters) {
        if (parameters.getMaxNumMeteringAreas() > 0) {
            Log.i(TAG, "Old metering areas: " + parameters.getMeteringAreas());
            List<Camera.Area> middleArea = buildMiddleArea(AREA_PER_1000);
            Log.i(TAG, "Setting metering area to : " + toString(middleArea));
            parameters.setMeteringAreas(middleArea);
        } else {
            Log.i(TAG, "Device does not support metering areas");
        }
    }
Utility methods for configuring the Android camera.

@author Sean Owen
zxing-android-embedded/src/com/journeyapps/barcodescanner/camera/CameraConfigurationUtils.java