summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKieran Bingham <kieran.bingham@ideasonboard.com>2020-07-01 16:47:58 +0100
committerKieran Bingham <kieran.bingham@ideasonboard.com>2020-08-06 15:44:01 +0100
commit8ad1b9ca2231dc28846bd9e7f05fccfe24a383d3 (patch)
tree54f4bc5d5c7fb742e3c5ec6bca13360cb1c9bf40
parent98986e0b578889500f2bbec87eea63113bf1c77f (diff)
android: camera_device: Report an error in notifyError()
If an error is generated, try to be verbose about it in the libcamera logs. Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
-rw-r--r--src/android/camera_device.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/android/camera_device.cpp b/src/android/camera_device.cpp
index 30aec1d8..0a0bcedb 100644
--- a/src/android/camera_device.cpp
+++ b/src/android/camera_device.cpp
@@ -1294,6 +1294,13 @@ void CameraDevice::notifyError(uint32_t frameNumber, camera3_stream_t *stream)
{
camera3_notify_msg_t notify = {};
+ /*
+ * \todo Report and identify the stream number or configuration to
+ * clarify the stream that failed.
+ */
+ LOG(HAL, Error) << "Error occurred on frame " << frameNumber << " ("
+ << toPixelFormat(stream->format).toString() << ")";
+
notify.type = CAMERA3_MSG_ERROR;
notify.message.error.error_stream = stream;
notify.message.error.frame_number = frameNumber;