简体   繁体   中英

Android Polyline not showing in release apk

I'm creating polyline route with using google directions API, I'm also trying to animate the route line with using MapAnimator from this link

https://github.com/tintinscorpion/Dual-color-Polyline-Animation/blob/master/uberpolylineanimation/src/main/java/com/logicbeanzs/uberpolylineanimation/MapAnimator.java

this looks nice when i debug the app , it animates well, but creatong release apk , no animation and no route line shown totaly

I had the same issue, the only issue was i was using a key for which directions api was not enabled. I solved it by changing api key with followings enables/added.

  1. Billing enabled
  2. Maps SDk for android (to show map)
  3. Directions API (get polyline/routes data)
  4. Places API (if you are using places search or similar)
  5. Release Signing SHA-1 fingerprint (if key is restricted)

Path for file (app\\src\\release\\res\\values\\google_maps_api.xml).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM