maps: [Android] Image in PointAnnotation can't be shown on Android
To Reproduce Should be starting from 7.0.5 Release
<View style={{height: 30, width: 21, backgroundColor: '#000'}}>
<Image source={require('../../images/map/school.png')} />
</View>
<MapboxGL.Callout title='xxx' />
</MapboxGL.PointAnnotation>
Screenshots


Versions (please complete the following information):
- Platfrom: Android
- Device: Asus Zenfone 5
- OS: Android 6
- SDK Version 28
- React Native Version 0.59
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 5
- Comments: 27 (8 by maintainers)
Workaround is to wrap
<Image/>with<Text/>. Or as @RichardLindhout wrote to use SVG instead. Source: https://github.com/react-native-community/react-native-maps/issues/431#issuecomment-524321467Use like this
Guys did you find the solution on it? if YES please guide.
Still getting this issue with 8.1.0 of @react-native-mapbox-gl/maps
Ty. Having this issue too. Will try this solution.
Still happening indeed
I use this fork https://github.com/RichardLindhout/maps
For me this does not work on Android while it does work on iOS
Can
SymbolLayerwork withcalloutafterPointAnnotationdeprecated?Calloutis needed!!Ok, I think I will use react-native-svg instead of an image for now. That does work!
@winseyli I realized this might be a different issue - for me icons aren’t black boxes, they’re completely invisible.
On your Android emulator, go to the three-dots menu, and navigate to Settings > Advanced > OpenGL ES Renderer. Choose
SwiftShaderand restart the emulator. Does that work?