diff --git a/src/sl/saveload.cpp b/src/sl/saveload.cpp index 15d3fecdd5..be2e445f94 100644 --- a/src/sl/saveload.cpp +++ b/src/sl/saveload.cpp @@ -685,7 +685,7 @@ size_t SlGetBytesWritten() * x = ((x & 0x7F) << 8) + SlReadByte(); * @return Return the value of the index */ -static uint SlReadSimpleGamma() +uint SlReadSimpleGamma() { uint i = SlReadByte(); if (HasBit(i, 7)) { @@ -727,7 +727,7 @@ static uint SlReadSimpleGamma() * @param i Index being written */ -static void SlWriteSimpleGamma(size_t i) +void SlWriteSimpleGamma(size_t i) { if (i >= (1 << 7)) { if (i >= (1 << 14)) { @@ -752,7 +752,7 @@ static void SlWriteSimpleGamma(size_t i) } /** Return how many bytes used to encode a gamma value */ -static inline uint SlGetGammaLength(size_t i) +uint SlGetGammaLength(size_t i) { return 1 + (i >= (1 << 7)) + (i >= (1 << 14)) + (i >= (1 << 21)) + (i >= (1 << 28)); } diff --git a/src/sl/saveload.h b/src/sl/saveload.h index 2106aff551..2e55cb1477 100644 --- a/src/sl/saveload.h +++ b/src/sl/saveload.h @@ -984,6 +984,10 @@ void SlSetLength(size_t length); size_t SlCalcObjMemberLength(const void *object, const SaveLoad &sld); size_t SlCalcObjLength(const void *object, const SaveLoadTable &slt); +uint SlReadSimpleGamma(); +void SlWriteSimpleGamma(size_t i); +uint SlGetGammaLength(size_t i); + /** * Run proc, automatically prepending the written length * @param proc The callback procedure that is called