Main Content

readCRS

Read coordinate reference system (CRS) data from RoadRunner HD map using MATLAB

Since R2023a

    Description

    crs = readCRS(rrMap) reads the coordinate reference system data from the RoadRunner HD map rrMap.

    This function requires Mapping Toolbox™.

    example

    Examples

    collapse all

    Create a RoadRunner HD map, represented by a roadrunnerHDMap object. Specify an author and spatial bounds for the geometric data attributes of the map.

    rrMap = roadrunnerHDMap(Author="Map Author",GeographicBoundary=[-0.782 -3.13 0; 101.565 50 0]);

    Read the CRS data from the RoadRunner HD map file using the readCRS function and generate a projcrs object.

    crs = readCRS(rrMap);
    disp(crs)
      projcrs with properties:
    
                        Name: "WGS 84 / Transverse Mercator"
               GeographicCRS: [1×1 geocrs]
            ProjectionMethod: "Transverse Mercator"
                  LengthUnit: "meter"
        ProjectionParameters: [1×1 map.crs.ProjectionParameters]
    

    Input Arguments

    collapse all

    RoadRunner HD Map road data model, specified as a roadrunnerHDMap object. rrMap defines a simple data structure to represent road layouts using lanes, lane boundaries, lane markings, and junctions. This object provides functions that support reading, writing, and plotting HD map data.

    Output Arguments

    collapse all

    Coordinate reference system (CRS), returned as one of these objects:

    • geocrs — Returned by a file that contains geographic CRS data.

    • projcrs — Returned by a file that contains projected CRS data.

    Version History

    Introduced in R2023a