[libcamera-devel] [RFC PATCH 04/10] libcamera: ipa_interface: add init for shims

Laurent Pinchart laurent.pinchart at ideasonboard.com
Thu Jun 6 11:44:10 CEST 2019


Hi Paul,

Thank you for the patch.

On Wed, Jun 05, 2019 at 06:18:11PM -0400, Paul Elder wrote:
> Add a function to IPAInterface for shims to use to initialize the IPA
> module that it will wrap around.
> 
> Signed-off-by: Paul Elder <paul.elder at ideasonboard.com>
> ---
>  include/libcamera/ipa/ipa_interface.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/include/libcamera/ipa/ipa_interface.h b/include/libcamera/ipa/ipa_interface.h
> index 2c5eb1f..fd779d2 100644
> --- a/include/libcamera/ipa/ipa_interface.h
> +++ b/include/libcamera/ipa/ipa_interface.h
> @@ -15,6 +15,7 @@ public:
>  	virtual ~IPAInterface() {}
>  
>  	virtual int init() = 0;
> +	virtual int init(const char *path) { return 0; };

Could there be a way to have a single init function ? Thinking out loud,
how about passing the path to the factory function, so that the shim can
already load the module it wraps at create time ?

>  };
>  
>  } /* namespace libcamera */

-- 
Regards,

Laurent Pinchart


More information about the libcamera-devel mailing list