[libcamera-devel,0/3] libcamera: pipeline handlers: Fail if roles are not supported
mbox series

Message ID 20200628161723.30625-1-jacopo@jmondi.org
Headers show
Series
  • libcamera: pipeline handlers: Fail if roles are not supported
Related show

Message

Jacopo Mondi June 28, 2020, 4:17 p.m. UTC
The Camera API prescribes that if the list of roles supplied to
generateConfiguration() is not supported, the function shall fail.

All pipeline handlers but the IPU3 do not comply with the specification,
silently adjusting the generated configuration to their capabilities.

Fix this by failing explicitly if the provided list of roles cannot be
satisfied.

This small series prepares to rework the IPU3 generate configuration function,
which will be aligned to the implementation found in other pipeline handlers
(more spcifically to the raspberry pi one, which has similar constraints on the
number of supported output streams)

Thanks
  j

Jacopo Mondi (3):
  libcamera: raspberrypi: Refuse invalid roles configuration
  libcamera: raspberrypi: Fail on unsupported stream role
  libcamera: pipelines: Fail if more than one role is requested

 src/libcamera/pipeline/raspberrypi/raspberrypi.cpp | 14 +++++++++++++-
 src/libcamera/pipeline/rkisp1/rkisp1.cpp           |  5 +++++
 src/libcamera/pipeline/simple/simple.cpp           |  5 +++++
 src/libcamera/pipeline/uvcvideo/uvcvideo.cpp       |  5 +++++
 src/libcamera/pipeline/vimc/vimc.cpp               |  5 +++++
 5 files changed, 33 insertions(+), 1 deletion(-)

--
2.27.0