utils: gen-controls: Improve YAML notation for variable-size array controls

Array controls specify the array size through the YAML 'size' element,
which stores a list of values, one per dimension. Variable-size arrays
currently use an empty 'size' list, which prevents describing the number
of dimensions of the array.

Improve this by using the same notation for fixed-size and variable-size
array controls. Dimensions that are not fixed are described as a string
instead of an integer, such as [n], [n,3] or [w,h]. The strings have
currently no special meaning, this may change in the future.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Umang Jain <umang.jain@ideasonboard.com>
This commit is contained in:
Laurent Pinchart
2022-08-10 01:01:22 +03:00
parent 24f866f6a3
commit 22ab0b4193
3 changed files with 28 additions and 9 deletions
+1 -1
View File
@@ -525,7 +525,7 @@ controls:
the window where the focal distance for the objects shown in that part
of the image are closest to the camera.
size: []
size: [n]
- AfTrigger:
type: int32_t
+2 -2
View File
@@ -497,7 +497,7 @@ controls:
- PixelArrayOpticalBlackRectangles:
type: Rectangle
size: []
size: [n]
description: |
The pixel array region(s) which contain optical black pixels
considered valid for calibration purposes.
@@ -592,7 +592,7 @@ controls:
- PixelArrayActiveAreas:
type: Rectangle
size: []
size: [n]
description: |
The PixelArrayActiveAreas property defines the (possibly multiple and
overlapping) portions of the camera sensor readable pixel matrix