“IBitmapDescriptorFactory is not initialized” error

后端 未结 7 916
小鲜肉
小鲜肉 2021-01-31 13:52

I\'m trying to get a marker with an custom icon in Google Maps Android API v2. I just changed one of the examples Google provides. I added .icon(BitmapDescriptorFactory.fr

7条回答
  •  无人共我
    2021-01-31 14:08

    Call following in onCreate()

    try {
            MapsInitializer.initialize(getApplicationContext());
        } catch (GooglePlayServicesNotAvailableException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }
    

提交回复
热议问题