I plot the globe in 3D, and would like to get the latitude and longtitude of the current mouse position.
I tried to use get(gca,'CurrentPoint'), and I don't know how to map those coordinates to the equivalent latitude and longtitude on the map. I think the camera view has some effect as well.
figure('units','normalized','outerposition',[0 0 1 1]);h=axesm ('globe','Grid', 'on');axis off;base = zeros(180,360); baseref = [1 90 0];geoshow(base,baseref,'FaceColor','white')load coast; % load all the map lines
plotm(lat, long); % plot the world maps
view([90 0 0])
Best Answer