FIX: project -G use angular unit#8727
Merged
joa-quim merged 1 commit intoGenericMappingTools:masterfrom May 14, 2025
Merged
Conversation
|
💖 Thanks for opening this pull request! 💖 Please make sure you read our Contributing Guide and abide by our Code of Conduct. A few things to keep in mind:
|
joa-quim
approved these changes
May 14, 2025
Member
joa-quim
left a comment
There was a problem hiding this comment.
Thanks for finding this and even more for providing a fix.
|
🎉🎉🎉 Congrats on merging your first pull request and welcome to the team! 🎉🎉🎉 We hope that this was a good experience for you. Let us know if there is any way that the contributing process could be improved. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi, GMT!
I found that
gmt project -G<dist>uses wrong interval when<dist>appending angular unitd|m|e. For example,$ gmt project -C125/33 -E146/46 -G1d -Q | head -n3 125 33 0 125.000007565 33.0000063736 0.001 125.00001513 33.0000127473 0.002looks like there's a strange 1e-3 scale. I checked
project.c, and I guess maybe we need to add anifstatement here, to check whether-Guse angular unit.gmt/src/project.c
Lines 847 to 848 in 640f1e6
So I imitate some lines for
-Z,gmt/src/project.c
Lines 783 to 793 in 640f1e6
I add an
ifstatement for-G,After recompiling, I test it with same command, the result seems fine.
$ gmt project -C125/33 -E146/46 -G1d -Q | head -n3 125 33 0 125.848042113 33.705854159 111.195051975 126.710079013 34.4058180505 222.39010395