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

.png extension for "standard" quality images which were re-encoded to JPEG #6882

Open
2 tasks done
scy opened this issue May 20, 2024 · 3 comments
Open
2 tasks done
Labels

Comments

@scy
Copy link

scy commented May 20, 2024

Using a supported version?

  • I have searched searched open and closed issues for duplicates.
  • I am using Signal-Desktop as provided by the Signal team, not a 3rd-party package.

Overall summary

When sending a PNG image with "standard" (not "high") image quality, Signal will re-encode it to a JPEG instead. However, when hitting the "download" button on the image, the suggested file extension will be .png instead.

Steps to reproduce

  1. Send a PNG image with "standard" image quality.
  2. Click on that image in the chat.
  3. Click the "download" button (arrow pointing into a tray).
  4. A file picker dialog will open.

Expected result

The suggested file name should end in .jpeg or .jpg to accurately represent the file format. This is especially important for operating systems that decide based on the file name which application to use when opening the file.

Actual result

The file picker dialog is suggesting a name like signal-2024-05-20-140823_002.png, even though the file has been re-encoded into a JPEG.

Saving it and the running the Linux file tool confirms that it's indeed a JPEG:

$ file signal-2024-05-20-140823_002.png 
signal-2024-05-20-140823_002.png: JPEG image data, JFIF standard 1.01, aspect ratio, density 1x1, segment length 16, baseline, precision 8, 928x640, components 3

Screenshots

image

Signal version

7.5.1

Operating system

Debian 12 (bookworm) amd64

Version of Signal on your phone

7.7.1

Link to debug log

No response

@jamiebuilds-signal
Copy link
Member

Could you try downloading the image using the inline download button next to the message and see if what result you get?

Screenshot 2024-05-24 at 2 18 41 PM

Could you also try it with pngs of different sizes?

You can use this tool I created to test out images of different sizes:

@scy
Copy link
Author

scy commented May 24, 2024

@jamiebuilds-signal I can do that, if you think that the inline button makes any difference.

Do you think that using the "Note to Self" chat will work for that, or do I need to bother one of my contacts with this?

@scottnonnenberg-signal
Copy link
Contributor

@scy Yes, Note to Self will be useful to check. The version of the file that we save locally (and sync to your other devices) is the version that we would send to your recipients.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

4 participants