summaryrefslogtreecommitdiff
path: root/src/apps
diff options
context:
space:
mode:
authorPaul Elder <paul.elder@ideasonboard.com>2024-10-16 20:19:42 +0900
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2024-10-21 00:23:03 +0300
commitb777d8272af030f66b1a3636d6ffc9b41be58e24 (patch)
tree9828655e17f07672fd02542adc3e55f043ba81b7 /src/apps
parentaafa406edd39d04689bfcd4ff5239f918a0885ce (diff)
apps: cam: Print control vendor information when listing controls
Now that the vendor of the control can be queried, print it in --list-controls. Example output: $ cam -c 1 --list-controls Using camera platform/vimc.0 Sensor B as cam0 Control: libcamera::Brightness: [-1.000000..1.000000] Control: libcamera::Contrast: [0.000000..2.000000] Control: libcamera::Saturation: [0.000000..2.000000] Signed-off-by: Paul Elder <paul.elder@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'src/apps')
-rw-r--r--src/apps/cam/camera_session.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/apps/cam/camera_session.cpp b/src/apps/cam/camera_session.cpp
index edc49b87..6e9890cc 100644
--- a/src/apps/cam/camera_session.cpp
+++ b/src/apps/cam/camera_session.cpp
@@ -160,10 +160,13 @@ void CameraSession::listControls() const
{
for (const auto &[id, info] : camera_->controls()) {
if (info.values().empty()) {
- std::cout << "Control: " << id->name() << ": "
+ std::cout << "Control: "
+ << id->vendor() << "::" << id->name() << ": "
<< info.toString() << std::endl;
} else {
- std::cout << "Control: " << id->name() << ":" << std::endl;
+ std::cout << "Control: "
+ << id->vendor() << "::" << id->name() << ":"
+ << std::endl;
for (const auto &value : info.values()) {
int32_t val = value.get<int32_t>();
const auto &it = id->enumerators().find(val);