-
Notifications
You must be signed in to change notification settings - Fork 84
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
Improve some of the maps that have slightly better upstream versions #109
Improve some of the maps that have slightly better upstream versions #109
Conversation
a6db699
to
33faaa2
Compare
I've merged two of your PRs so far then rebased this one onto master and force-pushed it (so you may want to do a full checkout or reset rather than a pull). Great stuff, thanks heaps! Let me know when you're done with this one. I've had a look at it on my end and only spotted one thing: the new |
Thanks for looking at and merging the other PRs.
Thanks for spotting that! I'll fix the transparency asap and finish this off. |
33faaa2
to
ec9b8b6
Compare
I've replaced the Indian Ocean map with an older version that has a white background (to save myself playing around with transparencies). It's otherwise identical to the newest version, so I think there should be no issues. As a bonus, looking at older versions made me realise that there's an older, smaller version of the Pacific Ocean map (the addition of the transparency somehow increased the size sevenfold, when it should have increased it by several bytes, at most...), so I used that. I split the pull request into several commits, as it made it easier to check that I had correctly updated all the necessary files. |
Awesome, thanks for the separate commits and for listing the sources 👍 Would you mind just shrinking the Denmark Strait map down to 500px wide to match most of the other maps? It looks a bit huge in Anki. The Celtic Sea map is also quite big. Perhaps a height of 500px would do as well? |
Oh and any reason why you picked 407px-wide versions for some of the other maps and not 500px-wide? |
Yes, of course, I'll do that.
I picked a width of 407px, as that was the width of the previous JPG versions, but I can standardise it to 500px-wide. |
ec9b8b6
to
a0d2f8c
Compare
They are taken from upstream with minimal changes. In the case of the Indian and Pacific Oceans, take older versions, since the new Indian Ocean map has a transparent background, while the new Pacific Ocean map is several times larger (and also has a transparent background).
For Polynesia, the labels and circles were removed as they were barely readable and slightly confusing. The number of colours (using `convert -colors 255`) was reduced for the Azores, Ceuta and Melilla without any discernable drop in quality. Testing showed that reducing the number of colours for Polynesia would cause a drop in quality, presumably because its map isn't "flat" like the others. (Terminology-wise I think that it's not strictly speaking colour-depth, as the images are still 8-bit. I suspect that the significant drop in size is due to transitions at boundaries, where there would normally be a large range of different colours, but most of which aren't really necessary for the depiction of a smooth transition.) (I have no idea why using 255 colours results in a non-negligible gain compared to 256 colours — AFAIK `-colors n` *doesn't* mean `n + 1` colours.)
For the Gulf of Mexico, note that the original NOAA image was indeed a JPG.
a0d2f8c
to
fce454c
Compare
I think that I've fixed all the issues and rebased on top of master. Slightly experimentally I've reduced the number of colours used for some of the "flat" maps, to reduce file sizes (without this, the "scaled down" maps of the Celtic Sea and Denmark Strait would have been far larger than the original PNGs). |
Brilliant, thank you!! |
This probably should be split into smaller, atomic commits, but ideally the commits should also update sources.csv, which doesn't yet exist in master. I don't want to continue piling pulls on top of each other, so I'm just pushing this, in case you (or anybody else) has some comments.
The label-free version of the Pacific Ocean on Wikimedia is, for some reason huge (98 kB) and playing around with pngout and optipng doesn't help.
The new sources for the files (for my future reference, when updating
sources.csv
), haphazardly listed are: