Skip to main content
100%

Raster Reprojection

✓ Published0🌍 Public
Mmbostock
Last edited Dec 6, 2019
Created on Dec 18, 2012

The Blue Marble earth image is reprojected from its equirectangular form into the Kavrayskiy7 projection, displayed on a dark canvas. The code loads the image, draws it, and then uses `projection.invert` from `d3.geo.kavrayskiy7` to map each output pixel back to source coordinates, sampling pixel data via Canvas `getImageData` and `putImageData`. This pixel-by-pixel transformation runs entirely in the browser with D3 v3 and `d3.geo.path`.

AI-generated description

The NASA Blue Marble is reprojected using d3.geo.kavrayskiy7’s invert function. Jason Davies has since done some amazing work on reprojecting raster tiles.

gpl-3.0 Licensed

Similar vizzes