summaryrefslogtreecommitdiff
path: root/src/android/camera_device.h
diff options
context:
space:
mode:
authorKieran Bingham <kieran.bingham@ideasonboard.com>2020-06-26 09:58:49 +0100
committerKieran Bingham <kieran.bingham@ideasonboard.com>2020-07-06 23:58:42 +0100
commit43e3b8002bad0e4f7b74132975285cb10c6b8a60 (patch)
tree01ac6c8d494b34a4c5f50b9fffd284c8b5b6510a /src/android/camera_device.h
parentd35cf6e4e4972948e49e6e45f3f0caaeea760a0b (diff)
android: camera_device: Provide a toPixelFormat helper
Rather than converting pixelformats through the map, and then dereferencing the iterator later, create a helper to explicitly return a PixelFormat type. Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Diffstat (limited to 'src/android/camera_device.h')
-rw-r--r--src/android/camera_device.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/android/camera_device.h b/src/android/camera_device.h
index ed11410a..5bd6cf41 100644
--- a/src/android/camera_device.h
+++ b/src/android/camera_device.h
@@ -72,6 +72,7 @@ private:
std::tuple<uint32_t, uint32_t> calculateStaticMetadataSize();
void notifyShutter(uint32_t frameNumber, uint64_t timestamp);
void notifyError(uint32_t frameNumber, camera3_stream_t *stream);
+ libcamera::PixelFormat toPixelFormat(int format);
std::unique_ptr<CameraMetadata> getResultMetadata(int frame_number,
int64_t timestamp);