summaryrefslogtreecommitdiff
path: root/src/libcamera/pipeline/raspberrypi/rpi_stream.cpp
diff options
context:
space:
mode:
authorKieran Bingham <kieran.bingham@ideasonboard.com>2020-10-15 15:10:55 +0100
committerKieran Bingham <kieran.bingham@ideasonboard.com>2020-10-21 16:15:41 +0100
commitd55f6a803727facbd8ae5df6882a4037086614fd (patch)
treec1ef9a7b084bbc21f057d79ff7c1ef82b7eea526 /src/libcamera/pipeline/raspberrypi/rpi_stream.cpp
parent4bd8d15f96173e1025ff03bfc5f05a94bf024270 (diff)
libcamera: pipeline: rpi_stream: Explicitly name requestBuffer
The FrameBuffer used to track any addition to the request in an under-run event was shadowed against the returned buffer, being placed back on the availableBuffers_ queue. Rename the shadowed variable to be more explicit that it is a separate Buffer. Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Diffstat (limited to 'src/libcamera/pipeline/raspberrypi/rpi_stream.cpp')
-rw-r--r--src/libcamera/pipeline/raspberrypi/rpi_stream.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libcamera/pipeline/raspberrypi/rpi_stream.cpp b/src/libcamera/pipeline/raspberrypi/rpi_stream.cpp
index 1a42cc17..3a5dadab 100644
--- a/src/libcamera/pipeline/raspberrypi/rpi_stream.cpp
+++ b/src/libcamera/pipeline/raspberrypi/rpi_stream.cpp
@@ -163,9 +163,9 @@ void Stream::returnBuffer(FrameBuffer *buffer)
* If so, do it now as availableBuffers_ will not be empty.
*/
while (!requestBuffers_.empty()) {
- FrameBuffer *buffer = requestBuffers_.front();
+ FrameBuffer *requestBuffer = requestBuffers_.front();
- if (!buffer) {
+ if (!requestBuffer) {
/*
* We want to queue an internal buffer, but none
* are available. Can't do anything, quit the loop.
@@ -177,12 +177,12 @@ void Stream::returnBuffer(FrameBuffer *buffer)
* We want to queue an internal buffer, and at least one
* is available.
*/
- buffer = availableBuffers_.front();
+ requestBuffer = availableBuffers_.front();
availableBuffers_.pop();
}
requestBuffers_.pop();
- queueToDevice(buffer);
+ queueToDevice(requestBuffer);
}
}