docs.rs failed to build proj-0.9.1
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Visit the last successful build:
proj-0.27.2
PROJ
Rust bindings for PROJ.4, v6.0.x
Examples
Convert from NAD 83 US Survey Feet to NAD 83 Meters Using EPSG Codes
extern crate proj;
use Proj;
extern crate geo_types;
use Point;
let from = "EPSG:2230";
let to = "EPSG:26946";
let nad_ft_to_m = new_known_crs.unwrap;
let result = proj
.convert
.unwrap;
assert_almost_eq;
assert_almost_eq;
Note that as of v5.0.0, PROJ.4 uses the pipeline
operator, which allows an arbitrary number of steps in a conversion. The example below works as follows:
- define the operation as a
pipeline
operation - define
step
1 as aninv
erse transform, yielding geodetic coordinates - define
step
2 as a forward transform to projected coordinates, yielding metres.
Convert from NAD 83 US Survey Feet to NAD 83 Meters Using the pipeline
Operator
extern crate proj;
use Proj;
extern crate geo_types;
use Point;
let nad_ft_to_m = new.unwrap;
// The Presidio, approximately
let result = nad_ft_to_m.convert.unwrap;
assert_eq!;
assert_eq!;
Inverse Projection from Stereo70 to Geodetic
extern crate proj;
use Proj;
extern crate geo_types;
use Point;
// Carry out an inverse projection from Pulkovo 1942(58) / Stereo70 (EPSG 3844) into geodetic lon and lat coordinates (in radians)
let stereo70 = new.unwrap;
let rp = stereo70.project.unwrap;
assert_eq!;
License
Licensed under either of
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.