Merge "Camera: Fix wrong wasImageCaptured flag" into sc-qpr1-dev am: 0f6c1c9d24
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16009383 Change-Id: I086f7400f1a7faba2eacb6e05c61a927ef768ce9
This commit is contained in:
committed by
Automerger Merge Worker
commit
fed7243e56
@@ -59,7 +59,7 @@ public class CaptureFailure {
|
||||
|
||||
private final CaptureRequest mRequest;
|
||||
private final int mReason;
|
||||
private final boolean mDropped;
|
||||
private final boolean mWasImageCaptured;
|
||||
private final int mSequenceId;
|
||||
private final long mFrameNumber;
|
||||
private final String mErrorPhysicalCameraId;
|
||||
@@ -68,10 +68,11 @@ public class CaptureFailure {
|
||||
* @hide
|
||||
*/
|
||||
public CaptureFailure(CaptureRequest request, int reason,
|
||||
boolean dropped, int sequenceId, long frameNumber, String errorPhysicalCameraId) {
|
||||
boolean wasImageCaptured, int sequenceId, long frameNumber,
|
||||
String errorPhysicalCameraId) {
|
||||
mRequest = request;
|
||||
mReason = reason;
|
||||
mDropped = dropped;
|
||||
mWasImageCaptured = wasImageCaptured;
|
||||
mSequenceId = sequenceId;
|
||||
mFrameNumber = frameNumber;
|
||||
mErrorPhysicalCameraId = errorPhysicalCameraId;
|
||||
@@ -141,7 +142,7 @@ public class CaptureFailure {
|
||||
* @return boolean True if the image was captured, false otherwise.
|
||||
*/
|
||||
public boolean wasImageCaptured() {
|
||||
return !mDropped;
|
||||
return mWasImageCaptured;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -1867,7 +1867,7 @@ public class CameraDeviceImpl extends CameraDevice
|
||||
final CaptureFailure failure = new CaptureFailure(
|
||||
request,
|
||||
reason,
|
||||
/*dropped*/ mayHaveBuffers,
|
||||
mayHaveBuffers,
|
||||
requestId,
|
||||
frameNumber,
|
||||
errorPhysicalCameraId);
|
||||
|
||||
Reference in New Issue
Block a user