-
-
Notifications
You must be signed in to change notification settings - Fork 851
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
APNG support #2511
APNG support #2511
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this, I really appreciate your efforts!
I've tried to offer guidance as to what need to change. Please let me know if anything doesn't make sense.
Thanks for your review! It is rigorous and easy for me to understand. I'm sorry for accidentally formatting some code that confused you (e.g. x++ to ++x). Now it's all reverted. |
@Poker-sang Sorry this is taking so long to merge. There's a bit of a backlog we need to shift first to ensure there are no functional conflicts. |
It's all right. Take your time please. |
@Poker-sang Thanks again for your patience. Following the merge of #2485 there's a few conflicts here. Would you be able to update your PR to include the updates from main? If not, I can have a try. |
I can have a try. But I'm sorry I can't handle it for I'm busy these days. If you're not in a hurry you can wait a few days for me. |
I'm having a go at merging main back into this PR now. |
If we convert GIF to APNG, WEBP or other animated image formats, the |
Yes, you would also lose any disposal or blend mode information |
Ok I see. Thanks for explaining. |
@Poker-sang I've added support for alpha blending and disposal. I think it's correct based on how we work with gif/webp but I could do with a second pair of eyes. We desperately need to add test images now to validate the implementation so if you could add that, it would be great! |
@JimBobSquarePants Thank you very much for your help! 😀 If you need some images to validate the implementation about alpha blending and disposal, I thought these images would help: |
@Poker-sang Can you give me collaboration access to your fork? There's an open issue with Git LFS which prevents me pushing images to your fork without those permissions. |
Sure. When I'm cloning this repo lately, |
I'm not sure what you mean by |
Ah yeah, there's a lot of LFS files. You should only be cloning the repo 1 time really though and using feature branches for your PRs. Every time someone with a fork clones the repo it actually uses up my LFS bandwidth and ends up costing me money if I go over my pre-purchased allowance. |
Oh I see. I'll pay attention to it. |
I’ve started adding the tests locally. |
APNG Specification says:
Seems like a simple and not very useful feature, do we need to implement it? Says adding an option in the |
I think that just means the first frame control is optional. The code I have locally handles that. |
I'm mostly happy with this now. All the test images I've thrown at it pass with flying colors. Will review again in the morning to be sure. |
I am very happy to hear that. I am so grateful that you have helped me so much!❤ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm happy with this now. Thanks @Poker-sang for a great addition to the library!
Prerequisites
Description
Implement APNG decoding and encoding based on PNG