Module Gdal.Transform

exception Invalid_transform
type data_t = (float, Bigarray.float64_elt, Bigarray.c_layout) Bigarray.Array1.t

Input coordinates are provided as bigarrays.

type result_t = (int, Bigarray.int_elt, Bigarray.c_layout) Bigarray.Array1.t option

Success/failure of coordinate transformations.

type image
type reprojection
type 'a t

Transformation

val make_gen_img : ?⁠gcp:(bool * int) ‑> [ `data_set of Data_set.t * Data_set.t | `wkt of (string * Geo_transform.t) * (string * Geo_transform.t) | `data_set_wkt of Data_set.t * string | `wkt_data_set of string * Data_set.t ] ‑> image t

make_gen_img ?gcp kind creates a transformation defined by kind.

Options for kind:

val set_dst_geo_transform : image t ‑> Geo_transform.t ‑> unit

set_dst_geo_transform t gt sets the destination geo transform matrix in t.

val make_reprojection : src:string ‑> dst:string ‑> reprojection t

make_reprojection ~src ~dst creates a transformation definition between the WKT definition in src and the WKT definition in dst.

val transform : _ t ‑> bool ‑> data_t ‑> data_t ‑> data_t ‑> result_t

transform t invert xs ys zs converts the coordinates xs, ys, zs according to the transformation defined in t.