summaryrefslogtreecommitdiff
path: root/include/libcamera/control_ids.h.in
AgeCommit message (Collapse)Author
2020-10-26libcamera: controls: Generate an array of valid valuesJacopo Mondi
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-26libcamera: Support draft controls and propertiesKieran Bingham
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-06-06libcamera: Replace C++ comments with C commentsLaurent Pinchart
The control_ids.h.in and property_ids.h.in headers use C++-style comments, when the coding style mandates C-style comments. Fix them. While at it, adjust three minor typos in comments. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
2019-10-13libcamera: control_ids: Generate map of all supported controlsLaurent Pinchart
In order to deserialise a ControlList, we will need to lookup ControlId instances based on their numerical ID. Generate a global map from the controls definitions to support such a lookup. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Tested-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
2019-10-05libcamera: controls: Auto-generate control_ids.h and control_ids.cppLaurent Pinchart
Bring back auto-generation of control ids. In this version, both the header and the source files are generated from a single YAML file that stores all control definitions. This allows centralising controls in a single file, while the previous version required keeping both declarations (in a header) and documentation (in a the source) in sync manually. Using YAML as a format to store control definitions is a trade-off between ease of use (there are many YAML parsers available) and simplicity (XML was considered, but would have lead to more complex processing). A new build time dependency is added on python3-yaml, which should be available as a package in all distributions and build environments. The YAML format is likely to change over time as we improve documentation of controls, the first version simply copies the information currently available. Future improvements should also include a YAML schema to validate the YAML source file. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>