I noticed that the following code doesn't work for SDF images that need to be colored:
final symbol = await mapController?.addSymbol(
SymbolOptions(
geometry: LatLng(latitude, longitude),
iconImage: 'assets/images/winterbolt.png',
iconSize: 0.5,
iconColor: 'red',
)
);
But the following does work and correctly colors the image red:
final bytes = await rootBundle.load('assets/images/winterbolt.png');
final list = bytes.buffer.asUint8List();
await mapController?.addImage('winterbolt', list, true);
// place Symbol
final symbol = await mapController?.addSymbol(
SymbolOptions(
geometry: LatLng(latitude, longitude),
iconImage: 'winterbolt',
iconSize: 0.5,
iconColor: 'red',
),
);
Maybe the solution is just to add a parameter for SDF to addSymbol?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
I noticed that the following code doesn't work for SDF images that need to be colored:
But the following does work and correctly colors the image red:
Maybe the solution is just to add a parameter for SDF to addSymbol?