Mapping Toolbox | ![]() ![]() |
Make an object a mapped object
Syntax
Background
The Mapping Toolbox identifies displayed objects that have been projected from geographic coordinates by a special structure in that object's UserData
property. Objects created using standard MATLAB display commands lack this structure, and retain the same Cartesian coordinates, regardless of the projection. This function adds the structure that makes an object mapped. The coordinates are unchanged in the process, but will change if the map projection is modified.
Description
makemapped(h) adds a Mapping Toolbox structure to the displayed objects associated with h
. h
can be a handle, vector of handles, or any name string recognized by handlem
. The objects are then considered to be geographic data. Objects extending outside the map frame should first be trimmed to the map frame using trimcart
.
Examples
axesm('miller','geoid',[25 0]) framem plot(humps,'b+-') h = plot(humps,'r+-'); trimcart(h) makemapped(h) setm(gca,'MapProjection','sinusoid')
Remarks
Objects should first be trimmed to the map frame using trimcart
. This avoids problems in taking inverse map projections with out-of-range data.
See Also
trimcart |
Trims graphic objects to the map frame |
handlem |
Returns the graphics handle for identified objects |
cart2grn |
Transforms from projected cartesian coordinates to Greenwich frame |
![]() | majaxis | map legend vector | ![]() |