This content has been marked as final. Show 4 replies
I know that graphics rendering has improved in v3.0. You can probably try Pre-Release. Another option is to probably use ArcGISDynamicMapServiceLayer with LayerDefinition (for query parameters), this will draw the features at once.
Only thing you can do to achieve this is to use a DispatcherTimer to trigger an add for X features every Y seconds.
I am not sure it would work in your case, but could you pattern the query after the ClipFeatures Geoprocessing Sample?
Depending on the line the user creates, more than 1000 polygons may be buffered and clipped. To help with the wait time there is a processing... message that appears in the dialog. And to help with the larger number of polygon features to be returned, instead of returning a feature set, a gp map image gets returned if the number of polygons exceeds 500. Which could shorten the wait time.
The performance with an ArcGISDynamicMapServiceLayer with query parameters is indeed faster. I did a quick prototype to prove this, but unfortunately would have meant too many changes to the application.
Tried a BackgroundWorker with Dispatcher.Invoke() to add 100 graphics at a time, but the wait time between chunks needed to be too long to let the graphics draw, so it took much, much longer than the original method.
Sometimes the simplest solutions are best. We ended up displaying an progress bar while the graphics were drawing. Also, as the polygons were been fetched via a QueryTask, we do some other UI tasks (Open a data table with some results).
This seems to have reduced the perceived time.
Thanks to all for your help.