Mapping Toolbox | ![]() ![]() |
Lights
The lightm
Mapping Toolbox command creates light objects in the current map. However, to change the location of the mapped light object you have to transform the position data from geographic and projected coordinates. The lightmui tool
creates a new map and then plots the location of light objects in the map, allowing you to interactively change the position of lights in a map. . The lights are plotted as circular markers whose facecolor indicates the light color. To change the position of a light, click and drag the circular marker. In addition, alternate (right) clicking on the circular marker creates a dialog box to change the position or color of the light object. Clicking on the push button invokes the uisetcolor
dialog box that can be used to change the light color.
As an example, create a topographic map and add a local light at a distance of 250 km above New York City, (40.75 °N, 73.9 °W). Change the material and lighting properties, then activate the lightmui
tool.
load topo; figure('Color','w'); axesm globe; view(30,30) meshm(topo,topolegend); demcmap(topo) lightm(40.75,-73.9, 250/6371,'color','yellow', 'style', 'local') material([0.7270 1.5353 1.9860 4.0000 0.9925]); lighting phong; hidem(gca) lightmui(gca)
Click and drag the control to the eastern tip of Brazil.
Alternate click on the control to display the change dialog box. Change the color of the light to cyan ([0 1 1]).
![]() | Colormap and Colorbars | Printing Maps | ![]() |