projects
/
epclust.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
FIX: C code (double, float, ...) + wrapper (read/write data, get medoids)
[epclust.git]
/
code
/
stage1
/
src
/
Util
/
utils.h
diff --git
a/code/stage1/src/Util/utils.h
b/code/stage1/src/Util/utils.h
index
2ed68aa
..
3cb5cd1
100644
(file)
--- a/
code/stage1/src/Util/utils.h
+++ b/
code/stage1/src/Util/utils.h
@@
-13,13
+13,17
@@
void free_result(Result_t* result);
char readInt(FILE* stream, int64_t* integer);
char readInt(FILE* stream, int64_t* integer);
-char readReal(FILE* stream,
Real
* real);
+char readReal(FILE* stream,
float
* real);
// convert n-bytes binary integers to uint32_t
// convert n-bytes binary integers to uint32_t
-uint32_t bInt_to_uint(Byte* pInteger
, size_t bytesCount
);
+uint32_t bInt_to_uint(Byte* pInteger);
// serialize integers with a portable bytes order
// serialize integers with a portable bytes order
-void write_int(uint32_t integer, size_t bytesCount, Byte* buffer);
+void write_int(uint32_t integer, Byte* buffer);
+
+float bReal_to_float(Byte* pFloat);
+
+void write_real(float x, Byte* buffer);
// Expected size of a Work message in bytes:
uint32_t get_packedWork_length(uint32_t nbSeriesInChunk);
// Expected size of a Work message in bytes:
uint32_t get_packedWork_length(uint32_t nbSeriesInChunk);