android: Remove CameraWorker

The CameraWorker class purpose was to handle acquire fences for incoming
capture requests directed to libcamera.

Now that fences are handled by the core library, it is not required to
handle them in the HAL and the CameraWorker and CaptureRequest classes
can be dropped.

Update the core in CameraDevice class accordingly to queue Requests
directly to the libcamera::Camera and set the release_fence to the
value of the FrameBuffer::fence() for streams of type ::Direct.

While at it make CameraRequest::StreamBuffer::fence a UniqueFD to ease
the management of the fences file descriptor values.

Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
This commit is contained in:
Jacopo Mondi
2021-10-25 11:47:44 +02:00
parent a71834e1a0
commit 015fa7f718
8 changed files with 28 additions and 236 deletions
-3
View File
@@ -29,7 +29,6 @@
#include "camera_capabilities.h"
#include "camera_metadata.h"
#include "camera_stream.h"
#include "camera_worker.h"
#include "jpeg/encoder.h"
class Camera3RequestDescriptor;
@@ -105,8 +104,6 @@ private:
unsigned int id_;
camera3_device_t camera3Device_;
CameraWorker worker_;
libcamera::Mutex stateMutex_; /* Protects access to the camera state. */
State state_ LIBCAMERA_TSA_GUARDED_BY(stateMutex_);