Viz rasterization joins polygon rings: a spurious segment in ST_Pixelize and the outline renderer, and a gap in the filled polygon
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 77/100
Direzione di ricerca
Start by reading RasterizationUtils.FindPixelCoordinates, which the issue identifies as the source of both outline and fill behavior. Trace how it handles polygon coordinates, then add coverage for polygons with holes and empty polygons in the relevant tests. Done means each ring is outlined without joining segments, filled pixels cover the polygon interior while excluding holes, and empty polygons do not throw.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Expected behavior
For a polygon with holes, ST_Pixelize (and the RDD visualization operators) should return the outline pixels of each ring, and the filled rasterization used by choropleth maps should cover the interior minus the holes.
Actual behavior
Both polygon paths in RasterizationUtils.FindPixelCoordinates read Polygon.getCoordinates(), which concatenates the exterior ring and the holes.
- Outline: tracing the concatenated coordinates also draws a segment from the end of the exterior ring to the start of the first hole (and between consecutive holes), and repeats the exterior's first pixel.
- Fill: the concatenated coordinates are turned into a single ring, which crosses itself along that same segment, so the interior pixels on it are dropped and the hole is only left out by accident. An empty polygon fails with an
IndexOutOfBoundsException.
Steps to reproduce
SELECT ST_Pixelize(
ST_GeomFromWKT('POLYGON ((0.5 0.5, 9.5 0.5, 9.5 9.5, 0.5 9.5, 0.5 0.5), (4.5 4.5, 6.5 4.5, 6.5 6.5, 4.5 6.5, 4.5 4.5))'),
10, 10, ST_PolygonFromEnvelope(0, 0, 10, 10))
This returns 48 pixels: the 36 of the exterior ring and the 8 of the hole, plus (1,1), (2,2), (3,3) on a segment joining them and a second (0,0). The filled path on the same polygon returns 52 pixels instead of 55, missing (1,1), (2,2) and (3,3).
Found while working on #1272. I'm a student contributing as part of a university software engineering course, and I'd like to fix this by handling each ring separately: tracing each ring for the outline, and building the pixel-space polygon with its holes for the fill.
- Lingua principale
- Java
- Stelle
- 2.4k
- Fork
- 793
- Merge medio
- 1g 10h
- PR unite (30g)
- 53
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di apache/sedona
-
GeoPackage reader throws NullPointerException on a NULL geometryForse già presa @Mayukh-D l’ha presa 1 giorno fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 25/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 45/100
apache/sedona#3429 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Clearing NoData on one raster band changes another band's MapAlgebra resultsForse di nuovo libera Una pull request per questa issue è stata chiusa senza essere unita. Apertabug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 55/100
apache/sedona#3324 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
RS_ZonalStats line rois: all_touched is ignored, and the default rule burns every traversed cellForse già presa @sudhamsh-git l’ha presa 5 giorni fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 55/100
apache/sedona#3322 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di apache/sedona
Issue simili
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
-
[Bug]: REST API URL starting with "http" but no scheme (e.g. httpbin.org/get) is not given an http:// prefixForse già presa @ItsDeadlyProgrammer l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
appsmithorg/appsmith#42471 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
-
code-maintenance
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
-
bug priority: medium Review effort [1-5]: 3 status: needs-triage type: bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
carlos-emr/carlos#5258 ·
I maintainer di solito rispondono entro 1 giorno