Crate gdal

source ·
Expand description

GDAL bindings for Rust.

A high-level API to access the GDAL library, for vector and raster data.

Use

use std::path::Path;
use gdal::vector::Dataset;

let mut dataset = Dataset::open(Path::new("fixtures/roads.geojson")).unwrap();
let layer = dataset.layer(0).unwrap();
for feature in layer.features() {
    let highway_field = feature.field("highway").unwrap();
    let geometry = feature.geometry();
    println!("{} {}", highway_field.into_string().unwrap(), geometry.wkt().unwrap());
}

Re-exports

pub use version::version_info;

Modules

GDAL Configuration Functions
GDAL Raster Data
GDAL Vector Data