Main Content

intrinsicToWorld

Transform intrinsic to planar world coordinates

Description

example

[xWorld,yWorld] = intrinsicToWorld(R,xIntrinsic,yIntrinsic)returns the planar world coordinates corresponding to intrinsic coordinates (xIntrinsic,yIntrinsic) in map rasterR. If a point is outside the bounds ofR, thenintrinsicToWorldextrapolates thexWorldandyWorldcoordinates.

Examples

collapse all

Import a GeoTIFF image[1]of Boston as an array and aMapCellsReferenceobject. Find the world coordinates of the center of the cell in column3500and row1200of the array.

[Z,R] = readgeoraster('boston.tif'); [xWorld,yWorld] = intrinsicToWorld(R,3500,1200)
xWorld = 7.7580e+05
yWorld = 2.9566e+06

You can reverse the operation by using theworldToIntrinsicfunction.

[xIntrinsic,yIntrinsic] = worldToIntrinsic(R,xWorld,yWorld)
xIntrinsic = 3.5000e+03
yIntrinsic = 1.2000e+03

[1] The data used in this example includes material copyrighted by GeoEye, all rights reserved.

Input Arguments

collapse all

Map raster, specified as aMapCellsReferenceorMapPostingsReferenceobject.

x-coordinates in intrinsic coordinate system, specified as a numeric array.xIntrinsiccoordinates can be outside the bounds of the rasterR.

Data Types:single|double

y-coordinates in intrinsic coordinate system, specified as a numeric array.yIntrinsicis the same size asxIntrinsic.yIntrinsiccoordinates can be outside the bounds of the rasterR.

Data Types:single|double

Output Arguments

collapse all

x-coordinates in the world coordinate system, specified as a numeric array.xWorldis the same size asxIntrinsic. WhenxIntrinsic(k) is outside the bounds ofR,intrinsicToWorldextrapolates thexWorldcoordinate.

Data Types:double

y-coordinates in the world coordinate system, specified as a numeric array.yWorldis the same size asxIntrinsic. WhenyIntrinsic(k) is outside the bounds ofR,intrinsicToWorldextrapolates theyWorldcoordinate.

Data Types:double

版本历史

Introduced in R2013b