Skip to content

Add type parameters for compile-time dispatch on CRS #30

@rafaqz

Description

@rafaqz

It would be useful to add at least coordinate order XY/YX and Spherical/Cartesian singletons to the CRS type.

This may let us wrap point with e.g. y/x order in the CRS, and dispatch to the correct distance/area methods. Having these in the type means we can use them for low level operations with no overheads.

These parameters could be nothing by default. At whatever point they to be used we could parse the CRS with Proj/ArchGDAL and fill in the parameters, or as the worse case / status quo - assume they are x/y, and just error for area/distance.

It may be that some other object could hold these parameters instead, but it seems like it should be attached to the CRS object to keep things simple.

It may also be useful for users to be able to specify the X/Y order manually because many other tools also do not follow the crs point order.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions