Hi Offer,
The InMemoryFeatureLayer is the best choice I think, and we have some sample shows the scenario in our wiki or Product Center ( the samples named: Dynamic Marker Overlay, How Do I [Dynamic Shapes–>efficiently move a plane image] ), but i guess they not suitable for you, because they did not use too many feature.
Here are some point you can try:
A. We need to determine if too much time is spent in the process of update feature, please try the follow code snippets:
StopWatch sw = new Stopwatch();
sw.Start();
inMemoryFeatureLayer.Open();
inMemoryFeatureLayer.EditTools.BeginTransaction();
for 0 => 1000:
inMemoryFeatureLayer.EditTools.Update(pointShape);
inMemoryFeatureLayer.EditTools.CommitTransaction();
inMemoryFeatureLayer.Close();
sw.Stop();
if it takes too much time, we can create a new InMemoryFeatureLayer instead of update, please follow the code below:
inMemoryFeatureLayer.Open();
var allFeatures = inMemoryFeatureLayer.FeatureSource.GetAllFeatures(ReturningColumnsType.AllColumns);
for 0=>1000
allFeatures[i].ColumnValues["Status"] = "xxx";
InMemoryFeatureLayer newInMemoryFeatureLayer = new InMemoryFeatureLayer(layer.GetColumns(), allFeatures);
newInMemoryFeatureLayer.ZoomLevelSet.ZoomLevel01.CustomStyles.Add(xxxStyle);
newInMemoryFeatureLayer.ZoomLevelSet.ZoomLevel01.ApplyUntilZoomLevel = ApplyUntilZoomLevel.Level20;
By the way, the update process takes time is 50ms in my side.
B. If the update content is relatively fixed, I think we can use cache to improved performance.
C. I guess use the vector symbol point style can improve performance, please have a try with the following PointStyles:
PointStyles.CreateSimplePointStyle(PointSymbolType.Triangle,GeoColor.SimpleColors.Black, GeoColor.SimpleColors.Blue, 1, 20);
PointStyles.CreateSimplePointStyle(PointSymbolType.Cross, GeoColor.SimpleColors.Black, GeoColor.SimpleColors.Blue, 1, 20);
I guess we can create some custom symbol point style for your requirement, if necessary, please contact your sales for details
Attached is the sample Shows the tests I did, please check it out, and let me know whether it restore your scene very well. if not, please sharing more information, or upload a simple project to show us that and we can work based on it.
Wpf_InMemoryFeatureLayerPerformanceSample.zip (12.6 KB)
Thanks,
Emil