Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support libaec? #207

Open
milankl opened this issue May 1, 2024 · 1 comment
Open

Support libaec? #207

milankl opened this issue May 1, 2024 · 1 comment

Comments

@milankl
Copy link

milankl commented May 1, 2024

Just checking whether there's any interest here to support libaec as a codec. It's made primarily for 16/32bit unsigned integers with low entropy and in that sense somewhat specific (but a lot of big data applications fall into this category) but it doesn't look too hard to create a jll for it and write a CodecLibaec.jl wrapper for it.

@nhz2
Copy link
Member

nhz2 commented May 1, 2024

There's a jll for libaec https://juliahub.com/ui/Packages/General/libaec_jll already, and it seems to have a similar API to zlib.

IIUC when decoding the parameters need to be set the exact same way they were for encoding, so things like: transcode(AECDecompressor, compressed_buffer) won't work, instead you can do something like:

codec = AECDecompressor(;aec_parameters)
TranscodingStreams.initialize(codec)
try
    data = transcode(codec, compressed_buffer)
finally
    TranscodingStreams.finalize(codec)
end

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants