<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: MapViewTapped invalid location DPI problem in .NET Maps SDK Questions</title>
    <link>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351756#M4132</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you,&amp;nbsp;is there some workaround? With pixel to coordinates ratio and real click point?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 24 Aug 2016 10:46:55 GMT</pubDate>
    <dc:creator>AlexKost</dc:creator>
    <dc:date>2016-08-24T10:46:55Z</dc:date>
    <item>
      <title>MapViewTapped invalid location DPI problem</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351754#M4130</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, I'am using ArcGIS &amp;nbsp;SDK for .NET&amp;nbsp;10.2.7.0 and creating "modern" store app (Store API) for Windows 8.1. &amp;nbsp;I have problem with DPI changes. On some monitors (Full HD, 24 inch, 100% scaling in Windows 10) returns&amp;nbsp;MapViewTapped event correct location, but on some monitors (Full HD, 15 inch, 150% scaling) returns wrong location (several cm from correct position on Map).&lt;/P&gt;&lt;DIV class="" style="color: #777777; background-color: #ffffff; font-size: 13px;"&gt;&lt;DIV style="margin-left: 4px;"&gt;&lt;DIV&gt;&lt;DIV style="background: whitesmoke; border: 1px solid whitesmoke; margin: 0px 0px 8px;"&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Aug 2016 09:46:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351754#M4130</guid>
      <dc:creator>AlexKost</dc:creator>
      <dc:date>2016-08-24T09:46:58Z</dc:date>
    </item>
    <item>
      <title>Re: MapViewTapped invalid location DPI problem</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351755#M4131</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unfortunately this is a bug in Windows 10&amp;nbsp;when running Windows Store&amp;nbsp;8.1&amp;nbsp;apps in different DPI settings. We have submitted support case&amp;nbsp;to Microsoft for it. I'll have a look if we have update for this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Aug 2016 09:59:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351755#M4131</guid>
      <dc:creator>AnttiKajanus1</dc:creator>
      <dc:date>2016-08-24T09:59:04Z</dc:date>
    </item>
    <item>
      <title>Re: MapViewTapped invalid location DPI problem</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351756#M4132</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you,&amp;nbsp;is there some workaround? With pixel to coordinates ratio and real click point?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Aug 2016 10:46:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351756#M4132</guid>
      <dc:creator>AlexKost</dc:creator>
      <dc:date>2016-08-24T10:46:55Z</dc:date>
    </item>
    <item>
      <title>Re: MapViewTapped invalid location DPI problem</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351757#M4133</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I found some workaround:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;public async void OnMapTouch(object sender, MapViewInputEventArgs e)&lt;BR /&gt; {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;MapView view = sender as MapView;&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;MapPoint mapPoint = e.Location; //clicked coordinate, not works on some DPI/DPI changes&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;double unitPerPx = view.UnitsPerPixel; //not works on some DPI/DPI changes&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;double unitPerPx_real = view.Extent.Width / view.ActualWidth; //it seems to works&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;double x_offset = e.Position.X * unitPerPx_real;&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;double y_offset = e.Position.Y * unitPerPx_real;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;Viewpoint viewpoint = view.GetCurrentViewpoint(ViewpointType.BoundingGeometry);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;double x = viewpoint.TargetGeometry.Extent.XMin + x_offset; //x coordinate,&amp;nbsp;&lt;SPAN&gt;seems to works&lt;/SPAN&gt;&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;double y = viewpoint.TargetGeometry.Extent.YMax - y_offset; //y coordinate,&amp;nbsp;&lt;SPAN&gt;seems to works&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Update:&lt;/P&gt;&lt;P&gt;But other functions, as&amp;nbsp;mapView.Editor.RequestShapeAsync not works &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/sad.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Aug 2016 11:24:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351757#M4133</guid>
      <dc:creator>AlexKost</dc:creator>
      <dc:date>2016-08-24T11:24:48Z</dc:date>
    </item>
    <item>
      <title>Re: MapViewTapped invalid location DPI problem</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351758#M4134</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just an idea what to test. You could&amp;nbsp;override editor progress and fix the geometry in the event.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Aug 2016 11:59:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351758#M4134</guid>
      <dc:creator>AnttiKajanus1</dc:creator>
      <dc:date>2016-08-24T11:59:51Z</dc:date>
    </item>
    <item>
      <title>Re: MapViewTapped invalid location DPI problem</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351759#M4135</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I tried this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;var progress = new Progress&amp;lt;GeometryEditStatus&amp;gt;((status) =&amp;gt;&lt;BR /&gt; {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;/&amp;nbsp;/never called&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;Esri.ArcGISRuntime.Geometry.Geometry newGeometry = await mapView.Editor.RequestShapeAsync(Esri.ArcGISRuntime.Controls.DrawShape.LineSegment, null, progress);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But progress delegate is never invoked during drawing &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/sad.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Aug 2016 13:17:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351759#M4135</guid>
      <dc:creator>AlexKost</dc:creator>
      <dc:date>2016-08-24T13:17:59Z</dc:date>
    </item>
    <item>
      <title>Re: MapViewTapped invalid location DPI problem</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351760#M4136</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ah, line segments doesn't have events since it's only one action. Ie. Polygons would raise the event. I take that the only way to fix LineSegment is to iterate through the Points collection and fix all the points. Not very convenient but might do the trick.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Aug 2016 13:27:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351760#M4136</guid>
      <dc:creator>AnttiKajanus1</dc:creator>
      <dc:date>2016-08-24T13:27:41Z</dc:date>
    </item>
    <item>
      <title>Re: MapViewTapped invalid location DPI problem</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351761#M4137</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you,&amp;nbsp;I solved it by own drawing to Canvas and pixel -&amp;gt; coordinates workaround from former post.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Aug 2016 16:47:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/mapviewtapped-invalid-location-dpi-problem/m-p/351761#M4137</guid>
      <dc:creator>AlexKost</dc:creator>
      <dc:date>2016-08-24T16:47:59Z</dc:date>
    </item>
  </channel>
</rss>

