android: camera_device: Set the camera location to Front if External
Our android HAL implementation currently does not support external cameras, so if the camera location property is external, set it to front. This allows the following CTS test to pass: - android.hardware.camera2.cts.CameraManagerTest#testCameraManagerGetDeviceIdList Signed-off-by: Paul Elder <paul.elder@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
This commit is contained in:
@@ -405,7 +405,11 @@ int CameraDevice::initialize()
|
||||
facing_ = CAMERA_FACING_BACK;
|
||||
break;
|
||||
case properties::CameraLocationExternal:
|
||||
facing_ = CAMERA_FACING_EXTERNAL;
|
||||
/*
|
||||
* \todo Set this to EXTERNAL once we support
|
||||
* HARDWARE_LEVEL_EXTERNAL
|
||||
*/
|
||||
facing_ = CAMERA_FACING_FRONT;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user