libcamera v0.2.0+3-c630fdf5-nvm
Supporting cameras in Linux since 2019
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
libcamera::SoftwareIsp Class Referenceabstract

Base class for the Software ISP. More...

#include <software_isp.h>

Inheritance diagram for libcamera::SoftwareIsp:
Inheritance graph
[legend]
Collaboration diagram for libcamera::SoftwareIsp:
Collaboration graph
[legend]

Public Member Functions

 SoftwareIsp (PipelineHandler *pipe, const ControlInfoMap &sensorControls)
 Constructor for the SoftwareIsp object.
 
virtual int loadConfiguration (const std::string &filename)=0
 Load a configuration from a file.
 
virtual bool isValid () const =0
 Gets if there is a valid debayer object.
 
virtual std::vector< PixelFormatformats (PixelFormat input)=0
 Get the supported output formats.
 
virtual SizeRange sizes (PixelFormat inputFormat, const Size &inputSize)=0
 Get the supported output sizes for the given input format and size.
 
virtual std::tuple< unsigned int, unsigned int > strideAndFrameSize (const PixelFormat &pixelFormat, const Size &size)=0
 Get the stride and the frame size.
 
virtual int configure (const StreamConfiguration &inputCfg, const std::vector< std::reference_wrapper< StreamConfiguration > > &outputCfgs, const ControlInfoMap &sensorControls)=0
 Configure the SwIspSimple object according to the passed in parameters.
 
virtual int exportBuffers (unsigned int output, unsigned int count, std::vector< std::unique_ptr< FrameBuffer > > *buffers)=0
 Exports the buffers for use in processing.
 
virtual int start ()=0
 Starts the Software ISP worker.
 
virtual void stop ()=0
 Stops the Software ISP worker.
 
virtual int queueBuffers (FrameBuffer *input, const std::map< unsigned int, FrameBuffer * > &outputs)=0
 Queues buffers for processing.
 
virtual void processStats (const ControlList &sensorControls)=0
 Process the statistics gathered.
 
virtual Signal< const ControlList & > & getSignalSetSensorControls ()=0
 Get the signal for when the sensor controls are set.
 

Public Attributes

Signal< FrameBuffer * > inputBufferReady
 Signals that the input buffer is ready.
 
Signal< FrameBuffer * > outputBufferReady
 Signals that the output buffer is ready.
 
Signal< int > ispStatsReady
 Signals that the ISP stats are ready.
 

Detailed Description

Base class for the Software ISP.

Base class of the SoftwareIsp interface.

Constructor & Destructor Documentation

◆ SoftwareIsp()

libcamera::SoftwareIsp::SoftwareIsp ( PipelineHandler pipe,
const ControlInfoMap sensorControls 
)

Constructor for the SoftwareIsp object.

Parameters
[in]pipeThe pipeline handler in use.
[in]sensorControlsThe sensor controls.

Member Function Documentation

◆ configure()

virtual int libcamera::SoftwareIsp::configure ( const StreamConfiguration inputCfg,
const std::vector< std::reference_wrapper< StreamConfiguration > > &  outputCfgs,
const ControlInfoMap sensorControls 
)
pure virtual

Configure the SwIspSimple object according to the passed in parameters.

Parameters
[in]inputCfgThe input configuration.
[in]outputCfgsThe output configurations.
[in]sensorControlsThe sensor controls.
Returns
0 on success, a negative errno on failure.

Implemented in libcamera::SwIspSimple.

◆ exportBuffers()

virtual int libcamera::SoftwareIsp::exportBuffers ( unsigned int  output,
unsigned int  count,
std::vector< std::unique_ptr< FrameBuffer > > *  buffers 
)
pure virtual

Exports the buffers for use in processing.

Parameters
[in]outputThe number of outputs requested.
[in]countThe number of planes.
[out]buffersThe exported buffers.
Returns
count when successful, a negative return value if an error occurred.

Implemented in libcamera::SwIspSimple.

◆ formats()

virtual std::vector< PixelFormat > libcamera::SoftwareIsp::formats ( PixelFormat  input)
pure virtual

Get the supported output formats.

Parameters
[in]inputThe input format.
Returns
all supported output formats or an empty vector if there are none.

Implemented in libcamera::SwIspSimple.

◆ getSignalSetSensorControls()

virtual Signal< const ControlList & > & libcamera::SoftwareIsp::getSignalSetSensorControls ( )
pure virtual

Get the signal for when the sensor controls are set.

Returns
The control list of the sensor controls.

Implemented in libcamera::SwIspSimple.

◆ isValid()

virtual bool libcamera::SoftwareIsp::isValid ( ) const
pure virtual

Gets if there is a valid debayer object.

Returns
true if there is, false otherwise.

Implemented in libcamera::SwIspSimple.

◆ loadConfiguration()

virtual int libcamera::SoftwareIsp::loadConfiguration ( const std::string &  filename)
pure virtual

Load a configuration from a file.

Parameters
[in]filenameThe file to load from.
Returns
0 on success.

Implemented in libcamera::SwIspSimple.

◆ processStats()

virtual void libcamera::SoftwareIsp::processStats ( const ControlList sensorControls)
pure virtual

Process the statistics gathered.

Parameters
[in]sensorControlsThe sensor controls.

Implemented in libcamera::SwIspSimple.

◆ queueBuffers()

virtual int libcamera::SoftwareIsp::queueBuffers ( FrameBuffer input,
const std::map< unsigned int, FrameBuffer * > &  outputs 
)
pure virtual

Queues buffers for processing.

Parameters
[in]inputThe input framebuffer.
[in]outputsThe output framebuffers.
Returns
0 on success, a negative errno on failure

Implemented in libcamera::SwIspSimple.

◆ sizes()

virtual SizeRange libcamera::SoftwareIsp::sizes ( PixelFormat  inputFormat,
const Size inputSize 
)
pure virtual

Get the supported output sizes for the given input format and size.

Parameters
[in]inputFormatThe input format.
[in]inputSizeThe input size.
Returns
The valid size ranges or an empty range if there are none.

Implemented in libcamera::SwIspSimple.

◆ start()

virtual int libcamera::SoftwareIsp::start ( )
pure virtual

Starts the Software ISP worker.

Returns
0 on success, any other value indicates an error.

Implemented in libcamera::SwIspSimple.

◆ stop()

virtual void libcamera::SoftwareIsp::stop ( )
pure virtual

Stops the Software ISP worker.

Implemented in libcamera::SwIspSimple.

◆ strideAndFrameSize()

virtual std::tuple< unsigned int, unsigned int > libcamera::SoftwareIsp::strideAndFrameSize ( const PixelFormat pixelFormat,
const Size size 
)
pure virtual

Get the stride and the frame size.

Parameters
[in]pixelFormatThe output format.
[in]sizeThe output size.
Returns
a tuple of the stride and the frame size, or a tuple with 0,0 if there is no valid output config.

Implemented in libcamera::SwIspSimple.

Member Data Documentation

◆ ispStatsReady

Signal<int> libcamera::SoftwareIsp::ispStatsReady

Signals that the ISP stats are ready.

The int parameter isn't actually used.


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