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

isQOI() doesn't give strong confirmation that decoding a sequence of bytes won't fail. #2

Open
magnus-ISU opened this issue Dec 23, 2021 · 1 comment
Labels
enhancement New feature or request

Comments

@magnus-ISU
Copy link

It really only checks that the header is correct and that the sequence of bytes isn't longer than the header claims.

Since decoding a QOI image only takes one pass, this is probably the correct implementation. However, the documentation makes no mention that isQOI doesn't guarantee that its input actually is a Quite Okay Image.

@ikskuh ikskuh added the enhancement New feature or request label Dec 23, 2021
@ikskuh
Copy link
Owner

ikskuh commented Dec 23, 2021

Ah, good point 👍
I'll improve the comment (and API) of the library soon. I wanna expose a pure stream encoder/decoder as well, where you have zero allocations involved

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

No branches or pull requests

2 participants