I’m loading in a bunch of points (little over 4000) from a spatial table in a ms sql database. I noticed it takes a bit of time to display on the map. Is there a way to increase performance of doing this? Relevant code is below:
I don’t think you need to display thousands points at the same time, because that will looks bad.
I think you can do something to solve this problem:
Create index file for your data source
Open cache if your render style won’t always get refresh
Show correct shapes in specified extent, that means you can modify the render logic to avoid show too many points at the same time. You can view our code for old WorldMapKit, it render so many shapes and the speed still be fast. You can find the project here now: https://github.com/ThinkGeo/WorldStreetsLayerSDKOnWindows-ForWinForms
Tried creating an index file with the BuildIndex function on the sqlLayer, but that just made my map appear blank.
Maybe you could help me get this cache working properly, I’m sort of confused how it works. I followed the example in the “HowDoI” project by doing this:
But I didn’t notice a difference and didn’t see anything being placed in the “SampleCacheTiles” folder when the map was loaded. I’m not positive but I think all the points do need to be shown, but I will double check.
I tested the mssql.BuildIndex(BuildIndexMode.DoNotRebuild); works well in my test sample.
For cache, please comment this line: bitmapTileCache.TileAccessMode = TileAccessMode.ReadOnly; Which means your application only read existing cache but not generate cache images, that’ not suitable for your scenario.