libcamera v0.4.0
Supporting cameras in Linux since 2019
 
Loading...
Searching...
No Matches
libcamera::Debayer Class Referenceabstract

Base debayering class. More...

Inheritance diagram for libcamera::Debayer:
Collaboration diagram for libcamera::Debayer:

Public Member Functions

virtual int configure (const StreamConfiguration &inputCfg, const std::vector< std::reference_wrapper< StreamConfiguration > > &outputCfgs)=0
 Configure the debayer object according to the passed in parameters.
 
virtual std::vector< PixelFormatformats (PixelFormat inputFormat)=0
 Get the supported output formats.
 
virtual std::tuple< unsigned int, unsigned int > strideAndFrameSize (const PixelFormat &outputFormat, const Size &size)=0
 Get the stride and the frame size.
 
virtual void process (uint32_t frame, FrameBuffer *input, FrameBuffer *output, DebayerParams params)=0
 Process the bayer data into the requested format.
 
virtual SizeRange sizes (PixelFormat inputFormat, const Size &inputSize)=0
 Get the supported output sizes for the given input format and size.
 

Public Attributes

Signal< FrameBuffer * > inputBufferReady
 Signals when the input buffer is ready.
 
Signal< FrameBuffer * > outputBufferReady
 Signals when the output buffer is ready.
 

Detailed Description

Base debayering class.

Base class that provides functions for setting up the debayering process.

Member Function Documentation

◆ configure()

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

Configure the debayer object according to the passed in parameters.

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

Implemented in libcamera::DebayerCpu.

◆ formats()

virtual std::vector< PixelFormat > libcamera::Debayer::formats ( PixelFormat inputFormat)
pure virtual

Get the supported output formats.

Parameters
[in]inputFormatThe input format
Returns
All supported output formats or an empty vector if there are none

Implemented in libcamera::DebayerCpu.

◆ process()

virtual void libcamera::Debayer::process ( uint32_t frame,
FrameBuffer * input,
FrameBuffer * output,
DebayerParams params )
pure virtual

Process the bayer data into the requested format.

Parameters
[in]frameThe frame number
[in]inputThe input buffer
[in]outputThe output buffer
[in]paramsThe parameters to be used in debayering
Note
DebayerParams is passed by value deliberately so that a copy is passed when this is run in another thread by invokeMethod().

Implemented in libcamera::DebayerCpu.

◆ sizes()

virtual SizeRange libcamera::Debayer::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::DebayerCpu.

◆ strideAndFrameSize()

virtual std::tuple< unsigned int, unsigned int > libcamera::Debayer::strideAndFrameSize ( const PixelFormat & outputFormat,
const Size & size )
pure virtual

Get the stride and the frame size.

Parameters
[in]outputFormatThe 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::DebayerCpu.


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