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

Faulty picture display with some pictures if picture is bigger than terminal #2542

Closed
RockyBoulder opened this issue Apr 13, 2020 · 6 comments

Comments

@RockyBoulder
Copy link

RockyBoulder commented Apr 13, 2020

Hello,

I am new to kitty. Like it so far but have one problem: Some pictures are broken when I use icat.
Only pictures that don't fit in the terminal window are affected. If I resize the terminal so that they fit and do icat again they are displayed correctly. Not all pictures not fitting in the terminal are affected.
Pictures all do display all right with for expample image magicks display command.
wrong

./kitty --version
kitty 0.17.2 created by Kovid Goyal
Package: imagemagick
Version: 8:6.9.10.23+dfsg-2.1
Linux orihime 4.19.0-8-amd64 #1 SMP Debian 4.19.98-1 (2020-01-26) x86_64 GNU/Linux

@kovidgoyal
Copy link
Owner

I'm going to need a way to reproduce. Attach a picture that causes the issue.

@RockyBoulder
Copy link
Author

tuuube

Sure.

@kovidgoyal
Copy link
Owner

That mess is what imagemagick does when resizing the image. I have no
idea why, not an ImageMagick expert.

@kovidgoyal
Copy link
Owner

To reproduce:

convert kbad.png -resize 20x20! /tmp/q.rgba
ls -l /tmp/q/rgba

gives a size of 3200 instead of the expected 20x20x4=1600

@RockyBoulder
Copy link
Author

convert kbad.png -resize 20x20! -depth 8 /tmp/q.rgba
ls -l /tmp/q/rgba

gives a size of 1600

I tried out a little more myself:
The not working png files are all 16-bit sRGB. Reducing the depth makes them show up non faulty (but naturally with reduced depth).

@Luflosi
Copy link
Contributor

Luflosi commented Apr 13, 2020

You may not have noticed the fix above. 16-bit depth images should work in the latest master now.

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

3 participants