<?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 identify all graphics within an area in ArcGIS Runtime SDK for iOS Questions</title>
    <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121057#M1147</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I would like to be able to draw/sketch a polygon on the map and then identify all graphics within that polygon area. The 'identify' functions appear to only take in a single point. &amp;nbsp;Is there a way to identify graphics within a geometry?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 03 Mar 2020 18:20:22 GMT</pubDate>
    <dc:creator>TravisYordi</dc:creator>
    <dc:date>2020-03-03T18:20:22Z</dc:date>
    <item>
      <title>identify all graphics within an area</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121057#M1147</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I would like to be able to draw/sketch a polygon on the map and then identify all graphics within that polygon area. The 'identify' functions appear to only take in a single point. &amp;nbsp;Is there a way to identify graphics within a geometry?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Mar 2020 18:20:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121057#M1147</guid>
      <dc:creator>TravisYordi</dc:creator>
      <dc:date>2020-03-03T18:20:22Z</dc:date>
    </item>
    <item>
      <title>Re: identify all graphics within an area</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121058#M1148</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you want to&amp;nbsp;take a set of &lt;STRONG&gt;AGSGraphics&lt;/STRONG&gt;&amp;nbsp;and see if they&amp;nbsp;are within a polygon, you can use &lt;STRONG&gt;AGSGeometryEngine&lt;/STRONG&gt; and the polygon and filter them out with something like this…&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;func &lt;SPAN class="token function"&gt;filterGraphics&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;graphics&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;AGSGraphic&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; within polygon&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; AGSPolygon&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;-&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;AGSGraphic&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
    &lt;SPAN class="keyword token"&gt;return&lt;/SPAN&gt; graphics&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;filter &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
        &lt;SPAN class="keyword token"&gt;if&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;let&lt;/SPAN&gt; geom &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; $&lt;SPAN class="number token"&gt;0&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;geometry &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
            &lt;SPAN class="keyword token"&gt;return&lt;/SPAN&gt; AGSGeometryEngine&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;geometry&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;geom&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; within&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt; polygon&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
        &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;else&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
            &lt;SPAN class="keyword token"&gt;return&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;false&lt;/SPAN&gt;
        &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;
    &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;
&lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm pretty sure that's what you're after.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm checking because&amp;nbsp;we use &lt;EM&gt;Identify&lt;/EM&gt; to mean a very specific thing in ArcGIS: respond to a user interaction with the map (usually a tap or click) looking to get more information about a feature the user can see in the map. But I don't think that's what you're looking for. If it is, let me know.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 07:01:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121058#M1148</guid>
      <dc:creator>Nicholas-Furness</dc:creator>
      <dc:date>2021-12-11T07:01:16Z</dc:date>
    </item>
    <item>
      <title>Re: identify all graphics within an area</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121059#M1149</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;it's not super fast because I have to give it all of the graphics that are currently on that layer to sift through, but it does work.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Mar 2020 22:34:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121059#M1149</guid>
      <dc:creator>TravisYordi</dc:creator>
      <dc:date>2020-03-03T22:34:14Z</dc:date>
    </item>
    <item>
      <title>Re: identify all graphics within an area</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121060#M1150</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Nick, I un-marked this as correct because I'm not sure this answers my question (unless the answer is no). &amp;nbsp;In your example your function takes a set of graphics to sort through, but this is what I'm looking for a map function to give me if possible. &amp;nbsp;I don't want to have to sort through ALL graphics on the map, I'm looking for a quicker way I guess.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Mar 2020 18:04:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121060#M1150</guid>
      <dc:creator>TravisYordi</dc:creator>
      <dc:date>2020-03-05T18:04:41Z</dc:date>
    </item>
    <item>
      <title>Re: identify all graphics within an area</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121061#M1151</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are they graphics in graphics overlays, or are they features in feature layers? Are their geometries&amp;nbsp;points, lines, or polygons? And how many do you have?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've used the above approach on a few thousand (animated)&amp;nbsp;AGSPoints&amp;nbsp;stored as AGSGraphics&amp;nbsp;testing against an&amp;nbsp;AGSPolygon&amp;nbsp;and it's pretty real-time whether the graphic is in or not on modern hardware.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Mar 2020 18:23:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121061#M1151</guid>
      <dc:creator>Nicholas-Furness</dc:creator>
      <dc:date>2020-03-05T18:23:16Z</dc:date>
    </item>
    <item>
      <title>Re: identify all graphics within an area</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121062#M1152</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;They are point graphics in graphics overlays. &amp;nbsp;There could be a few or many (20k +).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Mar 2020 16:49:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121062#M1152</guid>
      <dc:creator>TravisYordi</dc:creator>
      <dc:date>2020-03-06T16:49:47Z</dc:date>
    </item>
    <item>
      <title>Re: identify all graphics within an area</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121063#M1153</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is the process too slow to be useful to you, or is it impacting the UI? Are you dispatching the work&amp;nbsp;off the main thread?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you can provide a repro case (feel free to DM me) we can look into it. It should be pretty fast.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;One thought is that if you have, say, 20,000 graphics globally but are just searching a small polygon that might include only 20 points, that's a lot of point-in-polygon tests that are unnecessary. You could try first filtering against the polygon's extent (using geometryengine.intersect rather than within might be a bit quicker) and then filtering further to see what's actually in the polygon. But it's hard to know what to suggest without knowing more about the nature of the data so a repro case would really help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Mar 2020 18:16:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121063#M1153</guid>
      <dc:creator>Nicholas-Furness</dc:creator>
      <dc:date>2020-03-06T18:16:33Z</dc:date>
    </item>
    <item>
      <title>Re: identify all graphics within an area</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121064#M1154</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;Travis Yordi wrote:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Nick, I un-marked this as correct because I'm not sure this answers my question (unless the answer is no). &amp;nbsp;In your example your function takes a set of graphics to sort through, but this is what I'm looking for a map function to give me if possible. &amp;nbsp;I don't want to have to sort through ALL graphics on the map, I'm looking for a quicker way I guess.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Also, no, there is no single call against a &lt;STRONG&gt;AGSGraphicsOverlay&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What you could consider is using a &lt;STRONG&gt;AGSFeatureCollectionLayer&lt;/STRONG&gt; and &lt;STRONG&gt;AGSFeatureCollectionTable&lt;/STRONG&gt; instead of an&amp;nbsp;&lt;STRONG&gt;AGSGraphicsOverlay&lt;/STRONG&gt;, and then calling &lt;A href="https://developers.arcgis.com/ios/latest/api-reference/interface_a_g_s_feature_table.html#a43d152517c6ee3fa582d2f741367b7bb"&gt;&lt;STRONG&gt;queryFeatures&lt;/STRONG&gt;&lt;/A&gt; on the &lt;STRONG&gt;AGSeatureCollectionTable&lt;/STRONG&gt;. In the &lt;STRONG&gt;&lt;A href="https://developers.arcgis.com/ios/latest/api-reference/interface_a_g_s_query_parameters.html"&gt;AGSQueryParameters&lt;/A&gt;&lt;/STRONG&gt; you pass to &lt;STRONG&gt;queryFeatures&lt;/STRONG&gt;, set the &lt;STRONG&gt;geometry&lt;/STRONG&gt;&amp;nbsp;to your polygon and set the &lt;STRONG&gt;spatialRelationship&lt;/STRONG&gt; to &lt;STRONG&gt;.intersects&lt;/STRONG&gt;.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Mar 2020 18:24:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identify-all-graphics-within-an-area/m-p/121064#M1154</guid>
      <dc:creator>Nicholas-Furness</dc:creator>
      <dc:date>2020-03-06T18:24:01Z</dc:date>
    </item>
  </channel>
</rss>

