Repository navigation
How to compress gamedata #31
Replies: 4 comments 5 replies
|
You could look at LZ4, it's usually really fast. |
|
@Flapperkewiet you should try using a bufferedstream over gzipstream, with 4k/8k buffer size. |
|
I did some more testing and here is the result: RawBinary Explanation:
Conclusion:
|
|
Results: RawBinary Did some more testing with the suggestion from @Therzok:
Conclusion:
|
Uh oh!
There was an error while loading. Please reload this page.
I have been looking a bit into compressing the data coming from
Export()functions.My testing fuctions and result are here: pastebin.
First I tried to manualy compress EntityData and was able to compress from 124 bytes to 72 bytes in 0.0005ms.
Then I used Gzip on the binarywriter passed into
Export(). It takes around 3-4 times longer than normal, but is able to compress to half the original size.For my main game, a medium-large world with multiple colonized planets, the normal export took 460ms for 40MB of data and with gzip compression it took 1680ms for 18.1MB of (compressed) data.
Does anyone have other ideas for compression?
All reactions