am ee38cd33: am 3b57d98a: Merge changes Iccd4d53d,Id449bc7a into lmp-dev
* commit 'ee38cd33a91f9c153ef2b12d383766a314dfd95a': camera2: Avoid setting null metering regions in LEGACY. camera2: Fix JPEG orientation set by LEGACY request.
This commit is contained in:
@@ -399,8 +399,9 @@ public class LegacyRequestMapper {
|
||||
|
||||
// jpeg.orientation
|
||||
{
|
||||
int orientation = characteristics.get(CameraCharacteristics.SENSOR_ORIENTATION);
|
||||
params.setRotation(ParamsUtils.getOrDefault(request, JPEG_ORIENTATION, orientation));
|
||||
Integer orientation = request.get(CaptureRequest.JPEG_ORIENTATION);
|
||||
params.setRotation(ParamsUtils.getOrDefault(request, JPEG_ORIENTATION,
|
||||
(orientation == null) ? 0 : orientation));
|
||||
}
|
||||
|
||||
// jpeg.quality
|
||||
@@ -496,6 +497,11 @@ public class LegacyRequestMapper {
|
||||
}
|
||||
}
|
||||
|
||||
if (meteringRectangleList.size() == 0) {
|
||||
Log.w(TAG, "Only received metering rectangles with weight 0.");
|
||||
return Arrays.asList(ParameterUtils.CAMERA_AREA_DEFAULT);
|
||||
}
|
||||
|
||||
// Ignore any regions beyond our maximum supported count
|
||||
int countMeteringAreas =
|
||||
Math.min(maxNumMeteringAreas, meteringRectangleList.size());
|
||||
|
||||
Reference in New Issue
Block a user