Unsolved how to place float array inside a byte array?
-
Is it possible to place float array inside byte array
-
-
@jsulm i want to place float array inside byte array.
example:-
float floatArray1[5] = { 123.45f, 123.0f, 45.0f, 1.2f, 34.5f };
float floatArray2[5] = { 123.45f, 123.0f, 45.0f, 1.2f, 34.5f };i want to place inside byte array
-
@swansorter said in how to place float array inside a byte array?:
i want to place inside byte array
Then do so, what is the problem?
I gave you the link to a method you can use to convert one float to QByteArray. Simply call it for each entry of your array and append the result to your QByteArray.Depending on your requirements you can also use https://doc.qt.io/qt-5/qdatastream.html