Skip to main content

compute_target_grid

Function compute_target_grid 

Source
pub fn compute_target_grid(
    source: &RasterTile,
    target_crs: &Crs,
    target_width: u32,
) -> Result<(GeoTransform, u32, u32), ProjError>
Expand description

Compute the world-space bounds in the target CRS that contain the reprojected source extent. Useful for deciding the size of the output RasterTile when the caller wants “warp everything into target CRS at a reasonable resolution.”

Returns (target_geo_transform, target_width, target_height).