Looks like there needs to be some code to clear the output every gif frame?
This issue doesn't appear in timg, maybe looking at what they do can give us the solution to fix it.
I think we've brought as much clarity to this issue as we can hope for. Thanks, everyone. If there are further issues compositing images or clearing an area on the kitty terminal, we can open a new one.
See the following gif file:
See how chafa renders it in kitty:
https://user-images.githubusercontent.com/17132214/185245999-b2b526f3-ecd7-429f-93f9-6f51eba66fb5.mp4
Looks like there needs to be some code to clear the output every gif frame? This issue doesn't appear in timg, maybe looking at what they do can give us the solution to fix it.
Just putting some helpful links here, for future ref: https://github.com/hzeller/timg/blob/262acd1a417bed4ffda324ca8dc0db764ed03a3a/src/kitty-canvas.cc https://github.com/hpjansson/chafa/blob/92e766ae1fe212c0512c25cb3ed54a4a7d2502fc/chafa/chafa-term-db.c https://sw.kovidgoyal.net/kitty/graphics-protocol/