Where is UWP MapControl antialiasing property?

Dmitry Boyko 21 Reputation points

I work with UWP MapControl and adding some MapPolylines. And they looks ugly (see pic below)

I assume should be kind of antialiasing property but cannot find it here https://learn.microsoft.com/en-us/uwp/api/windows.ui.xaml.controls.maps.mapcontrol?view=winrt-20348.

Please help and thank you!


var mapPolyline = new MapPolyline();  
var geoPositions = new List<BasicGeoposition>();  
foreach (var vertex in polyLine.Vertex)  
  // add BasicGeopositions...  
mapPolyline.StrokeColor = Colors.Black;  
mapPolyline.StrokeThickness = 1;  
mapPolyline.Path = new Geopath(geoPositions);  
Universal Windows Platform (UWP)
Windows Maps
Windows Maps
A Microsoft app that provides voice navigation and turn-by-turn driving, transit, and walking directions.
253 questions
0 comments No comments
{count} votes

Accepted answer
  1. IoTGirl 2,976 Reputation points Microsoft Employee

    Hi @Dmitry Boyko ,

    We have the following answer for you from a member of the Microsoft Maps team:
    Currently MapPolylines are drawn without antialiasing and there is no setting to change that behavior. Looking at your screenshot, you may be better served by using a custom tile layer. See CustoMapTileDatasource here: https://learn.microsoft.com/en-us/windows/uwp/maps-and-location/overlay-tiled-images You can draw each tile in a callback using whatever method you like including antialiasing. It will also tend to perform better for a large collection of static lines like the topographic contours in your example.


    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Dmitry Boyko 21 Reputation points

    Thank you! I investigated MapTileBitmapRequestedEventArgs Class and sample code. It gives strange X, Y like X 6072 Y 6072. MSDN says: X Gets the X value of the requested tile. Y Gets the Y value of the requested tile.
    Would you mind clarify what those numbers are exactly and how I can associate it with geolocations set of vertices in memory if I want create tile-image only, please? (My polylines set already calculated in geopoints.)
    Thank you very much!

    0 comments No comments