Hello,
I am trying to show a list of map view with some details in jetpack compose.
for that I am using new Kotlin Maps SDK with following dependencies
implementation(platform("com.esri:arcgis-maps-kotlin-toolkit-bom:200.4.0"))
implementation("com.esri:arcgis-maps-kotlin-toolkit-geoview-compose")
Map View is loading successfully in each list item but when I keep scrolling up and down continuously, it leads to app crash with following error trace.
com.arcgismaps.exceptions.ArcGISExceptionImpl: message=Internal error., additionalMessage=Failed to load OpenGLES, errorCode=18
at com.arcgismaps.exceptions.ArcGISException$Companion.create$arcgis_maps_kotlin_release(ArcGISException.kt:86)
at com.arcgismaps.internal.ErrorFactoryKt.convertToPublic(ErrorFactory.kt:111)
at com.arcgismaps.internal.ErrorFactory.createThrowableFromCoreError(ErrorFactory.kt:59)
at com.arcgismaps.internal.jni.CoreGeoView.nativeDraw(Native Method)
at com.arcgismaps.internal.jni.CoreGeoView.draw(CoreGeoView.java:345)
at com.arcgismaps.mapping.view.GeoView.draw(GeoView.kt:1060)
at com.arcgismaps.mapping.view.GeoView.access$draw(GeoView.kt:100)
at com.arcgismaps.mapping.view.GeoView$RenderingThread.draw(GeoView.kt:1585)
at com.arcgismaps.mapping.view.MapView._init_$lambda$2(MapView.kt:492)
at com.arcgismaps.mapping.view.MapView.$r8$lambda$AhbjJf96hMEBchn4L_38b_w2LPM(Unknown Source:0)
at com.arcgismaps.mapping.view.MapView$$ExternalSyntheticLambda2.drawRequested(Unknown Source:2)
at com.arcgismaps.internal.jni.CoreGeoView.onDrawRequested(CoreGeoView.java:521)
at com.arcgismaps.internal.jni.CoreGeoView.nativePulse(Native Method)
at com.arcgismaps.internal.jni.CoreGeoView.pulse(CoreGeoView.java:651)
at com.arcgismaps.mapping.view.GeoView.pulse(GeoView.kt:1107)
at com.arcgismaps.mapping.view.GeoView.access$pulse(GeoView.kt:100)
at com.arcgismaps.mapping.view.GeoView$RenderingThread.doFrame(GeoView.kt:1939)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1403)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1413)
at android.view.Choreographer.doCallbacks(Choreographer.java:1040)
at android.view.Choreographer.doFrame(Choreographer.java:920)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1388)
at android.os.Handler.handleCallback(Handler.java:942)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loopOnce(Looper.java:240)
at android.os.Looper.loop(Looper.java:351)
at com.arcgismaps.mapping.view.GeoView$RenderingThread.run(GeoView.kt:1665)
Following MapItem composable is used to display as Map in list.
import com.arcgismaps.toolkit.geoviewcompose.MapView
import com.arcgismaps.mapping.ArcGISMap
@Composable
fun MapItem(modifier: Modifier = Modifier) {
val map = remember {
ArcGISMap(BasemapStyle.ArcGISImagery)
}
MapView(
modifier = modifier.fillMaxSize(),
arcGISMap = map
)
}
Kindly help me with this issue.
Solved! Go to Solution.
after upgrading sdk version to 200.5 I didnt face this issue.
implementation(platform("com.esri:arcgis-maps-kotlin-toolkit-bom:200.5.0"))
after upgrading sdk version to 200.5 I didnt face this issue.
implementation(platform("com.esri:arcgis-maps-kotlin-toolkit-bom:200.5.0"))