Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Option to disable smooth animation of compass and accuracy values #13574

Merged
merged 1 commit into from
Dec 14, 2018

Conversation

LukasPaczos
Copy link
Member

@LukasPaczos LukasPaczos commented Dec 13, 2018

Since smooth animation in the LocationComponent can have a significant battery impact this PR adds an option to disable the smooth animation of the compass and accuracy values.

ezgif com-video-to-gif 28

Option to disable location tracking animation is tracked in https://github.com/mapbox/mapbox-gl-native/issues/13225.

A note, that disabling smooth compass animation during scenarios where that'd be the only running animation can decrease CPU usage by a significant amount - from a constant ~20% CPU usage to ~8% CPU usage spikes (benchmarked on a Pixel 2 XL) every ~500ms because we are not redrawing the map constantly.

/cc @BharathMG

@LukasPaczos LukasPaczos added the Android Mapbox Maps SDK for Android label Dec 13, 2018
@LukasPaczos LukasPaczos added this to the android-v6.8.0 milestone Dec 13, 2018
Copy link
Member

@tobrun tobrun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@LukasPaczos LukasPaczos force-pushed the lp-disable-compass-accuracy-animation branch from 1091f3a to 09a450f Compare December 13, 2018 18:44
Copy link
Contributor

@danesfeder danesfeder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@LukasPaczos great work 🚢

@LukasPaczos LukasPaczos force-pushed the lp-disable-compass-accuracy-animation branch from 09a450f to 2f85d81 Compare December 13, 2018 18:54
@LukasPaczos LukasPaczos merged commit 9064c8e into master Dec 14, 2018
@LukasPaczos LukasPaczos deleted the lp-disable-compass-accuracy-animation branch December 14, 2018 09:26
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Android Mapbox Maps SDK for Android
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants