ipa: rkisp1: cproc: Report metadata
Presently the colour processing component exposes controls for brightness, saturation, and contrast to the applications which are handled and processed accordingly on the ISP. The implementation lacks reporting the values that are set back to the application. Utilise the new Quantised types to provide the values that were applied to the hardware and report them in the completed request metadata. Reviewed-by: Isaac Scott <isaac.scott@ideasonboard.com> Reviewed-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
@@ -143,6 +143,20 @@ void ColorProcessing::prepare([[maybe_unused]] IPAContext &context,
|
||||
config->sat = frameContext.cproc.saturation.quantized();
|
||||
}
|
||||
|
||||
/**
|
||||
* \copydoc libcamera::ipa::Algorithm::process
|
||||
*/
|
||||
void ColorProcessing::process([[maybe_unused]] IPAContext &context,
|
||||
[[maybe_unused]] const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
[[maybe_unused]] const rkisp1_stat_buffer *stats,
|
||||
ControlList &metadata)
|
||||
{
|
||||
metadata.set(controls::Brightness, frameContext.cproc.brightness.value());
|
||||
metadata.set(controls::Contrast, frameContext.cproc.contrast.value());
|
||||
metadata.set(controls::Saturation, frameContext.cproc.saturation.value());
|
||||
}
|
||||
|
||||
REGISTER_IPA_ALGORITHM(ColorProcessing, "ColorProcessing")
|
||||
|
||||
} /* namespace ipa::rkisp1::algorithms */
|
||||
|
||||
@@ -30,6 +30,10 @@ public:
|
||||
void prepare(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
RkISP1Params *params) override;
|
||||
void process(IPAContext &context, const uint32_t frame,
|
||||
IPAFrameContext &frameContext,
|
||||
const rkisp1_stat_buffer *stats,
|
||||
ControlList &metadata) override;
|
||||
};
|
||||
|
||||
} /* namespace ipa::rkisp1::algorithms */
|
||||
|
||||
Reference in New Issue
Block a user