summaryrefslogtreecommitdiff
path: root/src/ipa
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2024-02-23 14:03:32 +0200
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2024-04-24 20:44:25 +0300
commiteb3209902f697571d3363cbe94e75198afeb238f (patch)
tree901cfe5679d5dc11345c47c4ef8c8ba1b671eb33 /src/ipa
parente04590a727a023d2cf570b43695a520ef70de6e6 (diff)
libcamera: camera_sensor: Sort factories by priority
In order to support a default implementation for camera sensors when no better implementation matches, libcamera needs to try "specialized" implementations first and pick the default last. Make this possible by adding a priority value for factories. Newly registered factories are inserted in the factories list sorted by descending priority, and the default factory uses a negative priority to be inserted as the last element. This mechanism may be a bit overkill in the sense that there is no expected use cases for priorities other than trying the default last, but the implementation is simple and easy to understand. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Stefan Klug <stefan.klug@ideasonboard.com> --- Changes since combined RFC: - Make the factory priority mandatory
Diffstat (limited to 'src/ipa')
0 files changed, 0 insertions, 0 deletions