summaryrefslogtreecommitdiff
path: root/src/libcamera/control_serializer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/libcamera/control_serializer.cpp')
-rw-r--r--src/libcamera/control_serializer.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/libcamera/control_serializer.cpp b/src/libcamera/control_serializer.cpp
index 317b5a75..e1ba6d14 100644
--- a/src/libcamera/control_serializer.cpp
+++ b/src/libcamera/control_serializer.cpp
@@ -105,7 +105,7 @@ size_t ControlSerializer::binarySize(const ControlValue &value)
size_t ControlSerializer::binarySize(const ControlInfo &info)
{
- return binarySize(info.min()) + binarySize(info.max());
+ return binarySize(info.min()) + binarySize(info.max()) + binarySize(info.def());
}
/**
@@ -158,6 +158,7 @@ void ControlSerializer::store(const ControlInfo &info, ByteStreamBuffer &buffer)
{
store(info.min(), buffer);
store(info.max(), buffer);
+ store(info.def(), buffer);
}
/**
@@ -346,8 +347,9 @@ ControlInfo ControlSerializer::loadControlInfo(ControlType type,
ControlValue min = loadControlValue(type, b);
ControlValue max = loadControlValue(type, b);
+ ControlValue def = loadControlValue(type, b);
- return ControlInfo(min, max);
+ return ControlInfo(min, max, def);
}
/**