I am plotting a map using geoshow then I mask out the oceans. For it to look right on the screen I set the renderer to opengl.
Looks exactly the way I want it to look. BUT, when I save it to jpeg the dots over the ocean that do not show on the screen (I masked out the oceans) show in the jpeg, even when I print with the option -opengl.
If I print as eps, everything looks fine. I could add a step and converting the eps to jpeg outside Matlab, but that is not a Matlab solution, so I wonder if anyone has a suggestion.
I have Matlab 2009a installed in a MAC OSX (10.5.8). Below I reproduce part of my code...
geoshow(llats,llons,'DisplayType', 'point','Marker', 'o', 'MarkerFaceColor', 'k', 'MarkerEdgeColor','k', 'MarkerSize', 2)
geoshow(flipud(y'),flipud(x'),'DisplayType','polygon','FaceColor','white') %the mask
print('test.jpeg','-djpeg', '-r300', '-opengl')
Any help would be greatly appreciated,