mapbox / mapbox-plugins-android

Mapbox Android Plugins are a collection of libraries that extend our other SDKs, helping you design powerful mapping features while the plugins handle most of the heavy lifting.
https://www.mapbox.com/android-docs/plugins/overview/
BSD 2-Clause "Simplified" License
241 stars 120 forks source link

Should `MarkerViewManager` implement a more 'reactive' camera listener ? #1115

Open xseignard opened 4 years ago

xseignard commented 4 years ago

Hello, The MarkerViewManager implements the MapView.OnCameraDidChangeListener so updating a MarkerView is only updated after the camera did change, and not while the camera is changing.

The consequence of that is some sluggish MarkerView re-positioning after a camera move, as shown here: sluggish

I tried replacing MapView.OnCameraDidChangeListener by MapView.OnCameraIsChangeingListener and had no more updates ?!

I then tried using MapboxMap.OnCameraMoveListener with better results: okish https://imgur.com/ZNweZfQ

GPU usage is a tad high, that's why I'm not sending a PR.

Should MarkerViewManager implements a more 'reactive' camera listener ?

PS: on the above gifs, I'm using react-native with:

xseignard commented 4 years ago

Hi there! Any update ?

mfazekas commented 3 years ago

Seems to be fixed by https://github.com/mapbox/mapbox-plugins-android/pull/1165