Closed Martsva closed 1 month ago
D-Bus specification defines IEEE 754 double-precision floating point only among its basic types. sd-bus API (that sdbus-c++ is built on) follows that and expects this representation for serialization. Which is double
type in C/C++.
So with that I don't think sdbus-c++ can in any way help you with float
s.
We are sending a lot of floating point numbers which do not need the precision provided by the data type double. To reduce the size and overhead of the messages it would be nice to be able to serialize float values.
Is this as simple as making new overloads for
Message& operator<<(double item);
andMessage& operator>>(double& item);
?Thanks