Commit graph

5 commits

Author SHA1 Message Date
Jacopo Mondi
634fd30b39 libcamera: controls: Fix rogue whitespace
Remove an extra whitespace in the declaration of a dictionary entry in
gen-controls.py script.

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>
2020-10-26 17:51:55 +01:00
Jacopo Mondi
ef7a07dd8a libcamera: controls: Generate an array of valid values
For each Control that supports enumerated values generate an array
of ControlValue which contains the full list of valid values.

At the expense of a slight increase in memory occupation this change
allows the construction of the ControlInfo associated with a Control
from the values list, defaulting the minimum and maximum values
reported by the ControlInfo.

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>
2020-10-26 17:51:55 +01:00
Jacopo Mondi
7a307fa647 libcamera: controls: Rename enumerate values
Rename the enumeration of supported values with the suffix "Enum"
in place of "Values" to prepare to re-use the suffix "Values"
for the vector of Control's value introduced by the next patch.

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>
2020-10-26 17:51:55 +01:00
Kieran Bingham
89916a486c libcamera: Support draft controls and properties
Extend the control and property framework to support exposing draft
controls and properties in a scoped namespace.

The controls/properties themselves will retain the same ordering in the
relevant enum/id maps - but the access to any draft control will require
explicitly referencing through its' draft:: namespace prefix.

Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
[Added missing hunk in control_ids.cpp.in and changed subject]
Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>
2020-10-26 17:51:54 +01:00
Kieran Bingham
c09626cd63 libcamera: Move Header generation utilities to utils
Move the GPL2 utilities which handle generation of controls, formats and
the top level libcamera header to the utils subtree.

Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
2020-09-24 10:55:49 +01:00
Renamed from src/libcamera/gen-controls.py (Browse further)