mirror of
https://git.libcamera.org/libcamera/libcamera.git
synced 2025-07-13 23:39:44 +03:00
ipa: libipa: algorithm: queueRequest(): Pass frame context
IPA modules have access to incoming Request's controls list and need to store them in the frame context at queueRequest() time. Pass the frame context to the Algorithm::queueRequest() function. Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Signed-off-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Umang Jain <umang.jain@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
This commit is contained in:
parent
494662f082
commit
80cfe8f0f7
11 changed files with 14 additions and 1 deletions
|
@ -88,6 +88,7 @@ namespace ipa {
|
|||
* \brief Provide control values to the algorithm
|
||||
* \param[in] context The shared IPA context
|
||||
* \param[in] frame The frame number to apply the control values
|
||||
* \param[in] frameContext The current frame's context
|
||||
* \param[in] controls The list of user controls
|
||||
*
|
||||
* This function is called for each request queued to the camera. It provides
|
||||
|
|
|
@ -47,6 +47,7 @@ public:
|
|||
|
||||
virtual void queueRequest([[maybe_unused]] typename Module::Context &context,
|
||||
[[maybe_unused]] const uint32_t frame,
|
||||
[[maybe_unused]] typename Module::FrameContext &frameContext,
|
||||
[[maybe_unused]] const ControlList &controls)
|
||||
{
|
||||
}
|
||||
|
|
|
@ -128,6 +128,7 @@ void Awb::prepare(IPAContext &context,
|
|||
*/
|
||||
void Awb::queueRequest(IPAContext &context,
|
||||
[[maybe_unused]] const uint32_t frame,
|
||||
[[maybe_unused]] IPAFrameContext &frameContext,
|
||||
const ControlList &controls)
|
||||
{
|
||||
auto &awb = context.frameContext.awb;
|
||||
|
|
|
@ -24,6 +24,7 @@ public:
|
|||
IPAFrameContext &frameContext,
|
||||
rkisp1_params_cfg *params) override;
|
||||
void queueRequest(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
const ControlList &controls) override;
|
||||
void process(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameCtx,
|
||||
|
|
|
@ -38,6 +38,7 @@ LOG_DEFINE_CATEGORY(RkISP1CProc)
|
|||
*/
|
||||
void ColorProcessing::queueRequest(IPAContext &context,
|
||||
[[maybe_unused]] const uint32_t frame,
|
||||
[[maybe_unused]] IPAFrameContext &frameContext,
|
||||
const ControlList &controls)
|
||||
{
|
||||
auto &cproc = context.frameContext.cproc;
|
||||
|
|
|
@ -22,6 +22,7 @@ public:
|
|||
~ColorProcessing() = default;
|
||||
|
||||
void queueRequest(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
const ControlList &controls) override;
|
||||
void prepare(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
|
|
|
@ -176,6 +176,7 @@ int Dpf::init([[maybe_unused]] IPAContext &context,
|
|||
*/
|
||||
void Dpf::queueRequest(IPAContext &context,
|
||||
[[maybe_unused]] const uint32_t frame,
|
||||
[[maybe_unused]] IPAFrameContext &frameContext,
|
||||
const ControlList &controls)
|
||||
{
|
||||
auto &dpf = context.frameContext.dpf;
|
||||
|
|
|
@ -23,6 +23,7 @@ public:
|
|||
|
||||
int init(IPAContext &context, const YamlObject &tuningData) override;
|
||||
void queueRequest(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
const ControlList &controls) override;
|
||||
void prepare(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
|
|
|
@ -44,6 +44,7 @@ static constexpr uint32_t kFiltModeDefault = 0x000004f2;
|
|||
*/
|
||||
void Filter::queueRequest(IPAContext &context,
|
||||
[[maybe_unused]] const uint32_t frame,
|
||||
[[maybe_unused]] IPAFrameContext &frameContext,
|
||||
const ControlList &controls)
|
||||
{
|
||||
auto &filter = context.frameContext.filter;
|
||||
|
|
|
@ -22,6 +22,7 @@ public:
|
|||
~Filter() = default;
|
||||
|
||||
void queueRequest(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
const ControlList &controls) override;
|
||||
void prepare(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
|
|
|
@ -291,8 +291,11 @@ void IPARkISP1::unmapBuffers(const std::vector<unsigned int> &ids)
|
|||
|
||||
void IPARkISP1::queueRequest(const uint32_t frame, const ControlList &controls)
|
||||
{
|
||||
/* \todo Obtain the frame context to pass to process from the FCQueue */
|
||||
IPAFrameContext frameContext;
|
||||
|
||||
for (auto const &algo : algorithms())
|
||||
algo->queueRequest(context_, frame, controls);
|
||||
algo->queueRequest(context_, frame, frameContext, controls);
|
||||
}
|
||||
|
||||
void IPARkISP1::fillParamsBuffer(const uint32_t frame, const uint32_t bufferId)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue