Skip to main content

transform_point

Function transform_point 

Source
pub fn transform_point(
    point: &Point,
    source_crs: &str,
    target_crs: &str,
) -> Result<Point>
Expand description

Transforms a point between coordinate reference systems

§Arguments

  • point - Input point
  • source_crs - Source CRS (e.g., “EPSG:4326”)
  • target_crs - Target CRS (e.g., “EPSG:3857”)

§Returns

Transformed point

§Errors

Returns error if transformation fails