Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

-Jepsg where epsg is an UTM with negative longitudes fails in classic but only for .ps in modern.

Aperta
#7,773 3 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
c

Direzione di ricerca

Riproduci i comandi moderni gmt coast con EPSG:32618 e il comando classico gmt pscoast -JU18/14c, confrontando .ps con altri formati di output. Inizia con gmtproj_utm() e la sua chiamata da gmt_geo_to_xy, quindi esamina come viene utilizzata la trasformazione UTM di GDAL; il lavoro è completato quando il caso di longitudine negativa nell’emisfero meridionale viene renderizzato in modo coerente invece di produrre una figura vuota o fuori pagina.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug

The modern case first.
This fails. No PS error but figure is blank

gmt coast  -R-81.8/-66.9/-1.0/15.0 -J32618 -Baf -BWSen -W0.5 -Da -ps lixo

but this, or any other format, works.

gmt coast  -R-81.8/-66.9/-1.0/15.0 -J32618 -Baf -BWSen -W0.5 -Da -eps lixo

Now the classic mode case. Since here we only have output in .ps it always fails. But using the -J GMT syntax, works.
That is, this works. (epsg:32618 <==> JU18)

gmt pscoast  -R-81.8/-66.9/-1.0/15.0 -JU18/14c -Baf -BWSen -W0.5 -Da -P > lixo.ps

Several debugging hours later I found why. The gmtproj_utm() function (called by gmt_geo_to_xy) has

if (!GMT->current.proj.north_pole) (*y) += GMT_FALSE_NORTHING;	/* For S hemisphere, add 10^7 m */

but the corresponding GDAL function that is used for the UTM transformation doesn't have that offset and thus the computed ps units are negative and points fall off cliff.

So, one of the problems is identified though I don't know a cure since the transformation for the epsg case takes place inside the GDAL lib.

The second problem is: HTF the modern mode is insensitive to problem one when not using the .ps format????

Lingua principale
C
Stelle
984
Fork
413
Merge medio
21h 18m
PR unite (30g)
39

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di GenericMappingTools/gmt

Tutte le issue di GenericMappingTools/gmt

Issue simili

Altre issue su C

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.