libcamera::IPAProxyFactory Class Referenceabstract

Registration of IPAProxy classes and creation of instances. More...

## Public Member Functions

| IPAProxyFactory (const char *name)
| Construct a IPAProxy factory. More...
virtual std::unique_ptr< IPAProxy > | create (IPAModule *ipam)=0
| Create an instance of the IPAProxy corresponding to the factory. More...
const std::string & | name () const
| Retrieve the factory name. More...

## Static Public Member Functions

static void | registerType (IPAProxyFactory *factory)
| Add a IPAProxy class to the registry. More...
static std::vector< IPAProxyFactory * > & | factories ()
| Retrieve the list of all IPAProxy factories. More...

## Detailed Description

Registration of IPAProxy classes and creation of instances.

To facilitate discovery and instantiation of IPAProxy classes, the IPAProxyFactory class maintains a registry of IPAProxy classes. Each IPAProxy subclass shall register itself using the REGISTER_IPA_PROXY() macro, which will create a corresponding instance of a IPAProxyFactory subclass and register it with the static list of factories.

## Constructor & Destructor Documentation

## IPAProxyFactory()

libcamera::IPAProxyFactory::IPAProxyFactory | ( | const char * | name | ) |

Construct a IPAProxy factory.

Parameters

  [in] | name | Name of the IPAProxy class

Creating an instance of the factory registers is with the global list of factories, accessible through the factories() function.

The factory name is used for debugging and IPAProxy matching purposes and shall be unique.

## Member Function Documentation

## create()

libcamera::IPAProxyFactory::create | ( | IPAModule * | ipam | ) |

pure virtual

Create an instance of the IPAProxy corresponding to the factory.

Parameters

  [in] | ipam | The IPA module

This virtual function is implemented by the REGISTER_IPA_PROXY() macro. It creates a IPAProxy instance that isolates an IPA interface designated by the IPA module ipam.

Returns
  A pointer to a newly constructed instance of the IPAProxy subclass corresponding to the factory

## factories()

std::vector< IPAProxyFactory * > & libcamera::IPAProxyFactory::factories | ( |  | ) |

static

Retrieve the list of all IPAProxy factories.

The static factories map is defined inside the function to ensure it gets initialized on first use, without any dependency on link order.

Returns
  The list of pipeline handler factories

## name()

libcamera::IPAProxyFactory::name | ( |  | ) | const

inline

Retrieve the factory name.

Returns
  The factory name

## registerType()

void libcamera::IPAProxyFactory::registerType | ( | IPAProxyFactory * | factory | ) |

static

Add a IPAProxy class to the registry.

Parameters

  [in] | factory | Factory to use to construct the IPAProxy

The caller is responsible to guarantee the uniqueness of the IPAProxy name.

The documentation for this class was generated from the following files:

- include/libcamera/internal/ipa_proxy.h
- src/libcamera/ipa_proxy.cpp