Documentation

This is machine translation

Translated by Microsoft
Mouse over text to see original. Click the button below to return to the English verison of the page.

camtargm

Set camera target using geographic coordinates

Syntax

camtargm(lat,long,alt)
[x,y,z] = camtargm(lat,long,alt)

Description

camtargm(lat,long,alt) sets the axes CameraTarget property of the current map axes to the position specified in geographic coordinates. The inputs lat and long are assumed to be in the angle units of the current map axes.

[x,y,z] = camtargm(lat,long,alt) returns the camera target in the projected Cartesian coordinate system.

Examples

Look down the spine of the Andes from a location three Earth radii above the surface:

figure
axesm('globe','galt',0)
gridm('glinestyle','-')
load topo
geoshow(topo,topolegend,'DisplayType','texturemap');
demcmap(topo)
lightm(-80,-180); 
material(0.6*[ 1 1 1])
plat = 10; plon = -65; 
tlat = -30; tlon = -70;
camtargm(tlat,tlon,0); 
camposm(plat,plon,3);
camupm(tlat,tlon); 
camva(20)
set(gca,'CameraViewAngle',30)
land = shaperead('landareas.shp','UseGeoCoords',true)
linem([land.Lat],[land.Lon])
axis off

See Also

| | |

Introduced before R2006a

Was this topic helpful?