summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/py/libcamera/py_helpers.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/py/libcamera/py_helpers.cpp b/src/py/libcamera/py_helpers.cpp
index 45aecce9..f685e606 100644
--- a/src/py/libcamera/py_helpers.cpp
+++ b/src/py/libcamera/py_helpers.cpp
@@ -55,6 +55,7 @@ py::object controlValueToPy(const ControlValue &cv)
return py::cast(v);
}
case ControlTypeNone:
+ return py::none();
default:
throw std::runtime_error("Unsupported ControlValue type");
}
@@ -91,6 +92,7 @@ ControlValue pyToControlValue(const py::object &ob, ControlType type)
case ControlTypeSize:
return ControlValue(ob.cast<Size>());
case ControlTypeNone:
+ return ControlValue();
default:
throw std::runtime_error("Control type not implemented");
}