diff options
author | Jacopo Mondi <jacopo.mondi@ideasonboard.com> | 2024-10-28 10:32:00 +0100 |
---|---|---|
committer | Jacopo Mondi <jacopo.mondi@ideasonboard.com> | 2024-10-30 15:48:27 +0100 |
commit | 08d8bafa3de5f6001fae2516e7f1a15b9f303545 (patch) | |
tree | 081f97f58dc9186aba1243e65fd299b53b31041e | |
parent | 37cb4fedd4257185098fd8ba38701cff2e3ccdde (diff) |
libcamera: rkisp1: Create main buffer pool out of if(!isRaw)pfc/rkisp1-free-run-upstreaming
The "useDewarper_" class variable is set to true during configure
only if the configuration is !isRaw.
The main path buffer pool creation can thus be moved out of the
if (!isRaw) block at allocateBuffers() time.
Cosmetic change that will make it easier to create a buffer pool
for the main and self paths unconditionally in future.
Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
-rw-r--r-- | src/libcamera/pipeline/rkisp1/rkisp1.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/libcamera/pipeline/rkisp1/rkisp1.cpp b/src/libcamera/pipeline/rkisp1/rkisp1.cpp index dfee965b..209096e6 100644 --- a/src/libcamera/pipeline/rkisp1/rkisp1.cpp +++ b/src/libcamera/pipeline/rkisp1/rkisp1.cpp @@ -927,16 +927,16 @@ int PipelineHandlerRkISP1::allocateBuffers(Camera *camera) ret = stat_->allocateBuffers(maxCount, &statBuffers_); if (ret < 0) goto error; + } - /* If the dewarper is being used, allocate internal buffers for ISP. */ - if (useDewarper_) { - ret = mainPath_.exportBuffers(maxCount, &mainPathBuffers_); - if (ret < 0) - goto error; + /* If the dewarper is being used, allocate internal buffers for ISP. */ + if (useDewarper_) { + ret = mainPath_.exportBuffers(maxCount, &mainPathBuffers_); + if (ret < 0) + goto error; - for (std::unique_ptr<FrameBuffer> &buffer : mainPathBuffers_) - availableMainPathBuffers_.push(buffer.get()); - } + for (std::unique_ptr<FrameBuffer> &buffer : mainPathBuffers_) + availableMainPathBuffers_.push(buffer.get()); } for (std::unique_ptr<FrameBuffer> &buffer : paramBuffers_) { |