fleaflet / flutter_map

A versatile mapping package for Flutter. Simple and easy to learn, yet completely customizable and configurable, it's the best choice for mapping in your Flutter app.
https://pub.dev/packages/flutter_map
BSD 3-Clause "New" or "Revised" License
2.68k stars 848 forks source link

refactor: migrate tile rendering from widgets to `CustomPainter` #1908

Closed JaffaKetchup closed 5 days ago

JaffaKetchup commented 1 month ago

Superceeds #1853.

ReinisSprogis commented 1 month ago

I did some tests and found that CPU usage reduction is still there. With stack approach i was getting ~60+% CPU usage but with CustomPainter ~20-% flutter run -d chrome --release --web-renderer canvaskit On example folder

master branch chrome-widget-stack-edited

tile-layer-canvas branch

tile-canvas-edited

josxha commented 4 weeks ago

@JaffaKetchup It appears that https://github.com/fleaflet/flutter_map/pull/1907 got merged into this pr instead of master into breakin-changes.