create-dmg / create-dmg

A shell script to build fancy DMGs
MIT License
2.07k stars 295 forks source link

Background is smaller than expected #102

Closed Deuchnord closed 4 years ago

Deuchnord commented 4 years ago

I'm creating a DMG file to distribute my app, but the image is shrunk to a very small size.

This is the command I'm invoking:

create-dmg --volname "Kosmorro installer" \
           --background build/distrib/darwin/dmg-background.jpg \
           --icon Kosmorro.app 100 100 \
           --window-size 640 320 \
           --app-drop-link 500 100 \
           $(distmacdmg) \
           dist/dmg

The created DMG archive looks like the following:

Screenshot of the DMG file. The background is shrinked to a very small size in the top left corner.

The original dmg-background.jpg image dimensions are 1280 × 640. Everything else works as expected.

What am I missing?

aonez commented 4 years ago

Can you share the background or the DMG? I can only think of a retina issue, but your numbers feel ok...

Deuchnord commented 4 years ago

No problem, you can get them just here (links are valid 30 days):

aonez commented 4 years ago

~Using a TIFF with the two sizes fixes the issue for you? I don't have a retina screen to test.~

aonez commented 4 years ago

Forget that, the problem is the resolution of your image. It's 300 and it should be 72.

aonez commented 4 years ago

Anyway you can still create a TIFF containing both a 640x320 and a 1280x640 representations (both at 72 resolution) if you want it to show properly on retina and not retina displays.

dmg-background.zip

Deuchnord commented 4 years ago

It works like a charm! Thanks!

9mm commented 9 months ago

For anyone else looking how to make tiffs from pngs...

tiffutil -cathidpicheck background.png background@2x.png -out background.tiff

saved u some headache