[libcamera-devel] [PATCH 0/1] Fake Pipeline Handler

Cheng-Hao Yang chenghaoyang at chromium.org
Wed Oct 12 11:42:32 CEST 2022


Thanks Kieran for your thoughts!

On Wed, Oct 12, 2022 at 5:10 PM Kieran Bingham <
kieran.bingham at ideasonboard.com> wrote:

> Quoting Harvey Yang via libcamera-devel (2022-10-12 08:59:24)
> > This is a POC PATCH of the fake pipeline handler, which should be used
> > for tests and validating Android adaptor can pass CTS limited mode.
> >
>
> Aha, this is interesting. I've wondered if we should have a virtual/fake
> camera too, perhaps with our own internal pattern generator.
>
>
This fake pipeline handler actually came from a design in ChromeOS
that tried to do some tests (CTS for example) without involving the real
cameras, like green frames or providing frames from a prepared video file.

We also wonder how the fake pipeline handler could help libcamera scale
and launch on more real devices.


> There's lots that could be mocked up, perhaps even as far down as a Fake
> CameraSensor, and an IPA to support testing of controls too (or perhaps
> without an IPA as it could all be internal to the pipeline handler, with
> no particular imagery).
>
>
Yeah there's a TODO to read a prepared configuration file, which defines
the
fake cameras and maybe a prepared video file as well. True that I was not
sure
why an IPA is needed. Maybe some controls can be applied on the output
frames
(from the video)?

There's a lot of commented code in there from the IPU3, so I suspect
> that was the source.
>
> There's https://git.libcamera.org/libcamera/vivid.git/log/ which might
> be a 'smaller' pipeline handler to consider as a fake pipeline handler
> starting point, or even UVC might be simpler comparable starting point.
>
>
Thanks! Will take a look and update on my next patch.


> --
> Kieran
>
>
>
> > Signed-off-by: Harvey Yang <chenghaoyang at chromium.org>
> >
> > Harvey Yang (1):
> >   Add fake pipeline handler
> >
> >  meson_options.txt                       |   2 +-
> >  src/android/camera_capabilities.cpp     |   1 +
> >  src/libcamera/pipeline/fake/fake.cpp    | 518 ++++++++++++++++++++++++
> >  src/libcamera/pipeline/fake/meson.build |   3 +
> >  src/libcamera/pipeline_handler.cpp      |   2 +-
> >  test/camera/camera_reconfigure.cpp      |   2 +-
> >  6 files changed, 525 insertions(+), 3 deletions(-)
> >  create mode 100644 src/libcamera/pipeline/fake/fake.cpp
> >  create mode 100644 src/libcamera/pipeline/fake/meson.build
> >
> > --
> > 2.38.0.rc1.362.ged0d419d3c-goog
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.libcamera.org/pipermail/libcamera-devel/attachments/20221012/337b5339/attachment.htm>


More information about the libcamera-devel mailing list