I am trying to achieve a custom marker with text right now. Something like this. 
and I am following this tutorial.
As far as the progress goes, the markers are not appearing on the Map yet. Could you please check my code and tell me where I go wrong? Thank you.
class TestMapView extends StatefulWidget {
final NayyaaPropertyModel? propertyModel;
const TestMapView({Key? key, this.propertyModel}) : super(key: key);
@override
_TestMapViewState createState() => _TestMapViewState();
}
class _TestMapViewState extends State<TestMapView> {
GoogleMapController? mapController;
List<NayyaaPropertyModel> nayyaaProperty = [];
List<Marker> customMarkers = [];
@override
void initState() {
MarkerGenerator(markerWidgets(), (bitmaps) {
setState(() {
mapBitmapsToMarkers(bitmaps);
});
}).generate(context);
}
List<MapMarker> markerWidgets() {
return nayyaaProperty.map((l) => MapMarker(l)).toList();
}
List<Marker>? mapBitmapsToMarkers(List<Uint8List> bitmaps) {
bitmaps.asMap().forEach((i, bmp) async {
final value = await FirebaseFirestore.instance
.collection('properties')
.doc('GeoHash')
.get();
final data = value.data();
final _latPoint = data!['geopoint'];
final _lngPoint = data['geopoint'];
var _marker = Marker(
markerId: MarkerId("$i"),
position: LatLng(_latPoint.latitude, _lngPoint.longitude),
icon: BitmapDescriptor.fromBytes(bmp),
);
setState(() {
customMarkers.add(_marker);
});
});
}
void _onMapCreated(GoogleMapController controller) {
mapController = controller;
}
@override
Widget build(BuildContext context) {
return Scaffold(
body: GoogleMap(
markers: customMarkers.toSet(),
onMapCreated: _onMapCreated,
initialCameraPosition: const CameraPosition(
target: LatLng(16.871311, 96.199379), zoom: 10)));
}
}