我正在使用 Skobbler SDK 2.3.0,针对 Lollipop,在 Nexus 5 和 Galaxy S4 上进行测试,在 Android Studio 1.0.2 上构建。
我有一个带有导航抽屉和片段的 MainActivity。我在 MainActivity 中初始化 Skobbler 并加载显示地图的片段。但是,我只得到一个黑屏,右下角有水印“由 Scout OSM 提供支持”。单击和双击已注册,但如果我捏缩放应用程序崩溃。
在应用程序崩溃之前,我没有在 logcat 中看到任何错误。任何人都可以帮忙吗?
项目结构:
- 应用程序/库/SKMaps.jar
- 应用程序/src/main/assets/SKMaps.zip
- app/src/main/jniLibs/armeabi/libngnative.so
- 应用程序/src/main/jniLibs/armeabi-v7a/libngnative.so
- app/src/main/jniLibs/x86/libngnative.so
构建等级:
dependencies {
...
...
compile files('libs/SKMaps.jar')
}
日志猫
01-05 22:58:42.835 26785-26785/com.example.android I/MainActivity﹕ onCreate
01-05 22:58:42.869 26785-26785/com.example.android I/System.out﹕ Item selected in navigation drawer
01-05 22:58:42.895 26785-26785/com.example.android I/MainActivity﹕ Adding login fragment
01-05 22:58:42.895 26785-26785/com.example.android I/MainActivity﹕ Done
01-05 22:58:42.895 26785-26785/com.example.android I/MainActivity﹕ Initialising Skobbler
01-05 22:58:42.899 26785-26785/com.example.android I/MainActivity﹕ Start initializeLibrary()
01-05 22:58:42.899 26785-26785/com.example.android D/SKMaps﹕ SKMapInitSettings---- Map style [/storage/emulated/0/Android/data/com.example.android/files/SKMaps/daystyle/ , daystyle.json ,-1]
01-05 22:58:42.899 26785-26785/com.example.android D/SKMaps﹕ SKVersionManager----setMapUpdateListener - com.example.android.MainActivity@1c8a98bc
01-05 22:58:42.899 26785-26785/com.example.android I/MainActivity﹕ End initializeLibrary()
01-05 22:58:42.899 26785-26785/com.example.android I/MainActivity﹕ Skobbler initialised
01-05 22:58:42.899 26785-26785/com.example.android I/MainActivity﹕ onCreate end
...
01-05 22:58:55.790 26785-26785/com.example.android D/SKMaps﹕ SKMapSurfaceView----SKMapSurfaceView constructor
01-05 22:58:55.790 26785-26785/com.example.android D/SKMaps﹕ SKMapSurfaceView----os model Nexus 5
01-05 22:58:55.797 26785-26785/com.example.android D/SKMaps﹕ MapRenderer----Set map density 3.0
01-05 22:58:55.800 26785-26785/com.example.android D/SKMaps﹕ SKMapSurfaceView---- ON PAUSE
01-05 22:58:55.803 26785-26785/com.example.android D/SKMaps﹕ SKMapSurfaceView----Saved map cache state [ Map Region zoom=17.0 center= [13.385000228881836,52.51665115356445]] [Display mode=MODE_2D] [Follower mode=NONE] [Compass shown=false Position = [0.0 ,0.0] ] [Rotation=true ] [Panning=true][Zooming=true] [Bearing=0.0] [Annotations=0]
01-05 22:58:55.811 26785-26785/com.example.android E/BitmapFactory﹕ Unable to decode stream: java.io.FileNotFoundException: null/res/xhdpi/icon_map_popup_navigate.png: open failed: ENOENT (No such file or directory)
01-05 22:58:55.813 26785-26785/com.example.android E/BitmapFactory﹕ Unable to decode stream: java.io.FileNotFoundException: null/res/xhdpi/icon_map_popup_arrow.png: open failed: ENOENT (No such file or directory)
01-05 22:58:55.822 26785-26785/com.example.android D/SKMaps﹕ SKMapSurfaceView---- centerMapOnPosition [19.8171,41.3294]