libcamera: libcamera::Debayer Class Reference

libcamera v0.5.1 Supporting cameras in Linux since 2019 |

Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
libcamera::Debayer Class Referenceabstract

Base debayering class. More...

Inheritance diagram for libcamera::Debayer:
[legend]
Collaboration diagram for libcamera::Debayer:
[legend]

## Public Member Functions
virtual int | configure (const StreamConfiguration &inputCfg, const std::vector< std::reference_wrapper< StreamConfiguration > > &outputCfgs, bool ccmEnabled)=0
| Configure the debayer object according to the passed in parameters.
virtual std::vector< PixelFormat > | formats (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,
|  | bool | ccmEnabled )
| pure virtual

Configure the debayer object according to the passed in parameters.

Parameters

  [in] | inputCfg | The input configuration
  [in] | outputCfgs | The output configurations
  [in] | ccmEnabled | Whether a color correction matrix is applied

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] | inputFormat | The 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] | frame | The frame number
  [in] | input | The input buffer
  [in] | output | The output buffer
  [in] | params | The 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] | inputFormat | The input format
  [in] | inputSize | The 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] | outputFormat | The output format
  [in] | size | The 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:

- src/libcamera/software_isp/debayer.h
- src/libcamera/software_isp/debayer.cpp