[libcamera-devel] [RFC 0/4] prototype python bindings

Tomi Valkeinen tomi.valkeinen at iki.fi
Mon Sep 21 13:37:38 CEST 2020


Hi David,

On 21/09/2020 14:08, David Plowman wrote:
> Hi Tomi
> 
> Thank you for sharing this, I think it is very interesting work.
> 
> I was wondering, is there a discussion anywhere of what this Python API will look like for end users
> and how it would be used? You may know that Raspberry Pi has something called PiCamera which is a
> set of Python bindings for our existing (non-libcamera) camera stack. However, I think it's probably
> at a rather higher level that what is being envisaged for libcamera and therefore cannot be compared
> directly. But I'm definitely interested to understand more about it, and how (for example) we might
> build on top of it to provide something closer to what our users have been accustomed to.

No discussions.

I don't really have a use case target for this work. I don't even have any hardware that works with
libcamera, so I have just used vivid and vimc.

I wanted to do something with libcamera, and as I've implemented python bindings with pybind11 to
kms++ and rwmem, I thought adding basic python bindings would be an interesting project.

I had a super-quick look at PiCamera some time back (I was wondering if it would give me a hint
about the libcamera python API), but as you say, it seemed to be on a much higher level and I didn't
look further.

I agree that a higher level API would be very useful too, and I think that can be implemented with
pure python. Possibly that API might need to be (at least partly) libcamera pipeline specific,
although I'm just guessing here.

Or maybe PiCamera could use libcamera's python API as a backend? I have no clue how it is
architected, so may not be sensible.

 Tomi


More information about the libcamera-devel mailing list