modrana icon indicating copy to clipboard operation
modrana copied to clipboard

Use bounding box sections when drawing polylines

Open M4rtinK opened this issue 8 years ago • 0 comments

The basic idea is to only draw what's on the screen and ignore everything else. As iterating over all points would not bring much improvement, we should divide polyline into point batches (let's say 100 points big) and record the bounding box for each point batch. Then when drawing he route we would check which bounding boxes intersect with the screen and only draw the visible ones.

This should reduce the number of points being drawn quite a bit, especially when zoomed in on a long route or logging trace.

M4rtinK avatar Jan 19 '17 19:01 M4rtinK