summaryrefslogtreecommitdiff
path: root/src/qcam/main_window.h
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-03-23 02:34:36 +0200
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-03-24 10:34:04 +0200
commit615f7438ad6bf49bd213e7ae4f9f3fe334edeb67 (patch)
treea99021c5221bc0d627f89c89b27530ae652eeedf /src/qcam/main_window.h
parentb73192036db19f09057c64f350b53093ee9e7797 (diff)
qcam: viewfinder: Make the viewfinder hold a reference to a buffer
The viewfinder is currently expected to render frames to the screen synchronously in the display() function, or at least to copy data so that the buffer can be queued in a new request when the function returns. This prevents optimisations when the capture format is identical to the display format. Make the viewfinder take ownership of the buffer, and notify of its release through a signal. The release is currently still synchronous, this will be addressed in a subsequent patch. Rename the ViewFinder::display() function to render() to better describe its purpose, as it's meant to start the rendering and not display the frame synchronously. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Diffstat (limited to 'src/qcam/main_window.h')
-rw-r--r--src/qcam/main_window.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/qcam/main_window.h b/src/qcam/main_window.h
index 33522115..5d6251c8 100644
--- a/src/qcam/main_window.h
+++ b/src/qcam/main_window.h
@@ -55,6 +55,8 @@ private Q_SLOTS:
void saveImageAs();
+ void queueRequest(FrameBuffer *buffer);
+
private:
int createToolbars();
@@ -66,8 +68,6 @@ private:
void requestComplete(Request *request);
void processCapture();
- void display(FrameBuffer *buffer);
- void queueRequest(FrameBuffer *buffer);
/* UI elements */
QToolBar *toolbar_;