kovidgoyal / kitty

Cross-platform, fast, feature-rich, GPU based terminal
https://sw.kovidgoyal.net/kitty/
GNU General Public License v3.0
24.16k stars 972 forks source link

Compressed and/or optimized animated GIF files are shown layer by layer (not as expected) #6001

Closed Andrew15-5 closed 1 year ago

Andrew15-5 commented 1 year ago

Describe the bug Animated GIF files have layers and sometime each layer only has part of an image, but when displaying the GIF all layers are combined and output is full and animated image. But kitty (using icat kitten) shows GIF one layer at a time, resulting in undesirable result image.

To Reproduce Steps to reproduce the behavior:

  1. kitty -c none sh -c 'cd /tmp && wget -O image.gif https://i.imgur.com/5fbvxOy.gif && kitty +kitten icat image.gif && read -r _'

Screenshots icat: icat

chafa: chafa

Both were recorded using OBS Studio (also cropped with it) in kitty terminal window.

Environment details

kitty 0.26.5 created by Kovid Goyal
Linux pop-os 6.0.12-76060006-generic #202212290932~1674139725~22.04~ca93ccf SMP PREEMPT_DYNAMIC Thu J x86_64
Pop!_OS 22.04 LTS pop-os /dev/tty

DISTRIB_ID=Pop
DISTRIB_RELEASE=22.04
DISTRIB_CODENAME=jammy
DISTRIB_DESCRIPTION="Pop!_OS 22.04 LTS"
Running under: X11
Frozen: True
Paths:
  kitty: /home/user/.local/kitty.app/bin/kitty
  base dir: /home/user/.local/kitty.app/lib/kitty
  extensions dir: /home/user/.local/kitty.app/lib/kitty-extensions
  system shell: /bin/zsh
Loaded config overrides:
  map ctrl+shift+;>d debug_config

Config options different from defaults:
Added shortcuts:
    ctrl+shift+; > d →  debug_config

Important environment variables seen by the kitty process:
    PATH                                /home/user/.local/share/go/bin:/home/user/.local/share/pnpm:/usr/local/texlive/2022/bin/x86_64-linux:/home/user/.local/bin:/home/user/.local/share/go/bin:/home/user/.local/share/pnpm:/usr/local/texlive/2022/bin/x86_64-linux:/home/user/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
    LANG                                en_US.UTF-8
    EDITOR                              nvim
    SHELL                               /bin/zsh
    GLFW_IM_MODULE                      ibus
    DISPLAY                             :0
    USER                                user
    XDG_SESSION_TYPE                    x11
    XDG_SESSION_CLASS                   user
    XDG_RUNTIME_DIR                     /run/user/1000
    XDG_MENU_PREFIX                     gnome-
    XDG_CURRENT_DESKTOP                 pop:GNOME
    XDG_SESSION_DESKTOP                 pop
    XDG_DATA_DIRS                       /usr/share/pop:/usr/share/gnome:/home/user/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share/:/usr/share/
    XDG_CONFIG_DIRS                     /etc/xdg/xdg-pop:/etc/xdg

Additional context Due to this issue, I downgraded to 0.26.5. And as I'm writing this, I checked image preview in latest 0.27.1 and also in 0.27.0 and surprisingly it works. But I have ImageMagick installed, so I don't see any changelog messages that fixes this problem. And I failed to edit ctpv config file to use a new kitten binary that doesn't have this bug (ctpv uses kitty +kitten icat internally).

kovidgoyal commented 1 year ago

Update kitty.