jiayuasu opened a new pull request, #3217:
URL: https://github.com/apache/sedona/pull/3217

   Closes #3216.
   
   ## What changed
   
   - Transform the input geometry into the reference raster CRS before 
intersection validation.
   - Reuse the same transformed geometry for intersection, output extent 
calculation, and pixel rasterization.
   - Add a regression test comparing equivalent EPSG:4326 and EPSG:3857 
geometries for both reference-raster and geometry-derived output extents.
   
   ## Why
   
   `RS_AsRaster` previously used CRS-aligned operands only inside the 
intersection predicate. After that predicate succeeded, extent calculation and 
pixel burning still received the original geometry coordinates. With different 
known CRSs, this could produce an empty or misplaced raster, or fail while 
deriving the geometry-based output extent.
   
   The new path aligns the geometry once to the raster coordinate space and 
performs the intersection check directly in that space, so every subsequent 
rasterization step uses consistent coordinates.
   
   ## Compatibility
   
   This preserves the current CRS defaults: missing raster CRS metadata or 
geometry SRID is interpreted as WGS84. It does not relabel the reference 
raster, and custom non-EPSG raster CRSs remain supported.
   
   ## Validation
   
   - `mvn -pl common 
-Dtest=RasterConstructorsTest#testAsRasterTransformsGeometryToRasterCRS test`
   - `mvn -pl common test` — 1,229 tests passed
   - Repository commit hooks passed
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to