Я начал использовать MapBox в проекте. Когда я добавляю аннотацию с пользовательскими изображениями, она не центрируется правильно. Он выглядит немного ниже оригинальных контактов. Можно ли изменить центральную точку изображения аннотации?
Как это должно быть:
Как обстоят дела сейчас:
- (MGLAnnotationImage *)mapView:(MGLMapView *)mapView imageForAnnotation:(id <MGLAnnotation>)annotation {
MGLAnnotationImage *annotationImage = [mapView dequeueReusableAnnotationImageWithIdentifier:@"driverPinId"];
if (!annotationImage) {
UIImage *image = [UIImage imageNamed:@"DriverPin"];
annotationImageWithImage:image reuseIdentifier:@"driverPinId"];
}
return annotationImage;
}