[SOLVED] Display a large amount of MapQuickItem (MapPolyline QML) on a QML Map
In the context of a company project, I need to display a large network with mostly points and lines on a map. Every items need to be displayed at the same time on QML Map. My idea is to use the QML map module. However, there is more than a million of lines and points to display. How can I manage properly the performances ? Is there any better option than MapPolyline QML for the lines or better way to use it ? Is there any other way to create an overlay with MapQuickItem ?
However, there is more than a million of lines and points to display. How can I manage properly the performances ?
You need to make sure only to add the items currently really need to be visible for the given geo rect and zoom level.
Adding all items at once would be definitely the worst idea.
Thanks for the quick answer @raven-worx. Therefore if want to see all the lines/points at once, it is impossible to have good performances ? Should I go toward another tech ?
Therefore if want to see all the lines/points at once, it is impossible to have good performances ? Should I go toward another tech ?
i doubt you will have success with this approach in any other framework (unless it is designed for this specific case).
- showing millions of items on a map is highly waste of memory/performance, since a large amount of items are simply overlapping anyway and result in the same drawn pixel on the screen
- many maps group/combine nearby items ... depending what you want to achieve in the end
- you will need to group/store your items efficiently which enables you to search in the big amount of data quickly. (B-tree, etc...) There is a lot of material on the web (mostly related to navigation in maps) which are applicable for you
you will need to group/s
Okay I understand, thanks.