-
Hi, wanted to ask someone more knowledgeable about raylib (was looking for IRC:) I can't seem to get Because, trying to decompress either zlib or gzip (I know, gzip has headers on top, just tried) fails, probably trying to allocate too much memory (see picture). Was trying to decompress file created with Also, this error is basically un-catchable outside because there is no way to know that it actually failed somewhere. https://gist.github.com/wereii/6711de7e21667f0cf6d19e685524b560 |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi @wereii, raylib compression/decompression functions use internally the libraries I just tested it with PNGs zlib-streams (Deflate with pre-filtering on scanlines) and it worked ok with any PNG. Are you sure that those methods you used generate a pure Deflate (RFC 1951) stream? Maybe some header data is added automatically... |
Beta Was this translation helpful? Give feedback.
Hi @wereii,
raylib compression/decompression functions use internally the libraries
sdefl.h
andsinfl.h
that implement the standard Deflate (RFC 1951) algorithm, so, they should work with any stream using that same algorithm.I just tested it with PNGs zlib-streams (Deflate with pre-filtering on scanlines) and it worked ok with any PNG. Are you sure that those methods you used generate a pure Deflate (RFC 1951) stream? Maybe some header data is added automatically...